Problems with code in python

this doesn't have anything to do with arduino but im trying to use visual studio code and get the opencv library to work but it says that cv2 is not recongnized

import cv2 as cv

img = cv.imread("Photos/cat.jpg")

cv.imshow('Cat' , img)

cv.waitKey(0)

and you thought it would be appropriate to ask the question in a "Using Arduino" forum ?? :slight_smile:

even on a dedicated forum you'd be asked for waaaay more info..

like have you double checked the installation process? which python's version do you run? what's the error message? ...

opencv-python · PyPI

i use python 3.10

Just install the library?

pip install opencv-python

ModuleNotFoundError: No module named 'cv2'

I already did

I'd say start by reading in details the manual

it says that those commands are already satisfied for windows

Your other topic on the same subject deleted.

Please do not duplicate your questions as doing so wastes the time and effort of the volunteers trying to help you as they are then answering the same thing in different places.

Repeated duplicate posting could result in a temporary or permanent ban from the forum.

Could you take a few moments to Learn How To Use The Forum

It will help you get the best out of the forum in the future.

Thank you.

Ok thank you!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.