Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running demo.py and AttributeError: module 'pycocotools' has no attribute '__version__' #17

Open
swaggywilliam opened this issue Jun 9, 2023 · 8 comments

Comments

@swaggywilliam
Copy link

swaggywilliam commented Jun 9, 2023

Checklist

  1. I have searched related issues but cannot get the expected help.
  2. The bug has not been fixed in the latest version.

Describe the bug

AttributeError: module 'pycocotools' has no attribute '__version__'

Hello, I followed your environment setup and installed mmcv-full=1.3.0, mmdet=2.10.0, mmdet3d=0.10.0, mmpycocotools=12.0.3 and pycocotools=2.0.1. During the verification process, I tried to run demo.py to validate the successful installation of mmdet3d. However, I encountered an error that says "AttributeError: module 'pycocotools' has no attribute 'version'". I checked the faq.md , you mentioned that uninstalling mmpycocotools and pycocotools, then reinstalling mmpycocotools could resolve the issue. I tried this solution, but it didn't work. If I only install mmpycocotools, a new issue appeared.

ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 80 from PyObject

So I found the solution in the mmdetection3d documentation. The solution proposed there is similar to your suggestion, but it includes an additional step of installing pycocotools==2.0.1. However, the bug ‘’AttributeError: module 'pycocotools' has no attribute 'version' ‘’ recurrence when I installed pycocotools.

Reproduction

  1. What command or script did you run?
python demo/pcd_demo.py demo/kitti_000008.bin configs/second/hv_second_secfpn_6x8_80e_kitti-3d-car.py checkpoints/hv_second_secfpn_6x8_80e_kitti-3d-car_20200620_230238-393f000c.pth
  1. Did you make any modifications on the code or config? Did you understand what you have modified?
    I didn't make any modifications.
  2. What dataset did you use?
    demo.py

Environment

  1. Please run python mmdet3d/utils/collect_env.py to collect necessary environment infomation and paste it here.
sys.platform: linux
Python: 3.8.16 (default, Mar  2 2023, 03:21:46) [GCC 11.2.0]
CUDA available: True
GPU 0: NVIDIA GeForce RTX 2080 Ti
CUDA_HOME: /usr/local/cuda
NVCC: Build cuda_11.1.TC455_06.29190527_0
GCC: gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0
PyTorch: 1.9.0+cu111
PyTorch compiling details: PyTorch built with:
  - GCC 7.3
  - C++ Version: 201402
  - Intel(R) Math Kernel Library Version 2020.0.0 Product Build 20191122 for Intel(R) 64 architecture applications
  - Intel(R) MKL-DNN v2.1.2 (Git Hash 98be7e8afa711dc9b66c8ff3504129cb82013cdb)
  - OpenMP 201511 (a.k.a. OpenMP 4.5)
  - NNPACK is enabled
  - CPU capability usage: AVX2
  - CUDA Runtime 11.1
  - NVCC architecture flags: -gencode;arch=compute_37,code=sm_37;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75;-gencode;arch=compute_80,code=sm_80;-gencode;arch=compute_86,code=sm_86
  - CuDNN 8.0.5
  - Magma 2.5.2
  - Build settings: BLAS_INFO=mkl, BUILD_TYPE=Release, CUDA_VERSION=11.1, CUDNN_VERSION=8.0.5, CXX_COMPILER=/opt/rh/devtoolset-7/root/usr/bin/c++, CXX_FLAGS= -Wno-deprecated -fvisibility-inlines-hidden -DUSE_PTHREADPOOL -fopenmp -DNDEBUG -DUSE_KINETO -DUSE_FBGEMM -DUSE_QNNPACK -DUSE_PYTORCH_QNNPACK -DUSE_XNNPACK -DSYMBOLICATE_MOBILE_DEBUG_HANDLE -O2 -fPIC -Wno-narrowing -Wall -Wextra -Werror=return-type -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-unused-local-typedefs -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-psabi -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -fdiagnostics-color=always -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -fno-math-errno -fno-trapping-math -Werror=format -Wno-stringop-overflow, LAPACK_INFO=mkl, PERF_WITH_AVX=1, PERF_WITH_AVX2=1, PERF_WITH_AVX512=1, TORCH_VERSION=1.9.0, USE_CUDA=ON, USE_CUDNN=ON, USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_MKL=ON, USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=ON, USE_NNPACK=ON, USE_OPENMP=ON, 

TorchVision: 0.10.0+cu111
OpenCV: 4.7.0
MMCV: 1.3.0
MMCV Compiler: GCC 7.5
MMCV CUDA Compiler: 11.1
MMDetection: 2.10.0
MMDetection3D: 0.10.0+1b39a48
  1. You may add addition that may be helpful for locating the problem, such as
    • How you installed PyTorch [e.g., pip, conda, source]
pip install torch==1.9.0+cu111 torchvision==0.10.0+cu111 torchaudio==0.9.0 -f https://download.pytorch.org/whl/torch_stable.html

Error traceback
If applicable, paste the error trackback here.

Traceback (most recent call last):
  File "demo/pcd_demo.py", line 3, in <module>
    from mmdet3d.apis import inference_detector, init_detector, show_result_meshlab
  File "/root/autodl-tmp/project/mmdetection3d/mmdet3d/apis/__init__.py", line 1, in <module>
    from .inference import inference_detector, init_detector, show_result_meshlab
  File "/root/autodl-tmp/project/mmdetection3d/mmdet3d/apis/inference.py", line 10, in <module>
    from mmdet3d.datasets.pipelines import Compose
  File "/root/autodl-tmp/project/mmdetection3d/mmdet3d/datasets/__init__.py", line 1, in <module>
    from mmdet.datasets.builder import build_dataloader
  File "/root/autodl-tmp/project/mmdetection/mmdet/datasets/__init__.py", line 2, in <module>
    from .cityscapes import CityscapesDataset
  File "/root/autodl-tmp/project/mmdetection/mmdet/datasets/cityscapes.py", line 16, in <module>
    from .coco import CocoDataset
  File "/root/autodl-tmp/project/mmdetection/mmdet/datasets/coco.py", line 21, in <module>
    assert pycocotools.__version__ >= '12.0.2'
AttributeError: module 'pycocotools' has no attribute '__version__'

Bug fix
If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated!

@SxJyJay
Copy link
Owner

SxJyJay commented Jun 13, 2023

You can refer to this site

@swaggywilliam
Copy link
Author

swaggywilliam commented Jun 14, 2023

You can refer to this site

I'm sorry, but you may have misunderstood my problem. The solution you provided for the "AttributeError" was to "pip uninstall pycocotools and reinstall mmpycocotools". I have already tried that, but after trying the same command again,

python demo/pcd_demo.py demo/kitti_000008.bin configs/second/hv_second_secfpn_6x8_80e_kitti-3d-car.py checkpoints/hv_second_secfpn_6x8_80e_kitti-3d-car_20200620_230238-393f000c.pth

I encountered a "ValueError". Upon researching the solution for the "ValueError", it suggests to "install pycocotools". Does this mean that my previous step of "uninstalling pycocotools" was unnecessary? As you can imagine, after installing pycocotools to resolve the "ValueError", the "AttributeError" reappeared.

@SxJyJay
Copy link
Owner

SxJyJay commented Jun 14, 2023

This error is caused by the old version of numpy, you can refer to this solution. I suggest you install libraries with the same version as mine.

@swaggywilliam
Copy link
Author

This error is caused by the old version of numpy, you can refer to this solution. I suggest you install libraries with the same version as mine.

Thank you very much for your prompt response. There's one thing I need to clarify. The description of the "ValueError" I encountered is "Expected 96 from C header, got 80 from PyObject," which is slightly different from the referenced "ValueError: Expected 88 from C header, got 80 from PyObject." However, I have also tried changing the version of numpy and tried to match my environment as closely as possible to yours, but I am still experiencing these issues. I hope you can help me clarify this further.
The following is a list of libraries installed in my environment.

# Name                    Version                   Build  Channel
libgcc_mutex              0.1                        main    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
_openmp_mutex             5.1                       1_gnu    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
absl-py                   1.2.0                    pypi_0    pypi
addict                    2.4.0                    pypi_0    pypi
anyio                     3.6.2                    pypi_0    pypi
argon2-cffi               21.3.0                   pypi_0    pypi
argon2-cffi-bindings      21.2.0                   pypi_0    pypi
asttokens                 2.2.1                    pypi_0    pypi
attrs                     22.2.0                   pypi_0    pypi
backcall                  0.2.0                    pypi_0    pypi
beautifulsoup4            4.12.0                   pypi_0    pypi
black                     23.1.0                   pypi_0    pypi
bleach                    5.0.1                    pypi_0    pypi
ca-certificates           2023.05.30           h06a4308_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
cachetools                5.1.0                    pypi_0    pypi
certifi                   2022.9.24                pypi_0    pypi
cffi                      1.15.1                   pypi_0    pypi
charset-normalizer        3.0.1                    pypi_0    pypi
click                     8.1.3                    pypi_0    pypi
comm                      0.1.3                    pypi_0    pypi
contourpy                 1.0.6                    pypi_0    pypi
cycler                    0.11.0                   pypi_0    pypi
cython                    0.29.35                  pypi_0    pypi
debugpy                   1.6.6                    pypi_0    pypi
decorator                 5.1.1                    pypi_0    pypi
defusedxml                0.7.1                    pypi_0    pypi
descartes                 1.1.0                    pypi_0    pypi
entrypoints               0.4                      pypi_0    pypi
exceptiongroup            1.1.0                    pypi_0    pypi
executing                 1.2.0                    pypi_0    pypi
fastjsonschema            2.16.3                   pypi_0    pypi
fire                      0.4.0                    pypi_0    pypi
flake8                    6.0.0                    pypi_0    pypi
fonttools                 4.39.4                   pypi_0    pypi
google-auth               2.19.0                   pypi_0    pypi
google-auth-oauthlib      0.4.6                    pypi_0    pypi
grpcio                    1.54.2                   pypi_0    pypi
idna                      3.4                      pypi_0    pypi
imageio                   2.29.0                   pypi_0    pypi
importlib-metadata        6.3.0                    pypi_0    pypi
importlib-resources       5.12.0                   pypi_0    pypi
iniconfig                 2.0.0                    pypi_0    pypi
ipdb                      0.13.9                   pypi_0    pypi
ipykernel                 6.23.1                   pypi_0    pypi
ipython                   8.10.0                   pypi_0    pypi
ipython-genutils          0.2.0                    pypi_0    pypi
ipywidgets                8.0.6                    pypi_0    pypi
jedi                      0.18.2                   pypi_0    pypi
jinja2                    3.1.2                    pypi_0    pypi
joblib                    1.2.0                    pypi_0    pypi
jsonschema                4.8.0                    pypi_0    pypi
jupyter                   1.0.0                    pypi_0    pypi
jupyter-client            7.3.4                    pypi_0    pypi
jupyter-console           6.6.3                    pypi_0    pypi
jupyter-core              5.3.0                    pypi_0    pypi
jupyter-server            1.24.0                   pypi_0    pypi
jupyterlab-pygments       0.2.2                    pypi_0    pypi
jupyterlab-widgets        3.0.7                    pypi_0    pypi
kiwisolver                1.4.4                    pypi_0    pypi
ld_impl_linux-64          2.38                 h1181459_1    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
libffi                    3.4.4                h6a678d5_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
libgcc-ng                 11.2.0               h1234567_1    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
libgomp                   11.2.0               h1234567_1    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
libstdcxx-ng              11.2.0               h1234567_1    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
llvmlite                  0.31.0                   pypi_0    pypi
lyft-dataset-sdk          0.0.8                    pypi_0    pypi
markdown                  3.4.3                    pypi_0    pypi
markupsafe                2.1.2                    pypi_0    pypi
matplotlib                3.5.2                    pypi_0    pypi
matplotlib-inline         0.1.3                    pypi_0    pypi
mccabe                    0.7.0                    pypi_0    pypi
mistune                   2.0.5                    pypi_0    pypi
mmcv-full                 1.3.0                    pypi_0    pypi
mmdet                     2.10.0                    dev_0    <develop>
mmdet3d                   0.11.0                    dev_0    <develop>
mmpycocotools             12.0.3                   pypi_0    pypi
mypy-extensions           1.0.0                    pypi_0    pypi
nbclassic                 0.5.3                    pypi_0    pypi
nbclient                  0.8.0                    pypi_0    pypi
nbconvert                 7.2.5                    pypi_0    pypi
nbformat                  5.8.0                    pypi_0    pypi
ncurses                   6.4                  h6a678d5_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
nest-asyncio              1.5.4                    pypi_0    pypi
networkx                  2.2                      pypi_0    pypi
notebook                  6.5.4                    pypi_0    pypi
notebook-shim             0.2.2                    pypi_0    pypi
numba                     0.48.0                   pypi_0    pypi
numpy                     1.19.2                   pypi_0    pypi
nuscenes-devkit           1.1.9                    pypi_0    pypi
oauthlib                  3.2.2                    pypi_0    pypi
opencv-python             4.7.0.72                 pypi_0    pypi
openssl                   1.1.1t               h7f8727e_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
packaging                 23.1                     pypi_0    pypi
pandas                    1.4.4                    pypi_0    pypi
pandocfilters             1.5.0                    pypi_0    pypi
parso                     0.8.3                    pypi_0    pypi
pathspec                  0.11.0                   pypi_0    pypi
pexpect                   4.8.0                    pypi_0    pypi
pickleshare               0.7.5                    pypi_0    pypi
pillow                    9.3.0                    pypi_0    pypi
pip                       23.0.1           py38h06a4308_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
platformdirs              3.0.0                    pypi_0    pypi
plotly                    5.14.1                   pypi_0    pypi
pluggy                    1.0.0                    pypi_0    pypi
plyfile                   0.9                      pypi_0    pypi
prometheus-client         0.17.0                   pypi_0    pypi
prompt-toolkit            3.0.38                   pypi_0    pypi
protobuf                  3.20.3                   pypi_0    pypi
psutil                    5.9.4                    pypi_0    pypi
ptyprocess                0.7.0                    pypi_0    pypi
pure-eval                 0.2.2                    pypi_0    pypi
pyasn1                    0.4.8                    pypi_0    pypi
pyasn1-modules            0.2.8                    pypi_0    pypi
pycocotools               2.0.1                    pypi_0    pypi
pycodestyle               2.10.0                   pypi_0    pypi
pycparser                 2.21                     pypi_0    pypi
pyflakes                  3.0.1                    pypi_0    pypi
pygments                  2.14.0                   pypi_0    pypi
pyparsing                 3.0.9                    pypi_0    pypi
pyquaternion              0.9.9                    pypi_0    pypi
pyrsistent                0.19.3                   pypi_0    pypi
pytest                    7.2.1                    pypi_0    pypi
python                    3.8.16               h7a1cb2a_3    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
python-dateutil           2.8.2                    pypi_0    pypi
pytz                      2022.6                   pypi_0    pypi
pywavelets                1.3.0                    pypi_0    pypi
pyyaml                    6.0                      pypi_0    pypi
pyzmq                     25.1.0                   pypi_0    pypi
qtconsole                 5.4.0                    pypi_0    pypi
qtpy                      2.3.0                    pypi_0    pypi
readline                  8.2                  h5eee18b_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
requests                  2.31.0                   pypi_0    pypi
requests-oauthlib         1.3.1                    pypi_0    pypi
rsa                       4.9                      pypi_0    pypi
scikit-image              0.19.3                   pypi_0    pypi
scikit-learn              1.2.1                    pypi_0    pypi
scipy                     1.7.3                    pypi_0    pypi
send2trash                1.8.0                    pypi_0    pypi
setuptools                67.8.0           py38h06a4308_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
shapely                   1.8.5                    pypi_0    pypi
six                       1.16.0                   pypi_0    pypi
sniffio                   1.2.0                    pypi_0    pypi
soupsieve                 2.4                      pypi_0    pypi
sqlite                    3.41.2               h5eee18b_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
stack-data                0.6.2                    pypi_0    pypi
tenacity                  8.2.2                    pypi_0    pypi
tensorboard               2.11.2                   pypi_0    pypi
tensorboard-data-server   0.6.1                    pypi_0    pypi
tensorboard-plugin-wit    1.8.1                    pypi_0    pypi
termcolor                 2.1.1                    pypi_0    pypi
terminado                 0.17.0                   pypi_0    pypi
terminaltables            3.1.10                   pypi_0    pypi
threadpoolctl             3.1.0                    pypi_0    pypi
tifffile                  2023.4.12                pypi_0    pypi
tinycss2                  1.1.1                    pypi_0    pypi
tk                        8.6.12               h1ccaba5_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
toml                      0.10.2                   pypi_0    pypi
tomli                     2.0.1                    pypi_0    pypi
torch                     1.9.0+cu111              pypi_0    pypi
torchaudio                0.9.0                    pypi_0    pypi
torchvision               0.10.0+cu111             pypi_0    pypi
tornado                   6.1                      pypi_0    pypi
tqdm                      4.63.1                   pypi_0    pypi
traitlets                 5.9.0                    pypi_0    pypi
trimesh                   2.35.39                  pypi_0    pypi
typing-extensions         4.6.2                    pypi_0    pypi
urllib3                   1.26.16                  pypi_0    pypi
wcwidth                   0.2.5                    pypi_0    pypi
webencodings              0.5.1                    pypi_0    pypi
websocket-client          1.5.2                    pypi_0    pypi
werkzeug                  2.3.4                    pypi_0    pypi
wheel                     0.38.4           py38h06a4308_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
widgetsnbextension        4.0.7                    pypi_0    pypi
xz                        5.4.2                h5eee18b_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main
yapf                      0.32.0                   pypi_0    pypi
zipp                      3.15.0                   pypi_0    pypi
zlib                      1.2.13               h5eee18b_0    https://mirrors.ustc.edu.cn/anaconda/pkgs/main

