ayooshkathuria / YOLO_v3_tutorial_from_scratch

Accompanying code for Paperspace tutorial series "How to Implement YOLO v3 Object Detector from Scratch"
https://blog.paperspace.com/how-to-implement-a-yolo-object-detector-in-pytorch/
2.32k stars 724 forks source link

Error doing detection using Tiny_yolo network #17

Open akshayjrkp opened 6 years ago

akshayjrkp commented 6 years ago

I get this error:

Traceback (most recent call last): File "detect.py", line 171, in model(get_test_input(inp_dim, CUDA), CUDA) File "/home/akshayj/anaconda3/lib/python3.5/site-packages/torch/nn/modules/module.py", line 491, in call result = self.forward(*input, **kwargs) File "/home/akshayj/pytorch-yolo-v3/darknet.py", line 325, in forward x = torch.cat((map1, map2), 1) RuntimeError: invalid argument 0: Sizes of tensors must match except in dimension 1. Got 416 and 832 in dimension 2 at /opt/conda/conda-bld/pytorch_1524580978845/work/aten/src/THC/generic/THCTensorMath.cu:111

Any Idea Why this error occurs. Thanks in advance.

ayooshkathuria commented 6 years ago

This is a known issue. I'm busy at the moment. Won't be able to look it up until the end of this month. If you solve this, feel free to open a PR.

AhmedMagdyHendawy commented 5 years ago

did you solve it?

AbanoubMamdouh commented 5 years ago

@ayooshkathuria Any updates on working with the tiny yolov3 model? Problem seems to be in the route layer in the create_modules function Thanks in advance!

AbanoubMamdouh commented 5 years ago

Did some fixes, take a look at it here: https://github.com/AbanoubMamdouh/YOLO_v3_tutorial_from_scratch