Could you clarify the use case a little bit more? We discussed earlier that the input to norm will always have a channel dimension of 2 due to the call of complex_to_chan_dim. Are you intending to call norm without this function?
A secondary item is that with the new parameter we should have a new unit test.
Originally yes, we discussed some use cases where the input to NormUnet itself is multi-coil, which requires this change.
complex_to_chan_dim only guarantees c is a multiple of 2, which is fine with the current example, because the input to NormUnet is always functionally single-coil (both in the sensitivity module and the refinement module).
Even if we only want to use functionally single-coil input though, the old version of the code was a bit confusing, because it didn't explicitly require that c == 2, but in fact would fail to broadcast correctly for c != 2.
Originally yes, we discussed some use cases where the input to NormUnet itself is multi-coil, which requires this change.
complex_to_chan_dim
only guarantees c is a multiple of 2, which is fine with the current example, because the input to NormUnet is always functionally single-coil (both in the sensitivity module and the refinement module).Even if we only want to use functionally single-coil input though, the old version of the code was a bit confusing, because it didn't explicitly require that c == 2, but in fact would fail to broadcast correctly for c != 2.