# 1-D wavelet transform on individual pixels of an image time series data

2 Ansichten (letzte 30 Tage)
Faisal Sani Bala am 23 Okt. 2022
I am working on an imaging system, where I have a stack of images whose source of illumination is a sinusoidally varying source. Thus for any pixel p(x,y,t) in the image series , there is a sinusoidally varying intensity (starting from the first image to the last image and tracing a single pixel location). However the intensity is not stationary and also has harmonic contents. How may I get the component of each harmonic from the pixel location using wavelet transform?
##### 0 Kommentare-2 ältere Kommentare anzeigen-2 ältere Kommentare ausblenden

Melden Sie sich an, um zu kommentieren.

### Antworten (1)

Gokul Nath S J am 26 Mai 2023
Hi Faisal,
To extract the harmonics from a pixel location in an image series with sinusoidally varying intensity using wavelet transform, you can follow these general steps:
1. Load the image series into MATLAB as a 3D array, where each slice represents an image frame:
% Load the image series as a 3D array
The load_image_series function is a custom function that loads a series of images from a file path using the imread function.
2.For the pixel location of interest, extract the intensity values over time as a 1D array:
% Extract the intensity values for a pixel location as a 1D array
pixel_values = squeeze(image_series(x,y,:));
The squeeze function is used to remove singleton dimensions from the 3D array.
3. Decompose the pixel values into frequency components using wavelet transform:
% Perform wavelet decomposition on the pixel values
[c,l] = wavedec(pixel_values, num_levels, wavelet_name);
% Extract the wavelet coefficients for a specific harmonic frequency
harmonic_coefficients = detcoef(c,l,harm_level);
4. Reconstruct the harmonic frequency component from the extracted coefficients:
% Reconstruct the pixel values corresponding to the harmonic frequency component
harmonic_pixel_values = wrcoef('d',c,l,wavelet_name,harm_level);
The wrcoef function reconstructs the signal from the wavelet coefficients using a specified wavelet type and decomposition level.
5. Repeat steps 3-4 for each harmonic component of interest.
By repeating these steps for different harmonic frequencies, you can extract the frequency components of interest from a pixel location in an image series with sinusoidally varying intensity using wavelet transform.
with regards,
Gokul Nath S J
##### 3 Kommentare1 älteren Kommentar anzeigen1 älteren Kommentar ausblenden
Gokul Nath S J am 28 Mai 2023
Hi Faisal,
Yes, you might need to write the function while incorporating a loop depending on the number of images.
Faisal Sani Bala am 2 Jun. 2023
Hi Gokul,
I have created the function. thanks, but I discovered the signal multiresolution analyzer app, is it implementing the same thing ?

Melden Sie sich an, um zu kommentieren.

### Kategorien

Mehr zu Signal Analysis finden Sie in Help Center und File Exchange

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by