@SxJyJay
Copy link
Owner

SxJyJay commented Jun 16, 2023

It is hard for me to give you some useful suggestions with the above list of libraries and their versions. But I think the best try is that you reinstall your environment following my libraries dependency.

@swaggywilliam
Copy link
Author

It is hard for me to give you some useful suggestions with the above list of libraries and their versions. But I think the best try is that you reinstall your environment following my libraries dependency.

Thanks for your response once again. I have another question: Have you tried running MSMDFusion with the latest version of mmdetection3d? I initially attempted to use the latest version, but encountered issues, possibly due to a conflict with the mmengine and mmcv-full which now is renamed to mmcv.

@SxJyJay
Copy link
Owner

SxJyJay commented Jun 20, 2023

The latest version of mmdetection3d refactors their coordinate system and should be cooperated with a new version of mmcv. I do not adapt my codebase to the latest mmdetection3d.

@Libraaer
Copy link

Libraaer commented Sep 7, 2024

Checklist

  1. I have searched related issues but cannot get the expected help.
  2. The bug has not been fixed in the latest version.

Describe the bug

AttributeError: module 'pycocotools' has no attribute '__version__'

Hello, I followed your environment setup and installed mmcv-full=1.3.0, mmdet=2.10.0, mmdet3d=0.10.0, mmpycocotools=12.0.3 and pycocotools=2.0.1. During the verification process, I tried to run demo.py to validate the successful installation of mmdet3d. However, I encountered an error that says "AttributeError: module 'pycocotools' has no attribute 'version'". I checked the faq.md , you mentioned that uninstalling mmpycocotools and pycocotools, then reinstalling mmpycocotools could resolve the issue. I tried this solution, but it didn't work. If I only install mmpycocotools, a new issue appeared.

ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 80 from PyObject

