xoa.krig.ClusteredKriger#
- class xoa.krig.ClusteredKriger(da, krigtype, variogram_func, npmax=None, nproc=None, seed=None, **kwargs)[source]#
Kriger that supports clusterization to limit memory
Big input cloud of points (size >
npmax) are split into smaller clusters using cluster analysis of distance with functionclusterize().The problem is solved in this way:
Input points are split in clusters if necessary.
The input variogram matrix is factorized for each cluster, possibly using
multiprocessingifnproc>1.Values are computed at output positions each using the factorized matrix of cluster.
Final value is a weighted average of the values estimated using each cluster. Weights are inversely proportional to the squared error.
The final error is the same weighted average of the errors, which is conservative since the errors of the clusters are correlated.
- Parameters:
npmax (optional) – Maximal number of points to be used simultaneously for kriging. When the number of input points is greater than this value, clusterization is applied.
nproc (optional) – Number of processes to use to factorize matrices. Set it to a number <2 to switch off parallelisation.
seed (int, None) – Seed of the random initialisation of the clusters, to get reproducible results. The clusters, hence the result, change slightly from one call to another without it.
See also
Methods
get_A(cloud)Get the variogram matrix of a cloud of points
interp(dso[, block, name])Interpolate to the dso positions
Attributes
Distance units
Number of clusters
Max number of points per cluster
Sill of the variogram, used to convert it to a covariance for the simple kriging
Get the solver of the A matrix of each cluster
Variogram function or callable, like a
VariogramModelinstance