Dakota
Version 6.21
Explore and Predict with Confidence
|
Derived model class within the surrogate model branch for managing data fit surrogates (global and local) More...
Public Member Functions | |
DataFitSurrModel (ProblemDescDB &problem_db) | |
constructor | |
DataFitSurrModel (Iterator &dace_iterator, Model &actual_model, const ActiveSet &dfs_set, const ShortShortPair &dfs_view, const String &approx_type, const UShortArray &approx_order, short corr_type, short corr_order, short data_order, short output_level, const String &point_reuse, const String &import_build_points_file=String(), unsigned short import_build_format=TABULAR_ANNOTATED, bool import_build_active_only=false, const String &export_approx_points_file=String(), unsigned short export_approx_format=TABULAR_ANNOTATED) | |
alternate constructor for instantiations on the fly | |
~DataFitSurrModel () | |
destructor | |
void | total_points (int points) |
set pointsTotal and pointsManagement mode | |
int | required_points () |
return points required for build according to pointsManagement mode | |
void | declare_sources () |
Declare a model's sources to the evaluationsDB. | |
Public Member Functions inherited from Model | |
Model () | |
default constructor More... | |
Model (ProblemDescDB &problem_db) | |
standard constructor for envelope More... | |
Model (const Model &model) | |
copy constructor More... | |
virtual | ~Model () |
destructor | |
Model | operator= (const Model &model) |
assignment operator | |
virtual unsigned short | active_surrogate_model_form (size_t i) const |
return the model form of the i-th active surrogate model | |
virtual unsigned short | active_truth_model_form () const |
return the model form of the active truth model | |
virtual Model & | active_surrogate_model (size_t i=_NPOS) |
return the i-th active approximation sub-model in surrogate models More... | |
virtual const Model & | active_surrogate_model (size_t i=_NPOS) const |
return the i-th active approximation sub-model in surrogate models | |
virtual Model & | active_truth_model () |
return the active truth sub-model in surrogate models More... | |
virtual const Model & | active_truth_model () const |
return the active truth sub-model in surrogate models | |
virtual bool | active_truth_key () const |
return true if there is an active truth model indicated by truthModelKey | |
virtual size_t | active_surrogate_keys () const |
return the number of active surrogate models indicated by surrModelKeys | |
virtual bool | multifidelity () const |
identify if 1D hierarchy can be defined across model forms | |
virtual bool | multilevel () const |
identify if 1D hierarchy can be defined across resolution levels | |
virtual bool | multilevel_multifidelity () const |
identify if 2D hierarchy can be defined across both model forms and resolution levels | |
virtual short | ensemble_precedence () const |
return precedence for ensemble definition: model forms, resolution levels, or both | |
virtual void | ensemble_precedence (short mlmf_prec, bool update_default=false) |
assign precedence for ensemble definition (model forms or resolution levels or both) as determined from algorithm context | |
virtual size_t | solution_levels () const |
number of discrete levels within solution control (SimulationModel) More... | |
virtual void | solution_level_cost_index (size_t index) |
activate a particular level within the solution level control (SimulationModel) More... | |
virtual size_t | solution_level_cost_index () const |
return currently active level within the solution level control (SimulationModel) | |
virtual RealVector | solution_level_costs () const |
return ordered cost estimates across solution levels (SimulationModel) | |
virtual Real | solution_level_cost () const |
return currently active cost estimate from solution level control (SimulationModel) | |
virtual short | solution_control_variable_type () const |
return type of solution control variable | |
virtual size_t | solution_control_variable_index () const |
return index of solution control variable within all variables | |
virtual size_t | solution_control_discrete_variable_index () const |
return index of solution control variable within all discrete variables | |
virtual int | solution_level_int_value () const |
return the active (integer) value of the solution control | |
virtual String | solution_level_string_value () const |
return the active (string) value of the solution control | |
virtual Real | solution_level_real_value () const |
return the active (real) value of the solution control | |
virtual size_t | cost_metadata_index () const |
return index of online cost estimates within metadata | |
virtual bool | resize_pending () const |
return true if a potential resize is still pending, such that sizing-based initialization should be deferred | |
virtual const RealVector & | error_estimates () |
retrieve error estimates corresponding to the Model's response (could be surrogate error for SurrogateModels, statistical MSE for NestedModels, or adjoint error estimates for SimulationModels). Errors returned correspond to most recent evaluate(). | |
virtual unsigned short | correction_mode () const |
return correctionMode | |
virtual void | correction_mode (unsigned short corr_mode) |
set correctionMode | |
virtual void | single_apply (const Variables &vars, Response &resp, const Pecos::ActiveKey &paired_key) |
apply a DiscrepancyCorrection to correct an approximation within an EnsembleSurrModel | |
virtual void | recursive_apply (const Variables &vars, Response &resp) |
apply a sequence of DiscrepancyCorrections to recursively correct an approximation within an EnsembleSurrModel | |
virtual void | cache_unmatched_response (int raw_id) |
migrate an unmatched response record from active response map (computed by synchronize() or synhronize_nowait()) to cached response map | |
virtual void | cache_unmatched_responses () |
migrate remaining response records from responseMap to cachedResponseMap | |
virtual short | local_eval_synchronization () |
return derived model synchronization setting More... | |
virtual int | local_eval_concurrency () |
return derived model asynchronous evaluation concurrency More... | |
virtual bool | derived_master_overload () const |
Return a flag indicating the combination of multiprocessor evaluations and a dedicated master iterator scheduling. Used in synchronous evaluate functions to prevent the error of trying to run a multiprocessor job on the master. | |
virtual void | create_2d_plots () |
create 2D graphics plots for automatic logging of vars/response data | |
virtual void | create_tabular_datastream () |
create a tabular output stream for automatic logging of vars/response data | |
virtual void | derived_auto_graphics (const Variables &vars, const Response &resp) |
Update tabular/graphics data with latest variables/response data. | |
virtual void | eval_tag_prefix (const String &eval_id_str) |
set the hierarchical eval ID tag prefix More... | |
virtual bool | db_lookup (const Variables &search_vars, const ActiveSet &search_set, Response &found_resp) |
search the eval database (during derivative estimation); derived may need to reimplement due to problem transformations (RecastModel); return true if found in DB | |
virtual void | stop_init_mapping (ParLevLIter pl_iter) |
called from IteratorScheduler::run_iterator() for iteratorComm rank 0 to terminate serve_init_mapping() on other iteratorComm processors | |
virtual int | serve_init_mapping (ParLevLIter pl_iter) |
called from IteratorScheduler::run_iterator() for iteratorComm rank != 0 to balance resize() calls on iteratorComm rank 0 | |
virtual void | stop_finalize_mapping (ParLevLIter pl_iter) |
called from IteratorScheduler::run_iterator() for iteratorComm rank 0 to terminate serve_finalize_mapping() on other iteratorComm processors | |
virtual int | serve_finalize_mapping (ParLevLIter pl_iter) |
called from IteratorScheduler::run_iterator() for iteratorComm rank != 0 to balance resize() calls on iteratorComm rank 0 | |
ModelList & | subordinate_models (bool recurse_flag=true) |
return the sub-models in nested and surrogate models More... | |
void | evaluate () |
Compute the Response at currentVariables (default ActiveSet). | |
void | evaluate (const ActiveSet &set) |
Compute the Response at currentVariables (specified ActiveSet). | |
void | evaluate_nowait () |
Spawn an asynchronous job (or jobs) that computes the value of the Response at currentVariables (default ActiveSet). | |
void | evaluate_nowait (const ActiveSet &set) |
Spawn an asynchronous job (or jobs) that computes the value of the Response at currentVariables (specified ActiveSet). | |
const IntResponseMap & | synchronize () |
Execute a blocking scheduling algorithm to collect the complete set of results from a group of asynchronous evaluations. | |
const IntResponseMap & | synchronize_nowait () |
Execute a nonblocking scheduling algorithm to collect all available results from a group of asynchronous evaluations. | |
int | evaluation_id () const |
return Model's (top-level) evaluation counter, not to be confused with derived counter returned by derived_evaluation_id() | |
bool | mapping_initialized () const |
void | init_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
allocate communicator partitions for a model and store configuration in modelPCIterMap More... | |
void | init_serial () |
for cases where init_communicators() will not be called, modify some default settings to behave properly in serial. More... | |
void | set_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
set active parallel configuration for the model (set modelPCIter from modelPCIterMap) | |
void | free_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
deallocate communicator partitions for a model | |
MPI_Comm | analysis_comm () const |
retrieve the MPI communicator on which this model is configured to conduct function evaluation analyses (provided for library clients) | |
void | stop_init_communicators (ParLevLIter pl_iter) |
called from IteratorScheduler::init_iterator() for iteratorComm rank 0 to terminate serve_init_communicators() on other iteratorComm processors | |
int | serve_init_communicators (ParLevLIter pl_iter) |
called from IteratorScheduler::init_iterator() for iteratorComm rank != 0 to balance init_communicators() calls on iteratorComm rank 0 | |
void | estimate_message_lengths () |
estimate messageLengths for a model More... | |
size_t | response_size () const |
return (potentially aggregated) size of response vector in currentResponse | |
bool | manage_data_recastings () |
initialize modelList and recastFlags for data import/export More... | |
bool | recastings () const |
return true if recastFlags is defined | |
void | user_space_to_iterator_space (Variables &vars) |
employ the model recursion to transform from bottom level user-space variables to top level iterator-space variables | |
void | user_space_to_iterator_space (const Variables &user_vars, const Response &user_resp, Variables &iter_vars, Response &iter_resp) |
employ the model recursion to transform from bottom level user-space data to top level iterator-space data | |
void | iterator_space_to_user_space (Variables &vars) |
employ the model recursion to transform from top level iterator-space variables to bottom level user-space variables | |
void | iterator_space_to_user_space (const Variables &iter_vars, const Response &iter_resp, Variables &user_vars, Response &user_resp) |
employ the model recursion to transform from top level iterator-space data to bottom level user-space data | |
void | assign_rep (std::shared_ptr< Model > model_rep) |
replaces existing letter with a new one More... | |
size_t | tv () const |
returns total number of vars | |
size_t | cv () const |
returns number of active continuous variables | |
size_t | div () const |
returns number of active discrete integer vars | |
size_t | dsv () const |
returns number of active discrete string vars | |
size_t | drv () const |
returns number of active discrete real vars | |
size_t | icv () const |
returns number of inactive continuous variables | |
size_t | idiv () const |
returns number of inactive discrete integer vars | |
size_t | idsv () const |
returns number of inactive discrete string vars | |
size_t | idrv () const |
returns number of inactive discrete real vars | |
size_t | acv () const |
returns total number of continuous variables | |
size_t | adiv () const |
returns total number of discrete integer vars | |
size_t | adsv () const |
returns total number of discrete string vars | |
size_t | adrv () const |
returns total number of discrete real vars | |
void | active_variables (const Variables &vars) |
set the active variables in currentVariables | |
void | inactive_variables (const Variables &vars) |
set the inactive variables in currentVariables | |
const RealVector & | continuous_variables () const |
return the active continuous variables from currentVariables | |
Real | continuous_variable (size_t i) const |
return an active continuous variable from currentVariables | |
void | continuous_variables (const RealVector &c_vars) |
set the active continuous variables in currentVariables | |
void | continuous_variable (Real c_var, size_t i) |
set an active continuous variable in currentVariables | |
const IntVector & | discrete_int_variables () const |
return the active discrete integer variables from currentVariables | |
int | discrete_int_variable (size_t i) const |
return an active discrete integer variable from currentVariables | |
void | discrete_int_variables (const IntVector &d_vars) |
set the active discrete integer variables in currentVariables | |
void | discrete_int_variable (int d_var, size_t i) |
set an active discrete integer variable in currentVariables | |
StringMultiArrayConstView | discrete_string_variables () const |
return the active discrete string variables from currentVariables | |
const String & | discrete_string_variable (size_t i) const |
return an active discrete string variable from currentVariables | |
void | discrete_string_variables (StringMultiArrayConstView d_vars) |
set the active discrete string variables in currentVariables | |
void | discrete_string_variable (const String &d_var, size_t i) |
set an active discrete string variable in currentVariables | |
const RealVector & | discrete_real_variables () const |
return the active discrete real variables from currentVariables | |
Real | discrete_real_variable (size_t i) const |
return an active discrete real variable from currentVariables | |
void | discrete_real_variables (const RealVector &d_vars) |
set the active discrete real variables in currentVariables | |
void | discrete_real_variable (Real d_var, size_t i) |
set an active discrete real variable in currentVariables | |
UShortMultiArrayConstView | continuous_variable_types () const |
return the active continuous variable types from currentVariables | |
void | continuous_variable_types (UShortMultiArrayConstView cv_types) |
set the active continuous variable types in currentVariables | |
void | continuous_variable_type (unsigned short cv_type, size_t i) |
set an active continuous variable type in currentVariables | |
UShortMultiArrayConstView | discrete_int_variable_types () const |
return the active discrete variable types from currentVariables | |
void | discrete_int_variable_types (UShortMultiArrayConstView div_types) |
set the active discrete variable types in currentVariables | |
void | discrete_int_variable_type (unsigned short div_type, size_t i) |
set an active discrete variable type in currentVariables | |
UShortMultiArrayConstView | discrete_string_variable_types () const |
return the active discrete variable types from currentVariables | |
void | discrete_string_variable_types (UShortMultiArrayConstView div_types) |
set the active discrete variable types in currentVariables | |
void | discrete_string_variable_type (unsigned short div_type, size_t i) |
set an active discrete variable type in currentVariables | |
UShortMultiArrayConstView | discrete_real_variable_types () const |
return the active discrete variable types from currentVariables | |
void | discrete_real_variable_types (UShortMultiArrayConstView drv_types) |
set the active discrete variable types in currentVariables | |
void | discrete_real_variable_type (unsigned short drv_type, size_t i) |
set an active discrete variable type in currentVariables | |
SizetMultiArrayConstView | continuous_variable_ids () const |
return the active continuous variable identifiers from currentVariables | |
void | continuous_variable_ids (SizetMultiArrayConstView cv_ids) |
set the active continuous variable identifiers in currentVariables | |
void | continuous_variable_id (size_t cv_id, size_t i) |
set an active continuous variable identifier in currentVariables | |
const RealVector & | inactive_continuous_variables () const |
return the inactive continuous variables in currentVariables | |
void | inactive_continuous_variables (const RealVector &i_c_vars) |
set the inactive continuous variables in currentVariables | |
const IntVector & | inactive_discrete_int_variables () const |
return the inactive discrete variables in currentVariables | |
void | inactive_discrete_int_variables (const IntVector &i_d_vars) |
set the inactive discrete variables in currentVariables | |
StringMultiArrayConstView | inactive_discrete_string_variables () const |
return the inactive discrete variables in currentVariables | |
void | inactive_discrete_string_variables (StringMultiArrayConstView i_d_vars) |
set the inactive discrete variables in currentVariables | |
const RealVector & | inactive_discrete_real_variables () const |
return the inactive discrete variables in currentVariables | |
void | inactive_discrete_real_variables (const RealVector &i_d_vars) |
set the inactive discrete variables in currentVariables | |
UShortMultiArrayConstView | inactive_continuous_variable_types () const |
return the inactive continuous variable types from currentVariables | |
SizetMultiArrayConstView | inactive_continuous_variable_ids () const |
return the inactive continuous variable identifiers from currentVariables | |
const RealVector & | all_continuous_variables () const |
return all continuous variables in currentVariables | |
void | all_continuous_variables (const RealVector &a_c_vars) |
set all continuous variables in currentVariables | |
void | all_continuous_variable (Real a_c_var, size_t i) |
set a variable within the all continuous variables in currentVariables | |
const IntVector & | all_discrete_int_variables () const |
return all discrete variables in currentVariables | |
void | all_discrete_int_variables (const IntVector &a_d_vars) |
set all discrete variables in currentVariables | |
void | all_discrete_int_variable (int a_d_var, size_t i) |
set a variable within the all discrete variables in currentVariables | |
StringMultiArrayConstView | all_discrete_string_variables () const |
return all discrete variables in currentVariables | |
void | all_discrete_string_variables (StringMultiArrayConstView a_d_vars) |
set all discrete variables in currentVariables | |
void | all_discrete_string_variable (const String &a_d_var, size_t i) |
set a variable within the all discrete variables in currentVariables | |
const RealVector & | all_discrete_real_variables () const |
return all discrete variables in currentVariables | |
void | all_discrete_real_variables (const RealVector &a_d_vars) |
set all discrete variables in currentVariables | |
void | all_discrete_real_variable (Real a_d_var, size_t i) |
set a variable within the all discrete variables in currentVariables | |
UShortMultiArrayConstView | all_continuous_variable_types () const |
return all continuous variable types from currentVariables | |
UShortMultiArrayConstView | all_discrete_int_variable_types () const |
return all discrete variable types from currentVariables | |
UShortMultiArrayConstView | all_discrete_string_variable_types () const |
return all discrete variable types from currentVariables | |
UShortMultiArrayConstView | all_discrete_real_variable_types () const |
return all discrete variable types from currentVariables | |
SizetMultiArrayConstView | all_continuous_variable_ids () const |
return all continuous variable identifiers from currentVariables | |
const BitArray & | discrete_int_sets () |
define and return discreteIntSets using active view from currentVariables | |
const BitArray & | discrete_int_sets (short active_view) |
define and return discreteIntSets using passed active view | |
const IntSetArray & | discrete_set_int_values () |
return the sets of values available for each of the active discrete set integer variables (aggregated in activeDiscSetIntValues) | |
const IntSetArray & | discrete_set_int_values (short active_view) |
return the sets of values available for each of the active discrete set integer variables (aggregated in activeDiscSetIntValues) | |
const StringSetArray & | discrete_set_string_values () |
return the sets of values available for each of the active discrete set string variables (aggregated in activeDiscSetStringValues) | |
const StringSetArray & | discrete_set_string_values (short active_view) |
return the sets of values available for each of the active discrete set string variables (aggregated in activeDiscSetStringValues) | |
const RealSetArray & | discrete_set_real_values () |
return the sets of values available for each of the active discrete set real variables (aggregated in activeDiscSetRealValues) | |
const RealSetArray & | discrete_set_real_values (short active_view) |
return the sets of values available for each of the active discrete set real variables (aggregated in activeDiscSetRealValues) | |
Pecos::MultivariateDistribution & | multivariate_distribution () |
return mvDist | |
const Pecos::MultivariateDistribution & | multivariate_distribution () const |
return mvDist | |
StringMultiArrayConstView | continuous_variable_labels () const |
return the active continuous variable labels from currentVariables | |
void | continuous_variable_labels (StringMultiArrayConstView c_v_labels) |
set the active continuous variable labels in currentVariables | |
StringMultiArrayConstView | discrete_int_variable_labels () const |
return the active discrete variable labels from currentVariables | |
void | discrete_int_variable_labels (StringMultiArrayConstView d_v_labels) |
set the active discrete variable labels in currentVariables | |
StringMultiArrayConstView | discrete_string_variable_labels () const |
return the active discrete variable labels from currentVariables | |
void | discrete_string_variable_labels (StringMultiArrayConstView d_v_labels) |
set the active discrete variable labels in currentVariables | |
StringMultiArrayConstView | discrete_real_variable_labels () const |
return the active discrete variable labels from currentVariables | |
void | discrete_real_variable_labels (StringMultiArrayConstView d_v_labels) |
set the active discrete variable labels in currentVariables | |
StringArray | ordered_labels () const |
Return labels of all active variables in "input spec" order. | |
StringMultiArrayConstView | inactive_continuous_variable_labels () const |
return the inactive continuous variable labels in currentVariables | |
void | inactive_continuous_variable_labels (StringMultiArrayConstView i_c_v_labels) |
set the inactive continuous variable labels in currentVariables | |
StringMultiArrayConstView | inactive_discrete_int_variable_labels () const |
return the inactive discrete variable labels in currentVariables | |
void | inactive_discrete_int_variable_labels (StringMultiArrayConstView i_d_v_labels) |
set the inactive discrete variable labels in currentVariables | |
StringMultiArrayConstView | inactive_discrete_string_variable_labels () const |
return the inactive discrete variable labels in currentVariables | |
void | inactive_discrete_string_variable_labels (StringMultiArrayConstView i_d_v_labels) |
set the inactive discrete variable labels in currentVariables | |
StringMultiArrayConstView | inactive_discrete_real_variable_labels () const |
return the inactive discrete variable labels in currentVariables | |
void | inactive_discrete_real_variable_labels (StringMultiArrayConstView i_d_v_labels) |
set the inactive discrete variable labels in currentVariables | |
StringArray | inactive_ordered_labels () const |
Return labels of all inactive variables in "input spec" order. | |
StringMultiArrayConstView | all_continuous_variable_labels () const |
return all continuous variable labels in currentVariables | |
void | all_continuous_variable_labels (StringMultiArrayConstView a_c_v_labels) |
set all continuous variable labels in currentVariables | |
void | all_continuous_variable_label (const String &a_c_v_label, size_t i) |
set a label within the all continuous labels in currentVariables | |
StringMultiArrayConstView | all_discrete_int_variable_labels () const |
return all discrete variable labels in currentVariables | |
void | all_discrete_int_variable_labels (StringMultiArrayConstView a_d_v_labels) |
set all discrete variable labels in currentVariables | |
void | all_discrete_int_variable_label (const String &a_d_v_label, size_t i) |
set a label within the all discrete labels in currentVariables | |
StringMultiArrayConstView | all_discrete_string_variable_labels () const |
return all discrete variable labels in currentVariables | |
void | all_discrete_string_variable_labels (StringMultiArrayConstView a_d_v_labels) |
set all discrete variable labels in currentVariables | |
void | all_discrete_string_variable_label (const String &a_d_v_label, size_t i) |
set a label within the all discrete labels in currentVariables | |
StringMultiArrayConstView | all_discrete_real_variable_labels () const |
return all discrete variable labels in currentVariables | |
void | all_discrete_real_variable_labels (StringMultiArrayConstView a_d_v_labels) |
set all discrete variable labels in currentVariables | |
void | all_discrete_real_variable_label (const String &a_d_v_label, size_t i) |
set a label within the all discrete labels in currentVariables | |
StringArray | all_ordered_labels () const |
Return labels of all variables in "input spec" order. | |
const StringArray & | response_labels () const |
return the response labels from currentResponse | |
void | response_labels (const StringArray &resp_labels) |
set the response labels in currentResponse | |
const RealVector & | continuous_lower_bounds () const |
return the active continuous lower bounds from userDefinedConstraints | |
Real | continuous_lower_bound (size_t i) const |
return an active continuous lower bound from userDefinedConstraints | |
void | continuous_lower_bounds (const RealVector &c_l_bnds) |
set the active continuous lower bounds in userDefinedConstraints | |
void | continuous_lower_bound (Real c_l_bnd, size_t i) |
set the i-th active continuous lower bound in userDefinedConstraints | |
const RealVector & | continuous_upper_bounds () const |
return the active continuous upper bounds from userDefinedConstraints | |
Real | continuous_upper_bound (size_t i) const |
return an active continuous upper bound from userDefinedConstraints | |
void | continuous_upper_bounds (const RealVector &c_u_bnds) |
set the active continuous upper bounds in userDefinedConstraints | |
void | continuous_upper_bound (Real c_u_bnd, size_t i) |
set the i-th active continuous upper bound from userDefinedConstraints | |
const IntVector & | discrete_int_lower_bounds () const |
return the active discrete int lower bounds from userDefinedConstraints | |
int | discrete_int_lower_bound (size_t i) const |
return an active discrete int lower bound from userDefinedConstraints | |
void | discrete_int_lower_bounds (const IntVector &d_l_bnds) |
set the active discrete int lower bounds in userDefinedConstraints | |
void | discrete_int_lower_bound (int d_l_bnd, size_t i) |
set the i-th active discrete int lower bound in userDefinedConstraints | |
const IntVector & | discrete_int_upper_bounds () const |
return the active discrete int upper bounds from userDefinedConstraints | |
int | discrete_int_upper_bound (size_t i) const |
return an active discrete int upper bound from userDefinedConstraints | |
void | discrete_int_upper_bounds (const IntVector &d_u_bnds) |
set the active discrete int upper bounds in userDefinedConstraints | |
void | discrete_int_upper_bound (int d_u_bnd, size_t i) |
set the i-th active discrete int upper bound in userDefinedConstraints | |
const RealVector & | discrete_real_lower_bounds () const |
return the active discrete real lower bounds from userDefinedConstraints | |
Real | discrete_real_lower_bound (size_t i) const |
return an active discrete real lower bound from userDefinedConstraints | |
void | discrete_real_lower_bounds (const RealVector &d_l_bnds) |
set the active discrete real lower bounds in userDefinedConstraints | |
void | discrete_real_lower_bound (Real d_l_bnd, size_t i) |
set the i-th active discrete real lower bound in userDefinedConstraints | |
const RealVector & | discrete_real_upper_bounds () const |
return the active discrete real upper bounds from userDefinedConstraints | |
Real | discrete_real_upper_bound (size_t i) const |
return an active discrete real upper bound from userDefinedConstraints | |
void | discrete_real_upper_bounds (const RealVector &d_u_bnds) |
set the active discrete real upper bounds in userDefinedConstraints | |
void | discrete_real_upper_bound (Real d_u_bnd, size_t i) |
set the i-th active discrete real upper bound in userDefinedConstraints | |
const RealVector & | inactive_continuous_lower_bounds () const |
return the inactive continuous lower bounds in userDefinedConstraints | |
void | inactive_continuous_lower_bounds (const RealVector &i_c_l_bnds) |
set the inactive continuous lower bounds in userDefinedConstraints | |
const RealVector & | inactive_continuous_upper_bounds () const |
return the inactive continuous upper bounds in userDefinedConstraints | |
void | inactive_continuous_upper_bounds (const RealVector &i_c_u_bnds) |
set the inactive continuous upper bounds in userDefinedConstraints | |
const IntVector & | inactive_discrete_int_lower_bounds () const |
return the inactive discrete lower bounds in userDefinedConstraints | |
void | inactive_discrete_int_lower_bounds (const IntVector &i_d_l_bnds) |
set the inactive discrete lower bounds in userDefinedConstraints | |
const IntVector & | inactive_discrete_int_upper_bounds () const |
return the inactive discrete upper bounds in userDefinedConstraints | |
void | inactive_discrete_int_upper_bounds (const IntVector &i_d_u_bnds) |
set the inactive discrete upper bounds in userDefinedConstraints | |
const RealVector & | inactive_discrete_real_lower_bounds () const |
return the inactive discrete lower bounds in userDefinedConstraints | |
void | inactive_discrete_real_lower_bounds (const RealVector &i_d_l_bnds) |
set the inactive discrete lower bounds in userDefinedConstraints | |
const RealVector & | inactive_discrete_real_upper_bounds () const |
return the inactive discrete upper bounds in userDefinedConstraints | |
void | inactive_discrete_real_upper_bounds (const RealVector &i_d_u_bnds) |
set the inactive discrete upper bounds in userDefinedConstraints | |
const RealVector & | all_continuous_lower_bounds () const |
return all continuous lower bounds in userDefinedConstraints | |
void | all_continuous_lower_bounds (const RealVector &a_c_l_bnds) |
set all continuous lower bounds in userDefinedConstraints | |
void | all_continuous_lower_bound (Real a_c_l_bnd, size_t i) |
set a lower bound within continuous lower bounds in userDefinedConstraints | |
const RealVector & | all_continuous_upper_bounds () const |
return all continuous upper bounds in userDefinedConstraints | |
void | all_continuous_upper_bounds (const RealVector &a_c_u_bnds) |
set all continuous upper bounds in userDefinedConstraints | |
void | all_continuous_upper_bound (Real a_c_u_bnd, size_t i) |
set an upper bound within all continuous upper bounds in userDefinedConstraints | |
const IntVector & | all_discrete_int_lower_bounds () const |
return all discrete lower bounds in userDefinedConstraints | |
void | all_discrete_int_lower_bounds (const IntVector &a_d_l_bnds) |
set all discrete lower bounds in userDefinedConstraints | |
void | all_discrete_int_lower_bound (int a_d_l_bnd, size_t i) |
set a lower bound within all discrete lower bounds in userDefinedConstraints | |
const IntVector & | all_discrete_int_upper_bounds () const |
return all discrete upper bounds in userDefinedConstraints | |
void | all_discrete_int_upper_bounds (const IntVector &a_d_u_bnds) |
set all discrete upper bounds in userDefinedConstraints | |
void | all_discrete_int_upper_bound (int a_d_u_bnd, size_t i) |
set an upper bound within all discrete upper bounds in userDefinedConstraints | |
const RealVector & | all_discrete_real_lower_bounds () const |
return all discrete lower bounds in userDefinedConstraints | |
void | all_discrete_real_lower_bounds (const RealVector &a_d_l_bnds) |
set all discrete lower bounds in userDefinedConstraints | |
void | all_discrete_real_lower_bound (Real a_d_l_bnd, size_t i) |
set a lower bound within all discrete lower bounds in userDefinedConstraints | |
const RealVector & | all_discrete_real_upper_bounds () const |
return all discrete upper bounds in userDefinedConstraints | |
void | all_discrete_real_upper_bounds (const RealVector &a_d_u_bnds) |
set all discrete upper bounds in userDefinedConstraints | |
void | all_discrete_real_upper_bound (Real a_d_u_bnd, size_t i) |
set an upper bound within all discrete upper bounds in userDefinedConstraints | |
size_t | num_linear_ineq_constraints () const |
reshape the linear/nonlinear constraint arrays More... | |
size_t | num_linear_eq_constraints () const |
return the number of linear equality constraints | |
const RealMatrix & | linear_ineq_constraint_coeffs () const |
return the linear inequality constraint coefficients | |
void | linear_ineq_constraint_coeffs (const RealMatrix &lin_ineq_coeffs) |
set the linear inequality constraint coefficients | |
const RealVector & | linear_ineq_constraint_lower_bounds () const |
return the linear inequality constraint lower bounds | |
void | linear_ineq_constraint_lower_bounds (const RealVector &lin_ineq_l_bnds) |
set the linear inequality constraint lower bounds | |
const RealVector & | linear_ineq_constraint_upper_bounds () const |
return the linear inequality constraint upper bounds | |
void | linear_ineq_constraint_upper_bounds (const RealVector &lin_ineq_u_bnds) |
set the linear inequality constraint upper bounds | |
const RealMatrix & | linear_eq_constraint_coeffs () const |
return the linear equality constraint coefficients | |
void | linear_eq_constraint_coeffs (const RealMatrix &lin_eq_coeffs) |
set the linear equality constraint coefficients | |
const RealVector & | linear_eq_constraint_targets () const |
return the linear equality constraint targets | |
void | linear_eq_constraint_targets (const RealVector &lin_eq_targets) |
set the linear equality constraint targets | |
size_t | num_nonlinear_ineq_constraints () const |
return the number of nonlinear inequality constraints | |
size_t | num_nonlinear_eq_constraints () const |
return the number of nonlinear equality constraints | |
const RealVector & | nonlinear_ineq_constraint_lower_bounds () const |
return the nonlinear inequality constraint lower bounds | |
void | nonlinear_ineq_constraint_lower_bounds (const RealVector &nln_ineq_l_bnds) |
set the nonlinear inequality constraint lower bounds | |
const RealVector & | nonlinear_ineq_constraint_upper_bounds () const |
return the nonlinear inequality constraint upper bounds | |
void | nonlinear_ineq_constraint_upper_bounds (const RealVector &nln_ineq_u_bnds) |
set the nonlinear inequality constraint upper bounds | |
const RealVector & | nonlinear_eq_constraint_targets () const |
return the nonlinear equality constraint targets | |
void | nonlinear_eq_constraint_targets (const RealVector &nln_eq_targets) |
set the nonlinear equality constraint targets | |
const Variables & | current_variables () const |
return the current variables (currentVariables) as const reference (preferred) | |
Variables & | current_variables () |
return the current variables (currentVariables) in mutable form (special cases) | |
const Constraints & | user_defined_constraints () const |
return the user-defined constraints (userDefinedConstraints) as const reference (preferred) | |
Constraints & | user_defined_constraints () |
return the user-defined constraints (userDefinedConstraints) in mutable form (special cases) | |
const Response & | current_response () const |
return the current response (currentResponse) | |
ProblemDescDB & | problem_description_db () const |
return the problem description database (probDescDB) | |
ParallelLibrary & | parallel_library () const |
return the parallel library (parallelLib) | |
const String & | model_type () const |
return the model type (modelType) | |
const String & | surrogate_type () const |
return the surrogate type (surrogateType) | |
const String & | model_id () const |
return the model identifier (modelId) | |
size_t | num_primary_fns () const |
return number of primary functions (total less nonlinear constraints) | |
size_t | num_secondary_fns () const |
return number of secondary functions (number of nonlinear constraints) | |
const String & | gradient_type () const |
return the gradient evaluation type (gradientType) | |
const String & | method_source () const |
return the numerical gradient evaluation method source (methodSource) | |
const String & | interval_type () const |
return the numerical gradient evaluation interval type (intervalType) | |
bool | ignore_bounds () const |
option for ignoring bounds when numerically estimating derivatives | |
bool | central_hess () const |
option for using old 2nd-order scheme when computing finite-diff Hessian | |
const RealVector & | fd_gradient_step_size () const |
return the finite difference gradient step size (fdGradStepSize) | |
const String & | fd_gradient_step_type () const |
return the finite difference gradient step type (fdGradStepType) | |
const IntSet & | gradient_id_analytic () const |
return the mixed gradient analytic IDs (gradIdAnalytic) | |
const IntSet & | gradient_id_numerical () const |
return the mixed gradient numerical IDs (gradIdNumerical) | |
const String & | hessian_type () const |
return the Hessian evaluation type (hessianType) | |
const String & | quasi_hessian_type () const |
return the Hessian evaluation type (quasiHessType) | |
const RealVector & | fd_hessian_by_grad_step_size () const |
return gradient-based finite difference Hessian step size (fdHessByGradStepSize) | |
const RealVector & | fd_hessian_by_fn_step_size () const |
return function-based finite difference Hessian step size (fdHessByFnStepSize) | |
const String & | fd_hessian_step_type () const |
return the finite difference Hessian step type (fdHessStepType) | |
const IntSet & | hessian_id_analytic () const |
return the mixed Hessian analytic IDs (hessIdAnalytic) | |
const IntSet & | hessian_id_numerical () const |
return the mixed Hessian analytic IDs (hessIdNumerical) | |
const IntSet & | hessian_id_quasi () const |
return the mixed Hessian analytic IDs (hessIdQuasi) | |
void | primary_response_fn_sense (const BoolDeque &sense) |
set the optimization sense for multiple objective functions | |
const BoolDeque & | primary_response_fn_sense () const |
get the optimization sense for multiple objective functions | |
const RealVector & | primary_response_fn_weights () const |
get the relative weightings for multiple objective functions or least squares terms | |
const ScalingOptions & | scaling_options () const |
user-provided scaling options | |
short | primary_fn_type () const |
get the primary response function type (generic, objective, calibration) | |
void | primary_fn_type (short type) |
set the primary response function type, e.g., when recasting | |
bool | derivative_estimation () |
indicates potential usage of estimate_derivatives() based on gradientType/hessianType | |
void | supports_derivative_estimation (bool sed_flag) |
set whether this model should perform or pass on derivative estimation | |
void | init_comms_bcast_flag (bool icb_flag) |
set initCommsBcastFlag | |
int | evaluation_capacity () const |
return the evaluation capacity for use in iterator logic | |
int | derivative_concurrency () const |
return the gradient concurrency for use in parallel configuration logic More... | |
bool | asynch_flag () const |
return the asynchronous evaluation flag (asynchEvalFlag) | |
void | asynch_flag (const bool flag) |
set the asynchronous evaluation flag (asynchEvalFlag) | |
short | output_level () const |
return the outputLevel | |
void | output_level (const short level) |
set the outputLevel | |
const IntArray & | message_lengths () const |
return the array of MPI packed message buffer lengths (messageLengths) | |
void | parallel_configuration_iterator (ParConfigLIter pc_iter) |
set modelPCIter | |
ParConfigLIter | parallel_configuration_iterator () const |
return modelPCIter | |
void | auto_graphics (const bool flag) |
set modelAutoGraphicsFlag to activate posting of graphics data within evaluate/synchronize functions (automatic graphics posting in the model as opposed to graphics posting at the strategy level). | |
bool | auto_graphics () const |
get modelAutoGraphicsFlag to activate posting of graphics data within evaluate/synchronize functions (automatic graphics posting in the model as opposed to graphics posting at the strategy level). | |
bool | is_null () const |
function to check modelRep (does this envelope contain a letter) | |
std::shared_ptr< Model > | model_rep () const |
returns modelRep for access to derived class member functions that are not mapped to the top Model level | |
virtual String | root_model_id () |
Return the model ID of the "innermost" model. For all derived Models except RecastModels, return modelId. The RecastModel override returns the root_model_id() of the subModel. | |
virtual ActiveSet | default_active_set () |
Protected Member Functions | |
size_t | qoi () const |
return number of unique response functions (managing any aggregations) | |
DiscrepancyCorrection & | discrepancy_correction () |
return the DiscrepancyCorrection object used by SurrogateModels | |
void | correction_type (short corr_type) |
set the correction type from the DiscrepancyCorrection object used by SurrogateModels | |
bool | initialize_mapping (ParLevLIter pl_iter) |
Perform any global updates prior to individual evaluate() calls; returns true if the variables size has changed. | |
bool | finalize_mapping () |
void | update_model (Model &model) |
update model with data that could change per function evaluation (active variable values/bounds) | |
void | update_from_model (const Model &model) |
update current variables/labels/bounds/targets with data from model More... | |
void | nested_variable_mappings (const SizetArray &c_index1, const SizetArray &di_index1, const SizetArray &ds_index1, const SizetArray &dr_index1, const ShortArray &c_target2, const ShortArray &di_target2, const ShortArray &ds_target2, const ShortArray &dr_target2) |
set primaryA{C,DI,DS,DR}VarMapIndices, secondaryA{C,DI,DS,DR}VarMapTargets (coming from a higher-level NestedModel context to inform derivative est.) | |
const SizetArray & | nested_acv1_indices () const |
return primaryACVarMapIndices | |
const ShortArray & | nested_acv2_targets () const |
return secondaryACVarMapTargets | |
short | query_distribution_parameter_derivatives () const |
calculate and return derivative composition of final results w.r.t. distribution parameters (none, all, or mixed) | |
void | check_submodel_compatibility (const Model &sub_model) |
verify compatibility between SurrogateModel attributes and attributes of the submodel (DataFitSurrModel::actualModel or EnsembleSurrModel::truthModel) | |
void | derived_evaluate (const ActiveSet &set) |
void | derived_evaluate_nowait (const ActiveSet &set) |
const IntResponseMap & | derived_synchronize () |
const IntResponseMap & | derived_synchronize_nowait () |
void | asv_inflate_build (const ShortArray &orig_asv, ShortArray &actual_asv) |
map incoming ASV into actual request for surrogate construction, managing any mismatch in sizes due to response aggregation modes in actualModel | |
void | asv_split (const ShortArray &orig_asv, ShortArray &actual_asv, ShortArray &approx_asv) |
split incoming ASV into actual and approximate evaluation requests, managing any mismatch in sizes due to response aggregation modes in actualModel | |
Iterator & | subordinate_iterator () |
return daceIterator | |
void | active_model_key (const Pecos::ActiveKey &key) |
set active model key within approxInterface | |
void | clear_model_keys () |
remove all model keys within approxInterface | |
Model & | surrogate_model (size_t i=_NPOS) |
return this model instance | |
const Model & | surrogate_model (size_t i=_NPOS) const |
return this model instance | |
Model & | truth_model () |
return actualModel | |
const Model & | truth_model () const |
return actualModel | |
void | derived_subordinate_models (ModelList &ml, bool recurse_flag) |
return actualModel (and optionally its sub-models) | |
void | resize_from_subordinate_model (size_t depth=SZ_MAX) |
pass request to actualModel if recursing | |
void | update_from_subordinate_model (size_t depth=SZ_MAX) |
pass request to actualModel if recursing and then update from it | |
Interface & | derived_interface () |
return approxInterface | |
void | primary_response_fn_weights (const RealVector &wts, bool recurse_flag=true) |
set the relative weightings for multiple objective functions or least squares terms and optionally recurses into actualModel | |
void | surrogate_response_mode (short mode) |
set responseMode and pass any bypass request on to actualModel for any lower-level surrogates. | |
void | discrepancy_emulation_mode (short mode) |
set approxInterface.sharedData.discrepEmulationMode | |
void | surrogate_function_indices (const SizetSet &surr_fn_indices) |
(re)set the surrogate index set in SurrogateModel::surrogateFnIndices and ApproximationInterface::approxFnIndices | |
bool | force_rebuild () |
determine whether a surrogate model rebuild should be forced based on changes in the inactive data | |
void | build_approximation () |
Builds the local/multipoint/global approximation using daceIterator/actualModel to generate new data points. More... | |
bool | build_approximation (const Variables &vars, const IntResponsePair &response_pr) |
Builds the local/multipoint/global approximation using daceIterator/actualModel to generate new data points that augment the passed vars/response anchor point. More... | |
void | rebuild_approximation () |
Rebuilds the local/multipoint/global approximation using daceIterator/actualModel to generate an increment of appended data. More... | |
void | rebuild_approximation (const IntResponsePair &response_pr) |
Rebuilds the local/multipoint/global approximation using the passed response data for a single sample. | |
void | rebuild_approximation (const IntResponseMap &resp_map) |
Rebuilds the local/multipoint/global approximation using the passed response data for a set of samples. | |
void | update_approximation (bool rebuild_flag) |
replaces the approximation data with daceIterator results and rebuilds the approximation if requested More... | |
void | update_approximation (const Variables &vars, const IntResponsePair &response_pr, bool rebuild_flag) |
replaces the anchor point, and rebuilds the approximation if requested More... | |
void | update_approximation (const VariablesArray &vars_array, const IntResponseMap &resp_map, bool rebuild_flag) |
replaces the current points array and rebuilds the approximation if requested More... | |
void | update_approximation (const RealMatrix &samples, const IntResponseMap &resp_map, bool rebuild_flag) |
replaces the current points array and rebuilds the approximation if requested More... | |
void | append_approximation (bool rebuild_flag) |
appends daceIterator results to a global approximation and rebuilds it if requested More... | |
void | append_approximation (const Variables &vars, const IntResponsePair &response_pr, bool rebuild_flag) |
appends a point to a global approximation and rebuilds it if requested More... | |
void | append_approximation (const RealMatrix &samples, const IntResponseMap &resp_map, bool rebuild_flag) |
appends a matrix of points to a global approximation and rebuilds it if requested More... | |
void | append_approximation (const VariablesArray &vars_array, const IntResponseMap &resp_map, bool rebuild_flag) |
appends an array of points to a global approximation and rebuilds it if requested More... | |
void | append_approximation (const IntVariablesMap &vars_map, const IntResponseMap &resp_map, bool rebuild_flag) |
appends an map of points to a global approximation and rebuilds it if requested More... | |
void | replace_approximation (const IntResponsePair &response_pr, bool rebuild_flag) |
replace the response for a single point (based on eval id from response_pr) within an existing surrogate's data | |
void | replace_approximation (const IntResponseMap &resp_map, bool rebuild_flag) |
replace the responses for a set of points (based on eval ids from resp_map) within an existing surrogate's data | |
void | track_evaluation_ids (bool track) |
assigns a flag to track evaluation ids within surrogate data, enabling id-based lookups for data replacement | |
void | pop_approximation (bool save_surr_data, bool rebuild_flag=false) |
remove the previous data set addition to a surrogate (e.g., due to a previous append_approximation() call); flag manages storing of surrogate data for use in a subsequent push_approximation() | |
void | push_approximation () |
push a previous approximation data state; reverse of pop_approximation | |
bool | push_available () |
query for whether a trial increment is restorable within a surrogate | |
void | finalize_approximation () |
finalize an approximation by applying all previous trial increments | |
void | combine_approximation () |
combine all level approximations into a separate composite approximation | |
void | combined_to_active (bool clear_combined=true) |
promote the combined approximation into the active one | |
void | clear_inactive () |
clear inactive data stored in the approxInterface | |
bool | advancement_available () |
query approxInterface for available advancements in order, rank, etc. | |
bool | formulation_updated () const |
query approxInterface for updates in formulation (requiring a rebuild) | |
void | formulation_updated (bool update) |
update the formulation status in approxInterface | |
void | run_dace () |
execute the DACE iterator to generate build data | |
SharedApproxData & | shared_approximation () |
retrieve the SharedApproxData from approxInterface | |
std::vector< Approximation > & | approximations () |
retrieve the set of Approximations from approxInterface | |
const RealVectorArray & | approximation_coefficients (bool normalized=false) |
return the approximation coefficients from each Approximation (request forwarded to approxInterface) | |
void | approximation_coefficients (const RealVectorArray &approx_coeffs, bool normalized=false) |
set the approximation coefficients within each Approximation (request forwarded to approxInterface) | |
const RealVector & | approximation_variances (const Variables &vars) |
return the approximation variance from each Approximation (request forwarded to approxInterface) | |
const Pecos::SurrogateData & | approximation_data (size_t fn_index) |
return the approximation data from a particular Approximation (request forwarded to approxInterface) | |
void | component_parallel_mode (short mode) |
update component parallel mode for supporting parallelism in actualModel | |
IntIntPair | estimate_partition_bounds (int max_eval_concurrency) |
estimate the minimum and maximum partition sizes that can be utilized by this Model | |
void | derived_init_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
set up actualModel for parallel operations More... | |
void | derived_init_serial () |
set up actualModel for serial operations. | |
void | derived_set_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
set active parallel configuration within actualModel | |
void | derived_free_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
deallocate communicator partitions for the DataFitSurrModel (request forwarded to actualModel) | |
void | serve_run (ParLevLIter pl_iter, int max_eval_concurrency) |
Service actualModel job requests received from the master. Completes when a termination message is received from stop_servers(). | |
void | stop_servers () |
Executed by the master to terminate actualModel server operations when DataFitSurrModel iteration is complete. | |
void | active_view (short view, bool recurse_flag=true) |
update the Model's active view based on higher level context and optionally recurse into actualModel | |
void | inactive_view (short view, bool recurse_flag=true) |
update the Model's inactive view based on higher level context and optionally recurse into actualModel | |
const String & | interface_id () const |
return the approxInterface identifier | |
bool | evaluation_cache (bool recurse_flag=true) const |
if recurse_flag, return the actualModel evaluation cache usage | |
bool | restart_file (bool recurse_flag=true) const |
if recurse_flag, return the actualModel restart file usage | |
void | set_evaluation_reference () |
set the evaluation counter reference points for the DataFitSurrModel (request forwarded to approxInterface and actualModel) | |
void | fine_grained_evaluation_counters () |
request fine-grained evaluation reporting within approxInterface and actualModel | |
void | print_evaluation_summary (std::ostream &s, bool minimal_header=false, bool relative_count=true) const |
print the evaluation summary for the DataFitSurrModel (request forwarded to approxInterface and actualModel) | |
void | warm_start_flag (const bool flag) |
set the warm start flag, including actualModel | |
ActiveSet | default_interface_active_set () |
Protected Member Functions inherited from SurrogateModel | |
SurrogateModel (ProblemDescDB &problem_db) | |
constructor | |
SurrogateModel (ProblemDescDB &problem_db, ParallelLibrary ¶llel_lib, const ShortShortPair &surr_view, const SharedVariablesData &svd, bool share_svd, const SharedResponseData &srd, bool share_srd, const ActiveSet &surr_set, short corr_type, short output_level) | |
alternate constructor | |
~SurrogateModel () | |
destructor | |
Pecos::ProbabilityTransformation & | probability_transformation () |
return probability transformation employed by the Model (forwarded along to ProbabilityTransformModel recasting) | |
void | activate_distribution_parameter_derivatives () |
activate derivative setting w.r.t. distribution parameters | |
void | deactivate_distribution_parameter_derivatives () |
deactivate derivative setting w.r.t. distribution parameters | |
void | trans_U_to_X (const RealVector &u_c_vars, RealVector &x_c_vars) |
transform u-space variable values to x-space | |
void | trans_X_to_U (const RealVector &x_c_vars, RealVector &u_c_vars) |
transform x-space variable values to u-space | |
void | trans_grad_X_to_U (const RealVector &fn_grad_x, RealVector &fn_grad_u, const RealVector &x_vars) |
transform x-space gradient vector to u-space | |
void | trans_grad_U_to_X (const RealVector &fn_grad_u, RealVector &fn_grad_x, const RealVector &x_vars) |
transform u-space gradient vector to x-space | |
void | trans_grad_X_to_S (const RealVector &fn_grad_x, RealVector &fn_grad_s, const RealVector &x_vars) |
transform x-space gradient vector to gradient with respect to inserted distribution parameters | |
void | trans_hess_X_to_U (const RealSymMatrix &fn_hess_x, RealSymMatrix &fn_hess_u, const RealVector &x_vars, const RealVector &fn_grad_x) |
transform x-space Hessian matrix to u-space | |
Model & | subordinate_model () |
return truth_model() | |
void | active_model_key (const Pecos::ActiveKey &key) |
set the active model key within surrogate data, grid driver, and approximation classes that support the management of multiple approximation states within surrogate models | |
const Pecos::ActiveKey & | active_model_key () const |
return the active model key (used by surrogate data, grid driver, and approximation classes to support the management of multiple approximation states within surrogate models) | |
short | surrogate_response_mode () const |
return response computation mode used in SurrogateModels for forming currentResponse | |
short | correction_type () const |
return the correction type from the DiscrepancyCorrection object used by SurrogateModels | |
short | correction_order () const |
return the correction order from the DiscrepancyCorrection object used by SurrogateModels | |
int | derived_evaluation_id () const |
return the current evaluation id for this Model More... | |
size_t | mi_parallel_level_index () const |
return miPLIndex | |
virtual void | init_model (Model &model) |
initialize model with data that could change once per set of evaluations (e.g., an outer iterator execution), including active variable labels, inactive variable values/bounds/labels, and linear/nonlinear constraint coeffs/bounds | |
virtual size_t | insert_response_start (size_t position) |
compute start index for inserting response data into aggregated response | |
virtual void | insert_metadata (const RealArray &md, size_t position, Response &agg_response) |
insert a single response into an aggregated response in the specified position | |
bool | check_active_variables (const Model &sub_model) |
check sub_model for consistency in active variable counts | |
bool | check_inactive_variables (const Model &sub_model) |
check sub_model for consistency in inactive variable counts | |
bool | check_response_qoi (const Model &sub_model) |
check sub_model for consistency in response QoI counts | |
void | init_model_constraints (Model &model) |
initialize model with linear/nonlinear constraint data that could change once per set of evaluations (e.g., an outer iterator execution) More... | |
void | init_model_labels (Model &model) |
initialize model with active/inactive variable label data that could change once per set of evaluations (e.g., an outer iterator execution) | |
void | init_model_inactive_variables (Model &model) |
initialize model with inactive variable values/bounds data that could change once per set of evaluations (e.g., an outer iterator execution) | |
void | init_model_inactive_labels (Model &model) |
initialize model with inactive variable labels that could change once per set of evaluations (e.g., an outer iterator execution) | |
void | update_model_active_constraints (Model &model) |
update incoming (sub-)model with active bounds from userDefinedConstraints | |
void | update_model_distributions (Model &model) |
update model with random variable distribution data | |
void | update_variables_from_model (const Model &model) |
update current variables/bounds with data from model | |
void | update_distributions_from_model (const Model &model) |
update current random variable distributions with data from model | |
void | update_response_from_model (const Model &model) |
update response/constraints with data from model | |
void | check_key (int key1, int key2) const |
check for consistency in response map keys | |
bool | check_rebuild (const RealVector &ref_icv, const IntVector &ref_idiv, const StringMultiArray &ref_idsv, const RealVector &ref_idrv, const RealVector &ref_c_l_bnds, const RealVector &ref_c_u_bnds, const IntVector &ref_di_l_bnds, const IntVector &ref_di_u_bnds, const RealVector &ref_dr_l_bnds, const RealVector &ref_dr_u_bnds) |
evaluate whether a rebuild of the approximation should be forced based on changes in the inactive data More... | |
void | asv_combine (const ShortArray &actual_asv, const ShortArray &approx_asv, ShortArray &combined_asv) |
reconstitutes a combined_asv from actual_asv and approx_asv | |
void | response_combine (const Response &actual_response, const Response &approx_response, Response &combined_response) |
overlays actual_response and approx_response to update combined_response | |
void | aggregate_response (const Response &resp1, const Response &resp2, Response &agg_resp) |
aggregate 2 sets of response data to create a new response with 2x size | |
void | insert_response (const Response &response, size_t position, Response &agg_response) |
insert a single response into an aggregated response in the specified position | |
Protected Member Functions inherited from Model | |
Model (BaseConstructor, ProblemDescDB &problem_db) | |
constructor initializing the base class part of letter classes (BaseConstructor overloading avoids infinite recursion in the derived class constructors - Coplien, p. 139) More... | |
Model (LightWtBaseConstructor, const ShortShortPair &vars_view, const SharedVariablesData &svd, bool share_svd, const SharedResponseData &srd, bool share_srd, const ActiveSet &set, short output_level, ProblemDescDB &problem_db=dummy_db, ParallelLibrary ¶llel_lib=dummy_lib) | |
constructor initializing base class for derived model class instances constructed on the fly | |
Model (LightWtBaseConstructor, ProblemDescDB &problem_db=dummy_db, ParallelLibrary ¶llel_lib=dummy_lib) | |
constructor initializing base class for recast model instances More... | |
void | update_model_active_variables (Model &model) |
update incoming (sub-)model with active values from currentVariables | |
IntResponseMap & | response_map () |
return responseMap | |
void | initialize_distribution (Pecos::MultivariateDistribution &mv_dist, bool active_only=false) |
initialize distribution types from problemDescDB More... | |
void | initialize_active_types (Pecos::MultivariateDistribution &mv_dist) |
initialize distribution types from problemDescDB More... | |
void | initialize_distribution_parameters (Pecos::MultivariateDistribution &mv_dist, bool active_only=false) |
initialize distribution parameters from problemDescDB | |
void | set_ie_asynchronous_mode (int max_eval_concurrency) |
default logic for defining asynchEvalFlag and evaluationCapacity based on ie_pl settings | |
void | assign_max_strings (const Pecos::MultivariateDistribution &mv_dist, Variables &vars) |
assign all of the longest possible string values into vars | |
SSCIter | max_string (const StringSet &ss) |
return iterator for longest string value found in string set | |
SRMCIter | max_string (const StringRealMap &srm) |
return iterator for longest string value found in string map | |
SizetMultiArrayConstView | initialize_x0_bounds (const SizetArray &original_dvv, bool &active_derivs, bool &inactive_derivs, RealVector &x0, RealVector &fd_lb, RealVector &fd_ub) const |
Initialize data needed for computing finite differences (active/inactive, center point, and bounds) | |
Real | forward_grad_step (size_t num_deriv_vars, size_t xj_index, Real x0_j, Real lb_j, Real ub_j) |
Compute the forward step for a finite difference gradient; updates shortStep. | |
EvaluationsDBState | evaluations_db_state (const Interface &interface) |
Return the interface flag for the EvaluationsDB state. | |
EvaluationsDBState | evaluations_db_state (const Model &model) |
Return the model flag for the EvaluationsDB state. | |
void | asynch_eval_store (const Interface &interface, const int &id, const Response &response) |
Store the response portion of an interface evaluation. Called from rekey_response_map() | |
void | asynch_eval_store (const Model &model, const int &id, const Response &response) |
Exists to support storage of interface evaluations. No-op so that rekey_response_map<Model> can be generated. | |
template<typename MetaType > | |
void | rekey_response_map (MetaType &meta_object, IntIntMapArray &id_maps, IntResponseMapArray &resp_maps_rekey, bool deep_copy) |
rekey returned jobs matched in array of id_maps into array of resp_maps_rekey; unmatched jobs can be cached within the meta_object | |
template<typename MetaType > | |
void | rekey_response_map (MetaType &meta_object, IntIntMap &id_map, IntResponseMap &resp_map_rekey, bool deep_copy) |
rekey returned jobs matched in id_map into resp_map_rekey; unmatched jobs can be cached within the meta_object | |
template<typename MetaType > | |
void | rekey_synch (MetaType &meta_object, bool block, IntIntMapArray &id_maps, IntResponseMapArray &resp_maps_rekey, bool deep_copy=false) |
synchronize via meta_object and rekey returned jobs matched in array of id_maps into array of resp_maps_rekey; unmatched jobs are cached within the meta_object | |
template<typename MetaType > | |
void | rekey_synch (MetaType &meta_object, bool block, IntIntMap &id_map, IntResponseMap &resp_map_rekey, bool deep_copy=false) |
synchronize via meta_object and rekey returned jobs matched in id_map into resp_map_rekey; unmatched jobs are cached within the meta_object | |
Protected Attributes | |
const bool | exportSurrogate |
whether to export the surrogate to file | |
const bool | autoRefine |
whether to automatically refine the surrogate during the build phase | |
const size_t | maxIterations |
Maximum number of times to refine the surrogate. | |
const size_t | maxFuncEvals |
Maximum number of evaluations while refining a surrogate. | |
const Real | convergenceTolerance |
Convergence criterion, compared to CV score for specified metric. | |
const int | softConvergenceLimit |
Max number of iterations for which there is no average improvement. | |
const String | refineCVMetric |
Type of error metric to test for surrogate refinement convegence. | |
const int | refineCVFolds |
Number of cross validation folds for surrogate refinement. | |
Protected Attributes inherited from SurrogateModel | |
SizetSet | surrogateFnIndices |
for mixed response sets, this array specifies the response function subset that is approximated | |
short | responseMode |
an enumeration that controls the response calculation mode in {DataFit,Ensemble}SurrModel approximate response computations | |
Pecos::ActiveKey | activeKey |
array of indices that identify the currently active model key | |
short | corrType |
type of correction: additive, multiplicative, or combined | |
short | corrOrder |
order of correction: 0 (value), 1 (gradient), or 2 (Hessian) | |
IntVariablesMap | rawVarsMap |
map of raw continuous variables used by apply_correction(). Model::varsList cannot be used for this purpose since it does not contain lower level variables sets from finite differencing. | |
int | surrModelEvalCntr |
counter for calls to derived_evaluate()/derived_evaluate_nowait(); used to key response maps from SurrogateModels | |
IntResponseMap | surrResponseMap |
map of surrogate responses returned by derived_synchronize() and derived_synchronize_nowait() | |
size_t | approxBuilds |
number of calls to build_approximation() More... | |
size_t | miPLIndex |
the index of the active metaiterator-iterator parallelism level (corresponding to ParallelConfiguration::miPLIters) used at runtime | |
Protected Attributes inherited from Model | |
Variables | currentVariables |
the set of current variables used by the model for performing function evaluations | |
size_t | numDerivVars |
the number of active continuous variables used in computing most response derivatives (i.e., in places such as quasi-Hessians and response corrections where only the active continuous variables are supported) | |
Response | currentResponse |
the set of current responses that holds the results of model function evaluations | |
size_t | numFns |
the number of functions in currentResponse | |
Constraints | userDefinedConstraints |
Explicit constraints on variables are maintained in the Constraints class hierarchy. Currently, this includes linear constraints and bounds, but could be extended in the future to include other explicit constraints which (1) have their form specified by the user, and (2) are not catalogued in Response since their form and coefficients are published to an iterator at startup. | |
String | modelId |
model identifier string from the input file | |
String | modelType |
type of model: simulation, nested, or surrogate | |
String | surrogateType |
type of surrogate model: local_*, multipoint_*, global_*, or hierarchical | |
String | gradientType |
type of gradient data: analytic, numerical, mixed, or none | |
String | methodSource |
source of numerical gradient routine: dakota or vendor | |
String | intervalType |
type of numerical gradient interval: central or forward | |
String | hessianType |
type of Hessian data: analytic, numerical, quasi, mixed, or none | |
RealVector | fdGradStepSize |
relative finite difference step size for numerical gradients More... | |
String | fdGradStepType |
type of finite difference step to use for numerical gradient: relative - step length is relative to x absolute - step length is what is specified bounds - step length is relative to range of x | |
RealVector | fdHessByGradStepSize |
relative finite difference step size for numerical Hessians estimated using first-order differences of gradients More... | |
RealVector | fdHessByFnStepSize |
relative finite difference step size for numerical Hessians estimated using second-order differences of function values More... | |
String | fdHessStepType |
type of finite difference step to use for numerical Hessian: relative - step length is relative to x absolute - step length is what is specified bounds - step length is relative to range of x | |
bool | ignoreBounds |
option to ignore bounds when computing finite diffs | |
bool | centralHess |
option to use old 2nd-order finite diffs for Hessians | |
bool | warmStartFlag |
if in warm-start mode, don't reset accumulated data (e.g., quasiHessians) | |
bool | supportsEstimDerivs |
whether model should perform or forward derivative estimation | |
String | quasiHessType |
quasi-Hessian type: bfgs, damped_bfgs, sr1 | |
IntSet | gradIdAnalytic |
analytic id's for mixed gradients | |
IntSet | gradIdNumerical |
numerical id's for mixed gradients | |
IntSet | hessIdAnalytic |
analytic id's for mixed Hessians | |
IntSet | hessIdNumerical |
numerical id's for mixed Hessians | |
IntSet | hessIdQuasi |
quasi id's for mixed Hessians | |
EvaluationsDBState | modelEvaluationsDBState |
Whether to write model evals to the evaluations DB. | |
EvaluationsDBState | interfEvaluationsDBState |
Whether to write interface evals to the evaluations DB. | |
IntArray | messageLengths |
length of packed MPI buffers containing vars, vars/set, response, and PRPair | |
bool | mappingInitialized |
track use of initialize_mapping() and finalize_mapping() | |
ProblemDescDB & | probDescDB |
class member reference to the problem description database More... | |
ParallelLibrary & | parallelLib |
class member reference to the parallel library | |
ParConfigLIter | modelPCIter |
the ParallelConfiguration node used by this Model instance | |
short | componentParallelMode |
the component parallelism mode: NO_PARALLEL_MODE, SURROGATE_MODEL_MODE, | |
bool | asynchEvalFlag |
flags asynch evaluations (local or distributed) | |
int | evaluationCapacity |
capacity for concurrent evaluations supported by the Model | |
short | outputLevel |
output verbosity level: {SILENT,QUIET,NORMAL,VERBOSE,DEBUG}_OUTPUT | |
Pecos::MultivariateDistribution | mvDist |
the multivariate random variable distribution (in probability space corresponding to currentVariables) | |
BoolDeque | primaryRespFnSense |
array of flags (one per primary function) for switching the sense to maximize the primary function (default is minimize) | |
RealVector | primaryRespFnWts |
primary response function weightings (either weights for multiobjective optimization or weighted least squares) | |
bool | hierarchicalTagging |
whether to perform hierarchical evalID tagging of params/results | |
ScalingOptions | scalingOpts |
user-provided scaling data from the problem DB, possibly modified by Recasting | |
String | evalTagPrefix |
cached evalTag Prefix from parents to use at evaluate time | |
EvaluationStore & | evaluationsDB |
reference to the global evaluation database | |
Private Member Functions | |
void | import_points (unsigned short tabular_format, bool use_var_labels, bool active_only) |
optionally read surrogate data points from provided file More... | |
void | initialize_export () |
initialize file stream for exporting surrogate evaluations More... | |
void | finalize_export () |
finalize file stream for exporting surrogate evaluations More... | |
void | export_point (int eval_id, const Variables &vars, const Response &resp) |
initialize file stream for exporting surrogate evaluations More... | |
void | derived_synchronize_approx (bool block, IntResponseMap &approx_resp_map_rekey) |
Common code for processing of approximate response maps shared by derived_synchronize() and derived_synchronize_nowait() | |
void | update_local_reference () |
Updates fit arrays for local or multipoint approximations. | |
void | build_local_multipoint () |
Builds a local or multipoint approximation using actualModel. More... | |
void | build_local_multipoint (const Variables &vars, const IntResponsePair &response_pr) |
Builds a local or multipoint approximation using actualModel. | |
void | update_global_reference () |
Updates fit arrays for global approximations. | |
void | build_global () |
Builds a global approximation using daceIterator. More... | |
void | rebuild_global () |
Rebuilds a global approximation by generating new data using daceIterator and appending to approxInterface. More... | |
void | refine_surrogate () |
Refine the built surrogate until convergence criteria are met. | |
void | clear_approx_interface () |
clear current data from approxInterface | |
void | update_approx_interface (const Variables &vars, const IntResponsePair &response_pr) |
update anchor data in approxInterface | |
void | build_approx_interface () |
build the approxInterface surrogate, passing variable bounds | |
bool | consistent (const Variables &vars) const |
test if inactive state is consistent | |
bool | inside (const Variables &vars) const |
test if active vars are within [l_bnds, u_bnds] | |
bool | active_vars_compare (const Variables &vars, const Pecos::SurrogateDataVars &sdv) const |
test for exact equality in values between active vars and sdv | |
Private Attributes | |
Interface | approxInterface |
manages the building and subsequent evaluation of the approximations (required for both global and local) | |
Model | actualModel |
the truth model which provides evaluations for building the surrogate (optional for global, required for local) More... | |
Iterator | daceIterator |
selects parameter sets on which to evaluate actualModel in order to generate the necessary data for building global approximations (optional for global since restart data may also be used) | |
DiscrepancyCorrection | deltaCorr |
manages construction and application of correction functions that are applied to a surrogate model (DataFitSurr or EnsembleSurr) in order to reproduce high fidelity data. | |
IntIntMap | truthIdMap |
map from actualModel/highFidelityModel evaluation ids to DataFitSurrModel/EnsembleSurrModel ids | |
IntIntMap | surrIdMap |
map from approxInterface/lowFidelityModel evaluation ids to DataFitSurrModel/EnsembleSurrModel ids | |
IntResponseMap | cachedApproxRespMap |
map of approximate responses retrieved in derived_synchronize_nowait() that could not be returned since corresponding truth model response portions were still pending. | |
int | pointsTotal |
total points the user specified to construct the surrogate | |
short | pointsManagement |
configuration for points management in build_global() | |
String | pointReuse |
type of point reuse for approximation builds: all , region (default if points file), or none (default if no points file) | |
String | importPointsFile |
file name from import_build_points_file specification | |
String | exportPointsFile |
file name from export_approx_points_file specification | |
unsigned short | exportFormat |
file export format for variables and approximate responses | |
std::ofstream | exportFileStream |
output file stream for export_approx_points_file specification | |
String | exportVarianceFile |
file name from export_approx_variance_file specification | |
unsigned short | exportVarianceFormat |
file export format for variables and approximate response variance | |
std::ofstream | exportVarianceFileStream |
output file stream for export_approx_variance_file specification | |
RealVector | referenceICVars |
stores a reference copy of the inactive continuous variables when the approximation is built using a Distinct view; used to detect when a rebuild is required. | |
IntVector | referenceIDIVars |
stores a reference copy of the inactive discrete int variables when the approximation is built using a Distinct view; used to detect when a rebuild is required. | |
StringMultiArray | referenceIDSVars |
stores a reference copy of the inactive discrete string variables when the approximation is built using a Distinct view; used to detect when a rebuild is required. | |
RealVector | referenceIDRVars |
stores a reference copy of the inactive discrete real variables when the approximation is built using a Distinct view; used to detect when a rebuild is required. | |
RealVector | referenceCLBnds |
stores a reference copy of active continuous lower bounds when the approximation is built; used to detect when a rebuild is required. | |
RealVector | referenceCUBnds |
stores a reference copy of active continuous upper bounds when the approximation is built; used to detect when a rebuild is required. | |
IntVector | referenceDILBnds |
stores a reference copy of active discrete int lower bounds when the approximation is built; used to detect when a rebuild is required. | |
IntVector | referenceDIUBnds |
stores a reference copy of active discrete int upper bounds when the approximation is built; used to detect when a rebuild is required. | |
RealVector | referenceDRLBnds |
stores a reference copy of active discrete real lower bounds when the approximation is built; used to detect when a rebuild is required. | |
RealVector | referenceDRUBnds |
stores a reference copy of active discrete real upper bounds when the approximation is built; used to detect when a rebuild is required. | |
Additional Inherited Members | |
Static Public Member Functions inherited from Model | |
static void | active_variables (const RealVector &config_vars, Model &model) |
set the specified configuration to the Model's inactive vars, converting from real to integer or through index to string value as needed More... | |
static void | inactive_variables (const RealVector &config_vars, Model &model) |
set the specified configuration to the Model's inactive vars, converting from real to integer or through index to string value as needed More... | |
static void | inactive_variables (const RealVector &config_vars, Model &model, Variables &updated_vars) |
static void | evaluate (const RealMatrix &samples_matrix, Model &model, RealMatrix &resp_matrix) |
Bulk synchronously evaluate the model for each column (of active variables) in the samples matrix and return as columns of the response matrix. | |
static void | evaluate (const VariablesArray &sample_vars, Model &model, RealMatrix &resp_matrix) |
Bulk synchronously evaluate the model for each entry (of active variables) in the samples vector and return as columns of the response matrix. | |
Static Protected Member Functions inherited from Model | |
static String | user_auto_id () |
return the next available model ID for no-ID user methods More... | |
static String | no_spec_id () |
return the next available model ID for on-the-fly methods More... | |
Derived model class within the surrogate model branch for managing data fit surrogates (global and local)
The DataFitSurrModel class manages global or local approximations (surrogates that involve data fits) that are used in place of an expensive model. The class contains an approxInterface (required for both global and local) which manages the approximate function evaluations, an actualModel (optional for global, required for local) which provides truth evaluations for building the surrogate, and a daceIterator (optional for global, not used for local) which selects parameter sets on which to evaluate actualModel in order to generate the necessary data for building global approximations.
|
protectedvirtual |
Inactive variables must be propagated when a EnsembleSurrModel is employed by a sub-iterator (e.g., OUU with MLMC or MLPCE). In current use cases, this can occur once per sub-iterator execution within Model::initialize_mapping().
Reimplemented from Model.
References DataFitSurrModel::actualModel, Model::finalize_mapping(), and Model::is_null().
|
protectedvirtual |
update current variables/labels/bounds/targets with data from model
Update values and labels in currentVariables and bound/linear/nonlinear constraints in userDefinedConstraints from variables and constraints data within sub_model.
Reimplemented from SurrogateModel.
References Model::is_null(), SurrogateModel::update_distributions_from_model(), SurrogateModel::update_response_from_model(), and SurrogateModel::update_variables_from_model().
Referenced by DataFitSurrModel::DataFitSurrModel(), and DataFitSurrModel::update_from_subordinate_model().
|
protectedvirtual |
Compute the response synchronously using actualModel, approxInterface, or both (mixed case). For the approxInterface portion, build the approximation if needed, evaluate the approximate response, and apply correction (if active) to the results.
Reimplemented from Model.
References Response::active_set(), DataFitSurrModel::actualModel, SurrogateModel::aggregate_response(), Interface::analysis_components(), DiscrepancyCorrection::apply(), SurrogateModel::approxBuilds, DataFitSurrModel::approxInterface, DataFitSurrModel::asv_split(), DataFitSurrModel::build_approximation(), DataFitSurrModel::component_parallel_mode(), DiscrepancyCorrection::compute(), Response::copy(), Model::current_response(), Model::currentResponse, Model::currentVariables, DataFitSurrModel::deltaCorr, Model::eval_tag_prefix(), Model::evalTagPrefix, Model::evaluate(), Interface::evaluation_id(), Model::evaluationsDB, DataFitSurrModel::export_point(), DataFitSurrModel::exportPointsFile, DataFitSurrModel::exportVarianceFile, DataFitSurrModel::force_rebuild(), Model::hierarchicalTagging, Interface::interface_id(), Model::interfEvaluationsDBState, Interface::map(), Model::modelId, Model::outputLevel, ActiveSet::request_vector(), SurrogateModel::response_combine(), SurrogateModel::responseMode, SurrogateModel::surrModelEvalCntr, Response::update(), and DataFitSurrModel::update_model().
|
protectedvirtual |
Compute the response asynchronously using actualModel, approxInterface, or both (mixed case). For the approxInterface portion, build the approximation if needed and evaluate the approximate response in a quasi-asynchronous approach (ApproximationInterface::map() performs the map synchronously and bookkeeps the results for return in derived_synchronize() below).
Reimplemented from Model.
References DataFitSurrModel::actualModel, Interface::analysis_components(), SurrogateModel::approxBuilds, DataFitSurrModel::approxInterface, DataFitSurrModel::asv_split(), DataFitSurrModel::build_approximation(), Variables::copy(), Model::currentResponse, Model::currentVariables, Model::eval_tag_prefix(), Model::evalTagPrefix, Model::evaluate_nowait(), Interface::evaluation_id(), Model::evaluation_id(), Model::evaluationsDB, DataFitSurrModel::exportPointsFile, DataFitSurrModel::exportVarianceFile, DataFitSurrModel::force_rebuild(), Model::hierarchicalTagging, Interface::interface_id(), Model::interfEvaluationsDBState, Interface::map(), Model::modelId, SurrogateModel::rawVarsMap, ActiveSet::request_vector(), SurrogateModel::responseMode, DataFitSurrModel::surrIdMap, SurrogateModel::surrModelEvalCntr, DataFitSurrModel::truthIdMap, and DataFitSurrModel::update_model().
|
protectedvirtual |
Blocking retrieval of asynchronous evaluations from actualModel, approxInterface, or both (mixed case). For the approxInterface portion, apply correction (if active) to each response in the array. derived_synchronize() is designed for the general case where derived_evaluate_nowait() may be inconsistent in its use of actual evaluations, approximate evaluations, or both.
Reimplemented from Model.
References DataFitSurrModel::actualModel, SurrogateModel::aggregate_response(), SurrogateModel::check_key(), DataFitSurrModel::component_parallel_mode(), DiscrepancyCorrection::compute(), DataFitSurrModel::deltaCorr, DataFitSurrModel::derived_synchronize_approx(), Model::outputLevel, Model::rekey_synch(), SurrogateModel::response_combine(), SurrogateModel::responseMode, DataFitSurrModel::surrIdMap, SurrogateModel::surrResponseMap, and DataFitSurrModel::truthIdMap.
|
protectedvirtual |
Nonblocking retrieval of asynchronous evaluations from actualModel, approxInterface, or both (mixed case). For the approxInterface portion, apply correction (if active) to each response in the map. derived_synchronize_nowait() is designed for the general case where derived_evaluate_nowait() may be inconsistent in its use of actual evals, approx evals, or both.
Reimplemented from Model.
References Dakota::abort_handler(), DataFitSurrModel::actualModel, SurrogateModel::aggregate_response(), DataFitSurrModel::cachedApproxRespMap, DataFitSurrModel::component_parallel_mode(), DiscrepancyCorrection::compute(), DataFitSurrModel::deltaCorr, DataFitSurrModel::derived_synchronize_approx(), Model::outputLevel, Model::rekey_synch(), SurrogateModel::response_combine(), SurrogateModel::responseMode, DataFitSurrModel::surrIdMap, SurrogateModel::surrResponseMap, and DataFitSurrModel::truthIdMap.
|
protectedvirtual |
Builds the local/multipoint/global approximation using daceIterator/actualModel to generate new data points.
This function constructs a new approximation, discarding any previous data. It constructs any required data for SurrogateData::{vars,resp}Data and does not define an anchor point for SurrogateData::anchor{Vars,Resp}, so is an unconstrained build.
Reimplemented from Model.
References DataFitSurrModel::actualModel, DataFitSurrModel::build_global(), DataFitSurrModel::build_local_multipoint(), DataFitSurrModel::clear_approx_interface(), Dakota::strbegins(), Model::surrogateType, DataFitSurrModel::update_global_reference(), DataFitSurrModel::update_local_reference(), and DataFitSurrModel::update_model().
Referenced by DataFitSurrModel::derived_evaluate(), and DataFitSurrModel::derived_evaluate_nowait().
|
protectedvirtual |
Builds the local/multipoint/global approximation using daceIterator/actualModel to generate new data points that augment the passed vars/response anchor point.
This function constructs a new approximation, discarding any previous data. It uses the passed data to populate SurrogateData::anchor{Vars,Resp} and constructs any required data points for SurrogateData::{vars,resp}Data.
Reimplemented from Model.
References DataFitSurrModel::actualModel, DataFitSurrModel::build_global(), DataFitSurrModel::build_local_multipoint(), Dakota::strbegins(), Model::surrogateType, DataFitSurrModel::update_approx_interface(), DataFitSurrModel::update_global_reference(), DataFitSurrModel::update_local_reference(), and DataFitSurrModel::update_model().
|
protectedvirtual |
Rebuilds the local/multipoint/global approximation using daceIterator/actualModel to generate an increment of appended data.
This function updates an existing approximation, by appending new data. It does not define an anchor point, so is an unconstrained build.
Reimplemented from Model.
References DataFitSurrModel::actualModel, DataFitSurrModel::build_local_multipoint(), Model::outputLevel, DataFitSurrModel::rebuild_global(), Dakota::strbegins(), Model::surrogateType, and DataFitSurrModel::update_model().
Referenced by DataFitSurrModel::append_approximation(), DataFitSurrModel::replace_approximation(), and DataFitSurrModel::update_approximation().
|
protectedvirtual |
replaces the approximation data with daceIterator results and rebuilds the approximation if requested
This function populates/replaces SurrogateData::anchor{Vars,Resp} and rebuilds the approximation, if requested. It does not clear other data (i.e., SurrogateData::{vars,resp}Data) and does not update the actualModel with revised bounds, labels, etc. Thus, it updates data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References Iterator::all_responses(), Iterator::all_samples(), Iterator::all_variables(), DataFitSurrModel::approxInterface, Iterator::compact_mode(), DataFitSurrModel::daceIterator, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), Model::surrogateType, and Interface::update_approximation().
|
protectedvirtual |
replaces the anchor point, and rebuilds the approximation if requested
This function populates/replaces SurrogateData::anchor{Vars,Resp} and rebuilds the approximation, if requested. It does not clear other data (i.e., SurrogateData::{vars,resp}Data) and does not update the actualModel with revised bounds, labels, etc. Thus, it updates data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), Model::surrogateType, and Interface::update_approximation().
|
protectedvirtual |
replaces the current points array and rebuilds the approximation if requested
This function populates/replaces SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested. It does not clear other data (i.e., SurrogateData::anchor{Vars,Resp}) and does not update the actualModel with revised bounds, labels, etc. Thus, it updates data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), Model::surrogateType, and Interface::update_approximation().
|
protectedvirtual |
replaces the current points array and rebuilds the approximation if requested
This function populates/replaces SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested. It does not clear other data (i.e., SurrogateData::anchor{Vars,Resp}) and does not update the actualModel with revised bounds, labels, etc. Thus, it updates data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), Model::surrogateType, and Interface::update_approximation().
|
protectedvirtual |
appends daceIterator results to a global approximation and rebuilds it if requested
This function appends all{Samples,Variables,Responses} to SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested.
Reimplemented from Model.
References Iterator::all_responses(), Iterator::all_samples(), Iterator::all_variables(), Interface::append_approximation(), DataFitSurrModel::approxInterface, Iterator::compact_mode(), DataFitSurrModel::daceIterator, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), and Model::surrogateType.
Referenced by DataFitSurrModel::build_global(), DataFitSurrModel::rebuild_global(), and DataFitSurrModel::refine_surrogate().
|
protectedvirtual |
appends a point to a global approximation and rebuilds it if requested
This function appends one point to SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested. It does not modify other data (i.e., SurrogateData::anchor{Vars,Resp}) and does not update the actualModel with revised bounds, labels, etc. Thus, it appends to data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References Interface::append_approximation(), DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), and Model::surrogateType.
|
protectedvirtual |
appends a matrix of points to a global approximation and rebuilds it if requested
This function appends multiple points to SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested. It does not modify other data (i.e., SurrogateData::anchor{Vars,Resp}) and does not update the actualModel with revised bounds, labels, etc. Thus, it appends to data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References Interface::append_approximation(), DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), and Model::surrogateType.
|
protectedvirtual |
appends an array of points to a global approximation and rebuilds it if requested
This function appends multiple points to SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested. It does not modify other data (i.e., SurrogateData::anchor{Vars,Resp}) and does not update the actualModel with revised bounds, labels, etc. Thus, it appends to data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References Interface::append_approximation(), DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), and Model::surrogateType.
|
protectedvirtual |
appends an map of points to a global approximation and rebuilds it if requested
This function appends multiple points to SurrogateData::{vars,resp}Data and rebuilds the approximation, if requested. It does not modify other data (i.e., SurrogateData::anchor{Vars,Resp}) and does not update the actualModel with revised bounds, labels, etc. Thus, it appends to data from a previous call to build_approximation(), and is not intended to be used in isolation.
Reimplemented from Model.
References Interface::append_approximation(), DataFitSurrModel::approxInterface, Model::outputLevel, DataFitSurrModel::rebuild_approximation(), and Model::surrogateType.
|
protectedvirtual |
set up actualModel for parallel operations
asynchronous flags need to be initialized for the sub-models. In addition, max_eval_concurrency is the outer level iterator concurrency, not the DACE concurrency that actualModel will see, and recomputing the message_lengths on the sub-model is probably not a bad idea either. Therefore, recompute everything on actualModel using init_communicators.
Reimplemented from Model.
References DataFitSurrModel::actualModel, DataFitSurrModel::approxInterface, DataFitSurrModel::daceIterator, Model::derivative_concurrency(), ProblemDescDB::get_db_method_node(), ProblemDescDB::get_db_model_node(), Iterator::init_communicators(), Model::init_communicators(), Iterator::is_null(), Model::is_null(), Iterator::iterated_model(), Iterator::maximum_evaluation_concurrency(), Iterator::method_id(), Interface::minimum_points(), Model::model_id(), Model::probDescDB, ProblemDescDB::set_db_list_nodes(), ProblemDescDB::set_db_method_node(), and ProblemDescDB::set_db_model_nodes().
|
private |
optionally read surrogate data points from provided file
Constructor helper to read the points file once, if provided, and then reuse its data as appropriate within build_global(). Surrogate data imports default to active/inactive variables, but user can override to active only
process arrays of data from TabularIO::read_data_tabular() above
References DataFitSurrModel::actualModel, Response::copy(), Variables::copy(), Model::current_response(), Model::current_variables(), Model::currentResponse, Model::currentVariables, Dakota::data_pairs, ParamResponsePair::eval_id(), Model::evaluation_cache(), DataFitSurrModel::importPointsFile, Model::interface_id(), ParamResponsePair::interface_id(), Model::is_null(), Model::model_id(), Model::numFns, Model::outputLevel, Model::parallelLib, Model::restart_file(), Variables::total_active(), Variables::tv(), and ParallelLibrary::write_restart().
Referenced by DataFitSurrModel::DataFitSurrModel().
|
private |
initialize file stream for exporting surrogate evaluations
Constructor helper to export approximation-based evaluations to a file.
References Model::currentResponse, Model::currentVariables, DataFitSurrModel::exportFileStream, DataFitSurrModel::exportFormat, DataFitSurrModel::exportPointsFile, DataFitSurrModel::exportVarianceFile, DataFitSurrModel::exportVarianceFileStream, DataFitSurrModel::exportVarianceFormat, and Response::function_labels().
Referenced by DataFitSurrModel::DataFitSurrModel().
|
private |
finalize file stream for exporting surrogate evaluations
Constructor helper to export approximation-based evaluations to a file.
References DataFitSurrModel::exportFileStream, DataFitSurrModel::exportPointsFile, DataFitSurrModel::exportVarianceFile, and DataFitSurrModel::exportVarianceFileStream.
Referenced by DataFitSurrModel::~DataFitSurrModel().
initialize file stream for exporting surrogate evaluations
Constructor helper to export approximation-based evaluations to a file. Exports all variables, so it's clear at what values of inactive it was built at
References DataFitSurrModel::approximation_variances(), Response::copy(), DataFitSurrModel::exportFileStream, DataFitSurrModel::exportFormat, DataFitSurrModel::exportPointsFile, DataFitSurrModel::exportVarianceFile, DataFitSurrModel::exportVarianceFileStream, DataFitSurrModel::exportVarianceFormat, Response::function_values(), DataFitSurrModel::interface_id(), Model::iterator_space_to_user_space(), and Model::recastings().
Referenced by DataFitSurrModel::derived_evaluate(), and DataFitSurrModel::derived_synchronize_approx().
|
private |
Builds a local or multipoint approximation using actualModel.
Evaluate the value, gradient, and possibly Hessian needed for a local or multipoint approximation using actualModel.
References Response::active_set(), DataFitSurrModel::actualModel, DataFitSurrModel::asv_inflate_build(), DataFitSurrModel::component_parallel_mode(), Model::continuous_variable_ids(), Model::current_response(), Model::current_variables(), ActiveSet::derivative_vector(), Model::evaluate(), Model::evaluation_id(), Model::hessian_type(), Model::numFns, ActiveSet::request_vector(), Dakota::strbegins(), SurrogateModel::surrogateFnIndices, and Model::surrogateType.
Referenced by DataFitSurrModel::build_approximation(), and DataFitSurrModel::rebuild_approximation().
|
private |
Builds a global approximation using daceIterator.
Determine points to use in building the approximation and then evaluate them on actualModel using daceIterator. Any changes to the bounds should be performed by setting them at a higher level (e.g., SurrBasedOptStrategy).
References Dakota::abort_handler(), DataFitSurrModel::active_vars_compare(), DataFitSurrModel::actualModel, DataFitSurrModel::append_approximation(), Interface::append_approximation(), SurrogateModel::approxBuilds, Interface::approximation_data(), DataFitSurrModel::approxInterface, DataFitSurrModel::autoRefine, DataFitSurrModel::build_approx_interface(), DataFitSurrModel::component_parallel_mode(), DataFitSurrModel::consistent(), Model::currentVariables, Model::cv(), Variables::cv(), DataFitSurrModel::daceIterator, Dakota::data_pairs, Model::div(), Variables::div(), Model::drv(), Variables::drv(), DataFitSurrModel::inside(), Model::interface_id(), Iterator::is_null(), Model::is_null(), Interface::minimum_points(), Iterator::num_samples(), Model::outputLevel, DataFitSurrModel::pointReuse, Model::recastings(), DataFitSurrModel::refine_surrogate(), DataFitSurrModel::required_points(), DataFitSurrModel::run_dace(), Iterator::sampling_reset(), SurrogateModel::surrogateFnIndices, and Model::user_space_to_iterator_space().
Referenced by DataFitSurrModel::build_approximation().
|
private |
Rebuilds a global approximation by generating new data using daceIterator and appending to approxInterface.
Determine points to use in rebuilding the approximation and then evaluate them on actualModel using daceIterator. Assumes data imports/reuse have been handled previously within build_global().
References Dakota::abort_handler(), DataFitSurrModel::append_approximation(), SurrogateModel::approxBuilds, Interface::approximation_data(), DataFitSurrModel::approxInterface, DataFitSurrModel::build_approx_interface(), DataFitSurrModel::component_parallel_mode(), DataFitSurrModel::daceIterator, Interface::formulation_updated(), Iterator::is_null(), Interface::minimum_points(), Model::outputLevel, DataFitSurrModel::required_points(), DataFitSurrModel::run_dace(), Iterator::sampling_reference(), Iterator::sampling_reset(), SurrogateModel::surrogateFnIndices, and Dakota::SZ_MAX.
Referenced by DataFitSurrModel::rebuild_approximation().
|
private |
the truth model which provides evaluations for building the surrogate (optional for global, required for local)
actualModel is unrestricted in type; arbitrary nestings are possible.
Referenced by DataFitSurrModel::active_model_key(), DataFitSurrModel::active_view(), DataFitSurrModel::asv_inflate_build(), DataFitSurrModel::asv_split(), DataFitSurrModel::build_approx_interface(), DataFitSurrModel::build_approximation(), DataFitSurrModel::build_global(), DataFitSurrModel::build_local_multipoint(), DataFitSurrModel::consistent(), DataFitSurrModel::DataFitSurrModel(), DataFitSurrModel::declare_sources(), DataFitSurrModel::derived_evaluate(), DataFitSurrModel::derived_evaluate_nowait(), DataFitSurrModel::derived_free_communicators(), DataFitSurrModel::derived_init_communicators(), DataFitSurrModel::derived_init_serial(), DataFitSurrModel::derived_set_communicators(), DataFitSurrModel::derived_subordinate_models(), DataFitSurrModel::derived_synchronize(), DataFitSurrModel::derived_synchronize_nowait(), DataFitSurrModel::estimate_partition_bounds(), DataFitSurrModel::evaluation_cache(), DataFitSurrModel::finalize_mapping(), DataFitSurrModel::fine_grained_evaluation_counters(), DataFitSurrModel::import_points(), DataFitSurrModel::inactive_view(), DataFitSurrModel::initialize_mapping(), DataFitSurrModel::inside(), DataFitSurrModel::nested_acv1_indices(), DataFitSurrModel::nested_acv2_targets(), DataFitSurrModel::nested_variable_mappings(), DataFitSurrModel::primary_response_fn_weights(), DataFitSurrModel::print_evaluation_summary(), DataFitSurrModel::qoi(), DataFitSurrModel::query_distribution_parameter_derivatives(), DataFitSurrModel::rebuild_approximation(), DataFitSurrModel::resize_from_subordinate_model(), DataFitSurrModel::restart_file(), DataFitSurrModel::run_dace(), DataFitSurrModel::serve_run(), DataFitSurrModel::stop_servers(), DataFitSurrModel::surrogate_response_mode(), DataFitSurrModel::truth_model(), DataFitSurrModel::update_from_subordinate_model(), DataFitSurrModel::update_global_reference(), DataFitSurrModel::update_local_reference(), and DataFitSurrModel::warm_start_flag().