Traceback (most recent call last):
File "C:\ProgramData\Miniconda3\envs\faststain\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\ProgramData\Miniconda3\envs\faststain\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\ProgramData\Miniconda3\envs\faststain\Scripts\faststainnorm.exe\__main__.py", line 7, in <module>
File "C:\ProgramData\Miniconda3\envs\faststain\lib\site-packages\source\__main__.py", line 217, in main
run(*vars(ret).values())
File "C:\ProgramData\Miniconda3\envs\faststain\lib\site-packages\source\__main__.py", line 75, in run
target = cv2.cvtColor(cv2.imread(reference_image_filename), cv2.COLOR_BGR2RGB)
cv2.error: OpenCV(4.5.3) C:\Users\runneradmin\AppData\Local\Temp\pip-req-build-q3d_8t8e\opencv\modules\imgcodecs\src\loadsave.cpp:77: error: (-215:Assertion failed) pixels <= CV_IO_MAX_IMAGE_PIXELS in function 'cv::validateInputImageSize'
It looks like an opencv error related to input image size. The images are around 800 MB and 1.5GB each (input and reference image).
I tried editing the _ main _.py file and including this
os.environ["OPENCV_IO_MAX_IMAGE_PIXELS"] = str(pow(pow(2,40))) before importing cv2. This doesn't fix it unfortunately.
Hi
I was trying faststain on some tif images and ran into this error
It looks like an opencv error related to input image size. The images are around 800 MB and 1.5GB each (input and reference image).
I tried editing the _ main _.py file and including this
os.environ["OPENCV_IO_MAX_IMAGE_PIXELS"] = str(pow(pow(2,40)))before importing cv2. This doesn't fix it unfortunately.Cheers
Pradeep