当前位置: 首页 > news >正文

博物馆网站建设方案书wordpress 如果存在则

博物馆网站建设方案书,wordpress 如果存在则,网站建站工具,西宁网站建设维护在riscv编译安装飞桨PaddlePaddle参见#xff1a; 算能RISC-V通用云编译飞桨paddlepaddleopenKylin留档_在riscv下进行paddlelite源码编译-CSDN博客 安装好飞桨#xff0c;就可以用飞桨进行推理了。刚开始计划用ONNX推理#xff0c;但是在算能云没有装上#xff0c;所以最…在riscv编译安装飞桨PaddlePaddle参见 算能RISC-V通用云编译飞桨paddlepaddleopenKylin留档_在riscv下进行paddlelite源码编译-CSDN博客 安装好飞桨就可以用飞桨进行推理了。刚开始计划用ONNX推理但是在算能云没有装上所以最终是用的飞桨推理。但是还是用到了Paddle2ONNX里的代码。 下载Paddle2ONNX源代码 git clone https://github.com/PaddlePaddle/Paddle2ONNX ocr文字识别 下面是使用ONNX进行推理的示例我没有弄成希望有成功的朋友交流下经验。 安装需要的库 pip install shapely pyclipper 如果在riscv系统无法编译安装shapely那么可以先安装包 apt install libgeos-dev 下载相关模型文件 cd Paddle2ONNX/model_zoo/ocr# 下载det模型 wget https://bj.bcebos.com/paddle2onnx/model_zoo/ch_PP-OCRv2_det_infer.onnx# 下载rec模型 wget https://bj.bcebos.com/paddle2onnx/model_zoo/ch_PP-OCRv2_rec_infer.onnx# 下载cls模型 wget https://bj.bcebos.com/paddle2onnx/model_zoo/ch_ppocr_mobile_v2.0_cls_infer.onnx 进行识别 python3 infer.py \ --det_model_dir./ch_PP-OCRv2_det_infer.onnx \ --rec_model_dir./ch_PP-OCRv2_rec_infer.onnx \ --cls_model_dir./ch_ppocr_mobile_v2.0_cls_infer.onnx \ --image_path./images/lite_demo.png 使用飞桨推理进行文字识别 这个推理成功了。 下载和解压模型 wget -nc -P ./inference https://bj.bcebos.com/paddle2onnx/model_zoo/ch_PP-OCRv2_det_infer.tar cd ./inference tar xf ch_PP-OCRv2_det_infer.tar cd ..wget -nc -P ./inference https://bj.bcebos.com/paddle2onnx/model_zoo/ch_PP-OCRv2_rec_infer.tar cd ./inference tar xf ch_PP-OCRv2_rec_infer.tar cd ..wget -nc -P ./inference https://bj.bcebos.com/paddle2onnx/model_zoo/ch_ppocr_mobile_v2.0_cls_infer.tar cd ./inference tar xf ch_ppocr_mobile_v2.0_cls_infer.tar cd ..进行文字识别 python3 infer.py \ --cls_model_dir./inference/ch_ppocr_mobile_v2.0_cls_infer \ --rec_model_dir./inference/ch_PP-OCRv2_rec_infer \ --det_model_dir./inference/ch_PP-OCRv2_det_infer \ --image_path./images/lite_demo.png \ --use_paddle_predictTrue 推理识别结果 输出可紧致头发磷层从而达到0.99444813即时持久改善头发光泽的效果给干燥的头0.99019814发足够的滋养0.997668花费了0.457335秒 效果还不错 调试 ocr读取文件的时候报错 Python 3.11.0rc2 (main, Sep  4 2023, 07:22:49) [GCC 9.3.0] on linux Type help, copyright, credits or license for more information. import cv2 Traceback (most recent call last):   File stdin, line 1, in module   File /root/py311/lib/python3.11/site-packages/cv2/__init__.py, line 8, in module     from .cv2 import * ImportError: libtiff.so.6: cannot open shared object file: No such file or directory 安装libtiff pip install pylibtiff 结果还是报错 找到libtiff.so.5文件在/lib/riscv64-linux-gnu做了个链接。 ln -s libtiff.so.5 libtiff.so.6 报错ImportError: libgtk-x11-2.0.so.0 SyntaxError: invalid syntax (py311) root863c89a419ec:~/github/Paddle2ONNX/model_zoo/ocr# python -c import cv2 Traceback (most recent call last):   File string, line 1, in module   File /root/py311/lib/python3.11/site-packages/cv2/__init__.py, line 8, in module     from .cv2 import * ImportError: libtiff.so.6: cannot open shared object file: No such file or directory (py311) root863c89a419ec:~/github/Paddle2ONNX/model_zoo/ocr# python -c import cv2 Traceback (most recent call last):   File string, line 1, in module   File /root/py311/lib/python3.11/site-packages/cv2/__init__.py, line 8, in module     from .cv2 import * ImportError: libgtk-x11-2.0.so.0: cannot open shared object file: No such file or directory 安装包apt-get install libgtk2.0-dev ok了 识别是numpy.int报错 File /root/github/Paddle2ONNX/model_zoo/ocr/utils/predict_det.py, line 210, in box_score_fast     xmin np.clip(np.floor(box[:, 0].min()).astype(np.int), 0, w - 1) File /usr/local/lib/python3.8/dist-packages/numpy/__init__.py, line 305, in __getattr__     raise AttributeError(__former_attrs__[attr]) AttributeError: module numpy has no attribute int. np.int was a deprecated alias for the builtin int. To avoid this error in existing code, use int by itself. Doing this will not modify any behavior and is safe. When replacing np.int, you may wish to use e.g. np.int64 or np.int32 to specify the precision. If you wish to review your current use, check the release note link for additional information. The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at: 进入/root/github/Paddle2ONNX/model_zoo/ocr/utils/predict_det.py源码把np.int都改成np.int32
http://www.zqtcl.cn/news/154395/

相关文章:

  • cms网站如何修改黄山建设网站
  • 宾爵手表官方网站小熊源码网
  • 荥阳网站建设网站建设取得了
  • 江苏省住房和城乡建设厅 官方网站wordpress点击下载
  • 找家里做的工作上哪个网站公司取名三个字推荐
  • 购物网站建设源码wordpress 多多进宝
  • 重庆定制网站建设地址晋安福州网站建设
  • 360建网站了解深圳网站页面设计
  • 哪些网站首页做的好蛋糕网站内容规划
  • 富阳市网站息壤服务器网站打不开
  • 中文建站模板客户做网站嫌贵了
  • 做网站用jquery做网站都有哪些费用
  • 网站知识安卓studio制作一个简单app
  • 一个购物网站开发语言外贸企业
  • 给一个装修公司怎么做网站做网站打开图片慢
  • 互联网三网合一网站建设银川网站建站公司
  • 网站开发需要什么基础网站建设积分
  • 安平做网站的电话装修公司哪家产品好
  • 网站建设内部链接精选资料
  • 廊坊市网站中山网站建设排名
  • 济南网站APPwordpress零基础建站教程视频
  • nodejs和wordpress福建seo快速排名优化
  • 网站开发的主要工作步骤页面跳转流程图
  • 医院网站源码 asp网站店招用什么软件做的
  • 怎样做网站权重龙岗网站制作讯息
  • 谁可以教我做网站网页编辑工具是什么
  • 义乌网站建设费用多少建设网站套餐
  • 济南高端网站环保网站建设项目备案系统
  • 办公门户网站模板WordPress怎么两个标题
  • 做网站 域名是怎么回事邢台163交友手机端