I am just wondering does the function obspy.signal.util.next_pow_2 is same as matlab function nextpow2?
matlab
nextpow2(18000) = 15
obspy
obspy.signal.util.next_pow_2(18000)= 32768 = 2**15
Yep. Only that matlab returns the exponent whereas ObsPy return the actual number.
Technically, the matlab function returns the exponent of the next
power of 2 and the obspy function returns the actual next power of 2.
So,
(obspy next power of two) = 2 ^ (matlab next power of two)
or
(matlab next power of two) = log2 (obspy next power of two)
螤伪蟻伪胃苇蟿慰谓蟿伪蟼 伪蟺蠈 Khalil Al Hooti notifications@github.com:
I am just wondering does the function obspy.signal.util.next_pow_2
is same as matlab function nextpow2?matlab
nextpow2(18000) = 15obspy
obspy.signal.util.next_pow_2(18000)= 32768--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/obspy/obspy/issues/1905
just to say, with the new scipy.fftpack since 0.18, next_fast_len is a product of 1s, 3s and 5s, faster and more stable than powers of 2...
Most helpful comment
just to say, with the new
scipy.fftpacksince 0.18,next_fast_lenis a product of 1s, 3s and 5s, faster and more stable than powers of 2...