[ome-devel] Input java flags for command line tools

Balaji Ramalingam (Staff) b.ramalingam at dundee.ac.uk
Thu May 14 15:53:13 BST 2015


Hi,

Thank you for your suggestion.
We have updated one of our PR's to include your suggestion,
https://github.com/openmicroscopy/bioformats/pull/1783

Should mostly make it to our next stable release (Bio-Formats 5.1.2).

Best,
Balaji

__________________

Mr Balaji Ramalingam

Software Developer

OME Team

College of Life Sciences

University of Dundee

From: Simon Blanchoud <simon.blanchoud at otago.ac.nz<mailto:simon.blanchoud at otago.ac.nz>>
Reply-To: OME External Developer List <ome-devel at lists.openmicroscopy.org.uk<mailto:ome-devel at lists.openmicroscopy.org.uk>>
Date: Thursday, 7 May 2015 04:15
To: "ome-devel at lists.openmicroscopy.org.uk<mailto:ome-devel at lists.openmicroscopy.org.uk>" <ome-devel at lists.openmicroscopy.org.uk<mailto:ome-devel at lists.openmicroscopy.org.uk>>
Subject: [ome-devel] Input java flags for command line tools

Hi all,

I'm still playing with my .avi recordings that I want to convert to ome.tiff stacks. To do so, I first extract the key frames from the recording using FFMPEG (file QA 11011):

ffmpeg -i M-flow1.avi -y -vf select="eq(pict_type\,PICT_TYPE_I)" -vsync 2 -qscale:v 2 -f image2 ./tmp_folder/tmp_img%d.jpg

Turns out that those avi recordings contain quite a lot of frames (several thousands actually), and so, when I afterwards tried to stitch them up using:

./bfconvert -stitch ./tmp_folder/tmp_img1.jpg M-flow1.ome.tiff

I get a java out of memory error:
java.lang.OutOfMemoryError: GC overhead limit exceeded

Turns out that (thanks Google), this issue can be solved by using the following JVM flag:
-XX:+UseConcMarkSweepGC

(And yes, I then get a standard heap space error, for which I needed to increase the allocated space using -Xmx)

Anyway, finally to the point of this email:
Turns out that there is currently no way to provide additional flags to the JVM for the bio-formats command line tools ! Turns out that's very easily fixed by adding the following few lines at the beginning of bf.sh (just as for BF_MEM_MAX):

# Prepare the flags.
if [ -z "$BF_FLAGS" ]
then
  BF_FLAGS=""
fi

In case you find this relevant !

Cheers,
Simon


The University of Dundee is a registered Scottish Charity, No: SC015096
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-devel/attachments/20150514/ecfc0830/attachment.html>


More information about the ome-devel mailing list