I'm currenty trying to save a cv::Mat of type CV_64FC3 to my harddisk of float values between about 0 and 5. If you want to know why, read below.
I have been looking into saving it in hdr format, but if I just call imwrite("myname.hdr", myCV_64FC3);
, which they mention in this tutorial http://www.programmersought.com/article/33831043697/, it outputs a format that if you imread it again, is a UINT8 type and does not contain the float values anymore.
How do you save this correctly?
Why do I want this?
I want to use this to save the standard deviations of my background, which have float values of about 0 to 5, can be a bit higher. Now I can cast them to CV_8UC3 and be done with it, but it will round my values down. While I want to use it to threshold at x times the standard deviation, I want to keep this precise, since 3 times a standard deviation of 0.7, is something else than zero.
Does anyone know a way to save this?