I am currently trying to pip install tensorflow
, which works but after I install it, and then import it into my python module via import tensorflow as tf
I get following error message:
ImportError: Could not find the DLL(s) 'msvcp140_1.dll'. TensorFlow requires that these DLLs be installed in a directory that is named in your %PATH% environment variable. You may install these DLLs by downloading "Microsoft C++ Redistributable for Visual Studio 2015, 2017 and 2019" for your platform from this URL: https://support.microsoft.com/help/2977003/the-latest-supported-visual-c-downloads
I installed the msvcp140_1.dll
and put it into C:UsersUserAppDataLocalProgramsPythonPython37
which is contained in my path environment variable.
As you can see I am using Python 3.7 as 3.8 is not supported by tensorflow. Any ideas how to fix this?
Advertisement
Answer
You can find msvcp140.dll in your %windows%/System32 folder, once you installed VC++ DIST for VS 2015, for msvcp140_1.dll you need to goto this page
https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads
and in the section :Visual Studio 2015, 2017 and 2019, pick the correct package with the arch of your PC.