python中的库有什么作用,python库在哪个文件夹

本文介绍了如何在Windows11上查看Python的安装路径、安装的库列表以及管理过时库的方法,包括使用`pip`命令检查、更新和查找第三方库的安装位置。
摘要由CSDN通过智能技术生成

大家好,给大家分享一下python中的库有什么作用,很多人还不知道这一点。下面详细解释一下。现在让我们来看看!


Win11查看安装的Python路径及安装的库


Python3(基础|高级)语法实战(|多线程|多进程|线程池|进程池技术)|多线程安全问题解决方案实战


Win11查看安装的Python路径及安装的库

anaconda3最新版安装|使用详情|Error: Please select a valid Python interpreter

Python函数绘图与高等代数互融实例(一):正弦函数与余弦函数

Python函数绘图与高等代数互融实例(二):闪点函数

Python函数绘图与高等代数互融实例(三):设置X|Y轴|网格线

Python函数绘图与高等代数互融实例(四):设置X|Y轴参考线|参考区域

Python函数绘图与高等代数互融实例(五): 则线图综合案例


一: python安装路径查看
1.1: windows键+R 打开cmd窗口:输入python  然后输入import sys  ;    sys.path;

如下图所示即可查看安装的位置; 退出该界面执行: quit(); 或者Ctrl+Z;


1.2:  cmd窗口输入: where python

 打开路径, cd 到输出的路径,之后输入:start.  会自动弹出安装的目录窗口.......................

输入start. 弹出如下窗显示pip安装依赖库目录 

1.3: 查看已经安装的库

D:\program_file_worker\anaconda>pip list
Package                       Version
----------------------------- ---------------
aiobotocore                   2.4.2
aiofiles                      22.1.0
aiohttp                       3.8.3
aioitertools                  0.7.1
aiosignal                     1.2.0
aiosqlite                     0.18.0
alabaster                     0.7.12
anaconda-catalogs             0.2.0
anaconda-client               1.12.0
anaconda-navigator            2.4.2
anaconda-project              0.11.1
anyio                         3.5.0
appdirs                       1.4.4
argon2-cffi                   21.3.0
argon2-cffi-bindings          21.2.0
arrow                         1.2.3
astroid                       2.14.2
astropy                       5.1
asttokens                     2.0.5
async-timeout                 4.0.2
atomicwrites                  1.4.0
attrs                         22.1.0
Automat                       20.2.0
autopep8                      1.6.0
Babel                         2.11.0
backcall                      0.2.0
backports.functools-lru-cache 1.6.4
backports.tempfile            1.0
backports.weakref             1.0.post1
bcrypt                        3.2.0
beautifulsoup4                4.12.2
binaryornot                   0.4.4
black                         0.0
bleach                        4.1.0
bokeh                         3.2.1
boltons                       23.0.0
boto3                         1.24.28


D:\program_file_worker\anaconda>pip freeze
aiobotocore @ file:///C:/b/abs_74o47svlua/croot/aiobotocore_1680004300264/work
aiofiles @ file:///C:/b/abs_9ex6mi6b56/croot/aiofiles_1683773603390/work
aiohttp @ file:///C:/ci_311/aiohttp_1676432932774/work
aioitertools @ file:///tmp/build/80754af9/aioitertools_1607109665762/work
aiosignal @ file:///tmp/build/80754af9/aiosignal_1637843061372/work
aiosqlite @ file:///C:/b/abs_9djc_0pyi3/croot/aiosqlite_1683773915844/work
alabaster @ file:///home/ktietz/src/ci/alabaster_1611921544520/work
anaconda-catalogs @ file:///C:/b/abs_8btyy0o8s8/croot/anaconda-catalogs_1685727315626/work
anaconda-client==1.12.0
anaconda-navigator==2.4.2
anaconda-project @ file:///C:/ci_311/anaconda-project_1676458365912/work
anyio @ file:///C:/ci_311/anyio_1676425491996/work/dist
appdirs==1.4.4
argon2-cffi @ file:///opt/conda/conda-bld/argon2-cffi_1645000214183/work
argon2-cffi-bindings @ file:///C:/ci_311/argon2-cffi-bindings_1676424443321/work
arrow @ file:///C:/ci_311/arrow_1678249767083/work
astroid @ file:///C:/ci_311/astroid_1678740610167/work
astropy @ file:///C:/ci_311_rebuilds/astropy_1678996071858/work
asttokens @ file:///opt/conda/conda-bld/asttokens_1646925590279/work
async-timeout @ file:///C:/ci_311/async-timeout_1676431518331/work
atomicwrites==1.4.0
attrs @ file:///C:/ci_311/attrs_1676422272484/work


