Skip to content

Built-in Examples

Jupyter Notebook Examples

You can run the included examples (CNN, PICAE, PIMLTurb on 3D data, PIMLTurb1D,and KRR on 2D data). There is also a notebook with examples of plotting routines and ML network visualization. To copy the examples, type:

sapsan get_examples
This will create a folder ./sapsan_examples with appropriate example jupyter notebooks and GUI. For starters, to launch a CNN example:

jupyter notebook ./sapsan_examples/cnn_example.ipynb

GUI Examples

In order to try out Sapsan's GUI, start a streamlit instance to open in a browser. After the examples have been compied into your working directory as described above, you will be able to find the GUI example. The entry point:

streamlit run ./sapsan_examples/GUI/Welcome.py

The scripts for the pages you see (welcome and examples) are located in the subsequent directory: ./sapsan_examples/GUI/pages/.

If you want to build your own demo, then look into Examples.py to get started. Ideally, you would only need to import your Estimator, EstimatorConfig, EstimatorModel and adjust the run_experiment() function, which has a nearly identical setup to a standard Sapsan's jupyter notebook interface.

Sapsan GUI Sapsan GUI

Sample Data

The data for the CNN and KRR examples has been sourced from JHTDB. Specifically the Forced MHD Dataset (10243) has been used as a starting point.

Data Description
u_dim128_2d.h5 velocity field sampled down to [128,128,128] and using the 1st slice
u_dim32_fm15.h5 velocity field sampled down to [32,32,32], and spectrally filtered down to 15 modes