如下链接的文档有问题,望修改:
https://gitee.com/paddlepaddle/PaddleOCR/tree/release/2.0/deploy/hubserving
部署ocr_system完成后,执行访问指令python tools/test_hubserving.py http://127.0.0.1:8868/predict/ocr_system doc/imgs/ 报错
[2021/03/18 09:22:57] root INFO: Predict time of doc/imgs/1.jpg: 10.189s
Traceback (most recent call last):
File "tools/test_hubserving.py", line 117, in
main(server_url, image_path)
File "tools/test_hubserving.py", line 91, in main
res = r.json()["results"][0]
IndexError: string index out of range
请问解决了吗
大佬,你这边这个问题解决了么
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。
我也刚好碰到这种问题了,蛮想知道大佬们怎么解决的
请问解决了吗
我这边是解决了,时间过去蛮久 我要找找资料才行
不用啦谢谢,我也解决啦
怎么解决的,我现在也越大哦这个问题了,部署成功了,但是执行python tools/test_hubserving.py http://127.0.0.1:8868/predict/ocr_system doc/imgs/ 报错res = r.json()["results"][0]
IndexError: string index out of range
我也是
我也碰到了,有解决方案吗
解决了吗
解决了吗
paddlepaddle 2.3.0
paddleocr 2.6.1.3
paddlehub 2.2.0
我也碰到了相同的问题。
在test_hubserving.py中输出了一下错误
是下面这句
r = requests.post(url=url, headers=headers, data=json.dumps(data))
执行的时候出错了。
我输出了一下结果: logger.info(r.json())
得到下面的错误:
test_hubserving.py:91 - {'msg': "module 'numpy' has no attribute 'int'.\nnp.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.\nThe aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:\n https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations", 'results': '', 'status': '101'}
这下一步就不知道怎么修改了。
谁能进一步解决一下呢?
登录 后才可以发表评论