1.4:过时的库:pip list --outdated

D:\program_file_worker\anaconda>pip list --outdated
Package                       Version   Latest       Type
----------------------------- --------- ------------ -----
aiobotocore                   2.4.2     2.6.0        wheel
aiofiles                      22.1.0    23.2.1       wheel
aiohttp                       3.8.3     3.8.5        wheel
aioitertools                  0.7.1     0.11.0       wheel
aiosignal                     1.2.0     1.3.1        wheel
aiosqlite                     0.18.0    0.19.0       wheel
alabaster                     0.7.12    0.7.13       wheel
anyio                         3.5.0     4.0.0        wheel
argon2-cffi                   21.3.0    23.1.0       wheel
astroid                       2.14.2    2.15.6       wheel
astropy                       5.1       5.3.2        wheel
asttokens                     2.0.5     2.4.0        wheel
async-timeout                 4.0.2     4.0.3        wheel
atomicwrites                  1.4.0     1.4.1        sdist
attrs                         22.1.0    23.1.0       wheel
Automat                       20.2.0    22.10.0      wheel
autopep8                      1.6.0     2.0.4        wheel
Babel                         2.11.0    2.12.1       wheel
backports.functools-lru-cache 1.6.4     1.6.6        wheel
bcrypt                        3.2.0     4.0.1        wheel
black                         0.0       23.7.0       wheel
bleach                        4.1.0     6.0.0        wheel
bokeh                         3.2.1     3.2.2        wheel
boto3                         1.24.28   1.28.40      wheel
botocore                      1.27.59   1.31.40      wheel
Bottleneck                    1.3.5     1.3.7        wheel
chardet                       4.0.0     5.2.0        wheel
charset-normalizer            2.0.4     3.2.0        wheel
click                         8.0.4     8.1.7        wheel
comm                          0.1.2     0.1.4        wheel
conda-pack                    0.6.0     0.7.1        wheel
contourpy                     1.0.5     1.1.0        wheel
cookiecutter                  1.7.3     2.3.0        wheel
cryptography                  41.0.2    41.0.3       wheel
cssselect                     1.1.0     1.2.0        wheel
cytoolz                       0.12.0    0.12.2       wheel
daal4py                       2023.1.1  2023.2.1     wheel
dask                          2023.6.0  2023.9.0     wheel
datashader                    0.15.1    0.15.2       wheel
debugpy                       1.6.7     1.6.7.post1  wheel
diff-match-patch              20200713  20230430     wheel
dill                          0.3.6     0.3.7        wheel
distributed                   2023.6.0  2023.9.0     wheel
docstring-to-markdown         0.11      0.12         wheel
docutils                      0.18.1    0.20.1       wheel
executing                     0.8.3     1.2.0        wheel
fastjsonschema                2.16.2    2.18.0       wheel
filelock                      3.9.0     3.12.3       wheel
flake8                        6.0.0     6.1.0        wheel
Flask                         2.2.2     2.3.3        wheel
fonttools                     4.25.0    4.42.1       wheel
frozenlist                    1.3.3     1.4.0        wheel
fsspec                        2023.3.0  2023.9.0     wheel
gensim                        4.3.0     4.3.2        wheel
greenlet                      2.0.1     2.0.2        wheel 

1.5:python 标准库位置: %python安装路径%\Lib

1.6:第三方库安装的路径

第三方库位置: %python安装路径%\Lib\site-packages

  • 21
    点赞
  • 23
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值