Using blobFromImage with RGB-T or RGB-Depth 4 channel image

I’m using function blobFromImage to feed the output to DNN. Can I use this with 4-channel image, where last channel is not alpha value but thermal value? I’m using it right now, there is no error but the results of DNN are not satisfying.

what DNN is that? who constructed it? who trained it?

you must respect the network’s input dimensions and type of data.

it doesn’t magically accept arbitrary numbers of channels. the network’s first layer determines the width, height, and number of channels you can feed into it.

it also doesn’t magically understand thermal image data. it wasn’t trained for that.