UQ algorithms use repeated model evaluations to propagate uncertainties or to sample probability distributions. The same implementation of a UQ algorithm needs to be used on many different models. The Modeling module in MUQ provides a collection of classes that enable models to be defined in a way that MUQ can understand. Many algorithms also require derivative information (such as gradients, Jacobian matrices, and Hessian matrices), which can also be defined and evaluated using this module.
To define models and support derivative evaluations, it is common for software frameworks to leverage domain specific languages or to use specialized numeric types in throughout the model definition. These intrusive modeling approaches enable the calculation of derivative information using automatic differentiation and are therefore amenable to efficient structure-exploiting UQ algorithms that leverage gradient information. Black-box approaches are an alternative that do not need to know anything about the inner workings of a model. Only evaluations of the input-to-output mapping are necessary. This approach, in contrast to intrusive appraoches, provides incredible flexibility in how the models are defined and facilitates easy coupling with other software packages, system calls, humans-in-the-loop, etc... However, pure black-box approaches do not expose gradient information and do not allow shared modeling components to be easily reused.
MUQ adopts a hybrid approach that blends the computational graph concept used by AD packages with black-box modeling approaches. MUQ defines a model through the connection of many small modeling components on a computational graph, but treats each component as a black box. MUQ only needs to evaluate the input-output relationship and (optionally) evaluate derivatives of the component. A model component could therefore make a system call to evaluate a complicated CFD simulation in a commercial CFD package like Fluent and evaluate gradients through sophisticated adjoint techniques.
Modules | |
Model Components and the ModPiece class | |
User-Defined Models | |
Combining Components: Model Graphs | |