Closed lauracanalini closed 2 years ago
Hi,
The channels dimension can not be changed because the pretrained kernels of the Conv layers have (usually) the same depth as the input. You can modify the height and width because it is just a matter of sliding the kernel window, but the depth of the channels has to be the same.
For those cases, You can try to replicate the image two times to get the three-channel input or add zeros or something to fill the other channels.
Hi, I am trying to import an onnx file with
import_net_from_onnx_file
with a specifiedinput_shape
. If I change the width and height dimensions everything is ok, but if I change the channel dimension it doesn't work anymore. For example:Output:
Is there a way to change the input layer to provide an input with a different number of channels?