#include <GaussianDistribution.h>
Inheritance diagram for PLearn::GaussianDistribution:


Public Types | |
| typedef PDistribution | inherited |
Public Member Functions | |
| GaussianDistribution () | |
| PLEARN_DECLARE_OBJECT (GaussianDistribution) | |
| void | makeDeepCopyFromShallowCopy (CopiesMap &copies) |
| virtual void | forget () |
| (Re-)initializes the PLearner in its fresh state (that state may depend on the 'seed' option) And sets 'stage' back to 0 (this is the stage of a fresh learner!) | |
| virtual void | train () |
| The role of the train method is to bring the learner up to stage==nstages, updating the train_stats collector with training costs measured on-line in the process. | |
| virtual real | log_density (const Vec &x) const |
| Return log of probability density log(p(y | x)). | |
| virtual void | resetGenerator (long g_seed) const |
| Resets the random number generator used by generate using the given seed. | |
| virtual void | generate (Vec &x) const |
| return a pseudo-random sample generated from the distribution. | |
| virtual int | inputsize () const |
| Overridden so that it does not necessarily need a training set. | |
Public Attributes | |
| Vec | mu |
| Vec | eigenvalues |
| Mat | eigenvectors |
| int | k |
| real | gamma |
| float | ignore_weights_below |
| When doing a weighted fitting (weightsize==1), points with a weight below this value will be ignored. | |
Static Protected Member Functions | |
| void | declareOptions (OptionList &ol) |
| Declares this class' options. | |
|
|
Reimplemented from PLearn::PDistribution. Definition at line 63 of file GaussianDistribution.h. |
|
|
Definition at line 68 of file GaussianDistribution.cc. References k. |
|
|
Declares this class' options.
Reimplemented from PLearn::PDistribution. Definition at line 74 of file GaussianDistribution.cc. References PLearn::declareOption(), and PLearn::OptionList. |
|
|
(Re-)initializes the PLearner in its fresh state (that state may depend on the 'seed' option) And sets 'stage' back to 0 (this is the stage of a fresh learner!)
Reimplemented from PLearn::PDistribution. Definition at line 94 of file GaussianDistribution.cc. |
|
|
return a pseudo-random sample generated from the distribution.
Reimplemented from PLearn::PDistribution. Definition at line 142 of file GaussianDistribution.cc. References eigenvalues, eigenvectors, PLearn::fill_random_normal(), gamma, PLearn::TVec< T >::length(), PLearn::TMat< T >::length(), mu, PLearn::TVec< T >::resize(), PLearn::sqrt(), PLearn::transposeProduct(), and x. |
|
|
Overridden so that it does not necessarily need a training set.
Reimplemented from PLearn::PLearner. Definition at line 162 of file GaussianDistribution.cc. References PLearn::TVec< T >::length(), and mu. Referenced by train(). |
|
|
Return log of probability density log(p(y | x)).
Reimplemented from PLearn::PDistribution. Definition at line 131 of file GaussianDistribution.cc. References eigenvalues, eigenvectors, gamma, PLearn::logOfCompactGaussian(), mu, and x. |
|
|
Does the necessary operations to transform a shallow copy (this) into a deep copy by deep-copying all the members that need to be. Typical implementation: void CLASS_OF_THIS::makeDeepCopyFromShallowCopy(CopiesMap& copies) { SUPERCLASS_OF_THIS::makeDeepCopyFromShallowCopy(copies); member_ptr = member_ptr->deepCopy(copies); member_smartptr = member_smartptr->deepCopy(copies); member_mat.makeDeepCopyFromShallowCopy(copies); member_vec.makeDeepCopyFromShallowCopy(copies); ... } Reimplemented from PLearn::PLearner. Definition at line 59 of file GaussianDistribution.cc. References PLearn::CopiesMap, PLearn::deepCopyField(), eigenvalues, eigenvectors, and mu. |
|
|
|
|
|
Resets the random number generator used by generate using the given seed.
Reimplemented from PLearn::PDistribution. Definition at line 137 of file GaussianDistribution.cc. References PLearn::manual_seed(). |
|
|
The role of the train method is to bring the learner up to stage==nstages, updating the train_stats collector with training costs measured on-line in the process.
Reimplemented from PLearn::PDistribution. Definition at line 97 of file GaussianDistribution.cc. References PLearn::computeMeanAndCovar(), PLearn::computeWeightedMeanAndCovar(), eigenvalues, PLearn::eigenVecOfSymmMat(), eigenvectors, PLearn::PLearner::getTrainingSet(), ignore_weights_below, inputsize(), k, PLearn::VMat::length(), PLearn::min(), mu, PLERROR, PLearn::VMat::width(), and PLearn::ws(). |
|
|
Definition at line 67 of file GaussianDistribution.h. Referenced by generate(), log_density(), makeDeepCopyFromShallowCopy(), and train(). |
|
|
Definition at line 68 of file GaussianDistribution.h. Referenced by generate(), log_density(), makeDeepCopyFromShallowCopy(), and train(). |
|
|
Definition at line 72 of file GaussianDistribution.h. Referenced by generate(), and log_density(). |
|
|
When doing a weighted fitting (weightsize==1), points with a weight below this value will be ignored.
Definition at line 73 of file GaussianDistribution.h. Referenced by train(). |
|
|
Definition at line 71 of file GaussianDistribution.h. Referenced by train(). |
|
|
Definition at line 66 of file GaussianDistribution.h. Referenced by generate(), inputsize(), log_density(), makeDeepCopyFromShallowCopy(), and train(). |
1.3.7