Skip to main content

Physically Recurrent Neural Networks

Project description

Physically Recurrent Neural Networks

Intact constitutive models embedded in an encoder-decoder MLP architecture.

If you have accurate material models at the microscale and would like to perform computational homogenization, those same models can be directly embedded into a hybrid architecture to make macroscale predictions.

Because the models in the architecture are the exact same as in the micromodel, a number of features can be directly inherited and therefore not learned from data:

  • Path dependency (loading/unloading/reloading) without training for it
  • Strain rate dependency while training with only a single rate
  • Consistent step size dependence (independent for inviscid models; correct dependence for viscous models)
  • Between $10\times$ and $100\times$ less training data than RNNs for comparable performance

Journal papers and preprints

In this package

The code in this package contains a standalone demonstration of PRNNs for a 2D micromodel with $J_2$ elastoplasticity (matrix) and linear elasticity (fibers):

  • J2Tensor_vect.py: a simple $J_2$ plasticity model in plane stress. This code comes directly from an FE package, demonstrating how PRNNs can embed existing material models with little to no changes in code;
  • prnn.py: A PyTorch network class that implements the PRNN, with single-layer encoder and decoder;
  • rnn.py: Implements GRU and LSTM networks with variational Gaussian dropout. For comparing predictions and learning performance with PRNNs;
  • utils.py: Implements a custom dataset class for handling stress and strain paths, and a class for training and evaluating networks, with the ability of saving and loading checkpoints;

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

pyprnn-0.0.1.tar.gz (14.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyprnn-0.0.1-py3-none-any.whl (16.8 kB view details)

Uploaded Python 3

File details

Details for the file pyprnn-0.0.1.tar.gz.

File metadata

  • Download URL: pyprnn-0.0.1.tar.gz
  • Upload date:
  • Size: 14.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.6

File hashes

Hashes for pyprnn-0.0.1.tar.gz
Algorithm Hash digest
SHA256 66f811e6d9c095b3270d173b2aabcb8deed15e11c8b865be6fedfab40749f35a
MD5 67fefe3c98892709721ef7aaee5dba3e
BLAKE2b-256 d70d58f97853a51258dc3327b81ab43f2949684eb13f1a1b63d5a2251f5f543f

See more details on using hashes here.

File details

Details for the file pyprnn-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: pyprnn-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 16.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.6

File hashes

Hashes for pyprnn-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8cbb3766d83c3263d50dedb642287d76c5155079a437ae4493784dc5ea3691ea
MD5 6cea322fb320005b84a3aebe0bb44bc3
BLAKE2b-256 cff1aa5537fbabb6abe072fdadd7258b21cb29769bba22af0ad0a48cb471082b

See more details on using hashes here.

Supported by

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