Skip to content

Error reading CALIOP level 2 Day_Night_Flag #32

Description

@sofstef

Using read_data to access the day_night flag for a CALIOP level 2 swath like this:
test_dn = cis.read_data(some_file, 'Day_Night_Flag')

throws this:

`ValueError Traceback (most recent call last)
in
----> 1 test_dn.data

~/miniconda/envs/eda/lib/python3.7/site-packages/cis/data_io/ungridded_data.py in data(self)
280 for manager in self._data_manager[1:]:
281 self._data = ma.concatenate((self._data, self.retrieve_raw_data(manager)), axis=0)
--> 282 self._post_process()
283 except MemoryError:
284 raise MemoryError(

~/miniconda/envs/eda/lib/python3.7/site-packages/cis/data_io/ungridded_data.py in _post_process(self)
477 combined_mask = numpy.zeros(self._data.shape, dtype=bool).flatten()
478 for coord in self._coords:
--> 479 combined_mask |= numpy.ma.getmaskarray(coord.data).flatten()
480 if coord.data.dtype != 'object':
481 combined_mask |= numpy.isnan(coord.data).flatten()

ValueError: operands could not be broadcast together with shapes (3728,) (1487472,) (3728,) `

The strange thing is that if I just reload a jupyter cell with test_dn.data it sometimes returns the flag data without any complaints and other times it just fails. It always fails within a function though.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions