python: wrap long lines in the bfloat16 / float8 binding code and tests

Signed-off-by: Abhishek Gola <abhishek.gola@bigvisionllc.com>
This commit is contained in:
Abhishek Gola
2026-10-30 16:04:56 +05:30
parent 26bd26e400
commit 782daa0ab9
6 changed files with 14 additions and 8 deletions

View File

@@ -372,7 +372,8 @@ PyObject* pyopencv_from(const cv::Mat& m)
}
if( useExactNumpyDtypes() )
CV_LOG_ONCE_WARNING(NULL, "Python bindings: setUseExactNumpyDtypes(True) is set, "
"but NumPy does not know bfloat16 / float8 and they are returned as float32. "
"but NumPy does not know bfloat16 / float8 and they are "
"returned as float32. "
"Import ml_dtypes to keep the exact dtype.");
// NumPy alone cannot name these; widen to float32 (lossless).
cv::Mat m32f;