Closed tclements closed 3 years ago
Error found by @xtyangpsp: whiten! accepts only ComplexF32 data and not ComplexF64. MWE:
whiten!
ComplexF32
ComplexF64
using SeisNoise A = rand(ComplexF64,100,10); whiten!(A,1.,2.,10.,50) ERROR: MethodError: no method matching whiten!(::Array{Complex{Float64},2}, ::Float64, ::Float64, ::Float64, ::Int64) Closest candidates are: whiten!(::AbstractArray{Complex{Float32},N} where N, ::Real, ::Real, ::Real, ::Int64; pad) at /home/timclements/.julia/packages/SeisNoise/Bosrn/src/correlation.jl:168 whiten!(::FFTData, ::Real, ::Real; pad) at /home/timclements/.julia/packages/SeisNoise/Bosrn/src/correlation.jl:221 whiten!(::RawData, ::Real, ::Real; pad) at /home/timclements/.julia/packages/SeisNoise/Bosrn/src/correlation.jl:245 ... Stacktrace: [1] top-level scope at REPL[4]:1
Need to rewrite whiten! kernel to accept Complex{T} where T <: AbstractFloat.
Complex{T} where T <: AbstractFloat
Error found by @xtyangpsp:
whiten!
accepts onlyComplexF32
data and notComplexF64
. MWE:Need to rewrite
whiten!
kernel to acceptComplex{T} where T <: AbstractFloat
.