Skip to content

Commit

Permalink
Update CLEM collection table example
Browse files Browse the repository at this point in the history
  • Loading branch information
tischi committed Oct 4, 2024
1 parent 5a4ffe9 commit 9a0e954
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ public void run()

if ( showTransformationHistory )
{
IJ.log( "## Transformation history" );
transformations.forEach( transformation ->
{
IJ.log( transformation.toString() );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@ public static enum DataRoot{
public File table;

@Parameter( label = "Data Root",
description = "Use this is if the paths to the images and labels in the table are relative." )
description = "Specify whether the data URIs in the table are absolute or relative." )
public DataRoot dataRoot = DataRoot.PathsInTableAreAbsolute;

@Parameter( label = "Data Root Folder",
@Parameter( label = "( Data Root Folder )",
style = "directory",
description = "The root folder of the data (i.e., images and labels) in the table.",
description = "Optional. Use this is if the paths to the images and labels in the table are relative.",
required = false )
public File dataRootFile;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public String toString()
{
List<String> lines = new ArrayList<>();

lines.add( "## Affine transformation: " + getName() );
lines.add( "Affine transformation: " + getName() );

String affineString = MoBIEHelper.print( parameters, 3 );

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public class OpenCollectionTableCommandTest
static { net.imagej.patcher.LegacyInjector.preinit(); }

@Test
public void simpleTable( )
public void blobsTable( )
{
final ImageJ imageJ = new ImageJ();
imageJ.ui().showUI();
Expand All @@ -22,6 +22,19 @@ public void simpleTable( )
command.run();
}


@Test
public void clemTable( )
{
final ImageJ imageJ = new ImageJ();
imageJ.ui().showUI();

OpenCollectionTableCommand command = new OpenCollectionTableCommand();
command.table = new File( "src/test/resources/collections/clem-table.txt" );
command.dataRoot = OpenCollectionTableCommand.DataRoot.PathsInTableAreAbsolute;
command.run();
}

@Test
public void gridTable( )
{
Expand All @@ -37,6 +50,6 @@ public void gridTable( )

public static void main( String[] args )
{
new OpenCollectionTableCommandTest().gridTable();
new OpenCollectionTableCommandTest().clemTable();
}
}
6 changes: 3 additions & 3 deletions src/test/resources/collections/clem-table.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
uri type affine color
https://s3.embl.de/yeast-clem/hela/images/ome-zarr/em-overview.ome.zarr intensities (-0.102, -0.971, 0, 483.043, -0.985, 0.119, 0, 487.003, 0, 0, 29.308, 0) white
https://raw.githubusercontent.com/mobie/clem-example-project/main/data/hela/images/bdv-n5-s3/fluorescence-a2-FMR-c2.xml intensities (-0.377, 0.951, 0, 193.574, 0.974, 0.359, 0, -39.55, 0, 0, 15.546, 0) green
uri view type affine color
https://s3.embl.de/yeast-clem/hela/images/ome-zarr/em-overview.ome.zarr CLEM intensities (-0.102, -0.971, 0, 483.043, -0.985, 0.119, 0, 487.003, 0, 0, 29.308, 0) white
https://raw.githubusercontent.com/mobie/clem-example-project/main/data/hela/images/bdv-n5-s3/fluorescence-a2-FMR-c2.xml CLEM intensities (-0.377, 0.951, 0, 193.574, 0.974, 0.359, 0, -39.55, 0, 0, 15.546, 0) green

0 comments on commit 9a0e954

Please sign in to comment.