# Installing as part of the notebooks is not the best option -- see above for explanation
# !apt update && apt install ffmpeg libsm6 libxext6 -y
!pip install opencv-python
Collecting opencv-python
Using cached opencv_python-4.5.1.48-cp37-cp37m-manylinux2014_x86_64.whl (50.4 MB)
Requirement already satisfied: numpy>=1.14.5 in /shared-libs/python3.7/py/lib/python3.7/site-packages (from opencv-python) (1.19.5)
Installing collected packages: opencv-python
Successfully installed opencv-python-4.5.1.48
WARNING: You are using pip version 20.1.1; however, version 21.0.1 is available.
You should consider upgrading via the '/root/venv/bin/python -m pip install --upgrade pip' command.
import cv2