When channel_axis is provided, Cellpose appears to mis-handle the image axes. In this case, it runs
image = io.imread_3D(image_name) (line 214 in __main__), which moves the channel axis to the last position (axis 3). However, in lines 217–218, channel_axis is not updated accordingly because it is not None, leading to an inconsistency between the image shape and the specified axes.