我的Jupyter笔记本给了我一个用f2py编译的fortran代码的ModuleNotFound错误。f2py位于make.sh文件中,我在安装包时运行该文件。一些信息
有人能帮我解开这个谜吗
一些编辑: make.sh文件和fort_rebin.f90位于最上面的/目录中
我需要导入的fortran代码位于inner/directory/rebin\u give\u width.f90中。但是,软件包安装没有说明编译rebin_give_width.f90(make.sh中也没有提到)。我现在看到它没有生成任何.so文件
问题是,这个lib以前工作过。由于其他原因,我重新安装了软件包,结果发生了一些事情
调用库时出错-
$import rebin_将_宽度指定为rgw
ModuleNotFoundError回溯(上次最近调用) 在里面 ----&燃气轮机;1导入rebin\u以rgw的形式给出\u宽度
ModuleNotFoundError:没有名为“rebin\u give\u width”的模块
好吧,我找到了解决办法。我不知道为什么它以前能工作,也不知道为什么它不是安装的一部分。但是,我在make.sh中包含了命令$f2py-c internal/directory/rebin\u give\u width.f90-m rebin\u give\u width和语句$import upmost\u directory.rebin\u give\u width now works
目前没有回答
相关问题 更多 >
编程相关推荐