A clear and concise description of what the bug is.
Steps to reproduce the behavior:
1.python3 detect.py --source test_data/imgs/people1.jpg --cfg cfg/yolov3.cfg --weights weights/yolov3.weights
A clear and concise description of what you expected to happen.
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
i have old version of utils which works fine
Hello, thank you for your interest in our work! This is an automated response. Please note that most technical problems are due to:
git clone version of this repository we can not debug it. Before going further run this code and ensure your issue persists:sudo rm -rf yolov3 # remove exising repo
git clone https://github.com/ultralytics/yolov3 && cd yolov3 # git clone latest
python3 detect.py # verify detection
python3 train.py # verify training (a few batches only)
# CODE TO REPRODUCE YOUR ISSUE HERE
train_batch0.jpg and test_batch0.jpg for a sanity check of training and testing data.If none of these apply to you, we suggest you close this issue and raise a new one using the Bug Report template, providing screenshots and minimum viable code to reproduce your issue. Thank you!
I have encountered the problem too.
@ujsyehao Do you solve the problem? I have met the same problem
@farazBhatti @ujsyehao @MengXiao92 this error is not reproducible.
git clone https://github.com/ultralytics/yolov3
python3 detect.py --source data/samples/zidane.jpg --cfg cfg/yolov3.cfg --weights weights/yolov3.weights
Namespace(cfg='cfg/yolov3.cfg', conf_thres=0.3, data='data/coco.data', device='', fourcc='mp4v', half=False, img_size=416, nms_thres=0.5, output='output', source='data/samples/zidane.jpg', view_img=False, weights='weights/yolov3.weights')
Using CUDA device0 _CudaDeviceProperties(name='Tesla P100-PCIE-16GB', total_memory=16280MB)
Downloading https://drive.google.com/uc?export=download&id=1uTlyDWlnaqXcsKOktP5aH_zRDbfcDp-y as weights/yolov3.weights... Done (6.2s)
image 1/1 data/samples/zidane.jpg: 256x416 2 persons, 1 ties, Done. (0.185s)
Results saved to /content/yolov3/output
Done. (0.264s)
In actual experiment,I use last version code to replace 'utils' filefolder and models.py file.I also encounter this problem,but I use previous version same file fix this problems.
If you have this problem,you can check this point.
@farazBhatti @MengXiao92 @ujsyehao @Ronales I fixed it when update torchvision
@litingsjj which version of torchvision do you recommend?
@farazBhatti torch==1.3.0 and torchvision==0.2.x, I encounter this proble. when update torchvision==0.4.1, it's fixed.
I made these changes and am still running into the issue:
File "yolov3/utils/utils.py", line 527, in non_max_suppression
i = torchvision.ops.boxes.nms(boxes, scores, iou_thres)
AttributeError: module 'torchvision' has no attribute 'ops'
@blakete your environment is likely not set up correctly.
To access an up-to-date working environment (with all dependencies including CUDA/CUDNN, Python and PyTorch preinstalled), consider a:
@glenn-jocher
You were right. After setting up a new virtual environment and installing all of the dependencies from scratch I was able to run the code. Thank you for the quick feedback!
These specifics worked for me are:
Most helpful comment
I have encountered the problem too.