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

Fix imagenet models for v2 #104

Merged
merged 1 commit into from
Aug 17, 2017

Conversation

mitmul
Copy link
Member

@mitmul mitmul commented Aug 10, 2017

Actually models other than NIN work correctly with the current code, but NIN model raises the error below with Chainer v2.

$ cd chainermn/examples/imagenet/models_v2
$ python -c 'from nin import NIN; model = NIN()'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Users/shunta/Codes/chainermn/examples/imagenet/models_v2/nin.py", line 18, in __init__
    None, (96, 96, 96), 11, stride=4, wscale=w),
  File "/Users/shunta/.pyenv/versions/anaconda3-4.4.0/lib/python3.6/site-packages/chainer/links/connection/mlp_convolution_2d.py", line 69, in __init__
    argument.check_unexpected_kwargs(kwargs, wscale=msg)
  File "/Users/shunta/.pyenv/versions/anaconda3-4.4.0/lib/python3.6/site-packages/chainer/utils/argument.py", line 4, in check_unexpected_kwargs
    raise ValueError(message)
ValueError: wscale is not supported anymore. Use conv_init and bias_init argument to change the scale of initial parameters.

This PR fixes this and also update all other models for V2 style.

@iwiwi
Copy link
Contributor

iwiwi commented Aug 15, 2017

Thank you for the PR! We will shortly merge this after testing them locally.

@iwiwi iwiwi added the bug label Aug 15, 2017
@shu65 shu65 added this to the v1.0.0 milestone Aug 16, 2017
@keisukefukuda keisukefukuda merged commit a8287ee into chainer:master Aug 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants