Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Segnet] TypeError: new() received an invalid combination of arguments #42

Open
tailongnguyen opened this issue Jul 17, 2018 · 6 comments

Comments

@tailongnguyen
Copy link

Hi,
I am using pytorch version 0.4.0, python 3.6 and this code appears to need a minor modification to make Segnet works.
Here is the bug:
image
I found out that the line 12 should change from
middle_channels = in_channels / 2
to
middle_channels = in_channels // 2

@oujieww
Copy link

oujieww commented Jul 25, 2018

@tailongnguyen is your training ok? i also want to train segnet on voc but with training go on ,my mean iu is always =0.03469,can you give me your setting about trainning code,i use the setting same as fcn,lr=2.5e-4

@tailongnguyen
Copy link
Author

@oujieww
I used this code but did not focused on this SegNet architecture, thus only tried on training with one set of hyper parameters (lr = 1e-4, negative log likelihood loss function with weighted scheme following E-Net) . The performance was unexpectedly bad, too. I am not sure if there was something wrong with the code or my dataset is just not suitable with this model, so I skipped it.
However, if you ask about the training, my mean IoU DID change over the training phase.

@oujieww
Copy link

oujieww commented Jul 26, 2018

@tailongnguyen yeah, is your training mIoU is nromal? such as bigger than 0.5? and i have tried this code on fcn32s even is better than official code mIoU is 0.6447 i got. but for other model of this code i can not work, ,XD , do u know where can find a good code of semantic segmentation , i want to do some test on segmentation XD

@tailongnguyen
Copy link
Author

tailongnguyen commented Jul 26, 2018 via email

@oujieww
Copy link

oujieww commented Jul 26, 2018

@tailongnguyen thank you !!!

@robinreni96
Copy link

Its simple in the Decoderblock inside init function instead of
middle_channels = in_channels / 2
use
middle_channels = int(in_channels / 2)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants