2Provides class MeasurementSet, a class used to perform checks and adjustments
3on a group of measurements at the same time.
6__all__ = [
'MeasurementSet']
7from .lasp_measurement
import Measurement
13 Group of measurements that have some correspondence to one another. Class
14 is used to operate on multiple measurements at once.
17 def __init__(self, mlist: List[Measurement] =[]):
19 Initialize a measurement set
22 mlist: Measurement list
25 if any([
not isinstance(i, Measurement)
for i
in mlist]):
26 raise TypeError(
'Object in list should be of Measurement type')
32 Returns True if all measurements have the same measurement
38 return all([first == meas.N
for meas
in self])
44 Similar means: channel metadata is the same, and the measurement time
45 is the same. It means that the recorded data is, of course, different.
48 True if measChannelsSame() and measTimeSame() else False
56 This method is used to check whether a set of measurements can be
57 accessed in a loop, i.e. for computing power spectra or sound levels on
58 a set of measurements, simultaneously. If the channel data is the same
59 (name, sensitivity, ...) it returns True.
62 first = self[0].channelConfig
63 return all([first == meas.channelConfig
for meas
in self])
Group of measurements that have some correspondence to one another.
measTimeSame(self)
Returns True if all measurements have the same measurement time (recorded time)
__init__(self, List[Measurement] mlist=[])
Initialize a measurement set.
measSimilar(self)
Similar means: channel metadata is the same, and the measurement time is the same.
measChannelsSame(self)
This method is used to check whether a set of measurements can be accessed in a loop,...