mediapipe 的姿态检测遇到的问题

简介:

最近在用mediapipe 进行人体姿态检测,当我初始化pose(姿态检测对象)时出现了错误:报错如下:

Downloading model to D:\Anaconda\envs\taiji\lib\site-packages\mediapipe/modules/pose_landmark/pose_landmark_lite.tflite

Traceback (most recent call last):   File "D:\Anaconda\envs\taiji\lib\urllib\request.py", line 1354, in do_open     h.request(req.get_method(), req.selector, req.data, headers,   File "D:\Anaconda\envs\taiji\lib\http\client.py", line 1256, in request     self._send_request(method, url, body, headers, encode_chunked)   File "D:\Anaconda\envs\taiji\lib\http\client.py", line 1302, in _send_request     self.endheaders(body, encode_chunked=encode_chunked)   File "D:\Anaconda\envs\taiji\lib\http\client.py", line 1251, in endheaders     self._send_output(message_body, encode_chunked=encode_chunked)   File "D:\Anaconda\envs\taiji\lib\http\client.py", line 1011, in _send_output     self.send(msg)   File "D:\Anaconda\envs\taiji\lib\http\client.py", line 951, in send     self.connect()   File "D:\Anaconda\envs\taiji\lib\http\client.py", line 1425, in connect     self.sock = self._context.wrap_socket(self.sock,   File "D:\Anaconda\envs\taiji\lib\ssl.py", line 500, in wrap_socket     return self.sslsocket_class._create(   File "D:\Anaconda\envs\taiji\lib\ssl.py", line 1073, in _create     self.do_handshake()   File "D:\Anaconda\envs\taiji\lib\ssl.py", line 1342, in do_handshake     self._sslobj.do_handshake() ConnectionResetError: [WinError 10054] 远程主机强迫关闭了一个现有的连接。  During handling of the above exception, another exception occurred:  Traceback (most recent call last):   File "D:\Anaconda\envs\taiji\lib\urllib\request.py", line 1357, in do_open     raise URLError(err) urllib.error.URLError: python-BaseException Backend QtAgg is interactive backend. Turning interactive mode on.

然后上网查了以后发现解释是这样的:

mediapipe 运行代码的时候 有时候会下载模型,但是因为网络问题,可能下载不下来,报错

TimeoutError: [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连 接尝试失败。

解决办法:

可以得到就是在下载:Downloading model to D:\Anaconda\envs\taiji\lib\site-packages\mediapipe/modules/pose_landmark/pose_landmark_lite.tflite文件时出现了问题

我们需要自己下载这个文件,可以在gitee上下载:

mediapipe: MediaPipe 是一个基于图形的跨平台框架,用于构建多模式(视频,音频和传感器)应用的机器学习管道 - Gitee.com 我在git上没有找到该文件,然后通过一些其他途径搞到了该文件:

链接:https://pan.baidu.com/s/1O26LCXGgUBp-Ao0A4hKl9w?pwd=d8eh 
提取码:d8eh

mediapipe 的姿态检测遇到的问题_第1张图片 

你可能感兴趣的:(mediapipe,mediapipe)