Skip to content
This repository has been archived by the owner on Jul 6, 2023. It is now read-only.

Commit

Permalink
Move plotting scripts to same folder
Browse files Browse the repository at this point in the history
- Also uploaded pre-trained models to Zenodo
- Still untested
  • Loading branch information
Nicholas Geneva committed Dec 8, 2020
1 parent 2c02cae commit f59b940
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 9 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -127,3 +127,5 @@ dmypy.json

# Pyre type checker
.pyre/

*.zip
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Multi-fidelity Generative Deep Learning Turbulent Flows [[FoDS]()][[ArXiv](https
[Nicholas Geneva](https://nicholasgeneva.com/), [Nicholas Zabaras](https://cics.nd.edu)

---
[![Documentation Status](https://readthedocs.org/projects/deep-turbulence/badge/?version=latest)](https://deep-turbulence.readthedocs.io/en/latest/?badge=latest) [![dataset](https://zenodo.org/badge/DOI/10.5281/zenodo.4298896.svg)](https://doi.org/10.5281/zenodo.4298896) [![liscense](https://img.shields.io/github/license/zabaras/deep-turbulence)](https://github.com/zabaras/deep-turbulence/blob/master/LICENSE)
[![Documentation Status](https://readthedocs.org/projects/deep-turbulence/badge/?version=latest)](https://deep-turbulence.readthedocs.io/en/latest/?badge=latest) [![dataset](https://zenodo.org/badge/DOI/10.5281/zenodo.4311698.svg)](https://doi.org/10.5281/zenodo.4311698) [![liscense](https://img.shields.io/github/license/zabaras/deep-turbulence)](https://github.com/zabaras/deep-turbulence/blob/master/LICENSE)

A novel multi-fidelity deep generative model is introduced for the surrogate modeling of high-fidelity turbulent flow fields given the solution of a computationally inexpensive but inaccurate low-fidelity solver.

Expand Down
12 changes: 10 additions & 2 deletions docs/source/start.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ Start with cloning the repository to your local machine using:
2. Downloading Data
-------------------
To download both the training and testing data for both of the numerical examples, visit the following Zenodo repository.
`https://doi.org/10.5281/zenodo.4298896 <https://doi.org/10.5281/zenodo.4298896>`_
`https://doi.org/10.5281/zenodo.4311698 <https://doi.org/10.5281/zenodo.4311698>`_

The data-sets are compressed tarfiles, notes that pre-trained models are also included in this repository.
Extract the data using ``tar –xvzf data-set-name.tar.gz``, and move the training and testing data the desired directory.

The default directories in the config are:
Expand Down Expand Up @@ -64,6 +65,12 @@ For example:
-----------------------------
Alternatively, you can skip the training and simply run a pre-trained models.
These can be found in the ``examples`` folder where there are several scripts that demonstrate how to load and test a model.
Download the pre-trained models from the Zenodo repository.
These are the two files that are ``.zip`` folders, simply place them in the examples directory.

.. warning::
Do **not** unzip the workspace files, they should be just copied as is. TM-Glow will unzip them for you and read necessary data.

The general work flow of running a model for prediction is:

1. Load model from the workspace zip file.
Expand All @@ -73,4 +80,5 @@ The general work flow of running a model for prediction is:

.. note::
These programs require you download the *testing* data from the Zenodo data repository. The default location this data should be unzipped to is discussed in step :ref:`download-data`.
However, one can easily customize the data location in each script.
However, one can easily customize the data location in each script.

Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,9 @@ def plotPredictionSeries(input0, yPred0, yTarget0, bidx=0, nsteps=10, stride=1,

log = Log(args, record=False)

model_name = 'nsWorkspace'
model_id = args.epoch_start

# Load pretrained model parameters
model_name = 'bstepWorkspace'
model_id = 400
model_path = '.'
args, model_state_dict, optimizer_state_dict = loadWorkspace(args, model_path, file_name=model_name, file_id=model_id)
scheduler = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,9 @@ def plotPredictionSeries(input0, yPred0, yTarget0, bidx=0, nsteps=20, stride=1,

log = Log(args, record=False)

model_name = 'nsWorkspace'
model_id = args.epoch_start

# Load pretrained model parameters
model_name = 'cylinderWorkspace'
model_id = 400
model_path='.'
args, model_state_dict, optimizer_state_dict = loadWorkspace(args, model_path, file_name=model_name, file_id=model_id)
scheduler = None
Expand Down

0 comments on commit f59b940

Please sign in to comment.