提交 36b5c0da 编写于 作者: W WenmuZhou

update readme and requirements.txt

上级 3b9c7b82
...@@ -49,7 +49,7 @@ python3 PPOCRLabel.py ...@@ -49,7 +49,7 @@ python3 PPOCRLabel.py
``` ```
pip3 install pyqt5 pip3 install pyqt5
pip3 uninstall opencv-python # Uninstall opencv manually as it conflicts with pyqt pip3 uninstall opencv-python # Uninstall opencv manually as it conflicts with pyqt
pip3 install opencv-contrib-python-headless # Install the headless version of opencv pip3 install opencv-contrib-python-headless==4.2.0.32 # Install the headless version of opencv
cd ./PPOCRLabel # Change the directory to the PPOCRLabel folder cd ./PPOCRLabel # Change the directory to the PPOCRLabel folder
python3 PPOCRLabel.py python3 PPOCRLabel.py
``` ```
...@@ -160,9 +160,9 @@ For some data that are difficult to recognize, the recognition results will not ...@@ -160,9 +160,9 @@ For some data that are difficult to recognize, the recognition results will not
``` ```
pyrcc5 -o libs/resources.py resources.qrc pyrcc5 -o libs/resources.py resources.qrc
``` ```
- If you get an error ``` module 'cv2' has no attribute 'INTER_NEAREST'```, you need to delete all opencv related packages first, and then reinstall the headless version of opencv - If you get an error ``` module 'cv2' has no attribute 'INTER_NEAREST'```, you need to delete all opencv related packages first, and then reinstall the 4.2.0.32 version of headless opencv
``` ```
pip install opencv-contrib-python-headless pip install opencv-contrib-python-headless==4.2.0.32
``` ```
### Related ### Related
......
...@@ -49,7 +49,7 @@ python3 PPOCRLabel.py --lang ch ...@@ -49,7 +49,7 @@ python3 PPOCRLabel.py --lang ch
``` ```
pip3 install pyqt5 pip3 install pyqt5
pip3 uninstall opencv-python # 由于mac版本的opencv与pyqt有冲突,需先手动卸载opencv pip3 uninstall opencv-python # 由于mac版本的opencv与pyqt有冲突,需先手动卸载opencv
pip3 install opencv-contrib-python-headless # 安装headless版本的open-cv pip3 install opencv-contrib-python-headless==4.2.0.32 # 安装headless版本的open-cv
cd ./PPOCRLabel # 将目录切换到PPOCRLabel文件夹下 cd ./PPOCRLabel # 将目录切换到PPOCRLabel文件夹下
python3 PPOCRLabel.py --lang ch python3 PPOCRLabel.py --lang ch
``` ```
...@@ -145,9 +145,9 @@ PPOCRLabel支持三种保存方式: ...@@ -145,9 +145,9 @@ PPOCRLabel支持三种保存方式:
pyrcc5 -o libs/resources.py resources.qrc pyrcc5 -o libs/resources.py resources.qrc
``` ```
- 如果出现``` module 'cv2' has no attribute 'INTER_NEAREST'```错误,需要首先删除所有opencv相关包,然后重新安装headless版本的opencv - 如果出现``` module 'cv2' has no attribute 'INTER_NEAREST'```错误,需要首先删除所有opencv相关包,然后重新安装4.2.0.32版本的headless opencv
``` ```
pip install opencv-contrib-python-headless pip install opencv-contrib-python-headless==4.2.0.32
``` ```
### 参考资料 ### 参考资料
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册