Skip to content

HongsupOH/physics-regularized-bingo

Repository files navigation

Physics Regularized Bingo (PR-Bingo)

Table of contents

Authors

  • Hongsup Oh, Department of Mechanical Engineering, University of Utah
  • Roman Amici, Scientific Computing and Imaging Institute, School of Computing, University of Utah
  • Geoffrey Bomarito, NASA Langley Research Center
  • Shandian Zhe, School of Computing, University of Utah
  • Robert M. Kirby, Scientific Computing and Imaging Institute, School of Computing, University of Utah
  • Jacob D. Hochhalter, Department of Mechanical Engineering, University of Utah

Introduction

PR-GPSR is an interpretable machine learning package for the discovery of analytic solutions to differential equations. our paper is available for reading in the Engineering with Computers journal or on arxiv.

Install Bingo

To install Bingo, simply use pip or pip3. Detail descriptions of installation are Here.

pip install bingo-nasa

You need to have mpi to properly install mpi4py. It can be installed by

sudo apt install mpich 

Install PR-Bingo

RP-Bingo is simply installed by git clone, after installing Bingo.

git clone https://github.com/HongsupOH/physics-regularized-bingo

Tutorials

Two numerical experiments based on boundary-value problems were selected to verify that physics-regularized GPSR can evolve known solutions to differential equations. The first experiment verifies the solution to a linear, fourth-order ODE (Beam bending problem). The second experiment then verifies a linear, second-order PDE (Poisson's equation). Each experiment can be more easily understood through Tutorial: Beam-bending and Tutorial: Poisson's euqation.

Implement code with MPI

Beam bending problem

First, you need to select the hyperparameters at beam_bending.json file in experiments folder. Then, you can implement at Ubuntu or Windows terminal:

mpiexec -n <the number of cpu (int)> python soln_tests.py -e <Address of json file>/beam_bending.json

Where you need to fill <>. For example, it can be

mpiexec -n 10 python soln_tests.py -e /mnt/c/Users/hong/bingo_diffeq_pt/experiment_files/beam_bending.json

Then, the progress of the evolution is written at log file in logs folder. The name of log file is beam_bending_<cpu-rank>. As the evolution is terminated, the obtained equation is written at the log file. Or you can open pkl file in checkpoints folder to check the evolution process. The name of pkl file is beam_bending_<gen>.pkl. Then, you need write the name of pkl file with address in OpenPKL.py and implement code

python OpenPKL.py

then, you can check the obtained equation at the specific generation.

Poisson's equation

First, you need to select the hyperparameters at poisson_simple.json file in experiments folder. Then, you can implement at Ubuntu or Windows terminal:

mpiexec -n <the number of cpu (int)> python soln_tests.py -e <Address of json file>/poisson_simple.json

Where you need to fill <>. For example, it can be

mpiexec -n 10 python soln_tests.py -e /mnt/c/Users/hong/bingo_diffeq_pt/experiment_files/poisson_simple.json

Then, the progress of the evolution is written at log file in logs folder. The name of log file is poisson_simple_<cpu-rank>. As the evolution is terminated, the obtained equation is written at the log file. Or you can open pkl file in checkpoints folder to check the evolution process. The name of pkl file is poisson_simple_<gen>.pkl. Then, you need write the name of pkl file with address in OpenPKL.py and implement code

python OpenPKL.py

then, you can check the obtained equation at the specific generation.

Contact

If you have any issue about implementing code, you can contact us!

Thanks to visit us!

About

PR-GPSR is a interpretable machine learning package for the discovery of analytic solutions to differential equations.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published