mmfashion icon indicating copy to clipboard operation
mmfashion copied to clipboard

ImportError: cannot import name 'get_world_size' from 'torch.distributed'

Open iot-hunter opened this issue 5 years ago • 2 comments

env: win10 cuda10.1

absl-py 0.8.0 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main absl-py 0.8.1 addict 2.2.1 apex 0.1 astor 0.8.0 attrs 19.3.0 backcall 0.1.0 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main bcrypt 3.1.7 beautifulsoup4 4.8.1 blas 1.0 mkl anaconda bs4 0.0.1 bzip2 1.0.6 vc14_3 [vc14] anaconda ca-certificates 2019.8.28 0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main certifi 2019.9.11 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main cffi 1.12.3 py37h7a1dbc1_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main chardet 3.0.4 Click 7.0 cloudpickle 1.2.2 colorama 0.4.1 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main cryptography 2.8 cudatoolkit 10.1.243 h74a9793_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main cycler 0.10.0 py37_0 anaconda cython 0.29.13 py37ha925a31_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main decorator 4.4.1 py_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main detectron2 0.1 easydict 1.9 Flask 1.1.1 freetype 2.9.1 ha9979f8_1 anaconda future 0.17.1 py37_0 anaconda fvcore 0.1 gast 0.3.2 google-pasta 0.1.7 grpcio 1.24.1 grpcio 1.16.1 py37h351948d_1 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main h5py 2.10.0 hdf5 1.8.18 vc14h7a021fe_0 [] https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main html5lib 1.0.1 icc_rt 2019.0.0 h0cc432a_1 anaconda icu 58.2 vc14hc45fdbb_0 [vc14] anaconda idna 2.8 imagecorruptions 1.1.0 imageio 2.6.1 imgaug 0.2.6 intel-openmp 2019.5 281 anaconda ipython 7.9.0 py37h39e3cac_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main ipython_genutils 0.2.0 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main itsdangerous 1.1.0 jedi 0.15.1 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main Jinja2 2.10.3 joblib 0.14.0 jpeg 9b vc14h4d7706e_1 [vc14] anaconda jsonpatch 1.24 jsonpointer 2.0 Keras-Applications 1.0.8 Keras-Preprocessing 1.1.0 kiwisolver 1.1.0 py37ha925a31_0 anaconda labelme 3.16.7 libopencv 3.4.1 hf0769c1_3 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main libpng 1.6.37 h2a8f88b_0 anaconda libprotobuf 3.9.2 h7bd577a_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main libtiff 4.0.10 hb898794_2 anaconda markdown 3.1.1 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main MarkupSafe 1.1.1 maskrcnn-benchmark 0.1 matplotlib 3.1.1 py37hc8f65d3_0 anaconda mkl 2019.5 281 anaconda mkl-service 2.3.0 py37hb782905_0 anaconda mkl_fft 1.0.14 py37h14836fe_0 anaconda mkl_random 1.1.0 py37h675688f_0 anaconda mmcv 0.2.14 mmdet 1.0rc0+82c533b mmfashion 0.1.0+0288d70 mmfashion 0.1.0+ad2c911 msvc_runtime 1.0.1 vc14_0 [vc14] anaconda networkx 2.4 ninja 1.9.0.post1 ninja 1.9.0 py37h74a9793_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main numpy 1.16.5 py37h19fb1c0_0 anaconda numpy-base 1.16.5 py37hc3f5095_0 anaconda olefile 0.46 py37_0 anaconda opencv 3.4.1 py37h40b0b35_3 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main opencv-python 4.1.1.26 openssl 1.1.1d he774522_2 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main pandas 0.25.3 paramiko 2.6.0 parso 0.5.1 py_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main pickleshare 0.7.5 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main pillow 5.2.0 py37h08bbbbd_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main Pillow 6.2.1 pip 19.3.1 pip 19.2.3 py37_0 anaconda portalocker 1.5.1 prompt_toolkit 2.0.10 py_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main protobuf 3.10.0 protobuf 3.9.2 py37h33f27b4_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main py-opencv 3.4.1 py37hc319ecb_3 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main pycocotools 2.0 pycparser 2.19 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main pydensecrf 1.0rc2 pygments 2.4.2 py_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main pyhocon 0.3.51 PyNaCl 1.3.0 pyparsing 2.4.2 py_0 anaconda pypinyin 0.35.4 pypiwin32 223 pyqt 5.9.2 py37ha878b3d_0 anaconda python 3.7.1 h33f27b4_4 anaconda python-dateutil 2.8.0 py37_0 anaconda pytorch 1.3.0 py3.7_cuda101_cudnn7_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch pytz 2019.3 py_0 anaconda PyWavelets 1.1.1 pywin32 225 PyYAML 5.1.2 pyzmq 18.1.0 qt 5.9.7 vc14h73c81de_0 [vc14] anaconda QtPy 1.9.0 requests 2.22.0 scikit-image 0.16.2 scikit-learn 0.21.3 scipy 1.3.1 setuptools 41.4.0 py37_0 anaconda sip 4.19.13 py37ha925a31_0 anaconda six 1.12.0 py37_0 anaconda sklearn 0.0 soupsieve 1.9.4 sqlite 3.30.0 he774522_0 anaconda tb-nightly 2.1.0a20191016 tensorboard 2.0.0 tensorflow-gpu 2.0.0a0 termcolor 1.1.0 terminaltables 3.1.0 tf-estimator-nightly 1.14.0.dev2019030115 tk 8.6.7 vc14hb68737d_1 [] https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main torchfile 0.1.0 torchsummary 1.5.1 torchvision 0.4.1 py37_cu101 https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch tornado 6.0.3 py37he774522_0 anaconda tqdm 4.36.1 py_0 anaconda traitlets 4.3.3 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main urllib3 1.25.6 vc 14.1 h0510ff6_4 anaconda visdom 0.1.8.9 vs2015_runtime 14.16.27012 hf0eaf9b_0 anaconda wcwidth 0.1.7 py37_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main webencodings 0.5.1 websocket-client 0.56.0 werkzeug 0.16.0 py_0 https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main wheel 0.33.6 py37_0 anaconda wincertstore 0.2 py37_0 anaconda xz 5.2.4 h2fa13f4_4 anaconda yacs 0.1.6 zlib 1.2.11 vc14h1cdd9ab_1 [vc14] anaconda zstd 1.3.7 h508b16e_0 anaconda

cmd: python tools/test_landmark_detector.py --config configs/landmark_detect/landmark_detect_vgg.py --checkpoint Landmark_Detection_VGG-16.pth

iot-hunter avatar Nov 11 '19 11:11 iot-hunter

So far we have not implemented multiple worlds training/testing, which means world size can only be set to 1. We will try multiple worlds setting in future versions. Also, we used linux environment, cuda 9.0+.

veralauee avatar Nov 12 '19 18:11 veralauee

@iot-hunter

I am experiencing the sample problem. And pls see #15 for details

DominicDataScienctist avatar Dec 16 '19 09:12 DominicDataScienctist