Skip to content

Commit a54fbaf

Browse files
committed
Changing defintion of good frequencies to ensure that FP rounding errors don't cause non-didv frequencies to be plotted
1 parent 532259d commit a54fbaf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

qetpy/core/didv/_plot_didv.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -497,9 +497,9 @@ def _plot_freq_domain(self, function, poles):
497497

498498
# remove values set with placeholder mean
499499
goodinds = (
500-
self._didvmean != 0.5 - 0.5j
500+
np.abs(self._didvmean - (0.5 - 0.5j)) > 1e-16
501501
) & (
502-
self._didvmean != - 0.5 + 0.5j
502+
np.abs(self._didvmean - (- 0.5 + 0.5j)) > 1e-16
503503
)
504504
fitinds = self._freq > 0
505505
plotinds = np.logical_and(fitinds, goodinds)

0 commit comments

Comments
 (0)