SG++-Doxygen-Documentation
|
Public Member Functions | |
def | cdf (self, p, args, kws) |
def | corrcoeff (self, covMatrix=None) |
def | cov (self) |
def | crossEntropy (self, samples) |
def | fromJson (cls, jsonObject) |
def | getBounds (self) |
def | getDim (self) |
def | klDivergence (self, dist, testSamplesUnit=None, testSamplesProb=None, n=1e4) |
def | l2error (self, dist, testSamplesUnit=None, testSamplesProb=None, n=1e4, dtype=SampleType.ACTIVEPROBABILISTIC) |
def | mean (self) |
def | pdf (self, p, args, kws) |
def | ppf (self, p, args, kws) |
def | rvs (self, n=1) |
def | std (self) |
def | var (self) |
The Dist class, which is the super class for all distributions of this package
def python.uq.dists.Dist.Dist.cdf | ( | self, | |
p, | |||
args, | |||
kws | |||
) |
Cumulative distribution function @param p: (tuple) of floats @return: cumulative distribution value
def python.uq.dists.Dist.Dist.corrcoeff | ( | self, | |
covMatrix = None |
|||
) |
References python.uq.dists.Dist.Dist.cov(), and python.uq.dists.Dist.Dist.klDivergence().
def python.uq.dists.Dist.Dist.cov | ( | self | ) |
Get covariance matrix
References sgpp::base::ForwardSelectorRefinement_refinement_key.getDim(), sgpp::base::ImpurityRefinement_refinement_key.getDim(), sgpp::base::PredictiveRefinement_refinement_key.getDim(), python.uq.analysis.asgc.ASGCAnalysisSpecification.ASGCAnalysisSpecification.getDim(), python.uq.dists.Beta.Beta.getDim(), python.uq.dists.Corr.Corr.getDim(), python.uq.dists.Dist.Dist.getDim(), python.uq.dists.DataDist.DataDist.getDim(), python.data.DataContainer.DataContainer.getDim(), python.uq.dists.Beta.Beta.var(), python.uq.dists.Dist.Dist.var(), sgpp::combigrid::BsplineStochasticCollocation.var, sgpp::combigrid::PolynomialStochasticCollocation.var, python.uq.dists.DataDist.DataDist.var(), and python.uq.analysis.Analysis.Analysis.var().
Referenced by python.uq.dists.Dist.Dist.corrcoeff().
def python.uq.dists.Dist.Dist.crossEntropy | ( | self, | |
samples | |||
) |
this measure computes the cross entropy with respect to some unknown probability distribution from which only samples are available. This measure is known to minimize the kl divergence. @param samples: numpy array
References python.uq.dists.Dist.Dist.l2error(), python.uq.dists.CorrBeta.CorrBeta.pdf(), python.uq.dists.Dist.Dist.pdf(), python.uq.dists.Corr.Corr.pdf(), python.uq.dists.Beta.Beta.pdf(), python.uq.dists.DataDist.DataDist.pdf(), sgpp::combigrid::ProbabilityDensityFunction1D.pdf(), and sgpp::combigrid::OrthogonalPolynomialBasis1D.pdf().
def python.uq.dists.Dist.Dist.fromJson | ( | cls, | |
jsonObject | |||
) |
def python.uq.dists.Dist.Dist.getBounds | ( | self | ) |
Get the distribution's intervals @return: numpy array [dim, 2]
Referenced by python.uq.dists.J.J.discretize(), and python.uq.dists.Dist.Dist.l2error().
def python.uq.dists.Dist.Dist.getDim | ( | self | ) |
Get number of marginal distributions @return: int number of marginal distributions
Referenced by python.uq.dists.SGDEdist.SGDEdist.__str__(), python.uq.dists.Dist.Dist.cov(), python.uq.parameters.ParameterSet.ParameterSet.extractActiveSubset(), python.uq.dists.KDEDist.KDEDist.getBandwidths(), python.uq.dists.EstimatedDist.EstimatedDist.getBounds(), and python.uq.uq_setting.UQSetting.UQSetting.getDim().
def python.uq.dists.Dist.Dist.klDivergence | ( | self, | |
dist, | |||
testSamplesUnit = None , |
|||
testSamplesProb = None , |
|||
n = 1e4 |
|||
) |
computes the KL-divergence from this distribution with respect to dist \approx \frac{1}{n} \sum_{i = 1}^{n} p(x_i) log_2 (p(x_i) / q(x_i)) and for samples obtained via importance sampling it holds \approx \frac{1}{n} \sum_{i = 1}^{n} log_2 (p(y_i) / q(y_i)) = \frac{1}{n} \sum_{i = 1}^{n} log_2 p(y_i) - log_2 q(y_i)) = [\frac{1}{n} \sum_{i = 1}^{n} log_2 p(y_i)] - [\frac{1}{n} \sum_{i = 1}^{n} log_2 q(y_i)] = mean(log_2 p(y_i)) - mean(log_2 q(y_i)) @param dist: Dist @param testSamplesUnit: numpy array @param testSamplesProb: numpy array
References python.uq.dists.CorrBeta.CorrBeta.pdf(), python.uq.dists.Dist.Dist.pdf(), python.uq.dists.Corr.Corr.pdf(), python.uq.dists.Beta.Beta.pdf(), python.uq.dists.DataDist.DataDist.pdf(), sgpp::combigrid::ProbabilityDensityFunction1D.pdf(), and sgpp::combigrid::OrthogonalPolynomialBasis1D.pdf().
Referenced by python.uq.dists.Dist.Dist.corrcoeff().
def python.uq.dists.Dist.Dist.l2error | ( | self, | |
dist, | |||
testSamplesUnit = None , |
|||
testSamplesProb = None , |
|||
n = 1e4 , |
|||
dtype = SampleType.ACTIVEPROBABILISTIC |
|||
) |
mean squared error, defined as || p - p_n ||^2 = \int (p(x) - p_n(x))^2 * p(x) dx ~ 1/n \sum_i (p(x_i) - p_n(x_i)^2 for x_i drawn from p. @param dist: Dist @param testSamplesUnit: numpy array @param testSamplesProb: numpy array @param n: int, if no test samples are given, just select them uniformly within he range of the distribution
References python.uq.dists.CorrBeta.CorrBeta.getBounds(), sgpp::combigrid::AbstractLinearEvaluator< V >.getBounds(), python.uq.dists.Corr.Corr.getBounds(), python.uq.dists.Beta.Beta.getBounds(), python.uq.dists.Dist.Dist.getBounds(), python.uq.dists.DataDist.DataDist.getBounds(), sgpp::combigrid::BSplineScalarProductEvaluator.getBounds(), python.uq.dists.CorrBeta.CorrBeta.pdf(), python.uq.dists.Dist.Dist.pdf(), python.uq.dists.Corr.Corr.pdf(), python.uq.dists.Beta.Beta.pdf(), python.uq.dists.DataDist.DataDist.pdf(), sgpp::combigrid::ProbabilityDensityFunction1D.pdf(), and sgpp::combigrid::OrthogonalPolynomialBasis1D.pdf().
Referenced by python.uq.dists.Dist.Dist.crossEntropy().
def python.uq.dists.Dist.Dist.mean | ( | self | ) |
@return: expectation value
Referenced by python.uq.analysis.mc.MCAnalysis.MCAnalysis.computeMoments(), python.uq.analysis.asgc.ASGCAnalysis.ASGCAnalysis.computeMoments(), python.uq.dists.LibAGFDist.LibAGFDist.var(), and python.uq.dists.SGDEdist.SGDEdist.var().
def python.uq.dists.Dist.Dist.pdf | ( | self, | |
p, | |||
args, | |||
kws | |||
) |
Probability distribution function @param p: (tuple) of floats @return: probability distribution value
Referenced by python.uq.dists.Dist.Dist.crossEntropy(), python.uq.dists.J.J.discretize(), python.uq.dists.Dist.Dist.klDivergence(), and python.uq.dists.Dist.Dist.l2error().
def python.uq.dists.Dist.Dist.ppf | ( | self, | |
p, | |||
args, | |||
kws | |||
) |
Point percentile function @param p: (tuple) of floats @return: point percentile value
Referenced by python.uq.dists.EstimatedDist.EstimatedDist.rvs(), python.uq.dists.KDEDist.KDEDist.rvs(), python.uq.dists.NatafDist.NatafDist.rvs(), and python.uq.dists.SGDEdist.SGDEdist.rvs().
def python.uq.dists.Dist.Dist.rvs | ( | self, | |
n = 1 |
|||
) |
Generates n random numbers w.r.t. the marginal distributions @param n: int number of random values @return: numpy array [n, dim]
def python.uq.dists.Dist.Dist.std | ( | self | ) |
@return: standard deviation
References python.uq.dists.Beta.Beta.var(), python.uq.dists.Dist.Dist.var(), sgpp::combigrid::BsplineStochasticCollocation.var, sgpp::combigrid::PolynomialStochasticCollocation.var, python.uq.dists.DataDist.DataDist.var(), and python.uq.analysis.Analysis.Analysis.var().
def python.uq.dists.Dist.Dist.var | ( | self | ) |