Commit 2cf0bdd2 authored by gonciarz's avatar gonciarz

Merge branch 'master' into develop

parents 6ae30bd9 ae3334a1
......@@ -7,7 +7,7 @@
<groupId>mosaic</groupId>
<artifactId>MosaicSuite</artifactId>
<packaging>jar</packaging>
<version>1.0.11</version>
<version>1.0.13</version>
<description>Package contains image processing algorithms developed in MOSAIC Group</description>
<url>http://mosaic.mpi-cbg.de/?q=downloads/imageJ</url>
<inceptionYear>2010</inceptionYear>
......@@ -118,7 +118,7 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
<!--<scope>compile</scope>-->
</dependency>
<dependency>
<groupId>io.scif</groupId>
......
......@@ -26,7 +26,7 @@ public class Particle {
public float nonParticleDiscriminationScore = 0;
// linking stuff
public boolean special = true; // a flag that is used while detecting and linking particles
public boolean special = true; // a flag that is pused while detecting and linking particles
public int[] next = null; // array that holds in position i the next particle number in frame i
public float distance = -1;
public float lx, ly, lz; // previous Linking x,y,z
......@@ -173,7 +173,42 @@ public class Particle {
public double getSize() {
return m0;
}
public void setm0(double aM) {
m0 = (float) aM;
}
public double getm0() {
return m0;
}
public void setm1(double aM) {
m1 = (float) aM;
}
public double getm1() {
return m1;
}
public void setm2(double aM) {
m2 = (float) aM;
}
public double getm2() {
return m2;
}
public void setm3(double aM) {
m3 = (float) aM;
}
public double getm3() {
return m3;
}
public void setm4(double aM) {
m4 = (float) aM;
}
public double getm4() {
return m4;
}
// ------------------------------------------------------------------------
// CSV definitions and setters/getters used when reading Squassh output
// TODO: this is terrible solution, it should be handled differently
......
......@@ -371,7 +371,7 @@ public class MosaicUtils {
final Cursor<T> img_c = B.cursor();
final RandomAccessibleInterval<T> view = Views.hyperSlice(A, B.numDimensions(), fix);
final Cursor<T> img_v = Views.iterable(view).cursor();
final Cursor<T> img_v = Views.flatIterable(view).cursor();
while (img_c.hasNext()) {
img_c.fwd();
......
......@@ -21,7 +21,6 @@ public class Utils {
*/
public static HistogramWindow plotHistogram(String aTitle, double[] aValues, int aNumOfBins) {
final FloatProcessor hist = new FloatProcessor(aValues.length, 1, aValues);
System.out.println("HISTOGRAM..");
return new ij.gui.HistogramWindow(aTitle, new ImagePlus(aTitle, hist), aNumOfBins);
}
......
......@@ -124,6 +124,13 @@ public class CSV<E> {
setDelimiter(';');
numOfColumns = tempNumOfColumns;
}
else {
tempNumOfColumns = map[0].split("\t").length;
if (tempNumOfColumns > 1) {
setDelimiter('\t');
numOfColumns = tempNumOfColumns;
}
}
}
}
catch (final IOException e) {
......
......@@ -195,7 +195,7 @@ public class ParticleTracker3DModular_Test extends CommonBase {
// Define test data
final String tcDirName = "ParticleTracker/LoadFromCsv/";
final String setupString = "run";
final String macroOptions = "csv test=" + tmpPath + "test.csv link=2 displacement=10 size=0 intensity=-1 dynamics=[Straight lines]";
final String macroOptions = "please=[CSV File] test=" + tmpPath + "test.csv link=2 displacement=10 size=0 intensity=-1 dynamics=[Straight lines]";
final String inputFile = null;
final String[] expectedImgFiles = {};
final String[] referenceImgFiles = {};
......
......@@ -4,11 +4,13 @@ import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Vector;
import org.junit.Before;
import org.junit.Test;
......@@ -16,6 +18,7 @@ import org.supercsv.cellprocessor.ParseDouble;
import org.supercsv.cellprocessor.ParseInt;
import org.supercsv.cellprocessor.ift.CellProcessor;
import mosaic.core.detection.Particle;
import mosaic.test.framework.CommonBase;
public class CSVTest extends CommonBase {
......
......@@ -50,10 +50,10 @@ null% Particles after non-particle discrimination (1 particles):
%% Trajectory 1
%% frame x (pixel) y (pixel) z (pixel) m0 m1 m2 m3 m4 s
0 13.310000 12.923000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
1 13.455000 12.993000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
2 13.409000 13.117000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
3 13.804000 13.222000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
4 14.299000 12.958000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
5 14.302000 13.096000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
0 13.310000 12.923000 0.000000 4.455000 1.643000 3.361000 7.678000 19.058001 0.000000
1 13.455000 12.993000 0.000000 5.049000 1.671000 3.464000 8.003000 20.021000 0.000000
2 13.409000 13.117000 0.000000 3.665000 1.651000 3.396000 7.800000 19.454000 0.000000
3 13.804000 13.222000 0.000000 4.198000 1.670000 3.488000 8.211000 21.221001 0.000000
4 14.299000 12.958000 0.000000 3.701000 1.666000 3.474000 8.169000 21.117001 0.000000
5 14.302000 13.096000 0.000000 4.074000 1.629000 3.293000 7.436000 18.308001 0.000000
,Trajectory,Frame,x,y,z,m0,m1,m2,m3,m4,NPscore
1,1,0,13.310,12.923,0,0,0,0,0,0,0
2,1,1,13.455,12.993,0,0,0,0,0,0,0
3,1,2,13.409,13.117,0,0,0,0,0,0,0
4,1,3,13.804,13.222,0,0,0,0,0,0,0
5,1,4,14.299,12.958,0,0,0,0,0,0,0
6,1,5,14.302,13.096,0,0,0,0,0,0,0
1,1,0,13.310,12.923,0,4.455,1.643,3.361,7.678,19.058,0
2,1,1,13.455,12.993,0,5.049,1.671,3.464,8.003,20.021,0
3,1,2,13.409,13.117,0,3.665,1.651,3.396,7.800,19.454,0
4,1,3,13.804,13.222,0,4.198,1.670,3.488,8.211,21.221,0
5,1,4,14.299,12.958,0,3.701,1.666,3.474,8.169,21.117,0
6,1,5,14.302,13.096,0,4.074,1.629,3.293,7.436,18.308,0
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment