Utility function to promote scalar coords
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 30/100
Research direction
Begin with iris.util.promote_aux_coord_to_dim_coord and the equalise_cubes options documented in the linked API pages. Determine the supported scalar and related-coordinate cases and the required in-place behavior, then ensure the utility and integration make selected scalar coordinates create dimensions while related variables follow them, with tests covering the documented cases.
Written by the indexing model from the issue text.
Description
Part of #6383
Provide a new utility function + include it in the options for equalise_cubes
( which means it is also available in combine_cubes and CubeList.combine/combine_cube )
The basic need is to promote specific (i.e. ?named?) scalar coords to ensure they generate a new dimension
(( original spec called for remove/promote, but I can't see how this naturally extends to removal ? ))
The required api can probably look something like this:
def promote_scalars(
cubes: list[Cube],
scalars_and_related: dict[str | Coord, list[str]
):
"""Ensure specific scalar coords are promoted to a dimension."""
Functional Notes (to go in docstrings):
- changes input cubes in-place
- Each key of, 'scalars_and_related' specifies a scalar coord
- the associated values are names of other coords/aux-vars/cell-measures which should also map to the new dimension.
- See promote_aux_coord_to_dim_coord for how that needs to work
- Dominant language
- Python
- Stars
- 724
- Forks
- 317
- Avg merge
- 3d 20h
- Merged PRs (30d)
- 9
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from SciTools/iris
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
bancolombia/sentinel#23 ·
-
test md OpenCI
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
integration:quickjs org:external priority:backlog topic:code-interpreter topic:middleware type:feature
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
langchain-ai/deepagents#6450 ·
-
bug client
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100