PINNs-Torch MLP
A plain tanh network trained to obey a partial differential equation through automatic differentiation.
Physics and weather · 24 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
At a glance
- Task
- Physics and weather
- Parameters
- 3K
- Operations
- 24
- Framework
- PyTorch
- Recurrent
- No
- Published
- 2017
- Cited by
- 1,983 (as of 27 November 2026)
- Authors
- Maziar Raissi, Paris Perdikaris, George Em Karniadakis
- Source
- GitHub: rezaakb/pinns-torch
- License
- BSD-3-Clause
- Checked
- Passed: the trace was replayed operation by operation and matched the model's own output for this input.
Files
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
Details
- Stable ID
- m2110
- Graph hash
- 57392464c99a001843a3a32f0d4cbfb516cd8bd76c3ec35c322fd49671166049
- Skeleton hash
- cf8052658d21f0b8ff7567fc44005c4c1f5146d757491bda2c258224d2d83df6
- Architecture hash
- f06f4c2cac7a4d74a51ca3d9d44fca11ef1147553b943a50f0dba99f694ad60a
- Diagram SHA-256
- 47bfb515936178a4318ddf2681272c352e47399f6f18feb854dd0e8548b61002
- TorchLens version
- 2.36.0
- Renderer
- graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
- Check
- Forward pass replayed in PyTorch
What it is
Physics-informed neural networks (PINNs) are ordinary fully connected networks trained to satisfy a partial differential equation as well as the data. The idea matters because physical data is often scarce, and the equation acts as a prior that lets a network learn from very few samples.
The trick is automatic differentiation: the network's output u(t, x) is differentiated with respect to its own input coordinates, and those derivatives are assembled into the equation's residual. That residual is penalized at collocation points alongside the usual data loss, and the paper describes the physics term as a regularizer against over-fitting.
The showcase is the one-dimensional Burgers equation: from only 100 initial and boundary points, a 9-layer network with 3,021 parameters recovers the solution. Each hidden layer has 20 neurons with a hyperbolic tangent activation. The paper also sets out discrete-time variants built on Runge-Kutta time stepping, but the member captured here is the continuous-time network on the Burgers domain.
The traced member comes from PINNs-Torch, a PyTorch package that re-implements the method with CUDA Graphs and TorchScript compilation for speed. The original TensorFlow repository now describes itself as no longer maintained and points users to the PyTorch, JAX and TensorFlow v2 ports.
Key idea. Differentiating a neural network with respect to its input coordinates by automatic differentiation and penalizing the PDE residual, so a plain network can be fit to a physical law from very small data.
- PINN
- PINNs
- physics-informed neural network
- Physics Informed Deep Learning
- Burgers equation
- PDE solver
- PINNs-Torch
- pinnstorch
- Raissi
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
Cite the paper
@misc{raissi2017physicsinformeddeeplearning,
title={Physics Informed Deep Learning (Part I): Data-driven Solutions of Nonlinear Partial Differential Equations},
author={Maziar Raissi and Paris Perdikaris and George Em Karniadakis},
year={2017},
eprint={1711.10561},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/1711.10561},
}