![]() |
VOOZH | about |
Independent Component Analysis (ICA) is a technique used to separate mixed signals into their independent, non-Gaussian components. Its aim is to find a linear transformation of data that maximizes statistical independence among the components. ICA is widely used in audio & image processing and biomedical signal analysis to isolate distinct sources from mixed signals.
Statistical independence refers to the idea that two random variables: X and Y are independent if knowing one does not affect the probability of the other. Mathematically, this means the joint probability of X and Y is equal to the product of their individual probabilities.
or
ICA operates under two key assumptions:
These assumptions allow ICA to effectively separate mixed signals into independent components, a task that traditional methods like PCA cannot achieve
The observed random vector is representing the observed data with m components. The hidden components are represented by the random vector where is the number of hidden sources.
The observed data is transformed into hidden components using a linear static transformation representation by the matrix W.
The goal is to transform the observed data in a way that the resulting hidden components are independent. The independence is measured by some function . The task is to find the optimal transformation matrix that maximizes the independence of hidden components.
To better understand how Independent Component Analysis (ICA) works let’s look at a classic example known as the Cocktail Party Problem
Here there is a party going into a room full of people.
Hence the number of speakers is equal to the number of microphones in the room. Now using these microphones' recordings, we want to separate all the 'n' speakers voice signals in the room given that each microphone recorded the voice signals coming from each speaker of different intensity due to the difference in distances between them.
Decomposing the mixed signal of each microphone's recording into an independent source's speech signal can be done by using the machine learning technique independent component analysis.
where are the original signals present in the mixed signal and are the new features and are independent components that are independent of each other.
First we will import numpy, sklearn, FastICA and matplotlib.
In this step we create three separate signals: a sine wave, a square wave and random noise. These represent different types of real-world signals. We use NumPy to generate 200 time points between 0 and 8.
In this step we apply Independent Component Analysis using the FastICA class from Scikit-learn. We first create an instance of FastICA and set the number of independent components to 3 matching the number of original signals.
In this step we use Matplotlib to plot and compare the original sources, mixed signals and the signals recovered using ICA.
We create three subplots:
Output:
| Parameters | Principal Component Analysis (PCA) | Independent Component Analysis (ICA) |
|---|---|---|
| Goal | Reduces the dimensions to avoid the problem of overfitting | Decomposes the mixed signal into its independent source signals |
| Type of Components | Deals with the Principal Components | Deals with the Independent Components |
| Focus on Variance | Focuses on maximizing the variance | Doesn't focus on the issue of variance among the data points |
| Orthogonality | Focuses on the mutual orthogonality property of the principal components | Doesn't focus on the mutual orthogonality of the components |
| Independence | Doesn't focus on the mutual independence of the components | Focuses on the mutual independence of the components |
| Typical Use | Mainly used for dimensionality reduction | Mainly used for signal separation and feature extraction |