ROI Statistics and running Icy from commandline on Linux

Home Forums Protocols ROI Statistics and running Icy from commandline on Linux

  • Ekkehard Görlach

    Hi,

    I am currently exploring how to run Icy from the command line as described in the Protocols documentation. For this I have a simple protocol: threshold the image and output some statistics into a text file. It runs fine in the Icy GUI on Windows and Linux (CentOS 7) and from the command line on windows. When I run it from the shell in Linux, however, the list of measures for the ROI statistics are always taken from the Icy settings file settings.xml and not from the protcol definition.

    From the output on the shell all looks fine:
    Initializing…

    Java(TM) SE Runtime Environment 1.8.0_162-b12 (64 bit)
    Running on Linux 3.10.0-862.2.3.el7.x86_64 (amd64)
    Number of processors : 40
    System total memory : 65.4 GB
    System available memory : 9.6 GB
    Max java memory : 14.5 GB
    Image cache initialized (reserved memory = 5681 MB, disk cache location = /tmp)
    Headless mode.

    VTK 6.3.0 library successfully loaded…

    Icy Version 2.0.3.0 started !

    Loading workflow…
    Sequence: /Data/Imaging/test@Day0_B03_G051_0001.oir – 800 x 800 x 37 x 1 – 1 ch (double)
    Exiting…
    EHCache disposed
    For now I am editing the settings file, but how could I find out why that is?

    Thanks a lot in advance,
    Ekkehard

    Stephane Dallongeville

    Hi Ekkehard,

    That is a weird issue to be honest !
    Can you post the command line and the protocol you are using so we can do some tests with it and try to sort it out ? If you can’t attach the protocol to the message you can even copy/paste its content here (it’s an XML file internally).

    Best,

    – Stephane

    Ekkehard Görlach

    Hi Stephane,
    thanks for looking into this !

    I have to correct myself: on both platforms the selection of variables are taken from the setting.xml file when running from the command line. That at least makes much more sense.

    The command line to start Icy is (all on one line):

    /usr/prog/Java/1.8.0_162/jre/bin/java -jar icy.jar -hl 
    -x plugins.adufour.protocols.Protocols 
    protocol=/home/goerek/Data/Imaging/test/ClusterTest.protocol 
    ImageFile=/home/goerek/Data/Imaging/test/Day0_B03_G051_0001.oir 
    OutputFile=/home/goerek/Data/Imaging/test/out.txt

    and the protocol is below. Thanks again for any advice – I am also happy to test things if that helps.

    Best,

    Ekkehard

    <protocol VERSION="4">
    <blocks>
    <block CommandLineID="ImageFile" ID="1898731260" blockType="plugins.adufour.blocks.tools.input.File" className="plugins.adufour.blocks.tools.input.File" collapsed="false" definedName="Image File" height="61" keepsResults="true" width="160" xLocation="36" yLocation="14">
    <variables>
    <input>
    <variable ID="file" name="file" runtime="false" value="C:\Data\Imaging\imga-collagen\E2020-03-03\Day0_C03_G084_0001.oir" visible="true"/>
    </input>
    <output/>
    </variables>
    </block>
    <block ID="448989384" blockType="plugins.adufour.blocks.tools.io.FileToSequence" className="plugins.adufour.blocks.tools.io.FileToSequence" collapsed="false" definedName="File to sequence" height="115" keepsResults="true" width="200" xLocation="35" yLocation="91">
    <variables>
    <input>
    <variable ID="input file" name="input file" runtime="false" visible="true"/>
    <variable ID="Series" name="Series" runtime="false" value="0" visible="true"/>
    </input>
    <output>
    <variable ID="sequence" name="sequence" runtime="false" visible="true"/>
    </output>
    </variables>
    </block>
    <block ID="1153157121" blockType="plugins.tprovoost.sequenceblocks.remove.RemoveAllRois" className="plugins.tprovoost.sequenceblocks.SequenceBlocks" collapsed="false" definedName="Remove all rois" height="61" keepsResults="true" width="246" xLocation="31" yLocation="230">
    <variables>
    <input>
    <variable ID="sequence" name="Sequence" runtime="false" visible="true"/>
    </input>
    <output/>
    </variables>
    </block>
    <block ID="781966398" blockType="plugins.adufour.thresholder.Thresholder" className="plugins.adufour.thresholder.Thresholder" collapsed="false" definedName="Thresholder" height="198" keepsResults="true" width="368" xLocation="305" yLocation="16">
    <variables>
    <input>
    <variable ID="Input" name="Input" runtime="false" visible="true"/>
    <variable ID="channel" name="channel" runtime="false" value="1" visible="true"/>
    <variable ID="Manual thresholds" name="Manual thresholds" runtime="false" value="350.0" visible="true"/>
    <variable ID="Treat as percentiles" name="Treat as percentiles" runtime="false" value="false" visible="true"/>
    </input>
    <output>
    <variable ID="output" name="Binary output" runtime="false" visible="true"/>
    <variable ID="ROI" name="ROI" runtime="false" visible="true"/>
    </output>
    </variables>
    </block>
    <block ID="989621978" blockType="plugins.adufour.roi.ROIMeasures" className="plugins.adufour.roi.ROIMeasures" collapsed="false" definedName="ROI Statistics" height="154" keepsResults="true" width="302" xLocation="829" yLocation="17">
    <variables>
    <input>
    <variable ID="measures" name="Select features..." runtime="false" value="27917418509" visible="true"/>
    <variable ID="Regions of interest" name="Regions of interest" runtime="false" visible="true"/>
    <variable ID="Sequence" name="Sequence" runtime="false" visible="true"/>
    </input>
    <output>
    <variable ID="Workbook" name="Workbook" runtime="false" visible="true"/>
    </output>
    </variables>
    </block>
    <block CommandLineID="OutputFile" ID="551410056" blockType="plugins.adufour.blocks.tools.input.File" className="plugins.adufour.blocks.tools.input.File" collapsed="false" definedName="Result File" height="61" keepsResults="true" width="160" xLocation="42" yLocation="598">
    <variables>
    <input>
    <variable ID="file" name="file" runtime="false" value="C:\Data\Imaging\imga-collagen\E2020-03-03\test\out.txt" visible="true"/>
    </input>
    <output/>
    </variables>
    </block>
    <block ID="488480366" blockType="plugins.adufour.blocks.tools.io.WorkbookToFile" className="plugins.adufour.blocks.tools.io.WorkbookToFile" collapsed="false" definedName="Workbook to file" height="465" keepsResults="true" width="645" xLocation="525" yLocation="238">
    <variables>
    <input>
    <variable ID="workbook" name="workbook" runtime="false" visible="true"/>
    <variable ID="file format" name="file format" runtime="false" value="Text" visible="true"/>
    <variable ID="output file" name="output file" runtime="false" visible="true"/>
    <variable ID="If file exists" name="If file exists" runtime="false" value="Merge_sheets___excluding_first_row" visible="true"/>
    </input>
    <output/>
    </variables>
    </block>
    </blocks>
    <links>
    <link dstBlockID="448989384" dstVarID="input file" srcBlockID="1898731260" srcVarID="file"/>
    <link dstBlockID="1153157121" dstVarID="sequence" srcBlockID="448989384" srcVarID="sequence"/>
    <link dstBlockID="781966398" dstVarID="Input" srcBlockID="1153157121" srcVarID="sequence"/>
    <link dstBlockID="989621978" dstVarID="Regions of interest" srcBlockID="781966398" srcVarID="ROI"/>
    <link dstBlockID="989621978" dstVarID="Sequence" srcBlockID="781966398" srcVarID="Input"/>
    <link dstBlockID="488480366" dstVarID="workbook" srcBlockID="989621978" srcVarID="Workbook"/>
    <link dstBlockID="488480366" dstVarID="output file" srcBlockID="551410056" srcVarID="file"/>
    </links>
    </protocol>

     

     

    Stephane Dallongeville

    Hi Ekkehard,

    Thanks for providing the Protocol sample, it helped in reproducing the problem and indeed there was a regression here. We just updated ROI Statistics plugin so it should fix the issue.

    Thanks for reporting it !

    Best,

    – Stephane

    Ekkehard Görlach

    Hi Stephane,

    thank you so much ! All is fine now and my other protocols now run also nicely in parallel on our cluster environment without interfering with each other anymore. That really helps as I have a large number of data sets to analyze … 🙂

    Best,

    Ekkehard

     

    Stephane Dallongeville

    Hi Ekkehard,

    Glad to hear that 🙂 Thanks for confirming it’s now working as expected !

    Best,

    – Stephane

Viewing 6 posts - 1 through 6 (of 6 total)

The forum ‘Protocols’ is closed to new topics and replies.