Open cmeyer opened 4 months ago
@Tiomat85 can you put your explanation you just gave me of this in here please?!
@Tiomat85 nudge
I updated the main description of the bug. Is that sufficient?
What Chris has put there is a far better description than you would have got from me. I like the idea of a display hint going along with the data, as somewhere in the software should have some context as to what the data actually represents.
Yes thank you both - that's a big help, I actually understand the problem now!
Picking up on what @Tiomat85 said @cmeyer - we have that in the metadata somewhere at the moment? Like a property that is data item "type" or are most things just inferred of dims?
Data is displayed in two main modes: as an image or as a plot.
For many data items, the description of the data is sufficient to determine the display type. For instance, simple 1D data, or a sequence/collection of 1D data is displayed as a line plot; likewise simple 2D data, or a sequence/collection of 2D is displayed as an image.
However, there are some side cases that have historically used heuristics to determine the display mode. For instance, a 2D image with width >> height (e.g. 2048x4) has been displayed as a line plot with each row being a separate plot.
However, in the case of sequence/collection alignment, the resulting data is a sequence/collection of pairs of points representing the shift for the particular position in the sequence/collection. Aligning a sequence of 100 images would result in a sequence of 100 2x1 images (numpy array dimensions
(100, 1, 2)
). Aligning a 8x8 collection of spectra would result in a 20x20 collection 1x1 images (numpy array dimensions(20, 20, 1, 1)
?).In the image case, the
(100, 1, 2)
array would be described as a sequence of 2x1 images. So purely by using the data description, there is no way to determine definitively how to display the data. So we need to (a) add a short term heuristic or hint from the alignment processing to display as two stacked line plots (x and y shifts) that are length 100; (b) consider expanding data descriptors to allow for description of vector-valued data arrays.