Skip to main content

Stochastic Reduced Order Models with Python

Project description

SROMPy - Stochastic Reduced Order Models with Python

Coverage Status Coverage Status

General

Python module for generating Stochastic Reduced Order Models (SROMs) and applying them for uncertainty quantification problems. See documentation in docs/ directory for details.

Dependencies

SROMPy is intended for use with Python 2.7 and relies on the following packages:

  • numpy
  • scipy
  • matplotlib
  • mpi4py (optional for running in parallel)
  • pytest (optional if the testing suite is to be run)

Example Usage

from SROMPy.postprocess import Postprocessor
from SROMPy.srom import SROM
from SROMPy.target import NormalRandomVariable

#Initialize Normal random variable object to be modeled by SROM:
normal = NormalRandomVariable(mean=3., std_dev=1.5)

#Initialize SROM & optimize to model the normal random variable:
srom = SROM(size=10, dim=1)
srom.optimize(normal)

#Compare the CDF of the SROM & target normal variable:
post_processor = Postprocessor(srom, normal)
post_processor.compare_CDFs()

The above code snippet produces the following CDF comparison plot:

CDF comparison

Getting Started

The best way to get started with SROMPy is to take a look at the scripts in the examples/ directory. A simple example of propagating uncertainty through a spring mass system can be found in the examples/spring_mass/, while the examples/phm18/ directory contains scripts necessary to reproduce the results in the following conference paper on probabilistic prognostics: https://www.phmpapers.org/index.php/phmconf/article/view/551. For more information, see the source code documentation in docs/SROMPy_doc.pdf (a work in progress) or the technical report below that accompanied the release of SROMPy.

Tests

The tests can be performed by running "py.test" from the tests/ directory to ensure a proper installation.

Reference

If you use SROMPy for your research, please cite the technical report:

Warner, J. E. (2018). Stochastic reduced order models with Python (SROMPy). NASA/TM-2018-219824.

The report can be found in the docs/references directory. Thanks!

Developers

UQ Center of Excellence
NASA Langley Research Center
Hampton, Virginia

This software was funded by and developed under the High Performance Computing Incubator (HPCI) at NASA Langley Research Center.

Contributors: James Warner (james.e.warner@nasa.gov), Luke Morrill, Juan Barrientos

License

Copyright 2018 United States Government as represented by the Administrator of the National Aeronautics and Space Administration. No copyright is claimed in the United States under Title 17, U.S. Code. All Other Rights Reserved.

The Stochastic Reduced Order Models with Python (SROMPy) platform is licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

SROMPy-0.1.0.tar.gz (28.9 kB view details)

Uploaded Source

Built Distribution

SROMPy-0.1.0-py2-none-any.whl (53.6 kB view details)

Uploaded Python 2

File details

Details for the file SROMPy-0.1.0.tar.gz.

File metadata

  • Download URL: SROMPy-0.1.0.tar.gz
  • Upload date:
  • Size: 28.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.10

File hashes

Hashes for SROMPy-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7d7ac25f8b4bf4853fcc6e53473d70997a570219005794752bccb321ae9a88a2
MD5 0fb7a6f48d5c1ac50a80a5ad6a33723a
BLAKE2b-256 e6024a39b28f9770752f34ad54bc37001b7b3f9538d8559999e45f03ec976a0e

See more details on using hashes here.

File details

Details for the file SROMPy-0.1.0-py2-none-any.whl.

File metadata

  • Download URL: SROMPy-0.1.0-py2-none-any.whl
  • Upload date:
  • Size: 53.6 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.10

File hashes

Hashes for SROMPy-0.1.0-py2-none-any.whl
Algorithm Hash digest
SHA256 0a2463127fd6a98e3af1de00c675e6bc92ed7e09a968b3cf57f84dc533395dec
MD5 59a9da4f630c426749a01bf7e7b44c34
BLAKE2b-256 5101058f4999143be3b18edc41190300a428f8ded8e277ab2be1a471d41c331b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page