简体   繁体   中英

Import custom .py files in Jupyter Notebook for Anaconda3

如何在Mac上的Anaconda3上存储自定义.py文件,以便可以将它们作为软件包导入Jupyter Notebook?

You can store them anywhere if you insert

import os
import sys
sys.path.append(os.path.abspath("path/to/module.py"))

from module import * 

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