[PYTHON] Numpy 1.19.4 error RuntimeError: The current Numpy installation fails to pass a sanity check due to a bug in the windows runtime.

I ran into an unfamiliar error when trying to use Numpy. I was able to solve it unexpectedly easily, but it seems that there are many people who encounter it, so I will leave it for the time being.

environment

error

RuntimeError: The current Numpy installation ('C:\\Users\\ ... \\venv\\lib\\site-packages\\numpy\\__init__.py') fails to pass a sanity check due to a bug in the windows runtime. See this issue for more information: https://tinyurl.com/y3dm3h86

Solution

When I looked it up, StackOverFlow asked [Questions about the same error](https://stackoverflow.com/questions/64654805/how-do-you-fix-runtimeerror-package-fails-to-pass-a-sanity-check- There was for-numpy-an). According to this, it seems that the cause is the recently released Numpy 1.19.4.

To avoid this, simply lower the version of Numpy by one.

pip install numpy==1.19.3

Recommended Posts

Numpy 1.19.4 error RuntimeError: The current Numpy installation fails to pass a sanity check due to a bug in the windows runtime.
Instructions for connecting Google Colab. To the local runtime in a Windows environment
How to check the memory size of a variable in Python
How to check the memory size of a dictionary in Python
About the bug that anaconda fails to import numpy and scipy
I made a program to check the size of a file in Python
How to sort by specifying a column in the Python Numpy array.
If you get a no attribute error in boto3, check the version