itpp::Fast_ICA Class Reference
Signal Processing (SP) Module » Fast Independent Component Analysis

Fast_ICA Fast Independent Component Analysis (Fast ICA) More...

`#include <itpp/signal/fastica.h>`

## Public Member Functions

| Fast_ICA (mat ma_mixed_sig)
| Constructor.
bool | separate (void)
| Explicit launch of main FastICA function.
void | set_approach (int in_approach)
| Set approach : FICA_APPROACH_DEFL or FICA_APPROACH_SYMM (default)
void | set_nrof_independent_components (int in_nrIC)
| Set number of independent components to separate.
void | set_non_linearity (int in_g)
| Set non-linearity.
void | set_fine_tune (bool in_finetune)
| Set fine tuning.
void | set_a1 (double fl_a1)
| Set parameter.
void | set_a2 (double fl_a2)
| Set parameter.
void | set_mu (double fl_mu)
| Set parameter.
void | set_epsilon (double fl_epsilon)
| Set convergence parameter .
void | set_sample_size (double fl_sampleSize)
| Set sample size.
void | set_stabilization (bool in_stabilization)
| Set stabilization mode true or off.
void | set_max_num_iterations (int in_maxNumIterations)
| Set maximum number of iterations.
void | set_max_fine_tune (int in_maxFineTune)
| Set maximum number of iterations for fine tuning.
void | set_first_eig (int in_firstEig)
| Set first eigenvalue index to take into account.
void | set_last_eig (int in_lastEig)
| Set last eigenvalue index to take into account.
void | set_pca_only (bool in_PCAonly)
| If true, only perform Principal Component Analysis (default = false)
void | set_init_guess (mat ma_initGuess)
| Set initial guess matrix instead of random (default)
mat | get_mixing_matrix ()
| Get mixing matrix.
mat | get_separating_matrix ()
| Get separating matrix.
mat | get_independent_components ()
| Get separated signals.
int | get_nrof_independent_components ()
| Get number of independent components.
mat | get_principal_eigenvectors ()
| Get nrIC first columns of the de-whitening matrix.
mat | get_whitening_matrix ()
| Get the whitening matrix.
mat | get_dewhitening_matrix ()
| Get the de-whitening matrix.
mat | get_white_sig ()
| Get whitened signals.

## Detailed Description

Fast_ICA Fast Independent Component Analysis (Fast ICA)

The software is based upon original FastICA for Matlab from A. Hyvarinen. Fast and Robust Fixed-Point Algorithms for Independent Component Analysis. IEEE Transactions on Neural Networks, 10(3), pp. 626-634, 1999.

Example:

FastICA fastica(sources);
fastica.set_nrof_independent_components(sources.rows());
fastica.set_non_linearity( FICA_NONLIN_TANH );
fastica.set_approach( FICA_APPROACH_DEFL );
fastica.separate();
mat ICs = fastica.get_independent_components();
itpp::Array
General array class.
Definition array.h:105
FICA_APPROACH_DEFL
#define FICA_APPROACH_DEFL
Use deflation approach : compute IC one-by-one in a Gram-Schmidt-like fashion.
Definition fastica.h:69
FICA_NONLIN_TANH
#define FICA_NONLIN_TANH
Use tanh(x) non-linearity.
Definition fastica.h:76

Definition at line 118 of file fastica.h.

## Constructor & Destructor Documentation

## Fast_ICA()

itpp::Fast_ICA::Fast_ICA | ( | mat | ma_mixed_sig | ) |

Constructor.

Construct a Fast_ICA object with mixed signals to separate.

Parameters

  ma_mixed_sig | (Input) Mixed signals to separate

Definition at line 99 of file fastica.cpp.

References FICA_APPROACH_SYMM, FICA_INIT_RAND, and FICA_NONLIN_POW3.

## Member Function Documentation

## separate()

bool itpp::Fast_ICA::separate | ( | void |  | ) |

Explicit launch of main FastICA function.

Explicit launch of the Fast_ICA algorithm.

Returns
  true if algorithm converged and false otherwise

Definition at line 126 of file fastica.cpp.

References itpp::diag(), FICA_INIT_RAND, fpica(), itpp::max_index(), pcamat(), remmean(), itpp::Array< T >::size(), itpp::to_ivec(), whitenv(), and itpp::zeros().

## set_approach()

void itpp::Fast_ICA::set_approach | ( | int | in_approach | ) |

Set approach : FICA_APPROACH_DEFL or FICA_APPROACH_SYMM (default)

Set approach to use : FICA_APPROACH_SYMM (symmetric) or FICA_APPROACH_DEFL (deflation). The symmetric approach computes all ICs at a time, whereas the deflation approach computes them one by one.

Parameters

  in_approach | (Input) Type of approach to use

Definition at line 182 of file fastica.cpp.

References FICA_APPROACH_DEFL.

## set_nrof_independent_components()

void itpp::Fast_ICA::set_nrof_independent_components | ( | int | in_nrIC | ) |

Set number of independent components to separate.

Set the number of ICs to compute.

Parameters

  in_nrIC | (Input) Number of ICs to compute

Definition at line 184 of file fastica.cpp.

## set_non_linearity()

void itpp::Fast_ICA::set_non_linearity | ( | int | in_g | ) |

Set non-linearity.

Set non-linearity to use : FICA_NONLIN_POW3 (default), FICA_NONLIN_TANH, FICA_NONLIN_GAUSS, FICA_NONLIN_SKEW

Parameters

  in_g | (Input) Non-linearity. Can be selected from FICA_NONLIN_POW3, FICA_NONLIN_TANH, FICA_NONLIN_GAUSS or FICA_NONLIN_SKEW

Definition at line 186 of file fastica.cpp.

## set_fine_tune()

void itpp::Fast_ICA::set_fine_tune | ( | bool | in_finetune | ) |

Set fine tuning.

Set fine tuning true or false.

Parameters

  in_finetune | (Input) Boolean (true or false)

Definition at line 188 of file fastica.cpp.

## set_a1()

void itpp::Fast_ICA::set_a1 | ( | double | fl_a1 | ) |

Set parameter.

Set internal parameter of Fast_ICA (See reference paper).

Parameters

  fl_a1 | (Input) Parameter from reference paper

Definition at line 190 of file fastica.cpp.

## set_a2()

void itpp::Fast_ICA::set_a2 | ( | double | fl_a2 | ) |

Set parameter.

Set internal parameter of Fast_ICA (See reference paper).

Parameters

  fl_a2 | (Input) Parameter from reference paper

Definition at line 192 of file fastica.cpp.

## set_mu()

void itpp::Fast_ICA::set_mu | ( | double | fl_mu | ) |

Set parameter.

Set internal parameter of Fast_ICA (See reference paper).

Parameters

  fl_mu | (Input) Parameter from reference paper

Definition at line 194 of file fastica.cpp.

## set_epsilon()

void itpp::Fast_ICA::set_epsilon | ( | double | fl_epsilon | ) |

Set convergence parameter .

Set parameter for convergence precision.

Parameters

  fl_epsilon | (Input) is convergence precision

Definition at line 196 of file fastica.cpp.

## set_sample_size()

void itpp::Fast_ICA::set_sample_size | ( | double | fl_sampleSize | ) |

Set sample size.

Set the percentage of samples to take into account at every iteration.

Parameters

  fl_sampleSize | (Input) Percentage of data to take into account at every iteration

Definition at line 198 of file fastica.cpp.

## set_stabilization()

void itpp::Fast_ICA::set_stabilization | ( | bool | in_stabilization | ) |

Set stabilization mode true or off.

Set stabilization mode.

Parameters

  in_stabilization | (Input) Set stabilization true or false

Definition at line 200 of file fastica.cpp.

## set_max_num_iterations()

void itpp::Fast_ICA::set_max_num_iterations | ( | int | in_maxNumIterations | ) |

Set maximum number of iterations.

Set maximum number of iterations for Fast_ICA.

Parameters

  in_maxNumIterations | (Input) Maximum number of iterations to go through

Definition at line 202 of file fastica.cpp.

## set_max_fine_tune()

void itpp::Fast_ICA::set_max_fine_tune | ( | int | in_maxFineTune | ) |

Set maximum number of iterations for fine tuning.

Set maximum numberr of iterations for fine tuning.

Parameters

  in_maxFineTune | (Input) Maximum number of iterations for fine tuning stage

Definition at line 204 of file fastica.cpp.

## set_first_eig()

void itpp::Fast_ICA::set_first_eig | ( | int | in_firstEig | ) |

Set first eigenvalue index to take into account.

Set first eigenvalue index to take into account.

Parameters

  in_firstEig | (Input) First eigenvalue index to take into account

Definition at line 206 of file fastica.cpp.

## set_last_eig()

void itpp::Fast_ICA::set_last_eig | ( | int | in_lastEig | ) |

Set last eigenvalue index to take into account.

Set last eigenvalue index to take into account.

Parameters

  in_lastEig | (Input) Last eigenvalue index to take into account

Definition at line 208 of file fastica.cpp.

## set_pca_only()

void itpp::Fast_ICA::set_pca_only | ( | bool | in_PCAonly | ) |

If true, only perform Principal Component Analysis (default = false)

Wether to perform PCA only or PCA+ICA.

Parameters

  in_PCAonly | (Input) True = PCA only, false = PCA+ICA (default)

Definition at line 210 of file fastica.cpp.

## set_init_guess()

void itpp::Fast_ICA::set_init_guess | ( | mat | ma_initGuess | ) |

Set initial guess matrix instead of random (default)

Set initial matrix instead of random matrix.

Parameters

  ma_initGuess | (Input) Initial guess matrix

Definition at line 212 of file fastica.cpp.

References FICA_INIT_GUESS.

## get_mixing_matrix()

mat itpp::Fast_ICA::get_mixing_matrix | ( |  | ) |

Get mixing matrix.

Return mixing matrix.

Returns
  Mixing matrix

Definition at line 218 of file fastica.cpp.

References it_warning, and itpp::zeros().

## get_separating_matrix()

mat itpp::Fast_ICA::get_separating_matrix | ( |  | ) |

Get separating matrix.

Return separating matrix.

Returns
  Separating matrix

Definition at line 220 of file fastica.cpp.

References it_warning, and itpp::zeros().

## get_independent_components()

mat itpp::Fast_ICA::get_independent_components | ( |  | ) |

Get separated signals.

Return separated signals (Independent Components).

Returns
  ICs

Definition at line 222 of file fastica.cpp.

References it_warning, and itpp::zeros().

## get_nrof_independent_components()

int itpp::Fast_ICA::get_nrof_independent_components | ( |  | ) |

Get number of independent components.

Return number of ICs.

Returns
  Number of ICs

Definition at line 224 of file fastica.cpp.

## get_principal_eigenvectors()

mat itpp::Fast_ICA::get_principal_eigenvectors | ( |  | ) |

Get nrIC first columns of the de-whitening matrix.

Return principal eigenvectors.

Returns
  Principal eigenvectors

Definition at line 226 of file fastica.cpp.

## get_whitening_matrix()

mat itpp::Fast_ICA::get_whitening_matrix | ( |  | ) |

Get the whitening matrix.

Return whitening matrix.

Returns
  Whitening matrix

Definition at line 228 of file fastica.cpp.

## get_dewhitening_matrix()

mat itpp::Fast_ICA::get_dewhitening_matrix | ( |  | ) |

Get the de-whitening matrix.

Return dewhitening matrix.

Returns
  Dewhitening matrix

Definition at line 230 of file fastica.cpp.

## get_white_sig()

mat itpp::Fast_ICA::get_white_sig | ( |  | ) |

Get whitened signals.

Return whitened signals.

Returns
  Whitened signals

Definition at line 232 of file fastica.cpp.

The documentation for this class was generated from the following files:

- itpp/signal/fastica.h
- itpp/signal/fastica.cpp

Generated on Mon Jun 10 2024 11:49:35 for IT++ by Doxygen 1.9.8