Opencv installation

I’m trying to install opencv, I used “nix-env -i opencv” but I’m not sure what to do next.

If you want to use OpenCV from Python, you can do:

nix-shell -p 'python39Packages.opencv4'

It’ll create a new shell with python with opencv. So you can start python and import opencv:

$ python
Python 3.9.12 (main, Mar 23 2022, 21:36:19) 
[GCC 11.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import cv2