ratt-ru / dask-ms

Implementation of a dask/xarray dataset backed by a CASA MS
https://dask-ms.readthedocs.io
Other
19 stars 7 forks source link

Consider setting MS index arrays to be coordinates #19

Open sjperkins opened 6 years ago

sjperkins commented 6 years ago
  1. xarray supports the idea of coordinate arrays to support indexing and selection of data.
  2. The MS index columns (TIME, ANTENNA1, ANTENNA2, DATA_DESC_ID) etc. are appropriate to use as coordinate arrays.
  3. It's trivial to convert them from standard xarray arrays to xarray coordinates via Dataset.set_coords
  4. It might useful to support this as standard practice on the xarray-ms, but at some point a decision may need to be made as to whether to support this via numpy or dask arrays.

@bennahugo and @mulan-94, before deciding that 4. is a good idea, I'd be interested in hearing your experiences with 1, 2 and 3, if you have the need to use the xarray coordinate functionality for performing selections..

miguelcarcamov commented 3 years ago

Hi,

I have a suggestion also. It would be cool if the baselines could have an ID as well. So the index columns could be like TIME, ANTENNA1, ANTENNA2, DATA_DESC_ID and BASELINE_ID :)