|
SHOGUN
v1.1.0
|
Preprocessor PCACut performs principial component analysis on the input vectors and keeps only the n eigenvectors with eigenvalues above a certain threshold.
On preprocessing the stored covariance matrix is used to project vectors into eigenspace only returning vectors of reduced dimension n. Optional whitening is performed.
This is only useful if the dimensionality of the data is rather low, as the covariance matrix is of size num_feat*num_feat. Note that vectors don't have to have zero mean as it is substracted.

Protected Member Functions | |
| void | init () |
Protected Attributes | |
| SGMatrix< float64_t > | m_transformation_matrix |
| int32_t | num_dim |
| int32_t | num_old_dim |
| SGVector< float64_t > | m_mean_vector |
| SGVector< float64_t > | m_eigenvalues_vector |
| bool | m_initialized |
| bool | m_whitening |
| EPCAMode | m_mode |
| float64_t | thresh |
Protected Attributes inherited from CDimensionReductionPreprocessor | |
| int32_t | m_target_dim |
| CDistance * | m_distance |
| CKernel * | m_kernel |
| CEmbeddingConverter * | m_converter |
Additional Inherited Members | |
Public Attributes inherited from CSGObject | |
| SGIO * | io |
| Parallel * | parallel |
| Version * | version |
| Parameter * | m_parameters |
| Parameter * | m_model_selection_parameters |
| CPCA | ( | bool | do_whitening = false, |
| EPCAMode | mode = FIXED_NUMBER, |
||
| float64_t | thresh = 1e-6 |
||
| ) |
apply preprocessor to feature matrix
| features | features |
Reimplemented from CDimensionReductionPreprocessor.
apply preprocessor to feature vector
| vector | feature vector |
Reimplemented from CDimensionReductionPreprocessor.
|
virtual |
|
virtual |
Reimplemented from CDimensionReductionPreprocessor.
|
virtual |
Reimplemented from CDimensionReductionPreprocessor.
|
virtual |
initialize preprocessor from features
| features |
Reimplemented from CDimensionReductionPreprocessor.
|
protected |
default init
Reimplemented from CDimensionReductionPreprocessor.