All Projects → mgaitan → Fortran_magic

mgaitan / Fortran_magic

Licence: bsd-3-clause
An extension for IPython/Jupyter that helps to use Fortran in your interactive session.

Projects that are alternatives of or similar to Fortran magic

Ucl Deep Learning Ans Reinforcement Learning
Deep learning and Reinforcement learning lecture and course work
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Libpysal
Core components of Python Spatial Analysis Library
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Advisor
Open-source implementation of Google Vizier for hyper parameters tuning
Stars: ✭ 1,359 (+1272.73%)
Mutual labels:  jupyter-notebook
Math of machine learning
This is the code for "Mathematcs of Machine Learning" by Siraj Raval on Youtube
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Pyspark Predictive Maintenance
Predictive Maintenance using Pyspark
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Deeplearning
Python implementation of Deep Learning book
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Adversarially Learned Anomaly Detection
ALAD (Proceedings of IEEE ICDM 2018) official code
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Recommenders
Best Practices on Recommendation Systems
Stars: ✭ 11,818 (+11837.37%)
Mutual labels:  jupyter-notebook
Btctrading
Time Series Forecast with Bitcoin value, to detect upward/down trends with Machine Learning Algorithms
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Quant at
Python version of Dr. Ernie Chan's Matlab code and some inspired from Robert Carver's, plus some raw data downloaders
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Delf enhanced
Wrapper of DELF Tensorflow Model
Stars: ✭ 98 (-1.01%)
Mutual labels:  jupyter-notebook
Mv3d tf
Tensorflow implementation of Multi-View 3D Object Detection Network (in progress)
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Bayarea Dl Summerschool
Torch notebooks and slides for the Bay Area Deep Learning Summer School
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
100days Ml Code
100天机器学习 (翻译+ 实操)
Stars: ✭ 98 (-1.01%)
Mutual labels:  jupyter-notebook
Neural Tangents
Fast and Easy Infinite Neural Networks in Python
Stars: ✭ 1,357 (+1270.71%)
Mutual labels:  jupyter-notebook
Ml Sound Classifier
Machine Learning Sound Classifier
Stars: ✭ 98 (-1.01%)
Mutual labels:  jupyter-notebook
Noisy labels
TRAINING DEEP NEURAL-NETWORKS USING A NOISE ADAPTATION LAYER
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook
Dopamine
Dopamine is a research framework for fast prototyping of reinforcement learning algorithms.
Stars: ✭ 9,681 (+9678.79%)
Mutual labels:  jupyter-notebook
Hands On Machine Learning
A series of Jupyter notebooks with Chinese comment that walk you through the fundamentals of Machine Learning and Deep Learning in python using Scikit-Learn and TensorFlow.
Stars: ✭ 1,363 (+1276.77%)
Mutual labels:  jupyter-notebook
Junosautomation
To contain example scripts for different tools.
Stars: ✭ 99 (+0%)
Mutual labels:  jupyter-notebook

============= Fortran magic

.. image:: https://pypip.in/v/fortran-magic/badge.png :target: https://pypi.python.org/pypi/fortran-magic :alt: Latest PyPI version

.. image:: https://pypip.in/d/fortran-magic/badge.png :target: https://pypi.python.org/pypi/fortran-magic :alt: Number of PyPI downloads

Compile and import symbols from a cell with Fortran code, using f2py.

The contents of the cell are written to a .f90 file in the directory IPYTHONDIR/fortran using a filename with the hash of the code. This file is then compiled. The resulting module is imported and all of its symbols are injected into the user's namespace.

:author: Martín Gaitán [email protected] :homepage: https://github.com/mgaitan/fortran_magic :documentation: see this notebook__

__ documentation_ .. _documentation: http://nbviewer.ipython.org/urls/raw.github.com/mgaitan/fortran_magic/master/documentation.ipynb

Install

You can install or upgrade via pip

pip install -U fortran-magic

Basic usage

Once it's installed, you can load it with %load_ext fortranmagic. Then put your Fortran code in a cell started with the cell magic %%fortran. For example::

In[2]: %load_ext fortranmagic

In[3]: %%fortran

       subroutine f1(x, y, z)
            real, intent(in) :: x,y
            real, intent(out) :: z

            z = sin(x+y)

       end subroutine f1

Every symbol is automatically imported. So the subroutine f1 is already available in your python session as a function::

In[4]:  f1(1.0, 2.1415)
Out[4]: 9.26574066397734e-05

See the documentation_ for further details.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].