Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

copyTo() does not take any flags, you probably wanted a conversion to float:

image.convertTo(tensor_image, CV_32F);

(note, that it only takes the "depth", not the number of channels here (those are unchanged).)