Last answered:

07 Mar 2024

Posted on:

17 Jul 2023

0

Module not found error

Hi,


I have followed the same steps as mentioned in another question posted by using pip install numpy and have done the same with opencv. But even after that its showing module not found. Also can you provide with a tutorial from the begining to run vscode as am having some confusion. 


Kindly find the screenshot attached.

3 answers ( 0 marked as helpful)
Instructor
Posted on:

19 Jul 2023

1

Hey Abishek,


Thank you for reaching out!


Please, open your Anaconda Prompt and type in the following:

activate capstone
conda list

After executing the second line, you will get a list of the librarires installed within the capstone environment. Make sure you have both numpy and opencv in the list:

Then, try to execute the code again in Visual Studio (making sure you're in the capstone environment).


Kind regards,

365 Hristina

Posted on:

06 Mar 2024

0

Hello @hristina

I have the both numpy and opencv installed but still get the same error message

 

Instructor
Posted on:

07 Mar 2024

0

Hey Ebe,


Thank you for reaching out!


First, ensure the opencv library is installed inside your environment which I believe you've called capstone_opencv. To do so, execute the following steps:

1. Open the Anaconda Prompt.

2. Activate the capstone_opencv environment through

conda activate capstone_opencv

3. List all available packages using the command

conda list

4. If you don't find find the opencv library there, then please install it using the command

conda install -c conda-forge opencv

5. Restart Visual Studio, ensure you're within the capstone_opencv environment, and try importing cv2 anew.


Let me know if the issue persists.


Kind regards,

365 Hristina

Submit an answer