You are here
Running python script through matlab
Wed, 2010-04-28 05:45 - cgouder
Dear Friends ,
I am using an optimisation algorithm in matlab.I need to start abaqus from Matlab ( Using abaqus job=jobname), later i want to run a python code to extract some history outputs and feed into matlab. The process involves many iterations . Can anybody tell me how i can run the python script from Matlab ?.
Thanks and Best Regards
»
- cgouder's blog
- Log in or register to post comments
- 10277 reads
Comments
I've done some scripts
I've done some scripts before for extracting data, and i ran them like this;
abaqus python postprocess.py jobname.odb jobname.m
This script simply wrote the values to a matlab script (which you could later run in matlab)
Also, you want to run the actual job with
abaqus interactive job=jobname
to stop matlab from going to the next command before the job has finished.
In summary, I'd expect the matlab script to look like:
!abaqus interactive job=jobname
!abaqus python postprocess.py jobname.odb jobname.m
jobname
and then carrying one as normal.