SCaSML is a novel approach for solving high-dimensional partial differential equations (PDEs) that combines the dimension insensitivity of neural networks with the transparent, unbiased, and physical estimation from simulation solvers.
Addressing high-dimensional PDEs has long been challenging due to the 'curse of dimensionality'. Deep learning methods, while promising, often suffer from bias, non-transparency, and insufficient physics embedding. To address these, we propose Simulation Calibrated Scientific Machine Learning (SCaSML), integrating neural network's dimension insensitivity with transparent, unbiased and physical estimation from simulation solvers.
We train Physics-Informed Neural Networks (PINNs) to provide initial solution estimates, whose errors, governed by a new PDE, are corrected via Monte Carlo solvers using the Feynman-Kac and Elworthy-Bismut-Li formulae. We prove SCaSML's rate improvement for two state-of-the-art solvers, quadrature multilevel Picard and full-history multilevel Picard.
Numerical experiments on various high-dimensional PDEs, including the Hamilton-Jacobi-Bellman and Diffusion-Reaction equations, etc., confirm our theoretical results in terms of accuracy. This method advances fields like economics, finance, operations research, and physics by comprehensively considering all involved elements as agents, assets, and resources.
- Clone the repository:
git clone https://github.com/francis-fan-create/scasml.git
cd scasml
- Create and activate the conda environment:
conda env create -f environment.yml
conda activate myenv
To set up a new SCaSML solver for specific equations, follow these steps:
-
Configure your equation in
equations/equations.py
using theExplicit_Solution_Example
class as a guide. -
In the
models/
directory, create a new.py
file and define your network structure, takingFNN.py
as an example. Ensure to set theself.regularizer
parameter. -
In the
optimizers/
directory, create a new.py
file to customize your training process, following theAdam_LBFGS.py
template. -
To use test methods other than
tests/NormalSphere.py
, create a new one in thetests/
directory using theNormalSphere.py
format. -
Copy
experiment_run.py
(Adam_LBFGS training) fromresults/Explicit_Solution_Example/(certain dimension)/
toresults/(your equation)/(certain dimension)/
, replacing all "Explicit_Solution_Example" with your equation's name. -
Review beginning lines to enable or disable wandb online logging.
-
Run the experiment:
python results/(your equation)/(certain dimension)/experiment_run.py
- View your results in the
results/(your equation)/(certain dimension)/
folder and on wandb - (Optional) Repeat steps 6-9 for
further_training.py
after the weights ofexperiment_run.py
are generated to get further trained weights using L_inf training. - Replace
results/
byresults_full_history/
to replace the quadrature MLP solver by the full_history MLP solver. - If you still have problems, please submit it to Issues.
equations/
: Contains equation definitionsmodels/
: Neural network model definitionsoptimizers/
: Custom optimization algorithmstests/
: Test methods for evaluating the solverresults/
: Experiment results and wandb keyssolvers/
: Implementation of SCaSML and other solvers
Contributions to SCaSML are welcome! Please follow these steps:
- Fork the repository
- Create a new branch (
git checkout -b feature/your-feature
) - Make your changes
- Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin feature/your-feature
) - Create a new Pull Request
Maintainer&First Author:
Zexi Fan: 2200010816@stu.pku.edu.cn
Collaborators:
Yan Sun: yansun414@gmail.com
Yiping Lu: yiping.lu@northwestern.edu