.. _model-surrogate-global-gaussian_process-surfpack:

""""""""
surfpack
""""""""


Use the Surfpack version of Gaussian Process surrogates


.. toctree::
   :hidden:
   :maxdepth: 1

   model-surrogate-global-gaussian_process-surfpack-trend
   model-surrogate-global-gaussian_process-surfpack-optimization_method
   model-surrogate-global-gaussian_process-surfpack-max_trials
   model-surrogate-global-gaussian_process-surfpack-nugget
   model-surrogate-global-gaussian_process-surfpack-find_nugget
   model-surrogate-global-gaussian_process-surfpack-correlation_lengths
   model-surrogate-global-gaussian_process-surfpack-export_model
   model-surrogate-global-gaussian_process-surfpack-import_model


**Specification**

- *Alias:* None

- *Arguments:* None


**Child Keywords:**

+-------------------------+--------------------+-------------------------+-----------------------------------------------+
| Required/Optional       | Description of     | Dakota Keyword          | Dakota Keyword Description                    |
|                         | Group              |                         |                                               |
+=========================+====================+=========================+===============================================+
| Optional                                     | `trend`__               | Choose a trend function for a Gaussian        |
|                                              |                         | process surrogate                             |
+----------------------------------------------+-------------------------+-----------------------------------------------+
| Optional                                     | `optimization_method`__ | Change the optimization method used to        |
|                                              |                         | compute hyperparameters                       |
+----------------------------------------------+-------------------------+-----------------------------------------------+
| Optional                                     | `max_trials`__          | Max number of likelihood function evaluations |
+-------------------------+--------------------+-------------------------+-----------------------------------------------+
| Optional (Choose One)   | Nugget             | `nugget`__              | Specify a nugget to handle ill-conditioning   |
|                         |                    +-------------------------+-----------------------------------------------+
|                         |                    | `find_nugget`__         | Have Surfpack compute a nugget to handle      |
|                         |                    |                         | ill-conditioning                              |
+-------------------------+--------------------+-------------------------+-----------------------------------------------+
| Optional                                     | `correlation_lengths`__ | Specify the correlation lengths for the       |
|                                              |                         | Gaussian process                              |
+----------------------------------------------+-------------------------+-----------------------------------------------+
| Optional                                     | `export_model`__        | Exports surrogate model in user-specified     |
|                                              |                         | format(s)                                     |
+----------------------------------------------+-------------------------+-----------------------------------------------+
| Optional                                     | `import_model`__        | Import surrogate model from archive file      |
+----------------------------------------------+-------------------------+-----------------------------------------------+

.. __: model-surrogate-global-gaussian_process-surfpack-trend.html
__ model-surrogate-global-gaussian_process-surfpack-optimization_method.html
__ model-surrogate-global-gaussian_process-surfpack-max_trials.html
__ model-surrogate-global-gaussian_process-surfpack-nugget.html
__ model-surrogate-global-gaussian_process-surfpack-find_nugget.html
__ model-surrogate-global-gaussian_process-surfpack-correlation_lengths.html
__ model-surrogate-global-gaussian_process-surfpack-export_model.html
__ model-surrogate-global-gaussian_process-surfpack-import_model.html



**Description**


This keyword specifies the use of the Gaussian process that is
incorporated in our surface fitting library called Surfpack.

Several user options are available:


1. Optimization methods: Maximum Likelihood Estimation (MLE) is used to find the optimal values of the hyper-parameters governing the trend and correlation functions. By default the global optimization method DIRECT is used for MLE, but other options for the optimization method are available. See :dakkw:`model-surrogate-global-gaussian_process-surfpack-optimization_method`. The total number of evaluations of the likelihood function can be controlled using the ``max_trials`` keyword followed by a positive integer. Note that the likelihood function does not require running the "truth" model, and is relatively inexpensive to compute.



2. Trend Function: The GP models incorporate a parametric trend function whose purpose is to capture large-scale variations. See :dakkw:`model-surrogate-global-gaussian_process-surfpack-trend`.



3. Correlation Lengths: Correlation lengths are usually optimized by Surfpack, however, the user can specify the lengths manually. See :dakkw:`model-surrogate-global-gaussian_process-surfpack-correlation_lengths`.



4. Ill-conditioning One of the major problems in determining the governing values for a Gaussian process or Kriging model is the fact that the correlation matrix can easily become ill-conditioned when there are too many input points close together. Since the predictions from the Gaussian process model involve inverting the correlation matrix, ill-conditioning can lead to poor predictive capability and should be avoided. Note that a sufficiently bad sample design could require correlation lengths to be so short that any interpolatory GP model would become inept at extrapolation and interpolation. The ``surfpack`` model handles ill-conditioning internally by default, but behavior can be modified using



5. Gradient Enhanced Kriging (GEK). The ``use_derivatives`` keyword will cause the Surfpack GP to be constructed from a combination of function value and gradient information (if available). See notes in the Theory section.



**Theory**


*Gradient Enhanced Kriging*


Incorporating gradient information will only be
beneficial if accurate and inexpensive derivative information is
available, and the derivatives are not infinite or nearly so. Here
"inexpensive" means that the cost of evaluating a function value
plus gradient is comparable to the cost of evaluating only the
function value, for example gradients computed by analytical,
automatic differentiation, or continuous adjoint techniques. It is
not cost effective to use derivatives computed by finite differences.
In tests, GEK models built from finite difference derivatives were
also significantly less accurate than those built from analytical
derivatives. Note that GEK's correlation matrix tends to have a
significantly worse condition number than Kriging for the same
sample design.

This issue was addressed by using a pivoted Cholesky
factorization of Kriging's correlation matrix (which is a small
sub-matrix within GEK's correlation matrix) to rank points by how
much unique information they contain. This reordering is then
applied to whole points (the function value at a point immediately
followed by gradient information at the same point) in GEK's
correlation matrix. A standard non-pivoted Cholesky is then
applied to the reordered GEK correlation matrix and a bisection
search is used to find the last equation that meets the constraint on
the (estimate of) condition number. The cost of performing pivoted
Cholesky on Kriging's correlation matrix is usually negligible
compared to the cost of the non-pivoted Cholesky factorization of
GEK's correlation matrix. In tests, it also resulted in more
accurate GEK models than when pivoted Cholesky or
whole-point-block pivoted Cholesky was performed on GEK's
correlation matrix.


