简体   繁体   中英

How to load a code source modified package in Python?

I have downloaded from github a package (scikit-lean) and put the code source in repository folder (Windows 7 64-bit).

After modifying the code source, how can I load the package into the IPython notebook for testing ?

  1. Should I copy paste the modified in sites-packages folder ?
    (what about the current original scikit-lean package)

  2. Can I add the modified folder to the Python path ?

  3. How to manage versioning when loading package in Python since both are same names ?
    (ie: the original package vs the package I modified)

Sorry, it looks like beginner questions, but could not find anything how to start with

如果代码在一个名为file.py的文件中,则应该能够import file (如果不在正确的文件夹中,只需先在IPython中运行cd folder 。)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM