committed by
GitHub
parent
6a4febb33a
commit
78ed2a67a2
14
tutorials/tutorial5/tutorial.ipynb
vendored
14
tutorials/tutorial5/tutorial.ipynb
vendored
@@ -5,7 +5,9 @@
|
||||
"id": "e80567a6",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Tutorial: Two dimensional Darcy flow using the Fourier Neural Operator"
|
||||
"# Tutorial: Two dimensional Darcy flow using the Fourier Neural Operator\n",
|
||||
"\n",
|
||||
"[](https://colab.research.google.com/github/mathLab/PINA/blob/master/tutorials/tutorial5/tutorial.ipynb)\n"
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -24,6 +26,16 @@
|
||||
"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",
|
||||
" !pip install scipy\n",
|
||||
" \n",
|
||||
"# !pip install scipy # install scipy\n",
|
||||
"from scipy import io\n",
|
||||
"import torch\n",
|
||||
|
||||
13
tutorials/tutorial5/tutorial.py
vendored
13
tutorials/tutorial5/tutorial.py
vendored
@@ -2,6 +2,9 @@
|
||||
# coding: utf-8
|
||||
|
||||
# # Tutorial: Two dimensional Darcy flow using the Fourier Neural Operator
|
||||
#
|
||||
# [](https://colab.research.google.com/github/mathLab/PINA/blob/master/tutorials/tutorial5/tutorial.ipynb)
|
||||
#
|
||||
|
||||
# In this tutorial we are going to solve the Darcy flow problem in two dimensions, presented in [*Fourier Neural Operator for
|
||||
# Parametric Partial Differential Equation*](https://openreview.net/pdf?id=c8P9NQVtmnO). First of all we import the modules needed for the tutorial. Importing `scipy` is needed for input-output operations.
|
||||
@@ -9,6 +12,16 @@
|
||||
# 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"')
|
||||
get_ipython().system('pip install scipy')
|
||||
|
||||
# !pip install scipy # install scipy
|
||||
from scipy import io
|
||||
import torch
|
||||
|
||||
Reference in New Issue
Block a user