checkPDFeaturesStrRed.py 文件源码

python
阅读 31 收藏 0 点赞 0 评论 0

项目:Homology_BG 作者: jyotikab 项目源码 文件源码
def amp_freq(timeSeries):
    freq = spfft.rfftfreq(len(timeSeries),1)
    fft = spfft.rfft(timeSeries)
        amp = np.abs(fft)
        indmax = np.where(amp==np.max(amp))[0][0]
        oi = (np.sum(amp[indmax-1:indmax+1]))/np.sum(amp)

    indmax = np.where(amp==np.max(amp))[0][0]
    dfreq = freq[indmax]*1000         # Sampling frequency = 1/1ms = 1/0.001= 1000

    return oi,dfreq
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号