[ome-devel] Using the GatewayPrx object to copy an Image...

Jerome Avondo jeromeavondo at msn.com
Mon Jul 6 15:43:09 BST 2009



Right, 
got the copy image working by doing as suggested by Micheal,

>The info you need to gather is...
>imageName, channelList, pixelsType, physSizeX, physSizeY, physSizeZ, sizeX, sizeY, sizeZ, sizeT, timeStamp, >dimensionOrder, statsInfo(for GlobalMin/Max), sha1.

 >Then you need to create the channel object, logical channel object, populate the logical channels with your emission >wavelengths, attach the logical channels to the channel object, the channel object to the pixels, the pixels to the image, >then saveAndReturn the newImage.

A bit long handed, but seems to work as I end up with an unattached image full of black of the same dimensions as the source image. 

Now I am trying to populate the plane data.
So I use the getPlane() on my source Image, and the setPlane() on my destination Image.

However this seems to run out of memory after a while, the crash I get is:

    reason = "OutOfMemoryError occurred while allocating a ByteBuffer"
        at IceInternal.Buffer.reserve(Buffer.java:163)
        at IceInternal.Buffer.resize(Buffer.java:72)
        at IceInternal.Buffer.expand(Buffer.java:59)
        at IceInternal.BasicStream.expand(BasicStream.java:2031)
        at IceInternal.BasicStream.writeInt(BasicStream.java:872)
        at omero.api._RawPixelsStoreDelM.setPlane(_RawPixelsStoreDelM.java:1128)
        at omero.api.RawPixelsStorePrxHelper.setPlane(RawPixelsStorePrxHelper.java:1546)
        at omero.api.RawPixelsStorePrxHelper.setPlane(RawPixelsStorePrxHelper.java:1518)
        at omeroconnect.Main.setPlane(Main.java:906)
        at omeroconnect.Main.main(Main.java:110)
Caused by: java.lang.OutOfMemoryError: Java heap space

Anyone had this happen to them? Any help would be appreciated. Can post code if needed.
Thanks,

j.

_________________________________________________________________
With Windows Live, you can organise, edit, and share your photos.
http://clk.atdmt.com/UKM/go/134665338/direct/01/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.openmicroscopy.org.uk/pipermail/ome-devel/attachments/20090706/ddfe4cce/attachment.htm 


More information about the ome-devel mailing list