houqb / SPNet

Code for our CVPR2020 paper "Strip Pooling: Rethinking Spatial Pooling for Scene Parsing"
MIT License
387 stars 57 forks source link

Hello, thank you for your excellent contributions. I have a question. I want to ask, I always get the error of object has no attribute '_up_kwargs' when I add the strippooling module to my own network. What is the reason? My code is as follows, #3

Closed houqian2180320171 closed 4 years ago

houqian2180320171 commented 4 years ago

def init (self, nDenselayer, channels, growth, norm_layer = nn.BatchNorm2d, ** kwargs):          super (RDB1, self) . init ()          modules = []          channels_buffer = channels          for i in range (nDenselayer):              modules.append (make_dense1 (channels_buffer, growth, 3, norm_layer, self._up_kwargs))

swjtulinxi commented 4 years ago

hi,i can not find the code of spm in you model,can you show me where is it? thanks

houqb commented 4 years ago

You can find it in models/resnet.py

houqb commented 4 years ago

def init __ (self, nDenselayer, channels, growth, norm_layer = nn.BatchNorm2d, kwargs):          super (RDB1, self) .** init __ ()          modules = []          channels_buffer = channels          for i in range (nDenselayer):              modules.append (make_dense1 (channels_buffer, growth, 3, norm_layer, self._up_kwargs))

you can ignore it.