if self.axes is None:
self.axes = [i for i in range(len(inputs.shape)) if i != self.channel_axis]
If I understood correctly, the above code is calculating axes to get means and variances for the normalization.
But it looks weird to me because self.channel_axis can be -1. Shouldn't this change like this or something similar?
if self.axes is None:
self.axes = [i for i in range(len(inputs.shape)) if i != self.channel_axis]
if self.channel_axis == -1:
self.axes = self.axes[-1]
New Issue Checklist
Issue Description
https://github.com/tensorlayer/tensorlayer/blob/master/tensorlayer/layers/normalization.py#L291
If I understood correctly, the above code is calculating axes to get means and variances for the normalization. But it looks weird to me because self.channel_axis can be -1. Shouldn't this change like this or something similar?