committed by
GitHub
parent
6a4febb33a
commit
78ed2a67a2
11
tutorials/tutorial2/tutorial.ipynb
vendored
11
tutorials/tutorial2/tutorial.ipynb
vendored
@@ -7,6 +7,8 @@
|
||||
"source": [
|
||||
"# Tutorial: Two dimensional Poisson problem using Extra Features Learning\n",
|
||||
"\n",
|
||||
"[](https://colab.research.google.com/github/mathLab/PINA/blob/master/tutorials/tutorial2/tutorial.ipynb)\n",
|
||||
"\n",
|
||||
"This tutorial presents how to solve with Physics-Informed Neural Networks (PINNs) a 2D Poisson problem with Dirichlet boundary conditions. We will train with standard PINN's training, and with extrafeatures. For more insights on extrafeature learning please read [*An extended physics informed neural network for preliminary analysis of parametric optimal control problems*](https://www.sciencedirect.com/science/article/abs/pii/S0898122123002018).\n",
|
||||
"\n",
|
||||
"First of all, some useful imports."
|
||||
@@ -19,6 +21,15 @@
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"## routine needed to run the notebook on Google Colab\n",
|
||||
"try:\n",
|
||||
" import google.colab\n",
|
||||
" IN_COLAB = True\n",
|
||||
"except:\n",
|
||||
" IN_COLAB = False\n",
|
||||
"if IN_COLAB:\n",
|
||||
" !pip install \"pina-mathlab\"\n",
|
||||
"\n",
|
||||
"import torch\n",
|
||||
"from torch.nn import Softplus\n",
|
||||
"\n",
|
||||
|
||||
11
tutorials/tutorial2/tutorial.py
vendored
11
tutorials/tutorial2/tutorial.py
vendored
@@ -3,6 +3,8 @@
|
||||
|
||||
# # Tutorial: Two dimensional Poisson problem using Extra Features Learning
|
||||
#
|
||||
# [](https://colab.research.google.com/github/mathLab/PINA/blob/master/tutorials/tutorial2/tutorial.ipynb)
|
||||
#
|
||||
# This tutorial presents how to solve with Physics-Informed Neural Networks (PINNs) a 2D Poisson problem with Dirichlet boundary conditions. We will train with standard PINN's training, and with extrafeatures. For more insights on extrafeature learning please read [*An extended physics informed neural network for preliminary analysis of parametric optimal control problems*](https://www.sciencedirect.com/science/article/abs/pii/S0898122123002018).
|
||||
#
|
||||
# First of all, some useful imports.
|
||||
@@ -10,6 +12,15 @@
|
||||
# In[1]:
|
||||
|
||||
|
||||
## routine needed to run the notebook on Google Colab
|
||||
try:
|
||||
import google.colab
|
||||
IN_COLAB = True
|
||||
except:
|
||||
IN_COLAB = False
|
||||
if IN_COLAB:
|
||||
get_ipython().system('pip install "pina-mathlab"')
|
||||
|
||||
import torch
|
||||
from torch.nn import Softplus
|
||||
|
||||
|
||||
Reference in New Issue
Block a user