Repository navigation
Conversation
|
Presented to the instrument scientist and they approved the features. |
|
|
||
| self.bank_dim_sliders = { | ||
| key: [ | ||
| DimSlider( |
There was a problem hiding this comment.
other_dims is derived from the combined DataGroup dimensions, but this indexes every bank’s sizes with each of them. If banks have different dimension sets, construction raises KeyError (for example (layer, y, x) and (y, x) with show_dims=["y", "x"]). Could sliders be limited to dimensions present in each bank, or mismatched banks be rejected with a clear error?
| da: | ||
| The DataArray to process. | ||
| """ | ||
| return da.assign_coords({dim: sc.arange(dim, sz) for dim, sz in da.sizes.items()}) |
There was a problem hiding this comment.
This replaces coordinates for every dimension, including existing calibrated coordinates and units, so the plotted axes can become misleading. Could this add coordinates only for dimensions that lack them? If existing coordinates are preserved, mask-click positions will also need converting to pixel indices.
We turn the
LokiBankViewerinto a more generic tool that could also be used for other instruments.show_dimsarg.