将Matplotlib(适用于python 2.6)与Abaqus 6.12结合使用

问题描述:

我想知道是否有人将matplotlib用于与ABAQUS耦合的python代码.我真的想将matplotlib加载到abaqus-python接口上.我正在使用具有python 2.6的ABAQUS 6.12.另外,我正在使用Windows 64位.

I'm wondering if any of you use matplotlib for your python codes that are coupled with ABAQUS. I really want to load matplotlib onto the abaqus-python interface. I'm using ABAQUS 6.12, which has python 2.6. Also, I'm using Windows 64 bit.

但是,当我下载适用于python 2.6的matplotlib时,它无法安装并显示

However, when I download the matplotlib for python 2.6, it fails to install and says that

需要Python 2.6,该文件在注册表中找不到."

"Python 2.6 required, which is not found in the Registry."

有人可以帮我吗?有谁知道逐步安装matplotlib的方式以使其适用于Abaqus 6.12?

Could anyone help me out? Does anyone know of a step-by-step way to install matplotlib such that it works for Abaqus 6.12?

任何帮助将不胜感激! 谢谢

Any help would be appreciated! Thanks

注意:对于那些不熟悉FEA软件的人,Abaqus脚本接口是python面向对象编程语言的扩展,并带有ABAQUS/CAE.

Note: For those unfamiliar with FEA Software, the Abaqus Scripting Interface is an extension of the Python object-oriented programming language, and comes with ABAQUS/CAE.

我将Matplotlib 1.3.0与Abaqus 6.11一起使用.一切都是64位.我相信使用Abaqus 6.12也可以.该过程是(使用与我的配置相同的配置,但是我相信NumPy和Matplotlib的较新版本也可以使用):

I use Matplotlib 1.3.0 with Abaqus 6.11. Everything 64 bit. I believe with Abaqus 6.12 will work as well. The procedure is (using the same configuration as mine, but I believe newer versions of NumPy and Matplotlib will work as well):

  • install Python 2.7 64 bit
  • install NumPy 1.7.1 64 bit
  • install Matplotlib 1.3.0 64 bit

在从Abaqus导入之前,配置已安装指向matplotlib的环境变量PYTHONPATH.

Configure your environment variable PYTHONPATH pointing to were matplotlib is installed before importing it from Abaqus.

您可能会收到类似以下内容的RuntimeWarning:

You may get a RuntimeWarning like:

C:\Python27\Lib\site-packages\PIL\Image.py:71:
RuntimeWarning: The _imaging extension was built for another version of Python; most PIL functions will be disabled

但是您可以使用Abaqus的matplotlib的大多数功能.

But you can use most of matplotlib's features from Abaqus.