sunpy / ndcube

A base package for multi-dimensional contiguous and non-contiguous coordinate-aware arrays.
http://docs.sunpy.org/projects/ndcube/
BSD 2-Clause "Simplified" License
44 stars 48 forks source link

A ".coords" wrapper #285

Open Cadair opened 4 years ago

Cadair commented 4 years ago

This still needs some fleshing out, but it's looking like in 2.0 our coordinate information might be spread across three different places:

I was wondering if it would be worth providing a .coords attribute (borrowed a little from xarray) to provide a coherent unified interface to all the coordinate information in the cube. This could also allow us to implement more API in the .coords than we might be comfortable in doing on the top level of the NDCube object itself.

DanRyanIrish commented 4 years ago

Perhaps this should not be a blocker for 2.0. Presumably this is new API that could be introduced in the future. Unless you are suggesting that introducing .coords now would make implementation of code needed for 2.0 easier, or that it would have significant consequences for implementation at this stage?

Cadair commented 4 years ago

At this stage implementing ExtraCoords I am not sure. I feel like we need something and maybe this is the way to go. It could well get bumped.

DanRyanIrish commented 4 years ago

I vote for bumping it just because I think we should only include essential things in 2.0 or things that are urgent for users, e.g. sunraster.