In [1]:
using PyPlot
using WaveletScattering


Configuring Mocha...
WARNING: Method definition warn(Any...) in module Base at util.jl:350 overwritten in module Logging at /Users/vl238/.julia/v0.5/Logging/src/Logging.jl:115.
WARNING: Method definition info(Any...) in module Base at util.jl:320 overwritten in module Logging at /Users/vl238/.julia/v0.5/Logging/src/Logging.jl:115.
 * CUDA       disabled by default
 * Native Ext disabled by default
Mocha configured, continue loading module...

In [3]:
ws = WaveletScattering
spec = ws.Spec1D(log2_size = 9, n_filters_per_octave = 4)
@time bank = ws.Bank1D(spec);


  0.001464 seconds (1.66 k allocations: 663.234 KB)

In [4]:
N = 1 << spec.log2_size
halfN = N >> 1
ωs = (-halfN):(halfN-1)
for ψ in bank.ψs
    semilogx(fftshift(abs2(ψ[ωs])))
end
semilogx(fftshift(abs2(bank.ϕ[ωs])))


Out[4]:
1-element Array{Any,1}:
 PyObject <matplotlib.lines.Line2D object at 0x31dfbf950>

In [6]:
lp = ws.renormalize!(bank.ϕ, bank.ψs, bank.spec)
semilogx(lp)


Out[6]:
1-element Array{Any,1}:
 PyObject <matplotlib.lines.Line2D object at 0x3225ca950>

In [ ]: