Python whl file interpretation and installation

.whl file explanation

The whl file is a python installation package saved in the wheel format, which is the standard built-in package format of the Python distribution. A WHL file contains all the files and metadata for a Python installation, which also includes the Wheel version used and the packaging specification. WHL files are compressed using Zip compression, which is actually a compressed file .
Wheel is currently considered the standard format for python binary packages.

To put it bluntly, .whl is the compressed package of python

Take a chestnut:

rknn_toolkit-1.7.1-cp36-cp36m-win_amd64.whl

Among them, rknn_toolkit is the file name, cp36 refers to the corresponding python version, cp36 refers to python3.6 , similarly, cp37 refers to python3.7, win refers to the operating system as windows, and amd refers to 64-bit

The installation format of the whl file:

pip install 文件名.whl

Some error descriptions

  1. file does not exist
    insert image description here
    At this time, you need to switch the file location of the terminal to the address where you saved the .whl file.
    For example, my file address:
    insert image description here
    insert image description here

  2. .whl is not a supported wheel on this platform.
    This means that your current python version is inconsistent with the python version of the .whl file. Just switch the environment at this time

successful installation page

insert image description here

Guess you like

Origin blog.csdn.net/qq_52109814/article/details/124354299