I am creating a new environment using anaconda in windows with some packages
conda create -n myenv
conda activate myenv
conda install python
conda install cvxopt
conda install gym
conda install networkx
conda install pandas
conda install matplotlib
It installed the following versions:
python-3.9.2
cvxopt-1.2.6
gym-0.18.0
networkx-2.5
pandas-1.2.3
matplotlib-3.3.4
When I try to run any simple code that import numpy: I am getting the following error:
Traceback (most recent call last):
File "C:\Users\kkris\anaconda3\envs\cbf_gym\lib\site-packages\numpy\core\__init__.py", line 22, in <module>
from . import multiarray
File "C:\Users\kkris\anaconda3\envs\cbf_gym\lib\site-packages\numpy\core\multiarray.py", line 12, in <module>
from . import overrides
File "C:\Users\kkris\anaconda3\envs\cbf_gym\lib\site-packages\numpy\core\overrides.py", line 7, in <module>
from numpy.core._multiarray_umath import (
ImportError: DLL load failed while importing _multiarray_umath: The specified module could not be found.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "c:\Users\kkris\Documents\GitHub\DC-microgrids\run_microgrid.py", line 1, in <module>
import numpy as np
File "C:\Users\kkris\anaconda3\envs\cbf_gym\lib\site-packages\numpy\__init__.py", line 145, in <module>
raise ImportError(msg)
ImportError:
IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE!
Importing the numpy C-extensions failed. This error can happen for
many reasons, often due to issues with your setup or how NumPy was
installed.
We have compiled some common reasons and troubleshooting tips at:
https://numpy.org/devdocs/user/troubleshooting-importerror.html
Please note and check the following:
* The Python version is: Python3.9 from "C:\Users\kkris\anaconda3\envs\cbf_gym\python.exe"
* The NumPy version is: "1.20.1"
and make sure that they are the versions you expect.
Please carefully study the documentation linked above for further help.
Original error was: DLL load failed while importing _multiarray_umath: The specified module could not be found.
I verified that my path variables for anaconda and accurate and my previous environments are working.