Comments (7)
hi @kamauz , the priors/anchors needed in your model and the way of branching out paths to detection head might be different.
from pytorch-ssd.
@kamauz Hi, do you find the solution? I also changed the network structure and faced the same problem as yours.
from pytorch-ssd.
@qfgaohao Hi, in this situation, should I change the parameters of SSDSpec in the config file? Thank you!
from pytorch-ssd.
@qfgaohao I ve abandoned this repository time ago for this problem. I remember that I tried to change SSDSpec but I couldn't make it work. I don't exclude that the solution was there by the way. It is tricky maybe
from pytorch-ssd.
@kamauz @notabigfish you can also change the number of channels of extra layers to make the network output is consistent with the generated anchors.
from pytorch-ssd.
Thank you for the answers!! Actually, similar to @kamauz , I delete all the BatchNorm layers after Pointwise Conv layer and got location
with size [..., 1434] but priors
with size [..., 3000]. The reason is that the first feature map size in vision/ssd/ssd.py
line 58 is [1, 576, 10, 10], but it should be [1, 576, 19, 19]. So I changed line 14 in vision/ssd/config/mobilenetv1_ssd_config.py
to
SSDSpec(10, 16, SSDBoxSizes(60, 105), [2, 3])
Then the error that @kamauz mentioned is fixed. However, a new error shows up:
RuntimeError: invalid argument 0: Sizes of tensors must match except in dimention 1. Got 41 and 47 in dimension 0 at /pytorch/aten/src/TH/generic/THTensor.cpp:711
It turns out after changing the configuration, some labels
got size torch.Size([0])
.
I did not change any convolution layer but only deleted the batchnorm layer. So in theory the output channels are unchanged, right? Or maybe I miss something? Thank you!! @qfgaohao
from pytorch-ssd.
@notabigfish Are you trying in the same situation that I tried? So with the PTH file got from a conversion of the official tensorflow model?
By the way months ago I assumed that maybe Google developers experimented a different version with respect to the official SSD paper. I don't know if removing the BatchNorm could be a good idea. Maybe it's a matter of implemented choices that we can't know unless we can see how they actually trained the network. Keep me updated if you find a solution
from pytorch-ssd.
Related Issues (20)
- Training doesn't start - I'm getting an error with the data loader HOT 4
- convert_to_caffe2_models.py: RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cuda:0 and cpu! HOT 2
- SSDSpec for image size smaller than 300 HOT 1
- Re-training SSD-Mobilenet - loss going up and down
- Error using run_ssd_live_demo.py HOT 1
- [Question] what these parameters mean? HOT 2
- base net for mobilenetv3 ssd HOT 1
- ssd-mobilenet to tensorrt
- pytorch模型量化时报错
- Mobilnet-ssdv2 HOT 1
- NAN values in Boxes HOT 1
- How can I train the model without pre-trained weight specified? HOT 1
- runtime error mobillenet-ssd-v2 HOT 5
- run_ssd_example.py box variable type does not mach opencv rectangle and putText functions
- FileNotFoundError: [Errno 2] No such file or directory: 'models/mobilenet_v1_with_relu_69_5.pth'
- cv2.error: OpenCV(4.5.5) : -1 : error: (-5:Bad argument) in function 'rectangle' HOT 1
- Could u add Nesterov momentum in SGD
- 4xgx
- RuntimeError: The size of tensor a (12828) must match the size of tensor b (3000) at non-singleton dimension 1 HOT 3
- ValueError encountered during retraining on Open Images Dataset HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pytorch-ssd.