Replies: 1 comment
-
Hi @ClarkQTIM, after a deep look at your code, I find that the comma following the In addition, the reason why it didn't happen in 1.0.0 is that the version at that time had these parameters hard-coded. MONAI/monai/networks/nets/attentionunet.py Line 151 in 1700933 Hope it can help you. Thanks! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Describe the bug
Simply put, it seems no matter what is used for the stride parameter in MONAI's implementation of AttentionUNet (https://docs.monai.io/en/stable/networks.html#attentionunet), one will either get an output of 'tuple index out of range' if the number of stride lengths provided is less than the length of the channel parameter minus 1 or 'expected stride to be a single integer value or a list of 1 values to match the convolution dimensions, but got stride=[2, 2]', where the value (in this case, 2) depends on what value you put in the list, if you have a list of the correct size.
For example, if the channels is (8, 16, 32, 64, 128) and the strides is (2, 2, 2, 2), it will produce this error. Interestingly, this error only appears in MONAI version 1.1.0, as in 1.0.0, it worked as I expected it would.
To Reproduce
The following should reproduce the error:
The error
Expected behavior
I expected this would not bring up a stride error. With 1.0.0, it did not, but with 1.1.0, it does. Playing with the strides parameter as a single integer value or a list with a single (or multiple) values does not seem to change this.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment
Ensuring you use the relevant python executable, please paste the output of:
python -c 'import monai; monai.config.print_debug_info()'
Output of the command:
Additional context
I appreciate the support.
Beta Was this translation helpful? Give feedback.
All reactions