We're Hiring!

Write Image to Omero Server

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.

Re: Write Image to Omero Server

Postby kennethgillen » Mon Jun 04, 2018 4:08 pm

Hi Hang,

is there a documentation that covers all the Omero APIs?


I was thinking http://downloads.openmicroscopy.org/omero/5.4.6/api/ may have been what your'e after, but likely it's not. Someone on the team will be able to point you at something more concrete.

Cheers,

Kenny
kennethgillen
 
Posts: 254
Joined: Mon Nov 05, 2012 3:39 pm

Re: Write Image to Omero Server

Postby Hang » Tue Jun 05, 2018 8:32 pm

Great. I will wait for a response from the team member then.

Hang
Hang
 
Posts: 46
Joined: Wed Mar 07, 2018 10:22 pm

Re: Write Image to Omero Server

Postby jmoore » Tue Jun 05, 2018 8:40 pm

Hi Hang,

Hang wrote:Another question is that the image I saved to the server is not downloadable as other images in the dataset. When I right click the image, the download button is grayed out. So, how do I set the download property for an image.


There is a property which can be set to enable downloading, but on the group rather than the image: omero.policy.binary_access. It's a security feature, but if you can download other images, then I don't think this would be the problem. If you've created this image from scratch, then there is no Fileset nor OriginalFiles which enable download. Likely what you want to use is export.

Also, an general question: is there a documentation that covers all the Omero APIs? For example, in this case, I will be able to look up how to set the download property for an image. I really appreciate the speedy response from you guys, however, a documentation would help me to move along faster.


As I mentioned earlier today on another MATLAB-related thread, the MATLAB API as well as the documentation is certainly not on par with the other languages. Since MATLAB uses the Java API, currently the best starting point is

https://docs.openmicroscopy.org/latest/omero/developers/Java.html.

Sorry for any confusion.
~Josh
User avatar
jmoore
Site Admin
 
Posts: 1591
Joined: Fri May 22, 2009 1:29 pm
Location: Germany

Re: Write Image to Omero Server

Postby Hang » Wed Jun 06, 2018 4:08 pm

Josh,

Thanks! I see the Export feature you are talking about.

However, I still would like to figure out how to make it possible to download the images that I uploaded with Matlab exe just like the images that are imported with Omero.insight.

As you can see from the attachment, the download option for the images that I created/uploaded is grayed out.

Thanks,

Hang
Attachments
Capture2.JPG
Capture2.JPG (20.29 KiB) Viewed 1911 times
Capture1.JPG
Capture1.JPG (32.06 KiB) Viewed 1911 times
Hang
 
Posts: 46
Joined: Wed Mar 07, 2018 10:22 pm

Re: Write Image to Omero Server

Postby jmoore » Wed Jun 06, 2018 7:34 pm

Hi Hang,

Hang wrote:However, I still would like to figure out how to make it possible to download the images that I uploaded with Matlab exe just like the images that are imported with Omero.insight.

As you can see from the attachment, the download option for the images that I created/uploaded is grayed out.


OMERO.insight uploads a fileset to the server which is then parsed on the server-side to generate the Image and Channel objects like you are doing in Matlab. (Those files are stored under /OMERO/ManagedRepository if you'd like to inspect them.) When you download from the GUI, you are getting these files back without any changes to the metadata. In order to have the download option work for you, then you will need to upload files from Matlab and have the server import them. If this is what you'd like to do, we're certainly happy to help.

(This will be similar to simpleImportTest.m.)

Cheers,
~Josh
User avatar
jmoore
Site Admin
 
Posts: 1591
Joined: Fri May 22, 2009 1:29 pm
Location: Germany

Re: Write Image to Omero Server

Postby Hang » Thu Jun 07, 2018 5:23 pm

Hi Josh,

I see. But one thing I don't understand is that it seems that https://github.com/openmicroscopy/openmicroscopy/blob/v5.4.6/examples/Training/matlab/CreateImage.m already saves image to the server. So what does "have the server import them" mean? I don't understand what simpleImportTest.m does.

How do I combine simpleImportTest.m with CreateImage.m to finish this whole process?
Hang
 
Posts: 46
Joined: Wed Mar 07, 2018 10:22 pm

Re: Write Image to Omero Server

Postby jmoore » Fri Jun 08, 2018 5:46 am

Hang wrote:I see. But one thing I don't understand is that it seems that https://github.com/openmicroscopy/openmicroscopy/blob/v5.4.6/examples/Training/matlab/CreateImage.m already saves image to the server. So what does "have the server import them" mean? I don't understand what simpleImportTest.m does.


The standard clients are all file-based in that they collect together files and upload them to the server at which point they are finished. The server then takes over what we can import which means parsing the filess and creating the Images and other metadata objects in the database. The binary data is left in the original files themselves.

In your case, no files are involved. Your client is creating the metadata (client-side) and then set the pixel values directly. These, however, aren't stored in a file that is useful outside the server. It's a bit like just having a matrix you can consume. That's why there's nothing to download.

How do I combine simpleImportTest.m with CreateImage.m to finish this whole process?


I'm not sure. It depends on what you are trying to achieve. Why do you need to have "download" enabled?

~Josh
User avatar
jmoore
Site Admin
 
Posts: 1591
Joined: Fri May 22, 2009 1:29 pm
Location: Germany

Re: Write Image to Omero Server

Postby Hang » Fri Jun 08, 2018 9:08 pm

Hi Josh,

Export function does achieve what I need, which is letting user download images from Omero. However, I'm just worried that our users will see the download button being grayed out, and then get confused.

Hang
Hang
 
Posts: 46
Joined: Wed Mar 07, 2018 10:22 pm

Re: Write Image to Omero Server

Postby jmoore » Mon Jun 11, 2018 7:28 am

Hi Hang,

Understood. Have you see then the user-focused documentation yet? http://help.openmicroscopy.org/export.html might be of some use in explaining the differences.

Cheers,
~Josh
User avatar
jmoore
Site Admin
 
Posts: 1591
Joined: Fri May 22, 2009 1:29 pm
Location: Germany

Previous

Return to Developer Discussion

Who is online

Users browsing this forum: No registered users and 0 guests