代码实现

1
2
3
4
5
6
import os, sys
# Dynamically add path for local imports
current_file_dir = os.path.dirname(os.path.abspath(__file__))
path = os.path.abspath(os.path.join(current_file_dir, '..')) # modify as your need
if hawor_path not in sys.path:
sys.path.insert(0, path)