pip opencv
- pip-opencv
This script allow us to install only one of the four available opencv-python packages via pip-tools.
- Arguments:
$1… - The path to therequirements.txtto be inline patched
OpenCV provides four interchangable python packages: - opencv-contrib-python: main modules, contrib/extra, GUI - opencv-python: main modules, GUI - opencv-contrib-python-headless: main modules, contrib/extra, headless (no GUI) - opencv-python-headless: main modules, headless (no GUI)
Users are advised to install only one of the four packages opencv-python depending on their needs https://pypi.org/project/opencv-python/#:~:text=There%20are%20four,only%20one%20package
This function will modify a pip-tools requirements.txt file to keep only the most fully featured opencv-python package. Less featured opencv-python packages are commented out from the requirements.txt file.
A subsequent pip-sync must be run with the argument --pip-args --no-deps to ensure only one opencv-python package is installed.
- Arguments:
$1… -requirements.txtfile to be modified
- pip-opencv
Same syntax as pip-opencv