Multi-dimensional lookup tables must be passed to ExtraCoords in world order

Open
#342 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
data

Research direction

The issue identifies ExtraCoords.add_coordinate and the LookupTableCoord layer; first read the linked pull request discussion and trace how multidimensional lookup_table values relate to NDCube data order. Done means callers can provide lookup tables in data-array order while the resulting coordinates remain in world order, with existing coordinate behavior preserved.

Written by the indexing model from the issue text.

Description

This is following on from https://github.com/sunpy/ndcube/pull/327#discussion_r526960030. Due to perfectly sensible design decisions in the LookupTableCoord layer of the new ExtraCoords stack, currently when calling ExtraCoords.add_coordinate is called the lookup_table argument must be in world order if it is multi-dimensional, i.e transposed with respect to the NDCube data array.

We probably want to change this to automatically transpose, but doing that in the add_coordinate method is a little fiddily and needs some thought.

Dominant language
Python
Stars
49
Forks
56
Avg merge
5h 54m
Merged PRs (30d)
9

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from sunpy/ndcube

All issues in sunpy/ndcube

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.