-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Always marshal tile metadata on presence of pyramid #193
Conversation
It is possible, in particular for floating point data, that a pyramid is present even if the server thinks a pyramid is not required. The condition for tile metadata being available is now pyramid presence. See: * ome/omero-romio#24
Looks good. |
Tested using our sample multi-resolution OME-TIFF derived from an EM-based floating-point image: Prior to this PR {
"id": 10865,
"meta": {
"imageName": "BGal_000438_frames.ome.tiff",
"imageDescription": "",
"imageAuthor": "xxxx xxx",
"projectName": "Multiple",
"projectId": null,
"projectDescription": "",
"datasetName": "Multiple",
"datasetId": null,
"datasetDescription": "",
"wellSampleId": "", "wellId": "",
"imageTimestamp": 1595837815.0,
"imageId": 10865,
"pixelsType": "float"
},
"perms": {
"canAnnotate": true,
"canEdit": true,
"canDelete": true,
"canLink": true
},
"tiles": false,
"interpolate": true,
"size": {
"width": 7676,
"height": 7420,
"z": 38,
"t": 1,
"c": 1
},
"pixel_size": {
"x": 6.375423073768616e-05,
"y": 6.375423073768616e-05,
"z": 1.0
},
"init_zoom": 0,
"nominalMagnification": 105000.0,
"pixel_range": [
-2147483648,
2147483647
],
"channels": [
{
"emissionWave": null,
"label": "0",
"color": "808080",
"inverted": false,
"reverseIntensity": false,
"family": "linear",
"coefficient": 1.0,
"window": {
"min": -2147483648.0,
"max": 2147483647.0,
"start": 0.0,
"end": 7.636034965515137
},
"active": true
}
],
"split_channel": {
"g": {
"width": 7680,
"height": 7424,
"border": 2,
"gridx": 1,
"gridy": 1
},
"c": {
"width": 15358,
"height": 7424,
"border": 2,
"gridx": 2,
"gridy": 1
}
},
"rdefs": {
"model": "greyscale",
"projection": "normal",
"defaultZ": 19,
"defaultT": 0,
"invertAxis": false
}
} After this PR, the {
"id": 136705,
"meta": {
"imageName": "BGal_000438_frames.ome.tiff",
"imageDescription": "",
"imageAuthor": "xxx xxx",
"projectName": "Multiple",
"projectId": null,
"projectDescription": "",
"datasetName": "Multiple",
"datasetId": null,
"datasetDescription": "",
"wellSampleId": "",
"wellId": "",
"imageTimestamp": 1595837581.0,
"imageId": 136705,
"pixelsType": "float"
},
"perms": {
"canAnnotate": true,
"canEdit": true,
"canDelete": true,
"canLink": true
},
"tiles": true,
"tile_size": {
"width": 1024,
"height": 1024
},
"levels": 5,
"interpolate": true,
"size": {
"width": 7676,
"height": 7420,
"z": 38,
"t": 1,
"c": 1
},
"pixel_size": {
"x": 6.375423073768616e-05,
"y": 6.375423073768616e-05,
"z": 1.0
},
"init_zoom": 0,
"nominalMagnification": 105000.0,
"pixel_range": [
-2147483648,
2147483647
],
"channels": [
{
"emissionWave": null,
"label": "0",
"color": "808080",
"inverted": false,
"reverseIntensity": false,
"family": "linear",
"coefficient": 1.0,
"window": {
"min": -2147483648.0,
"max": 2147483647.0,
"start": 0.0,
"end": 7.636034965515137
},
"active": true
}
],
"split_channel": {
"g": {
"width": 7680,
"height": 7424,
"border": 2,
"gridx": 1,
"gridy": 1
},
"c": {
"width": 15358,
"height": 7424,
"border": 2,
"gridx": 2,
"gridy": 1
}
},
"rdefs": {
"model": "greyscale",
"projection": "normal",
"defaultZ": 19,
"defaultT": 0,
"invertAxis": false
}
} In terms of the marshalling, the change proposed here make complete sense. As discussed in ome/omero-romio#24, the current implementation of While looking at the rendered data using OMERO.iviewer with and without this PR in our CI servers, the data access feel much slower with this change included than without. Roughly each tile seems to render 5 times slower. I will take a look at the server logs as well as compare with other pyramidal images to confirm whether this issue is caused by this change or might be the consequence of other unrelated open changes. A few additional comments:
|
@sbesson: The floating point renderer is quite slow if memory serves so you might just be seeing the realities of accepting that performance hit once rather than multiple times. There is certainly scope beyond the limited change to fundamentally adjust the way clients are informed as to the nature of the underlying pixel data. Such clients can then make informed decisions on how they want to approach visualization. We already do this to a large extent with the image-region microservice and PathViewer. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Retested after excluding ome/omero-iviewer#316 which was the source of the issue described in #193 (comment).
Performance is now comparable with and without this PR while accessing the various resolutions and Z-planes of the pyramidal floating-point image. As discussed above, the metadata addition makes sense and might be something worth generalizing to all images.
@sbesson: 👍 Do we have a sense of when a release would be made including the change? |
As far as I am concerned, this release can happen immediately. Thoughts about the version increment? Would you consider this as a bug fix? |
I do consider it a bugfix but it is definitely changing the behaviour of an existing and established method so I can see it both ways. |
👍 now released as https://pypi.org/project/omero-web/5.7.1/ |
@knabar: Pointed out that Might be worth fixing |
It is possible, in particular for floating point data, that a pyramid is present even if the server thinks a pyramid is not required. The condition for tile metadata being available is now pyramid presence. See: * ome/omero-romio#24 * ome/omero-web#193
Restoration of |
It is possible, in particular for floating point data, that a pyramid is
present even if the server thinks a pyramid is not required. The
condition for tile metadata being available is now pyramid presence.
See:
/cc @kkoz, @melissalinkert, @knabar