Esempio n. 1
0
 def data_array_from_gappy_stream(self, basic_stream_with_gap):
     st = basic_stream_with_gap[0]
     return obspy_to_array(st.merge(method=1), trim_stream=False)
Esempio n. 2
0
 def data_array_from_trace(self, waveform_cache_trace):
     """ convert the trace to a data array, return data array """
     tr = waveform_cache_trace
     return obspy_to_array(tr), tr
Esempio n. 3
0
 def test_idempotent(self, st_dict_close_lens):
     """ ensure the transformation to data array is idempotent """
     dar = obspy_to_array(st_dict_close_lens)
     dar2 = obspy_to_array(dar)
     assert (dar == dar2).all()
Esempio n. 4
0
 def data_array_from_stream(self, waveform_cache_stream):
     return obspy_to_array(waveform_cache_stream)
Esempio n. 5
0
 def test_stream_uneven(self, st_dict_close_lens):
     """ tests for when all streams are different lens """
     ar = obspy_to_array(st_dict_close_lens)
     assert not ar.isnull().any()
Esempio n. 6
0
 def list_array1(self):
     """A  list of homogeneous streams"""
     return obspy_to_array([obspy.read() for _ in range(self.list1_len)])
Esempio n. 7
0
def default_array():
    """ the basic waveforms turned into an array """
    st = obspy.read()
    return obspy_to_array(st)
Esempio n. 8
0
def bingham_dar(bingham_stream_dict):
    """ build a data array from the bingham waveforms dictionary """
    return obspy_to_array(bingham_stream_dict)
Esempio n. 9
0
def data_array_from_dict(stream_dict):
    """ feed the waveforms dict into the stream_dict2dataset functions """
    return obspy_to_array(stream_dict)