Open JasOleander opened 5 months ago
@JasOleander did you have any success on that? I got the same error.
@Gengzigang , could you upload all necessary files ?
@JasOleander Turns out, on Windows machine you must do what PYTHONPATH="$(dirname $0)/..":$PYTHONPATH
does in Linux machine. This command updates the python path to include the parent directory since the script itself is one-level down.
If you're on Windows do the following:
set "SCRIPT_DIR=C:\path\to\your\PCT\vis_tools\demo_img_with_mmdet.py"
set "PARENT_DIR=%SCRIPT_DIR%\.."
set "PYTHONPATH=%PARENT_DIR%;%PYTHONPATH%"
Then run the command: python vis_tools/demo_img_with_mmdet.py vis_tools/cascade_rcnn_x101_64x4d_fpn_coco.py https://download.openmmlab.com/mmdetection/v2.0/cascade_rcnn/cascade_rcnn_x101_64x4d_fpn_20e_coco/cascade_rcnn_x101_64x4d_fpn_20e_coco_20200509_224357-051557b1.pth configs/pct_[base/large/huge]_classifier.py weights/pct/swin_[base/large/huge].pth --img-root images/ --img your_image.jpg --out-img-root images/ --thickness 2
@bit-scientist when install mmcv, is it mmcv-full or mmcv==1.7.0? When I run above line you mentioned, I got this error ModuleNotFoundError: No module named 'mmcv._ext'. could you tell your mmcv, mmdet, mmpose version?
@JasOleander, sure. Note that I created a conda env on Windows machine. Here you are:
pip install torch==1.8.0+cu111 torchvision==0.9.0+cu111 torchaudio==0.8.0 -f https://download.pytorch.org/whl/torch_stable.html
pip install mmcv-full==1.7.0 -f https://download.openmmlab.com/mmcv/dist/cu111/torch1.8.0/index.html
pip install mmpose==0.29.0 -f https://download.openmmlab.com/mmcv/dist/cu111/torch1.8.0/index.html
pip install tqdm yacs scikit-learn tensorboardX pycocotools timm albumentations
pip install mmdet==2.27.0 -f https://download.openmmlab.com/mmcv/dist/cu111/torch1.8.0/index.html
@bit-scientist Thank you so much for your reply. Your reply support me a lot. The main problem is cuda version of me. Now, I can run by your support. By the way, have you ever been trained the tokenizer? How much time taken for training?
@JasOleander I haven't trained it and have no plan either. Because the model works quite well.
user/PCT/tools/train.py", line 19, in
from models import build_posenet
ModuleNotFoundError: No module named 'models'
I face with this issue although there is a models folder under PCT. How can fix it?