So I found the solution in the mmdetection3d documentation. The solution proposed there is similar to your suggestion, but it includes an additional step of installing pycocotools==2.0.1. However, the bug ‘’AttributeError: module 'pycocotools' has no attribute 'version' ‘’ recurrence when I installed pycocotools.

Reproduction

  1. What command or script did you run?
python demo/pcd_demo.py demo/kitti_000008.bin configs/second/hv_second_secfpn_6x8_80e_kitti-3d-car.py checkpoints/hv_second_secfpn_6x8_80e_kitti-3d-car_20200620_230238-393f000c.pth
  1. Did you make any modifications on the code or config? Did you understand what you have modified?
    I didn't make any modifications.
  2. What dataset did you use?
    demo.py

Environment

  1. Please run python mmdet3d/utils/collect_env.py to collect necessary environment infomation and paste it here.
sys.platform: linux
Python: 3.8.16 (default, Mar  2 2023, 03:21:46) [GCC 11.2.0]
CUDA available: True
GPU 0: NVIDIA GeForce RTX 2080 Ti
CUDA_HOME: /usr/local/cuda
NVCC: Build cuda_11.1.TC455_06.29190527_0
GCC: gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0
PyTorch: 1.9.0+cu111
PyTorch compiling details: PyTorch built with:
  - GCC 7.3
  - C++ Version: 201402
  - Intel(R) Math Kernel Library Version 2020.0.0 Product Build 20191122 for Intel(R) 64 architecture applications
  - Intel(R) MKL-DNN v2.1.2 (Git Hash 98be7e8afa711dc9b66c8ff3504129cb82013cdb)
  - OpenMP 201511 (a.k.a. OpenMP 4.5)
  - NNPACK is enabled
  - CPU capability usage: AVX2
  - CUDA Runtime 11.1
  - NVCC architecture flags: -gencode;arch=compute_37,code=sm_37;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75;-gencode;arch=compute_80,code=sm_80;-gencode;arch=compute_86,code=sm_86
  - CuDNN 8.0.5
  - Magma 2.5.2
  - Build settings: BLAS_INFO=mkl, BUILD_TYPE=Release, CUDA_VERSION=11.1, CUDNN_VERSION=8.0.5, CXX_COMPILER=/opt/rh/devtoolset-7/root/usr/bin/c++, CXX_FLAGS= -Wno-deprecated -fvisibility-inlines-hidden -DUSE_PTHREADPOOL -fopenmp -DNDEBUG -DUSE_KINETO -DUSE_FBGEMM -DUSE_QNNPACK -DUSE_PYTORCH_QNNPACK -DUSE_XNNPACK -DSYMBOLICATE_MOBILE_DEBUG_HANDLE -O2 -fPIC -Wno-narrowing -Wall -Wextra -Werror=return-type -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-unused-local-typedefs -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-psabi -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -fdiagnostics-color=always -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -fno-math-errno -fno-trapping-math -Werror=format -Wno-stringop-overflow, LAPACK_INFO=mkl, PERF_WITH_AVX=1, PERF_WITH_AVX2=1, PERF_WITH_AVX512=1, TORCH_VERSION=1.9.0, USE_CUDA=ON, USE_CUDNN=ON, USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_MKL=ON, USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=ON, USE_NNPACK=ON, USE_OPENMP=ON, 

