get_pilot_covariance¶
-
pyapprox.control_variate_monte_carlo.
get_pilot_covariance
(nmodels, variable, model_ensemble, npilot_samples)[source]¶ - Parameters
- nmodelsinteger
The number of information sources
- variable
pyapprox.variable.IndependentMultivariateRandomVariable
Object defining the nvar uncertain random variables. Samples will be drawn from its joint density.
- model_ensemblecallable
Function with signature
model_ensemble(samples) -> np.ndarray (nsamples,1)
where samples is a np.ndarray with shape (nvars+1,nsamples)
- npilot_samplesinteger
The number of samples used to compute correlations
- Returns
- cov_matrixnp.ndarray (nmodels,nmodels)
The covariance between each information source
- pilot_samplesnp.ndarray (nvars+1,nsamples)
The samples used to evaluate each information source when computing correlations
- pilot_valuesnp.ndarray (nsamples,nmodels)
The values of each information source at the pilot samples