1、No module named 'python_motion_planning'
这里的文档需要在python_motion_planning的上一级文件夹下才可以运行,比如:
如果在这个跟python_motion_planning同级的文件夹下进行以下导入操作时候
就会出现以下的报错:
Traceback (most recent call last):
File "local_example.py", line 7, in <module>
from python_motion_planning.utils import Grid, ControlFactory
ModuleNotFoundError: No module named 'python_motion_planning'
将common_example.py文件放到python_motion_planning的上一级文件夹时,就可以运行,如下:
运行结果:
显然是已经导入了python_motion_planning模块,其他的报错是强化学习一些包的问题。
[注意]
想要让python_motion_planning模块作为一个模块导入,必须在python_motion_planning模块下有一个__init__.py文件,可以是空的,但不能没有,这样python可以把这个识别为一个包。
2、No module named 'tensorboard'
pip3 install tensorboard