TorchVision: 0.10.0+cu111
OpenCV: 4.7.0
MMCV: 1.3.0
MMCV Compiler: GCC 7.5
MMCV CUDA Compiler: 11.1
MMDetection: 2.10.0
MMDetection3D: 0.10.0+1b39a48
  1. You may add addition that may be helpful for locating the problem, such as

    • How you installed PyTorch [e.g., pip, conda, source]
pip install torch==1.9.0+cu111 torchvision==0.10.0+cu111 torchaudio==0.9.0 -f https://download.pytorch.org/whl/torch_stable.html

Error traceback If applicable, paste the error trackback here.

Traceback (most recent call last):
  File "demo/pcd_demo.py", line 3, in <module>
    from mmdet3d.apis import inference_detector, init_detector, show_result_meshlab
  File "/root/autodl-tmp/project/mmdetection3d/mmdet3d/apis/__init__.py", line 1, in <module>
    from .inference import inference_detector, init_detector, show_result_meshlab
  File "/root/autodl-tmp/project/mmdetection3d/mmdet3d/apis/inference.py", line 10, in <module>
    from mmdet3d.datasets.pipelines import Compose
  File "/root/autodl-tmp/project/mmdetection3d/mmdet3d/datasets/__init__.py", line 1, in <module>
    from mmdet.datasets.builder import build_dataloader
  File "/root/autodl-tmp/project/mmdetection/mmdet/datasets/__init__.py", line 2, in <module>
    from .cityscapes import CityscapesDataset
  File "/root/autodl-tmp/project/mmdetection/mmdet/datasets/cityscapes.py", line 16, in <module>
    from .coco import CocoDataset
  File "/root/autodl-tmp/project/mmdetection/mmdet/datasets/coco.py", line 21, in <module>
    assert pycocotools.__version__ >= '12.0.2'
AttributeError: module 'pycocotools' has no attribute '__version__'

Bug fix If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated!

Hello, have you trained this model? I'm using A800 here but still not enough to train. If you've trained, can you give me an answer to the reason for my lack of memory here, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants