AlphaTracker icon indicating copy to clipboard operation
AlphaTracker copied to clipboard

YOLO weigths error for demo tracking

Open monami-nishio opened this issue 2 years ago • 4 comments

Hi, I have a question about running demo with pretrained model. When I run 'python track.py' without changing anything, those error message came out. Isn't this mean the pretrained weight not matched with YOLO model ?

Traceback (most recent call last):
  File "demo.py", line 46, in <module>
    det_loader = DetectionLoader(data_loader, batchSize=args.detbatch,use_boxGT=args.use_boxGT,gt_json=args.gt_json).start()
  File "/home/mona0414/GITHUB/Choi-lab/AlphaTracker/Tracking/AlphaTracker/dataloader.py", line 338, in __init__
    self.det_model.load_weights(opt.yolo_model_path)
  File "/home/mona0414/GITHUB/Choi-lab/AlphaTracker/Tracking/AlphaTracker/yolo/darknet.py", line 488, in load_weights
    conv_weights = conv_weights.view_as(conv.weight.data)
RuntimeError: shape '[32, 3, 3, 3]' is invalid for input of size 420
terminate called without an active exception
Aborted (core dumped)

monami-nishio avatar Mar 18 '22 02:03 monami-nishio

Hello! Thank you for your interest in using AlphaTracker.

I would like to collect some information from you while I investigate your issue.
Can you provide the following information please:

  1. What operating system are you using?
  2. What is the CUDA version you are using?
  3. Please confirm that you are in the correct conda environment by using the command: conda activate alphatracker
  4. Did you install AlphaTracker using the bash install.sh functionality or another way?
  5. Could you please include a copy of the settings.py file?

Thank you!

laurelrr avatar Mar 18 '22 20:03 laurelrr

Actually, I think there may be an issue with downloading the models and the demo sets.
Would you please try the following: ls -l ./data/demo.mp4 and check what is the size of the video? Also, could you verify that the sample_demo_data.zip correctly unzipped and created a folder 'sample_demo_data ' with images and a json inside?

laurelrr avatar Mar 18 '22 21:03 laurelrr

I suspect that your institution's firewall is blocking the install script from automatically downloading the models and sample data sets. You will know this is the case if your files are only 3 kb or less.

As a workaround, you may manually download each file using a browser and save the datasets to the correct folder. Click each link below and save it to the corresponding location.

https://drive.google.com/file/d/1OPORTWB2cwd5YTVBX-NE8fsauZJWsrtW Save the file to 'AlphaTracker/Tracking/AlphaTracker/models/sppe/duc_se.pth'

https://drive.google.com/file/d/1g8uJjK7EOlqrUCmjZTtCegwnNsBig6zn Save the file to 'AlphaTracker/Tracking/AlphaTracker/train_yolo/darknet/darknet53.conv.74'

https://drive.google.com/file/d/1_BwtYySpX9uWDgdwqw0UEppyMYYv1gkJ Save the file to 'AlphaTracker/Tracking/AlphaTracker/train_sppe/exp/coco/demo/model_10.pkl'

https://drive.google.com/file/d/13zXkuZ4dNm3ZOwstr1sSWKOOzJ19XZpN Save the file to 'AlphaTracker/Tracking/AlphaTracker/train_yolo/darknet/backup/demo/yolov3-mice_final.weights'

https://drive.google.com/file/d/1N0JjazqW6JmBheLrn6RoDTSRXSPp1t4K Save the file to 'AlphaTracker/Tracking/AlphaTracker/data/demo.mp4'

https://drive.google.com/file/d/15dR-vVCEsg2z7mEVzJOF9YDW6YioEU3N' Save the file to 'AlphaTracker/Tracking/AlphaTracker/data/sample_annotated_data.zip' Extract all, then move/rename the resulting folder to 'AlphaTracker/Tracking/AlphaTracker/data/sample_annotated_data' (Naming it this way will match the setting.py file and you will not need to make changes.)

https://drive.google.com/file/d/1c6vJQbAm_TcGyTCr1ah-x_R-iIYmT9TM Save the file to 'AlphaTracker/UI/data/scipy.data'

laurelrr avatar Mar 18 '22 21:03 laurelrr

Hi, thank you for the quick response. It works fine with weights attached to your email. Thanks so much !!

Monami

2022年3月19日(土) 6:55 Laurelrr @.***>:

I suspect that your institution's firewall is blocking the install script from automatically downloading the models and sample data sets. You will know this is the case if your files are only 3 kb or less.

As a workaround, you may manually download each file using a browser and save the datasets to the correct folder. Click each link below and save it to the corresponding location.

https://drive.google.com/file/d/1OPORTWB2cwd5YTVBX-NE8fsauZJWsrtW Save the file to './models/sppe/duc_se.pth'

https://drive.google.com/file/d/1g8uJjK7EOlqrUCmjZTtCegwnNsBig6zn Save the file to './train_yolo/darknet/darknet53.conv.74'

https://drive.google.com/file/d/1_BwtYySpX9uWDgdwqw0UEppyMYYv1gkJ Save the file to './train_sppe/exp/coco/demo/model_10.pkl'

https://drive.google.com/file/d/13zXkuZ4dNm3ZOwstr1sSWKOOzJ19XZpN Save the file to './train_yolo/darknet/backup/demo/yolov3-mice_final.weights'

https://drive.google.com/file/d/1N0JjazqW6JmBheLrn6RoDTSRXSPp1t4K Save the file to './data/demo.mp4'

https://drive.google.com/file/d/15dR-vVCEsg2z7mEVzJOF9YDW6YioEU3N' Save the file to './data/sample_annotated_data.zip' Extract all to the folder './data/sample_annotated_data'

https://drive.google.com/file/d/1c6vJQbAm_TcGyTCr1ah-x_R-iIYmT9TM Save the file to '../../UI/data/scipy.data'

— Reply to this email directly, view it on GitHub https://github.com/ZexinChen/AlphaTracker/issues/9#issuecomment-1072844664, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKVVO5AJMINW2VCG7ERKMFDVAT3WNANCNFSM5RASKAHA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

--

Monami Nishio(西尾 萌波)

Sophomore University of Tokyo Japan

E-mail : @.***

monami-nishio avatar Mar 18 '22 23:03 monami-nishio