We're Hiring!

DeltaT info in python-omero

General user discussion about using the OMERO platform to its fullest. Please ask new questions at https://forum.image.sc/tags/omero
Please note:
Historical discussions about OMERO. Please look for and ask new questions at https://forum.image.sc/tags/omero

There are workflow guides for various OMERO functions on our help site - http://help.openmicroscopy.org

You should find answers to any basic questions about using the clients there.

DeltaT info in python-omero

Postby talley » Wed Feb 13, 2019 5:12 pm

not sure if I should be directing this to a bioformats-specific forum... but here goes:

I'm struggling to get DeltaT info for each timepoint in a timelapse, for an image stored on an OMERO server using the python bindings for omero, python-omero v5.4.10. From what I've been able to find in the documentation, it seems like it should be an attribute of image.pixels.plane ... but after loading an image (
Code: Select all
conn.getObject()
) and getting the pixels (
Code: Select all
im.getPrimaryPixels()
) the pixel wrapper object I get has only a getPlane() function that just returns the actual numpy array, but no "getPlaneDeltaT" or similar function, that I've seen referred to elsewhere.

if anyone can provide a basic example of extracting DeltaT info from an image ID on OMERO, using the python bindings, I would be grateful!
talley
 
Posts: 4
Joined: Sun Apr 08, 2012 11:18 pm

Re: DeltaT info in python-omero

Postby talley » Wed Feb 13, 2019 9:48 pm

for anyone else who stumbles upon this, I was able to find a working example in the example omero scripts on github: https://github.com/openmicroscopy/omero-example-scripts/blob/master/analysis_scripts/Simple_FRAP.py#L108

In this particular example... the query was actually performed in SQL using BlitzGateway.getQueryService()... so maybe this particular bit of metadata hasn't been exposed with the python wrapper yet?
talley
 
Posts: 4
Joined: Sun Apr 08, 2012 11:18 pm

Re: DeltaT info in python-omero

Postby Dominik » Fri Feb 15, 2019 1:34 pm

Hi,

it is in the pixel wrapper, but the method is called 'copyPlaneInfo'.

Here's an example:
Code: Select all
from omero.gateway import BlitzGateway

conn = BlitzGateway(USERNAME, PASSWORD, host="HOSTNAME")
conn.connect()

image_id = 123

img = conn.getObject("Image", oid=image_id)
pix = img.getPrimaryPixels()
for plane_info in pix.copyPlaneInfo():
    print "Plane ID: %d , Channel: %d, deltaT: %f, exposureTime: %f" %\
          (plane_info.getId(), plane_info.theC, plane_info.getDeltaT(),
           plane_info.getExposureTime())

conn.close()


Regards,
Dominik
User avatar
Dominik
Team Member
 
Posts: 149
Joined: Mon Feb 10, 2014 11:26 am

Re: DeltaT info in python-omero

Postby talley » Fri Feb 15, 2019 2:30 pm

Thanks very much!
talley
 
Posts: 4
Joined: Sun Apr 08, 2012 11:18 pm


Return to User Discussion

Who is online

Users browsing this forum: No registered users and 1 guest