I am trying to run the following Code Snippet in a Jupyter Notebook (Python) via VSCode and I am getting the following error:
import matplotlib.pyplot as plt
from scipy.integrate import odeint
Error:
{
"name": "ModuleNotFoundError",
"message": "No module named 'matplotlib'",
"stack": "---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
Cell In[2], line 3
2 import numpy as np
----> 3 import matplotlib.pyplot as plt
4 from scipy.integrate import odeint
ModuleNotFoundError: No module named 'matplotlib'"
I checked the active Virtual environment and I am certain its the right one. Its the only one the ipykernel is even installed in and I installed and uninstalled matplotlib multiple times. Any help would be greatly appreciated, as far as I can see, most similiar issues were resolved by switching to the right venv.
EDIT
Looks like the issue was caused by moving my venv into this project, which caused matplot to not install properly. Creating a new venv resolved the issue.
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1742416948a4439925.html
评论列表(0条)