« Previous 1 2 3
Accessing Fortran code with Python
Scientific Computing
Summary
Fortran code is accessible by Python in a number of ways, ranging from C wrappers for Fortran functions to dedicated tools that all are pretty simple to use. While f2py
is the most popular tool, I have had trouble using it with non-GFortran compilers.
In the next article, I will present a few of the many Python libraries that allow you to use GPUs. I think you will be pleasantly surprised at the state of GPU computing in Python.
Infos
- Fortran 2003: https://en.wikipedia.org/wiki/Fortran#Fortran_2003
- Fortran 90: https://www.fortran90.org/
- Fortran 2003 standard: https://en.wikipedia.org/wiki/Fortran#Fortran_2003
- Pierre Augier's website: http://www.legi.grenoble-inp.fr/people/Pierre.Augier/how-to-call-fortran-from-python.html
- "High-Performance Python – Compiled Code and C Interface" by Jeff Layton: http://www.admin-magazine.com/HPC/Articles/High-Performance-Python
- f2py: http://cens.ioc.ee/~pearu/
- f2py users guide: https://docs.scipy.org/doc/numpy/f2py/
- Wrapping fortran functions: https://docs.scipy.org/doc/numpy/f2py/getting-started.html#the-quick-and-smart-way
- "Multicore Processing with Fortran and OpenMP" by Jeff Layton: http://www.admin-magazine.com/HPC/Articles/Multicore-Processing-in-Python
- gfort2py: https://github.com/rjfarmer/gfort2py
« Previous 1 2 3
Buy this article as PDF
Express-Checkout as PDF
Price $2.95
(incl. VAT)
(incl. VAT)
Buy ADMIN Magazine
Subscribe to our ADMIN Newsletters
Find SysAdmin Jobs
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Topics
12.04 LTS
16 cores
8 cores
AI
AMD
AMD-V
AMI
Active Directory
Administration
Amazon AWS
Amazon CloudFront
Amazon Machine Images
Anaconda
Analytics
Ansible
Apache
Apache Deltacloud
Apache benchmarking tool
ab
acceleration
acquisition
admin tools
agedu
alert
amazon
analysis
analysis
anticipatory
application performance