check_data_dimensions¶
- sofia_redux.instruments.exes.utils.check_data_dimensions(**kwargs)[source]¶
Check the data dimensions and return number of frames.
Input data should be 2 or 3 dimensions, matching specified x and y sizes.
- Parameters:
- kwargsdict
May contain a ‘params’ key, containing a dict with ‘data’, ‘nx’, ‘ny’ input. Otherwise, it may contain ‘data’, ‘nx’, and ‘ny’ directly specified. The ‘data’ key should contain an array; ‘nx’ and ‘ny’ should specify its expected x and y dimensions, respectively.
- Returns:
- nzint
The number of frames in the input data cube. Returns 1 if the input has 2 dimensions.