Dear all,
I would like to analysis images of surface with variable roughness in space. In practice, I would like to quantify the roughness of signals and report it on 2D maps (in the original spatial coordinates). It seems that a discrete wavelet analysis could be the ideal tool for this. If I understand well, I could report the spatial distribution of energy for different frequencies… (I am a newbie on that topic)
Does anyone know an example that does such type of analysis using Julia-based tools?
It looks like it could be done with Wavelets.jl but I failed at finding a detailed example/tutorial.
Here’s an example of a synthetic signal that may be relevant. I would expect that a wavelet analysis will be able to detect energy in high frequency range in the upper right region. And energy at low frequency in the lower-left region.
Is Wavelets.jl the appropriate tool to carry out such analysis? Is there a tutorial that I could use to get started with this?
(If not I’d be happy to progress on this example and then contribute to the docs)
# Synthetic signal
nx, ny = 128, 150
x = LinRange(0, 1.0, nx)
y = LinRange(0, 1.0, ny)
# Create a low frequency part in the the upper-right region
k = (5., 10) # Wavenumbers
shift = (0.75, 0.75) # Shift
gauss = @. exp(-((x .- shift[1]).^2 + (y' .- shift[2]).^2) / 0.1) # Gaussian function for varying energy
signal_HR = @. gauss * (sin(2π * k[1] * x) + cos(2π * k[2] * y'))
# Create a low frequency part in the the lower-left region
k = (2., 2) # Wavenumbers
shift = (0.25, 0.25) # Shift
gauss = @. exp(-((x .- shift[1]).^2 + (y' .- shift[2]).^2) / 0.1) # Gaussian function for varying energy
signal_LR = @. gauss * (sin(2π * k[1] * x) + cos(2π * k[2] * y'))
# Total signal
signal = signal_LR .+ signal_HR
edit: added the image corresponding to the test signal below