Ejemplo n.º 1
0
 def state(self):
     """Return test state."""
     out = AttribDict()
     out.path = os.path.join(os.path.dirname(__file__), 'data')
     out.path_images = os.path.join(os.path.dirname(__file__), 'images')
     out.a = np.sin(np.linspace(0, 10, 101))
     out.b = 5 * np.roll(out.a, 5)
     out.c = 5 * np.roll(out.a[:81], 5)
     return out
Ejemplo n.º 2
0
 def state(self):
     # directory where the test files are located
     out = AttribDict()
     out.path = PATH
     out.path_images = os.path.join(PATH, os.pardir, "images")
     # some pre-computed ppsd used for plotting tests:
     # (ppsd._psd_periods was downcast to np.float16 to save space)
     out.example_ppsd_npz = os.path.join(PATH, "ppsd_kw1_ehz.npz")
     # ignore some "RuntimeWarning: underflow encountered in multiply"
     return out