Anaconda site-packages(Anaconda 站点包)
问题描述
在 anaconda 环境中安装包后,我想对该包中的代码进行一些更改.
After installing a package in an anaconda environment, I'll like to make some changes to the code in that package.
在哪里可以找到包含已安装软件包的 site-packages 目录?我没有找到目录 /Users/username/anaconda/lib/python2.7/site-packages
Where can I find the site-packages directory containing the installed packages? I do not find a directory /Users/username/anaconda/lib/python2.7/site-packages
推荐答案
您可以导入模块并检查 module.__file__ 字符串.它包含相关源文件的路径.
You can import the module and check the module.__file__ string. It contains the path to the associated source file.
或者,您可以阅读模块文档中的 File 标记,可以使用 help(module) 或 module? 在 IPython 中.
Alternatively, you can read the File tag in the the module documentation, which can be accessed using help(module), or module? in IPython.
这篇关于Anaconda 站点包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:Anaconda 站点包
基础教程推荐
- Discord.py 缺少必需的参数 2022-01-01
- 与常规 dict 相比,Python manager.dict() 非常慢 2022-01-01
- 尝试制作WhatsApp机器人 2022-01-01
- numpy float:比算术运算中内置的慢 10 倍? 2022-01-01
- 用 Python 编写 Fortran 无格式文件 2022-01-01
- 在 Celery 工作人员中捕获 Heroku SIGTERM 以优雅地关 2022-01-01
- pyserial - 可以从线程 a 写入串行端口,是否阻塞从线程 b 读取? 2022-01-01
- 使用生成器和迭代器时 Python 多循环失败 2022-01-01
- 将 x 轴刻度更改为自定义字符串 2022-01-01
- 由Python将MP3转换为MIDI(类型错误:无法加载插件:mtg-Melodia:Melodia) 2022-01-01
