简体   繁体   English

make: *** 没有规则可以制作目标 'qt5py3'。 停止

[英]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)并使用以下步骤解决。

  1. Unzip the labelImg downloaded from here , cd labelImg-master解压从这里下载的labelImg, cd labelImg-master
  2. brew install qt qt5 brew install libxml2 brew install pyqt5

  3. make qt5py3

  4. python3 labelImg.py

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/labelImghttps://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.

相关问题 MacOS:make pycaffe给出“没有目标的规则” - MacOS: make pycaffe gives “no rule to make target” 没有将目标设为libpython2.6.a的规则 - No rule to make target `libpython2.6.a' 如何让 Discord bot 在 discord py 中发送垃圾邮件时停止发送垃圾邮件 - how to make a discord bot stop spamming when it is spamming in discord py 构建Python 2.7.2失败,并显示“没有规则可以使目标'Parser / printgrammar.o'” - Building Python 2.7.2 fails with “No rule to make target ‘Parser/printgrammar.o’” vtk build mac os x 10.10,没有规则来制作目标'... libpython2.7.dylib' - vtk build mac os x 10.10 , no rule to make target '…libpython2.7.dylib' 制作一个将运行.py的按钮 - make a button that will run .py 运行 make -f hello.py 时出现错误。 它说“hello.py:1: *** 缺少分隔符。停止。” - I'm getting an error when running make -f hello.py. It says " hello.py:1: *** missing separator. Stop. " Discord-py 当用户打字时,如何让机器人跟随打字,当用户停止时,机器人也停止在特定频道打字? - Discord-py When a user is typing, how to make the bot to follow the typing and when the user stop, the bot also stop typing in a specific channel? 一旦达到目标,如何使我的递归算法停止? - How do I make my recursive algorithm to stop once the target is reached? 如何制定资产记录规则? - how to make record rule for asset?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM