提交 869469f3 编辑于 作者: Mijian Xu's avatar Mijian Xu 😷
浏览文件

remove nan from power

上级 53dc4284
流水线 #1156 已失败 ,包含阶段
in 50 second
......@@ -228,7 +228,6 @@ Syntax: powspec [w1, w2]
print('w1 should be less than w2')
self.mg.power_fit(w1, w2)
self.mg.plotpower()
self.mg.pcot = None
else:
print('Only two arguments can be accepted')
......
......@@ -191,6 +191,8 @@ class mgmat(object):
power = np.zeros_like(radfreq)
for i, frq in enumerate(radfreq):
power[i] = np.mean(sf_amp[np.where(omega == frq)])
power = power[np.where(np.logical_not(np.isnan(power)))]
radfreq = radfreq[np.where(np.logical_not(np.isnan(power)))]
self.power = np.vstack((radfreq, np.log(power)))
def power_fit(self, freqmin, freqmax):
......
Supports Markdown
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册