We're Hiring!

Setting a Parent Image ID in description field

General and open developer discussion about using OMERO APIs from C++, Java, Python, Matlab and more! Please 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

If you are having trouble with custom code, please provide a link to a public repository, ideally GitHub.

Setting a Parent Image ID in description field

Postby PaulVanSchayck » Tue May 20, 2014 7:18 am

Dear all,

In the final report of the DMBI workgroup I found the following image:

Image

Here an inside the image description/comment field a clickable link to another image is shown. I would like to recreate something like this, being able to link a processed image back to an original image. Setting the description field from a Python script has been no problem:

Code: Select all
image = conn.getQueryService().get("Image", imageId)
   
image.setDescription(rstring("Parent Image ID:351"))
       
conn.getUpdateService().saveObject(image)


However, this does not automatically create the link as shown in the image. How has this been done, or is there any other way of linking one image to another?

Thanks,

Paul
PaulVanSchayck
 
Posts: 41
Joined: Tue May 20, 2014 7:04 am

Re: Setting a Parent Image ID in description field

Postby jburel » Tue May 20, 2014 12:59 pm

Thanks Paul
This is a bug in insight. Some code got removed during some refactoring.
There is nothing wrong in your code.
I have fixed the issue and opened a Pull Request see
https://github.com/openmicroscopy/openm ... /pull/2523

Thanks
Jmarie
User avatar
jburel
Team Member
 
Posts: 348
Joined: Thu May 21, 2009 6:38 pm
Location: dundee

Re: Setting a Parent Image ID in description field

Postby PaulVanSchayck » Wed May 21, 2014 6:33 am

Thanks Jmari for the quick reply and fix!
PaulVanSchayck
 
Posts: 41
Joined: Tue May 20, 2014 7:04 am

Re: Setting a Parent Image ID in description field

Postby jburel » Thu May 22, 2014 11:46 am

Hi Paul
The fix will be included in the coming 5.0.2 release
Regards
Jmarie
User avatar
jburel
Team Member
 
Posts: 348
Joined: Thu May 21, 2009 6:38 pm
Location: dundee


Return to Developer Discussion

Who is online

Users browsing this forum: No registered users and 1 guest