-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add norm param to ResNet #7752
Add norm param to ResNet #7752
Conversation
Hi @Pkaps25 thanks for this, is it ready to review? We should add at least one test for the new argument in Daf3D however. |
Daf3D doesn't currently have a |
Signed-off-by: Peter Kaplinsky <peterkaplinsky@gmail.com>
Signed-off-by: Peter Kaplinsky <peterkaplinsky@gmail.com>
Signed-off-by: Peter Kaplinsky <peterkaplinsky@gmail.com>
Signed-off-by: Peter Kaplinsky <peterkaplinsky@gmail.com>
I, Peter Kaplinsky <peterkaplinsky@gmail.com>, hereby add my Signed-off-by to this commit: 335ab0f Signed-off-by: Peter Kaplinsky <peterkaplinsky@gmail.com>
Ah, nice catch. I will take a look.
…On Tue, May 14, 2024 at 11:56 PM YunLiu ***@***.***> wrote:
Hi @Pkaps25 <https://github.com/Pkaps25>, after we discussed from the dev
meeting.
One thing I overlooked in this PR
<https://github.com/Project-MONAI/MONAI/pull/7749/files> is whether the
change of the name of act will affect the weights loading of the original
model, can you help check that, if so, maybe we need to revert the name
change for the variable and add an alias.
Thanks!
—
Reply to this email directly, view it on GitHub
<#7752 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKNCEMEWE4G2GVSQNSN5GMTZCLMFXAVCNFSM6AAAAABHPJ56SWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMJRGUZTGMBTGI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Hi @KumoLiu, I trained ResNet with latest MONAI and loaded the model state using my branch. The model loaded successfully, had the same layers, and a forward pass with a random input produced the same result on both branches. Let me know if that's a sufficient check and if we need to add tests for this compatibility in the future |
Thanks to the quick verification, and make sense it works since the activation function usually has no parameters to learn in the neural network. I guess we don't need to add a test for this. But if the norm layer name changed, it should be worth to add the test. What do you think? cc @ericspod |
Agreed that if the name changes we should add that test, but I don't change the name in this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The norm type added in ResNet look good to me. But have a concern regarding the norm layer added in daf3d added inline. Thanks!
This looks good then, I thought that a layer with no parameters wouldn't show up in the state dict but it's best to double check. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think things are fine if all comments are addressed.
/build |
1 similar comment
/build |
Fixes #7294 .
Description
Adds a
norm
param to ResNetTypes of changes
./runtests.sh -f -u --net --coverage
../runtests.sh --quick --unittests --disttests
.make html
command in thedocs/
folder.