diff --git a/python_src/lasp/__init__.py b/python_src/lasp/__init__.py index d28c3e8..58c09c8 100644 --- a/python_src/lasp/__init__.py +++ b/python_src/lasp/__init__.py @@ -10,11 +10,11 @@ from .lasp_cpp import * # from .lasp_imptube import * # TwoMicImpedanceTube from .lasp_measurement import * # Measurement, scaleBlockSens -from .lasp_octavefilter import * +from .lasp_octavefilter import * # OverallFilterBank, SosOctaveFilterBank, SosThirdOctaveFilterBank from .lasp_slm import * # SLM, Dummy from .lasp_record import * # RecordStatus, Recording -from .lasp_daqconfigs import * -from .lasp_measurementset import * +from .lasp_daqconfigs import * # DaqConfigurations +from .lasp_measurementset import * # MeasurementSet # from .lasp_siggen import * # SignalType, NoiseType, SiggenMessage, SiggenData, Siggen # from .lasp_weighcal import * # WeighCal diff --git a/python_src/lasp/lasp_measurement.py b/python_src/lasp/lasp_measurement.py index 1843360..3463900 100644 --- a/python_src/lasp/lasp_measurement.py +++ b/python_src/lasp/lasp_measurement.py @@ -77,9 +77,9 @@ class MeasurementType(Enum): Measurement flags related to the measurement. Stored as bit flags in the measurement file. This is for possible changes in the API later. """ - # Not specific measurement type + # Not specific measurement type NotSpecific = 0 - + # Measurement serves as an insertion loss reference measurement ILReference = 1 << 0 @@ -1156,11 +1156,8 @@ class Measurement: if data.ndim != 2: data = data[:, np.newaxis] - try: - len(sensitivity) - except: - raise ValueError("Sensitivity should be given as array-like data type") - sensitivity = np.asarray(sensitivity) + if not (isinstance(sensitivity, np.ndarray) and sensitivity.ndim >= 1): + sensitivity = np.asarray(sensitivity)[np.newaxis] nchannels = data.shape[1] if nchannels != sensitivity.shape[0]: