API Reference¶
This is the class and function reference of destructive-deep-learning (ddl).
ddl.autoregressive¶
Module for very simple autoregressive destructors.
Autoregressive classes¶
autoregressive.AutoregressiveDestructor([…]) |
Autoregressive destructor using densities that can compute conditionals. |
ddl.base¶
Base destructors and destructor mixins.
Base classes¶
base.BaseDensityDestructor |
Abstract destructor derived from an explicit underlying density. |
base.BoundaryWarning |
Warning that data is on the boundary of the required set. |
base.CompositeDestructor([destructors, …]) |
Meta destructor composed of multiple destructors. |
base.DestructorMixin |
Mixin helper class to add universal destructor methods. |
base.IdentityDestructor |
Identity destructor/transform. |
base.ScoreMixin |
Mixin for score that returns mean of score_samples. |
base.UniformDensity() |
Uniform density estimator. |
Base functions¶
base.create_implicit_density(fitted_destructor) |
Create the implicit density associated with a fitted destructor. |
base.create_inverse_canonical_destructor(…) |
Create inverse destructor of a fitted canonical destructor. |
base.create_inverse_transformer(…[, copy]) |
Create inverse transformer from fitted transformer. |
base.get_implicit_density(\*args, \*\*kwargs) |
|
base.get_inverse_canonical_destructor(…) |
|
base.get_n_features(destructor[, …]) |
Get the number of features for a fitted destructor. |
ddl.datasets¶
Simple module to generate toy datasets.
Datasets functions¶
datasets.make_toy_data(data_name[, …]) |
Make simple toy datasets. |
ddl.deep¶
Deep destructors module.
Deep classes¶
deep.DeepDestructor([canonical_destructor, …]) |
Destructor formed by composing copies of some atomic destructor. |
deep.DeepDestructorCV([…]) |
Deep destructor whose number of destructors/layers is determined by CV. |
ddl.externals¶
Externals package init file.
ddl.externals.mlpack¶
Init for ddl.externals.mlpack package.
Mlpack classes¶
mlpack.MlpackDensityTreeEstimator([…]) |
Density tree estimator via mlpack (mlpack.org). |
ddl.gaussian¶
Module for Gaussian density.
Gaussian classes¶
gaussian.GaussianDensity([covariance_type, …]) |
Gaussian density estimator with conditional and marginal methods. |
ddl.independent¶
Module for independent densities and destructors.
Independent classes¶
independent.IndependentDensity([…]) |
Independent density estimator. |
independent.IndependentDestructor([…]) |
Coordinate-wise destructor based on underlying independent density. |
independent.IndependentInverseCdf |
Independent inverse CDF transformer applied coordinate-wise. |
ddl.linear¶
Module to handle linear projectors and destructors.
Linear classes¶
linear.BestLinearReconstructionDestructor([…]) |
Best linear reconstruction after a linear destructor. |
linear.IdentityLinearEstimator() |
Identity linear projection. |
linear.LinearProjector([linear_estimator, …]) |
A linear projector based on an underlying linear estimator. |
linear.RandomOrthogonalEstimator([…]) |
Random linear orthogonal estimator. |
ddl.local¶
Module for local destructors such as adjacent-pixel-pair destructors.
Local classes¶
local.FeatureGroupsDestructor([…]) |
Destructor that transforms groups of features independently. |
local.ImageFeaturePairs([image_shape, …]) |
Generate pairs of pixels based on image layout. |
local.RandomFeaturePairs([random_state]) |
Random feature pairs estimator for use with FeatureGroupsDestructor. |
ddl.mixture¶
Module for mixture densities and destructors.
Mixture classes¶
mixture.FirstFixedGaussianMixtureDensity([…]) |
Mixture density where one component is fixed as the standard normal. |
mixture.GaussianMixtureDensity([…]) |
Gaussian mixture density that can be used with AutoregressiveDestructor. |
ddl.tree¶
Module for tree densities and destructors.
Tree classes¶
tree.RandomTreeEstimator([min_samples_leaf, …]) |
Random tree estimator via ExtraTreeRegressor. |
tree.TreeDensity([tree_estimator, get_tree, …]) |
Tree density estimator defined on the unit hypercube. |
tree.TreeDestructor([tree_density]) |
Canonical tree destructor based on an underlying tree density. |
ddl.univariate¶
Module for univariate densities (see also ddl.independent).
Univariate classes¶
univariate.HistogramUnivariateDensity([…]) |
Histogram univariate density estimator. |
univariate.ScipyUnivariateDensity([…]) |
Density estimator via random variables defined in scipy.stats. |
ddl.utils¶
Module for utility functions and classes.
Utils functions¶
utils.check_X_in_interval(X, interval) |
Check if the input X lies in the specified interval. |
utils.check_X_in_interval_decorator(func) |
Decorate functions such as transform to check domain. |
utils.check_domain(domain, n_features) |
Check and return domain, broadcasting domain if necessary. |
utils.get_domain_or_default(destructor[, warn]) |
Get the domain of the density or return DEFAULT_DOMAIN. |
utils.get_support_or_default(density[, warn]) |
Get the support of the density or return DEFAULT_SUPPORT. |
utils.has_method(est, method_name[, warn]) |
Check if an estimator has a method and possibly warn if not. |
utils.make_finite(X) |
Make the data matrix finite by replacing -infty and infty. |
utils.make_interior(X, bounds[, eps]) |
Scale/shift data to fit in the open interval given by bounds. |
utils.make_interior_probability(X[, eps]) |
Convert data to probability values in the open interval between 0 and 1. |
utils.make_positive(X) |
Make the data matrix positive by clipping to +epsilon if not positive. |
ddl.validation¶
Module for validating destructor interface and testing properties.
Validation functions¶
validation.check_density(density[, random_state]) |
Check that an estimator implements density methods correctly. |
validation.check_destructor(destructor[, …]) |
Check for the required interface and properties of a destructor. |