使用pip安装时wheel文件应放置在何处?含Windows7下NumPy安装场景
Installing NumPy Wheel from Christoph Gohlke: File Location Guide
Hey there! Let me break this down clearly for you—you don’t have to place that NumPy wheel file in your Python installation directory (C:\Program Files\Python36\). It can live anywhere on your Windows 7 system, as long as you point pip to the correct file path when running the install command.
How to handle different locations:
- If you save the wheel in a custom folder like
D:\Python Packages\, your install command would look like this:pip install D:\Python Packages\numpy-1.14.3+mkl-cp36-cp36m-win_amd64.whl - If your command prompt’s current working directory is already the folder where the wheel is stored, you can skip the full path and just run:
pip install numpy-1.14.3+mkl-cp36-cp36m-win_amd64.whl - A quick heads-up: if your file path includes spaces (like
C:\Users\Jane Smith\Downloads), wrap the path in double quotes to avoid syntax errors:pip install "C:\Users\Jane Smith\Downloads\numpy-1.14.3+mkl-cp36-cp36m-win_amd64.whl"
One extra tip:
If your Python is installed in the system-wide Program Files directory, you might need to run your command prompt as an administrator to avoid permission issues during installation. Just right-click the Command Prompt shortcut and select "Run as administrator" before executing the pip command.
内容的提问来源于stack exchange,提问作者RTC222
相关产品推荐
相关产品推荐

