Skip to content

Commit

Permalink
Up
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickvonplaten committed Sep 29, 2024
1 parent 8970dcc commit 1a7c9cf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/mistral_common/tokens/tokenizers/multimodal.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@
_cv2_installed = True
except ImportError:
_cv2_installed = False
except Exception:
except Exception as e:
# cv2 has lots of import problems: https://github.com/opencv/opencv-python/issues/884
# for better UX, let's simple skip import errors for now
logger.warn(
"Warning: Your installation of OpenCV appears to be broken. "
logger.warning(
f"Warning: Your installation of OpenCV appears to be broken: {e}."
"Please follow the instructions at https://github.com/opencv/opencv-python/issues/884 "
"to correct your environment. The import of cv2 has been skipped."
)
Expand Down

0 comments on commit 1a7c9cf

Please sign in to comment.