当前位置: 代码迷 >> 综合 >> 【何弃疗】windows 安装 pycocotools 方法未果,转到乌班图,且记录(也附上windows10编译 Pycocotools出错解决方案最新的链接)
  详细解决方案

【何弃疗】windows 安装 pycocotools 方法未果,转到乌班图,且记录(也附上windows10编译 Pycocotools出错解决方案最新的链接)

热度:73   发布时间:2023-11-25 04:58:59.0

很多例子,我就不一一介绍了,我就记录下自己的安装错误

我从win10安装出现下面附件的错误后,我洗心革面,在乌班图环境下装pycocotools

 

在路径下用

 报错,查了一下是因为没有按照cython

 在路径下make,如图没有发现装了还是没有装,list后没发现pycocotools

乖乖走一次程序

 

https://github.com/philferriere/cocoapi

https://blog.csdn.net/chixia1785/article/details/80040172

https://blog.csdn.net/gxiaoyaya/article/details/78363391

https://blog.csdn.net/gxiaoyaya/article/details/78363391

附件:

D:\ProgramData\Anaconda3\envs\tfpose\python.exe H:/tf-pose-estimation-master/tf_pose/train.py
mask.py err= No module named 'pycocotools._mask'
[2019-01-28 19:29:08,116] [train] [INFO] define model+
loading annotations into memory...
[2019-01-28 19:29:08,126] [pose_dataset] [INFO] dataflow img_path=H:/tf-pose-estimation-master/data/public/rw/coco/images/
Done (t=6.79s)
creating index...
index created!
[2019-01-28 19:29:15,104] [pose_dataset] [INFO] H:/tf-pose-estimation-master/data/public/rw/coco/annotations dataset 82783
[0128 19:29:15 @parallel.py:176] WRN MultiProcessPrefetchData does support windows. However, windows requires more strict picklability on processes, which may lead of failure on some of the code.
[0128 19:29:15 @parallel.py:186] [MultiProcessPrefetchData] Will fork a dataflow more than one times. This assumes the datapoints are i.i.d.
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
mask.py err= No module named 'pycocotools._mask'
Traceback (most recent call last):
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorflow\python\platform\self_check.py", line 87, in preload_check
    ctypes.WinDLL(build_info.cudnn_dll_name)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\ctypes\__init__.py", line 348, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: [WinError 1455] 页面文件太小,无法完成操作。

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\spawn.py", line 105, in spawn_main
    exitcode = _main(fd)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\spawn.py", line 114, in _main
    prepare(preparation_data)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\spawn.py", line 225, in prepare
    _fixup_main_from_path(data['init_main_from_path'])
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
    run_name="__mp_main__")
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\runpy.py", line 263, in run_path
    pkg_name=pkg_name, script_name=fname)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\runpy.py", line 96, in _run_module_code
    mod_name, mod_spec, pkg_name, script_name)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "H:\tf-pose-estimation-master\tf_pose\train.py", line 13, in <module>
    import tensorflow as tf
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorflow\__init__.py", line 22, in <module>
    from tensorflow.python import pywrap_tensorflow  # pylint: disable=unused-import
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorflow\python\__init__.py", line 49, in <module>
    from tensorflow.python import pywrap_tensorflow
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 30, in <module>
    self_check.preload_check()
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorflow\python\platform\self_check.py", line 97, in preload_check
    % (build_info.cudnn_dll_name, build_info.cudnn_version_number))
ImportError: Could not find 'cudnn64_7.dll'. TensorFlow requires that this DLL be installed in a directory that is named in your %PATH% environment variable. Note that installing cuDNN is a separate step from installing CUDA, and this DLL is often found in a different directory from the CUDA DLLs. You may install the necessary DLL by downloading cuDNN 7 from this URL: https://developer.nvidia.com/cudnn
Traceback (most recent call last):
  File "H:/tf-pose-estimation-master/tf_pose/train.py", line 71, in <module>
    df = get_dataflow_batch(args.datapath, True, args.batchsize, img_path=args.imgpath)
  File "H:\tf-pose-estimation-master\tf_pose\pose_dataset.py", line 389, in get_dataflow_batch
    ds = get_dataflow(path, is_train, img_path=img_path)
  File "H:\tf-pose-estimation-master\tf_pose\pose_dataset.py", line 368, in get_dataflow
    ds = PrefetchData(ds, 1000, multiprocessing.cpu_count() * 4)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorpack\dataflow\parallel.py", line 193, in __init__
    start_proc_mask_signal(self.procs)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\site-packages\tensorpack\utils\concurrency.py", line 235, in start_proc_mask_signal
    p.start()
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\process.py", line 105, in start
    self._popen = self._Popen(self)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\context.py", line 223, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\context.py", line 322, in _Popen
    return Popen(process_obj)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\popen_spawn_win32.py", line 65, in __init__
    reduction.dump(process_obj, to_child)
  File "D:\ProgramData\Anaconda3\envs\tfpose\lib\multiprocessing\reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)
BrokenPipeError: [Errno 32] Broken pipe

Process finished with exit code 1

  相关解决方案