Open jklaise opened 2 years ago
Another suggestion is to not make it a required dependency and start recommending opencv-python-headless
as alternative for opencv-python
. Much better in docker images.
Pull Request #853
Just created a pull request to solve this issue.
PS: I implemented every alternative (known to me) using scipy, scikit-image, custom numpy convolution, etc., and compared the results using Mean Squared Error (MSE) and Structural Similarity Index (SSI). If anyone is interested in those comparisons, let me know I'll put the notebook somewhere online.
opencv
is a fairly heavy dependency and requires building (see recent CI failures), but we only use it in one place for making image perturbations (https://github.com/SeldonIO/alibi-detect/blob/master/alibi_detect/utils/perturbation.py). We should either explore replacing it with another library that's lighter (potentially scikit-image) or make it an optional dependency.