EvaluateGaussianProcess

Tool for sampling gaussian process surrogate models.

Overview

Similar in function to EvaluateSurrogate, this object takes in a sampler and a GaussianProcess surrogate model and executes the evaluate method within each surrogate for each row of the sampler. The evaluate return the predictive mean and standard deviation of the Gaussian process surrogate at the specified evaluation point.

Example Syntax

Simple example using EvaluateGaussianProcess

[StochasticTools]
[]

[Distributions]
  [k_dist]
    type = Uniform
    lower_bound = 1
    upper_bound = 10
  []
  [q_dist]
    type = Uniform
    lower_bound = 9000
    upper_bound = 11000
  []
[]

[Samplers]
  [test_sample]
    type = MonteCarlo
    num_rows = 100
    distributions = 'k_dist q_dist'
    execute_on = PRE_MULTIAPP_SETUP
  []
[]

[VectorPostprocessors]
  [samp_avg]
    type = EvaluateGaussianProcess
    model = GP_avg
    sampler = test_sample
    output_samples = true
    execute_on = final
  []

[]

[Surrogates]
  [GP_avg]
    type = GaussianProcess
    filename = 'gauss_process_training_GP_avg_trainer.rd'
  []
[]

[Outputs]
  [out]
    type = CSV
    execute_on = FINAL
  []
[]
(modules/stochastic_tools/test/tests/surrogates/gaussian_process/GP_squared_exponential_testing.i)

CSV output when output_samples = true, note the predictive standard deviation in the last column.

surrogate,sample_p0,sample_p1,sample_p2
GP_avg,sample_p0,sample_p1,GP_avg_std
680.81518263199,8.1474396732963,9319.6492446266,0.58627430888001
1101.357289321,4.5170853933506,10872.970311667,0.58627427931307
787.59042890478,6.9085650921783,10118.299854788,0.58627437370922
722.81295049602,7.2617914444642,9222.6647540836,0.58627431013298
1127.8161258388,4.2903122598679,10668.108638239,0.58627425407458
1602.4960766395,2.7392312254796,10716.920553975,0.58627406227184
...

Input Parameters

  • modelName of surrogate models.

    C++ Type:std::vector<UserObjectName>

    Options:

    Description:Name of surrogate models.

  • samplerSampler to use for evaluating surrogate models.

    C++ Type:SamplerName

    Options:

    Description:Sampler to use for evaluating surrogate models.

Required Parameters

  • contains_complete_historyFalseSet this flag to indicate that the values in all vectors declared by this VPP represent a time history (e.g. with each invocation, new values are added and old values are never removed). This changes the output so that only a single file is output and updated with each invocation

    Default:False

    C++ Type:bool

    Options:

    Description:Set this flag to indicate that the values in all vectors declared by this VPP represent a time history (e.g. with each invocation, new values are added and old values are never removed). This changes the output so that only a single file is output and updated with each invocation

  • execute_onTIMESTEP_ENDThe list of flag(s) indicating when this object should be executed, the available options include NONE, INITIAL, LINEAR, NONLINEAR, TIMESTEP_END, TIMESTEP_BEGIN, FINAL, CUSTOM.

    Default:TIMESTEP_END

    C++ Type:ExecFlagEnum

    Options:NONE, INITIAL, LINEAR, NONLINEAR, TIMESTEP_END, TIMESTEP_BEGIN, FINAL, CUSTOM

    Description:The list of flag(s) indicating when this object should be executed, the available options include NONE, INITIAL, LINEAR, NONLINEAR, TIMESTEP_END, TIMESTEP_BEGIN, FINAL, CUSTOM.

  • output_samplesFalseTrue to output value of parameter values from samples (this may be VERY large).

    Default:False

    C++ Type:bool

    Options:

    Description:True to output value of parameter values from samples (this may be VERY large).

  • parallel_typeREPLICATEDSet how the data is represented within the VectorPostprocessor (VPP); 'distributed' indicates that data within the VPP is distributed and no auto communication is preformed, this setting will result in parallel output within the CSV output; 'replicated' indicates that the data within the VPP is correct on processor 0, the data will automatically be broadcast to all processors unless the '_auto_broadcast' param is set to false within the validParams function.

    Default:REPLICATED

    C++ Type:MooseEnum

    Options:DISTRIBUTED, REPLICATED

    Description:Set how the data is represented within the VectorPostprocessor (VPP); 'distributed' indicates that data within the VPP is distributed and no auto communication is preformed, this setting will result in parallel output within the CSV output; 'replicated' indicates that the data within the VPP is correct on processor 0, the data will automatically be broadcast to all processors unless the '_auto_broadcast' param is set to false within the validParams function.

Optional Parameters

  • allow_duplicate_execution_on_initialFalseIn the case where this UserObject is depended upon by an initial condition, allow it to be executed twice during the initial setup (once before the IC and again after mesh adaptivity (if applicable).

    Default:False

    C++ Type:bool

    Options:

    Description:In the case where this UserObject is depended upon by an initial condition, allow it to be executed twice during the initial setup (once before the IC and again after mesh adaptivity (if applicable).

  • control_tagsAdds user-defined labels for accessing object parameters via control logic.

    C++ Type:std::vector<std::string>

    Options:

    Description:Adds user-defined labels for accessing object parameters via control logic.

  • enableTrueSet the enabled status of the MooseObject.

    Default:True

    C++ Type:bool

    Options:

    Description:Set the enabled status of the MooseObject.

  • force_preauxFalseForces the GeneralUserObject to be executed in PREAUX

    Default:False

    C++ Type:bool

    Options:

    Description:Forces the GeneralUserObject to be executed in PREAUX

  • force_preicFalseForces the GeneralUserObject to be executed in PREIC during initial setup

    Default:False

    C++ Type:bool

    Options:

    Description:Forces the GeneralUserObject to be executed in PREIC during initial setup

  • outputsVector of output names were you would like to restrict the output of variables(s) associated with this object

    C++ Type:std::vector<OutputName>

    Options:

    Description:Vector of output names were you would like to restrict the output of variables(s) associated with this object

  • use_displaced_meshFalseWhether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.

    Default:False

    C++ Type:bool

    Options:

    Description:Whether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.

Advanced Parameters

Input Files