初学者,python中关于sitepacks/celltool/numerics/fitpack/\u fitpack.s的错误

2024-09-28 01:29:47 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在为我的研究做一些图像分析,包括使用CellTool(http://pantheon.yale.edu/~zp2/Celltool/)、Python和numpy。我用的是OS X 10.8.3。在我那台坏了的旧笔记本电脑上,我可以很好地运行我的命令,但我得到了一个新的,一切都不顺利!在

我相信CellTool和numpy已经正确安装,我只使用Mac上的标准python2.7.2。但是当我尝试运行这个python脚本“calculate”时_距离.py“命令,我得到这个错误:

Yuxins-MacBook-Pro:Modified_Contours yuxinsun$ python calculate_distances.py
Traceback (most recent call last):
  File "calculate_distances.py", line 24, in <module>
    normals = contours[n-1].inward_normals()
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/celltool/contour/contour_class.py", line 384, in inward_normals
    import celltool.numerics.fitpack as fitpack
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/celltool/numerics/fitpack/__init__.py", line 1, in <module>
    from fitpack import *
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/celltool/numerics/fitpack/fitpack.py", line 34, in <module>
    import _fitpack
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/celltool/numerics/fitpack/_fitpack.so, 2): Library not loaded: /usr/local/lib/libgfortran.2.dylib
  Referenced from: /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/celltool/numerics/fitpack/_fitpack.so
  Reason: image not found

我不知道这意味着什么…我只需要运行这个python脚本并得到它输出的文件。在

我是不是错过了“fitpack”呢?如果是,如何安装?或者我能做些什么来解决这个问题。在


Tags: inpylibpackageslinelibrarysiteframework
1条回答
网友
1楼 · 发布于 2024-09-28 01:29:47

您需要确保按照安装要求安装了这些:

If one of the above binary installers did not suit your needs, 
please install Celltool from the source code. 
This depends on only three things:

1.Python (version 2.3 or later).
2. NumPy 1.0.4 or later.
3. Working C/C++ and Fortran compilers.

看起来你的Fortran编译器库没有安装。在

这可能有帮助:https://scicomp.stackexchange.com/questions/2469/how-should-i-install-a-fortran-compiler-on-a-mac-os-x-10-x-x-4

相关问题 更多 >

    热门问题