[ome-devel] Python import API

Mark Carroll m.t.b.carroll at dundee.ac.uk
Tue Mar 1 08:50:05 GMT 2016


On 02/29/2016 05:56 PM, Colin Blackburn (Staff) wrote:
(snip)
>> I do have one small question though: as discussed with J-M and
>> Sebastien during last year's meeting in Paris, it would be extremely
>> helpful if the Python API call for importing an image into OMERO would
>> report the ID of the new image after a successful import.
(snip)
> Here we capture the stdout and stderr. The Pixels IDs are in stdout
> (just the IDs each on a new line), for example:
>
>> 9
> 10
> 11
> 12
> "
>
> And the Image IDs can be parsed from stderr

They're also readily available via HQL, e.g., for Pixels ID 12345,

echo Image ID is `bin/omero hql --style plain "SELECT image.id FROM
Pixels WHERE id = 12345" | cut -f 2 -d ,`

-- Mark

The University of Dundee is a registered Scottish Charity, No: SC015096


More information about the ome-devel mailing list