ome / omero-figure

An OMERO.web app for creating Figures from images in OMERO
http://figure.openmicroscopy.org
GNU Affero General Public License v3.0
15 stars 30 forks source link

Request: Add Non-User, Named Rendering Definitions #509

Open JoshuaFortriede opened 1 year ago

JoshuaFortriede commented 1 year ago

With the increase in ultra-high, multiplexed imaging (e.g. CODEX), the ability to easily look at files containing dozens of channels becomes a valuable feature.

I propose adding a feature that allows for the creation of non-user rendering definitions that can be configured and given a useful name. For instance, if I have a CODEX image with 18 channels, I might want to create preset rendering definitions for various types of views: immune cells, structural, vasculature, mesenchyme. These rendering presets would, just like user defined rendering definitions, specify channel information: active/disabled, color, min/max, etc.

What is the feasibility of adding this as an enhancement? Is this something that can be done within omero-figure, or would it require changes in omero-py to allow for non-user rendering definitions?

will-moore commented 1 year ago

Thanks for the feedback.

One approach that has been used by Glencoe Software in their OMERO-Plus and Pathviewer is to group channels together to allow multiple channels to be turned on/off at a time.

Screenshot from https://www.glencoesoftware.com/webinars/2018-10-02-exploring-data-pathology-data-with-omeroplus-pathviewer-and-parade.html

Screenshot 2023-05-16 at 13 28 17

This uses some custom annotations that are understood by the Pathviewer client.

But it sounds like you're suggesting something a bit different?

The OMERO.server does actually support multiple rendering settings for an Image. Currently the clients expect there to be a single rendering setting per user. It should be possible to save more than that but I don't think it's possible to give each one a name. This would need a bit of work at the omero-py level to figure out and test the saving of multiple rendering settings. Currently we just load existing settings or reset to defaults (https://github.com/ome/omero-py/blob/d5ca72f930d85ee1f147f9f8e3cfd1c95c8089ae/src/omero/gateway/__init__.py#L8173) so when we saveDefaults` it replaces existing settings instead of creates new settings.

OMERO.figure could be adapted to store multiple rendering settings for each Image, and to give them a name etc, since these could be stored in the figure JSON without any change needed on the server or omero-py. However, it feels like it would be wrong to develop such a feature that wasn't supported by the iviewer.