Closed wumy27 closed 5 years ago
Need help. Thanks.
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!
what does it mean?
@wumy27 this error typically occurs when there is a mismatch between the shape of the input and the expected size within the code. This can happen due to changes made to the default repository or specific customizations involving the data and environment.
To troubleshoot, consider the following tips:
git clone
version of the repository to debug effectively.If none of these apply to your situation, feel free to close this issue and submit a new one using the Bug Report template, along with relevant screenshots and minimum viable code to replicate the issue. Thank you for your understanding!
File "", line 1, in
runfile('C:/Users/Lenovo/Desktop/yolov3-improvement/train.py', wdir='C:/Users/Lenovo/Desktop/yolov3-improvement')
File "E:\Users\Lenovo\Anaconda3\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 668, in runfile execfile(filename, namespace)
File "E:\Users\Lenovo\Anaconda3\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 108, in execfile exec(compile(f.read(), filename, 'exec'), namespace)
File "C:/Users/Lenovo/Desktop/yolov3-improvement/train.py", line 345, in
accumulate=opt.accumulate)
File "C:/Users/Lenovo/Desktop/yolov3-improvement/train.py", line 104, in train cutoff = load_darknet_weights(model, weights + 'darknet53.conv.74')
File "C:\Users\Lenovo\Desktop\yolov3-improvement\models.py", line 309, in load_darknet_weights conv_w = torch.from_numpy(weights[ptr:ptr + num_w]).view_as(conv_layer.weight)
RuntimeError: shape '[512, 256, 3, 3]' is invalid for input of size 537934