[英]make: *** No rule to make target 'qt5py3'. Stop
I'm working on a machine learning assignment.我正在做机器学习作业。 By the when I was trying to install the following file
当我尝试安装以下文件时
brew install qt qt5
brew install libxml2
make qt5py3
python labelImg.py
python labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
at make qt5py3 the output from terminal is make: *** No rule to make target 'qt5py3'.在 make qt5py3 终端的输出是 make: *** No rule to make target 'qt5py3'。 Stop
停止
I'm using OsX high sierra with default terminal Does anyone know just what's happened?我正在使用带有默认终端的 OsX high sierra 有谁知道发生了什么?
To get the labelImg package (from the link you gave) working on OSX High Sierra, I needed to do the following.要获得在 OSX High Sierra 上运行的 labelImg 包(来自您提供的链接),我需要执行以下操作。
First installed the missing lxml dependency using the solution in this answer首先使用此答案中的解决方案安装缺少的 lxml 依赖项
Also还有
brew install qt qt5
brew install libxml2
brew install pyqt5
After installing pyqt5, ensure that pyrcc5 can be run from the command line.安装pyqt5后,确保可以从命令行运行pyrcc5。
Download and unzip the labelImg .zip file from the link, and cd into the unzipped folder .从链接下载并解压缩 labelImg .zip 文件,然后cd 到解压缩的文件夹中。 Then
然后
make qt5py3
When trying to run, I found it necessary to simplify the libs/usty.py file to remove the PyQt4 dependency.在尝试运行时,我发现有必要简化 libs/usty.py 文件以删除 PyQt4 依赖项。 I just changed it to:
我只是将其更改为:
import sys
def ustr(x):
return x
At this point I can run the program with此时我可以运行程序
python labelImg.py
Hope this is useful.希望这是有用的。
For me, I have occurred the same problem (MacOS version 10.13.4 and python 3.7) and solved using below steps.对我来说,我遇到了同样的问题(MacOS 版本 10.13.4 和 python 3.7)并使用以下步骤解决。
you should download the project from github and enter the folder where file "makefile" is in,你应该从github下载项目并进入文件“makefile”所在的文件夹,
then run make qt5py3然后运行 make qt5py3
Came across this post (and maybe 30 others) while trying to install labelImg.在尝试安装 labelImg 时遇到了这篇文章(可能还有其他 30 篇文章)。
This gentleman's solution (from the beginning) finally allowed me to get started:这位先生的解决方案(从一开始)终于让我开始了:
First, install Mini Conda ( https://conda.io/docs/user-guide/install/macos.html ), and open a new terminal window.首先,安装 Mini Conda ( https://conda.io/docs/user-guide/install/macos.html ),并打开一个新的终端窗口。
cd labelImg
conda create -n py2 python=2.7
source activate py2
conda install pyqt=4
conda install libxml2
conda install lxml
make qt4py2
python labelImg.py
https://gist.github.com/plopd/487f2caf2f983abc990987b97a8a734b https://gist.github.com/plopd/487f2caf2f983abc990987b97a8a734b
brew install qt qt5
酿造安装qt qt5
downloaded and extracted zip file from https://github.com/tzutalin/labelImg从https://github.com/tzutalin/labelImg下载并提取 zip 文件
make qt5py3 after running this command i got an error stating "No module found pyqt5";
运行此命令后使 qt5py3 出现错误,指出“未找到模块 pyqt5”;
pip install pyqt5
pip 安装 pyqt5
run跑
python labelImg.py
蟒蛇标签Img.py
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.