diff --git a/src/main/java/org/mastodon/mamut/tomancak/sort_tree/CellLifetimeOrder.java b/src/main/java/org/mastodon/mamut/tomancak/sort_tree/CellLifetimeOrder.java index 7ef29885..8d1dfbcc 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/sort_tree/CellLifetimeOrder.java +++ b/src/main/java/org/mastodon/mamut/tomancak/sort_tree/CellLifetimeOrder.java @@ -34,7 +34,7 @@ import org.mastodon.mamut.model.Link; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.BranchGraphUtils; +import org.mastodon.mamut.tomancak.trackmatching.BranchGraphUtils; /** * A sorting "order" for sorting the lineage tree in a {@link ModelGraph}. diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/BranchGraphUtils.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/BranchGraphUtils.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/BranchGraphUtils.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/BranchGraphUtils.java index 04de7bd3..1e263499 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/BranchGraphUtils.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/BranchGraphUtils.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import net.imglib2.util.Pair; import net.imglib2.util.ValuePair; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/ClosableLock.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/ClosableLock.java similarity index 96% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/ClosableLock.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/ClosableLock.java index e351eefd..b7cd3810 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/ClosableLock.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/ClosableLock.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; /** * Similar to {@link AutoCloseable}, but without the checked exception. diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/ComboBoxDialog.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/ComboBoxDialog.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/ComboBoxDialog.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/ComboBoxDialog.java index 03b7a313..f94c1eee 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/ComboBoxDialog.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/ComboBoxDialog.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.awt.Component; import java.util.Arrays; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageTreeUtils.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/LineageTreeUtils.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageTreeUtils.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/LineageTreeUtils.java index 29abbfe8..e2e186c3 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageTreeUtils.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/LineageTreeUtils.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.function.Predicate; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LockUtils.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/LockUtils.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LockUtils.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/LockUtils.java index 02f39bd6..4240ff32 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LockUtils.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/LockUtils.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.concurrent.locks.Lock; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RefCollectionUtils.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RefCollectionUtils.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RefCollectionUtils.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/RefCollectionUtils.java index 9d742868..392cd962 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RefCollectionUtils.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RefCollectionUtils.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.function.Predicate; import java.util.function.UnaryOperator; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RefMapUtils.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RefMapUtils.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RefMapUtils.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/RefMapUtils.java index 80847261..6d267e67 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RefMapUtils.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RefMapUtils.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.function.BiConsumer; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RegisteredGraphs.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RegisteredGraphs.java similarity index 93% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RegisteredGraphs.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/RegisteredGraphs.java index 7bd238ca..01dd8e3b 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RegisteredGraphs.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RegisteredGraphs.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import org.mastodon.RefPool; import org.mastodon.collection.RefDoubleMap; @@ -36,15 +36,15 @@ import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.InverseSpatialRegistration; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistration; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.InverseSpatialRegistration; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistration; /** *
* This datastructure holds two {@link ModelGraph}s and a mapping between them. *
*- * This is also the return type of {@link LineageRegistrationAlgorithm#run}. + * This is also the return type of {@link SpatialTrackMatchingAlgorithm#run}. *
*/ public class RegisteredGraphs diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RootsPairing.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RootsPairing.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RootsPairing.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/RootsPairing.java index 500a3329..00aed76e 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/RootsPairing.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/RootsPairing.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.HashSet; import java.util.Objects; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/SelectedProject.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SelectedProject.java similarity index 93% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/SelectedProject.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/SelectedProject.java index b3d67757..65d8940c 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/SelectedProject.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SelectedProject.java @@ -26,14 +26,14 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import org.mastodon.mamut.ProjectModel; import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; /** - * Used in {@link LineageRegistrationFrame} and {@link LineageRegistrationControlService} + * Used in {@link SpatialTrackMatchingFrame} and {@link SpatialTrackMatchingControlService} * to exchange information about the selected projects and related sittings. */ public class SelectedProject diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationAlgorithm.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingAlgorithm.java similarity index 90% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationAlgorithm.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingAlgorithm.java index e8e2a1d5..48fdfa35 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationAlgorithm.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingAlgorithm.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import net.imglib2.realtransform.AffineTransform3D; @@ -37,10 +37,10 @@ import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.NotEnoughPairedRootsException; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistration; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistrationFactory; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistrationMethod; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.NotEnoughPairedRootsException; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistration; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistrationFactory; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistrationMethod; import org.mastodon.mamut.tomancak.sort_tree.SortTreeUtils; /** @@ -50,7 +50,7 @@ * * @see SortTreeUtils#directionOfCellDevision(ModelGraph, Spot) */ -public class LineageRegistrationAlgorithm +public class SpatialTrackMatchingAlgorithm { private static final int TIME_OFFSET = SortTreeUtils.DIVISION_DIRECTION_TIME_OFFSET; @@ -71,7 +71,7 @@ public class LineageRegistrationAlgorithm private final RefDoubleMap< Spot > angles; /** - * Runs the lineage registration algorithm for to given graphs. The spots before + * Runs the spatial track matching for to given graphs. The spots before * the given timepoints are ignored. * * @return a {@link RegisteredGraphs} object that contains the two graphs and the @@ -117,7 +117,7 @@ private static NotEnoughPairedRootsException newDetailedNotEnoughPairedRootsExce public static RegisteredGraphs run( Model modelA, Model modelB, RefRefMap< Spot, Spot > roots, SpatialRegistration spatialRegistration ) { - LineageRegistrationAlgorithm algorithm = new LineageRegistrationAlgorithm( + SpatialTrackMatchingAlgorithm algorithm = new SpatialTrackMatchingAlgorithm( modelA.getGraph(), modelB.getGraph(), roots, spatialRegistration ); return new RegisteredGraphs( modelA, modelB, spatialRegistration, algorithm.getMapping(), algorithm.getAngles() ); @@ -128,7 +128,7 @@ private RefDoubleMap< Spot > getAngles() return angles; } - private LineageRegistrationAlgorithm( ModelGraph graphA, ModelGraph graphB, RefRefMap< Spot, Spot > roots, + private SpatialTrackMatchingAlgorithm( ModelGraph graphA, ModelGraph graphB, RefRefMap< Spot, Spot > roots, SpatialRegistration spatialRegistration ) { this.spatialRegistration = spatialRegistration; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationControlService.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingControlService.java similarity index 88% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationControlService.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingControlService.java index 08084a60..096ac044 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationControlService.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingControlService.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.ArrayList; import java.util.List; @@ -41,27 +41,27 @@ import org.mastodon.mamut.ProjectModel; import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.angle_feature.CellDivisionAngleFeature; -import org.mastodon.mamut.tomancak.lineage_registration.coupling.ModelCoupling; +import org.mastodon.mamut.tomancak.trackmatching.angle_feature.CellDivisionAngleFeature; +import org.mastodon.mamut.tomancak.trackmatching.coupling.ModelCoupling; import org.mastodon.model.tag.TagSetStructure; import org.scijava.plugin.Plugin; import org.scijava.service.AbstractService; /** - * This class is the controller for the {@link LineageRegistrationFrame}. + * This class is the controller for the {@link SpatialTrackMatchingFrame}. * It shows the dialog and performs the actions requested by the user. ** There should be only one instance of this class in the Fiji application. * This is ensured by making it an {@link ImageJService}. Being a service, - * allows the {@link LineageRegistrationPlugin} to access it, and to call + * allows the {@link SpatialTrackMatchingPlugin} to access it, and to call * {@link #registerMastodonInstance}. * * @author Matthias Arzt */ @Plugin( type = ImageJService.class ) -public class LineageRegistrationControlService extends AbstractService implements ImageJService +public class SpatialTrackMatchingControlService extends AbstractService implements ImageJService { - private LineageRegistrationFrame dialog = null; + private SpatialTrackMatchingFrame dialog = null; private final List< ProjectModel > projectModels = new ArrayList<>(); @@ -87,7 +87,7 @@ public synchronized void showDialog() return; } if ( dialog == null ) - dialog = new LineageRegistrationFrame( new Listener() ); + dialog = new SpatialTrackMatchingFrame( new Listener() ); dialog.setMastodonInstances( projectModels ); dialog.pack(); dialog.setVisible( true ); @@ -108,7 +108,7 @@ private static void executeTask( boolean writeLock, SelectedProject projectA, Se } ).start(); } - private class Listener implements LineageRegistrationFrame.Listener + private class Listener implements SpatialTrackMatchingFrame.Listener { private ModelCoupling coupling = null; @@ -132,7 +132,7 @@ private void sortSecondTrackScheme( SelectedProject project1, SelectedProject pr dialog.log( "Sort the order of the child cells in the TrackScheme of project \"%s\".", project1.getName() ); dialog.log( "Use project \"%s\" as reference...", project2.getName() ); RegisteredGraphs registration = runRegistrationAlgorithm( project1, project2 ); - LineageRegistrationUtils.sortSecondTrackSchemeToMatch( registration ); + SpatialTrackMatchingUtils.sortSecondTrackSchemeToMatch( registration ); project2.getProjectModel().getBranchGraphSync().sync(); project2.getModel().setUndoPoint(); dialog.log( "done." ); @@ -148,7 +148,7 @@ public void onColorLineagesClicked() dialog.clearLog(); dialog.log( "Create tag set \"lineages\" in project \"%s\"...", projectA.getName() ); dialog.log( "Create tag set \"lineages\" in project \"%s\"...", projectB.getName() ); - LineageColoring.tagLineages( + TrackColoring.tagLineages( projectA.getModel(), projectA.getFirstTimepoint(), projectB.getModel(), projectB.getFirstTimepoint() ); projectA.getModel().setUndoPoint(); @@ -176,7 +176,7 @@ private void copyLabelsFromTo( SelectedProject fromProject, SelectedProject toPr dialog.log( "Copy labels from project \"%s\" to project \"%s\"...", fromProject.getName(), toProject.getName() ); RegisteredGraphs registration = runRegistrationAlgorithm( fromProject, toProject ); - LineageRegistrationUtils.copySpotLabelsFromAtoB( registration ); + SpatialTrackMatchingUtils.copySpotLabelsFromAtoB( registration ); toProject.getModel().setUndoPoint(); dialog.log( "done." ); } ); @@ -222,7 +222,7 @@ private void copyTagSetFromTo( SelectedProject fromProject, SelectedProject toPr tagSet.getName(), fromProject.getName(), toProject.getName() ); String newTagSetName = tagSet.getName() + " (" + fromProject.getName() + ")"; RegisteredGraphs registration = runRegistrationAlgorithm( fromProject, toProject ); - LineageRegistrationUtils.copyTagSetToSecondModel( registration, tagSet, newTagSetName ); + SpatialTrackMatchingUtils.copyTagSetToSecondModel( registration, tagSet, newTagSetName ); toModel.setUndoPoint(); dialog.log( "done." ); } ); @@ -253,11 +253,11 @@ private void putTags( boolean modifyA, boolean modifyB ) executeTask( false, projectA, projectB, () -> { dialog.clearLog(); if ( modifyA ) - dialog.log( "Create tag set \"lineage registration\" in project \"%s\"...", projectA.getName() ); + dialog.log( "Create tag set \"spatial track matching\" in project \"%s\"...", projectA.getName() ); if ( modifyB ) - dialog.log( "Create tag set \"lineage registration\" in project \"%s\"...", projectB.getName() ); + dialog.log( "Create tag set \"spatial track matching\" in project \"%s\"...", projectB.getName() ); RegisteredGraphs registration = runRegistrationAlgorithm( projectA, projectB ); - LineageRegistrationUtils.tagCells( registration, modifyA, modifyB ); + SpatialTrackMatchingUtils.tagCells( registration, modifyA, modifyB ); if ( modifyA ) projectA.getModel().setUndoPoint(); if ( modifyB ) @@ -299,7 +299,7 @@ public void onPlotAnglesClicked() SelectedProject projectB = dialog.getProjectB(); RegisteredGraphs registeredGraphs = runRegistrationAlgorithm( projectA, projectB ); RefDoubleMap< Spot > anglesA = registeredGraphs.anglesA; - LineageRegistrationUtils.plotAngleAgainstTimepoint( anglesA ); + SpatialTrackMatchingUtils.plotAngleAgainstTimepoint( anglesA ); } @Override @@ -316,7 +316,7 @@ public void onAddAnglesFeatureClicked() private RegisteredGraphs runRegistrationAlgorithm( SelectedProject projectA, SelectedProject projectB ) { - return LineageRegistrationAlgorithm.run( + return SpatialTrackMatchingAlgorithm.run( projectA.getModel(), projectA.getFirstTimepoint(), projectB.getModel(), projectB.getFirstTimepoint(), dialog.getSpatialRegistrationMethod() ); diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationFrame.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingFrame.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationFrame.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingFrame.java index 1f7d86e0..34a054b9 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationFrame.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingFrame.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.text.NumberFormat; import java.util.ArrayList; @@ -52,13 +52,13 @@ import org.mastodon.app.ui.GroupLocksPanel; import org.mastodon.mamut.ProjectModel; import org.mastodon.mamut.io.project.MamutProject; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistrationMethod; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistrationMethod; /** - * Dialog for the {@link LineageRegistrationPlugin}. It allows to select two + * Dialog for the {@link SpatialTrackMatchingPlugin}. It allows to select two * {@link MamutProject}s and to perform various actions on them. */ -public class LineageRegistrationFrame extends JFrame +public class SpatialTrackMatchingFrame extends JFrame { private static final String FIRST_TIMEPOINT_TOOLTIP = "
" + "The first time point of a project to be used for the registration.- * The plugin interacts with the {@link LineageRegistrationControlService} to + * The plugin interacts with the {@link SpatialTrackMatchingControlService} to * register and unregister the {@link ProjectModel}s - * and to show the {@link LineageRegistrationFrame}. + * and to show the {@link SpatialTrackMatchingFrame}. */ @Plugin( type = MamutPlugin.class ) -public class LineageRegistrationPlugin implements MamutPlugin +public class SpatialTrackMatchingPlugin implements MamutPlugin { @Parameter - LineageRegistrationControlService lineageRegistrationControlService; + SpatialTrackMatchingControlService spatialTrackMatchingControlService; private static final String MATCH_TREE = "[tomancak] match tree to other project"; private static final String[] MATCH_TREE_KEYS = { "not mapped" }; private static final Map< String, String > menuTexts = - Collections.singletonMap( MATCH_TREE, "Lineage Registration" ); + Collections.singletonMap( MATCH_TREE, "Spatial Track Matching" ); @Plugin( type = CommandDescriptionProvider.class ) public static class Descriptions extends CommandDescriptionProvider @@ -87,7 +87,7 @@ public void getCommandDescriptions( CommandDescriptions descriptions ) private final AbstractNamedAction matchTreeAction; - public LineageRegistrationPlugin() + public SpatialTrackMatchingPlugin() { matchTreeAction = new RunnableAction( MATCH_TREE, this::matchTree ); } @@ -95,8 +95,8 @@ public LineageRegistrationPlugin() @Override public void setAppPluginModel( ProjectModel model ) { - lineageRegistrationControlService.registerMastodonInstance( model ); - model.projectClosedListeners().add( () -> lineageRegistrationControlService.unregisterMastodonInstance( model ) ); + spatialTrackMatchingControlService.registerMastodonInstance( model ); + model.projectClosedListeners().add( () -> spatialTrackMatchingControlService.unregisterMastodonInstance( model ) ); } @Override @@ -119,6 +119,6 @@ public void installGlobalActions( Actions actions ) private void matchTree() { - lineageRegistrationControlService.showDialog(); + spatialTrackMatchingControlService.showDialog(); } } diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationUtils.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingUtils.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationUtils.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingUtils.java index a6086eb4..6640c3ad 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationUtils.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingUtils.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.Arrays; import java.util.HashMap; @@ -58,9 +58,9 @@ /** * Utility class that implements most of the functionality - * provided by the {@link LineageRegistrationPlugin}. + * provided by the {@link SpatialTrackMatchingPlugin}. */ -public class LineageRegistrationUtils +public class SpatialTrackMatchingUtils { /** @@ -182,7 +182,7 @@ public static void tagCells( RegisteredGraphs result, boolean modifyA, boolean m private static void tagSpotsA( RegisteredGraphs result ) { - TagSetStructure.TagSet tagSet = TagSetUtils.addNewTagSetToModel( result.modelA, "lineage registration", Arrays.asList( + TagSetStructure.TagSet tagSet = TagSetUtils.addNewTagSetToModel( result.modelA, "spatial track matching", Arrays.asList( Pair.of( "not mapped", 0xff00ccff ), Pair.of( "flipped", 0xffeeaa00 ) ) ); diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageColoring.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/TrackColoring.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageColoring.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/TrackColoring.java index b6c4fb39..a2b24e1f 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/LineageColoring.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/TrackColoring.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.util.Collection; import java.util.HashMap; @@ -46,7 +46,7 @@ import org.mastodon.model.tag.TagSetStructure; import org.mastodon.util.TagSetUtils; -public class LineageColoring +public class TrackColoring { /** * Assigns a tag to the lineages in two models, model A and modelB: diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/angle_feature/CellDivisionAngleFeature.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/angle_feature/CellDivisionAngleFeature.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/angle_feature/CellDivisionAngleFeature.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/angle_feature/CellDivisionAngleFeature.java index 1ff70f41..d229c361 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/angle_feature/CellDivisionAngleFeature.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/angle_feature/CellDivisionAngleFeature.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.angle_feature; +package org.mastodon.mamut.tomancak.trackmatching.angle_feature; import java.util.Iterator; @@ -49,7 +49,7 @@ public class CellDivisionAngleFeature extends DoubleScalarFeature< Spot > private static final String KEY = "Cell division angle"; - public static final String INFO_STRING = "Result of the lineage registration algorithm: angle between paired cell division directions."; + public static final String INFO_STRING = "Result of the spatial track matching algorithm: angle between paired cell division directions."; public static final FeatureProjectionSpec PROJECTION_SPEC = new FeatureProjectionSpec( KEY, Dimension.ANGLE ); diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/angle_feature/CellDivisionAngleFeatureSerializer.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/angle_feature/CellDivisionAngleFeatureSerializer.java similarity index 96% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/angle_feature/CellDivisionAngleFeatureSerializer.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/angle_feature/CellDivisionAngleFeatureSerializer.java index e31cd54a..e74dbb6a 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/angle_feature/CellDivisionAngleFeatureSerializer.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/angle_feature/CellDivisionAngleFeatureSerializer.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.angle_feature; +package org.mastodon.mamut.tomancak.trackmatching.angle_feature; import org.mastodon.feature.DoubleScalarFeatureSerializer; import org.mastodon.feature.FeatureSpec; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/BranchMapCoupling.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/BranchMapCoupling.java similarity index 93% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/BranchMapCoupling.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/BranchMapCoupling.java index d784b240..af21334b 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/BranchMapCoupling.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/BranchMapCoupling.java @@ -26,15 +26,15 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import java.util.function.Consumer; import org.mastodon.collection.RefRefMap; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.BranchGraphUtils; -import org.mastodon.mamut.tomancak.lineage_registration.RegisteredGraphs; +import org.mastodon.mamut.tomancak.trackmatching.BranchGraphUtils; +import org.mastodon.mamut.tomancak.trackmatching.RegisteredGraphs; /** *
diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/FocusModelHook.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/FocusModelHook.java similarity index 96% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/FocusModelHook.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/FocusModelHook.java index a1c13bb1..f37f552b 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/FocusModelHook.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/FocusModelHook.java @@ -26,12 +26,11 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import java.util.function.Consumer; import org.mastodon.mamut.ProjectModel; -import org.mastodon.mamut.model.Link; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; import org.mastodon.model.FocusListener; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/GuardingHook.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/GuardingHook.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/GuardingHook.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/GuardingHook.java index 8ccbf553..69908d01 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/GuardingHook.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/GuardingHook.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import java.util.function.Consumer; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/HighlightModelHook.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/HighlightModelHook.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/HighlightModelHook.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/HighlightModelHook.java index 4a875c57..dd010357 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/HighlightModelHook.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/HighlightModelHook.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import java.util.function.Consumer; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/ModelCoupling.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/ModelCoupling.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/ModelCoupling.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/ModelCoupling.java index 2a6d19f4..40d98bb6 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/ModelCoupling.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/ModelCoupling.java @@ -26,10 +26,10 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import org.mastodon.mamut.ProjectModel; -import org.mastodon.mamut.tomancak.lineage_registration.RegisteredGraphs; +import org.mastodon.mamut.tomancak.trackmatching.RegisteredGraphs; import org.mastodon.model.FocusModel; import org.mastodon.model.HighlightModel; import org.mastodon.model.NavigationHandler; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/ModelHooks.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/ModelHooks.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/ModelHooks.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/ModelHooks.java index b9a9d844..9749b2af 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/ModelHooks.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/ModelHooks.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import org.mastodon.grouping.GroupHandle; import org.mastodon.mamut.ProjectModel; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/NavigationHandlerHook.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/NavigationHandlerHook.java similarity index 97% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/NavigationHandlerHook.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/NavigationHandlerHook.java index 0a0681fe..656ba2f8 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/NavigationHandlerHook.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/NavigationHandlerHook.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import java.util.function.Consumer; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/SpotHook.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/SpotHook.java similarity index 96% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/SpotHook.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/SpotHook.java index af89f8d3..38606de1 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/coupling/SpotHook.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/coupling/SpotHook.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.coupling; +package org.mastodon.mamut.tomancak.trackmatching.coupling; import java.util.function.Consumer; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/DynamicLandmarkRegistration.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/DynamicLandmarkRegistration.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/DynamicLandmarkRegistration.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/DynamicLandmarkRegistration.java index 5ea6a663..c31c1397 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/DynamicLandmarkRegistration.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/DynamicLandmarkRegistration.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import java.util.ArrayList; import java.util.Collection; @@ -48,7 +48,7 @@ import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.RefMapUtils; +import org.mastodon.mamut.tomancak.trackmatching.RefMapUtils; import org.mastodon.mamut.tomancak.sort_tree.SortTreeUtils; import org.mastodon.model.tag.TagSetStructure; import org.mastodon.util.TagSetUtils; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/EstimateTransformation.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/EstimateTransformation.java similarity index 98% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/EstimateTransformation.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/EstimateTransformation.java index 8b79b6cf..53961b14 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/EstimateTransformation.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/EstimateTransformation.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import java.util.ArrayList; import java.util.List; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/FixedSpatialRegistration.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/FixedSpatialRegistration.java similarity index 94% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/FixedSpatialRegistration.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/FixedSpatialRegistration.java index b37681ca..562d2eef 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/FixedSpatialRegistration.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/FixedSpatialRegistration.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import net.imglib2.realtransform.AffineTransform3D; @@ -35,8 +35,8 @@ import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.BranchGraphUtils; -import org.mastodon.mamut.tomancak.lineage_registration.RefMapUtils; +import org.mastodon.mamut.tomancak.trackmatching.BranchGraphUtils; +import org.mastodon.mamut.tomancak.trackmatching.RefMapUtils; public class FixedSpatialRegistration implements SpatialRegistration { diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/InverseSpatialRegistration.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/InverseSpatialRegistration.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/InverseSpatialRegistration.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/InverseSpatialRegistration.java index 767af077..bac6b3b9 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/InverseSpatialRegistration.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/InverseSpatialRegistration.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import net.imglib2.realtransform.AffineTransform3D; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/NotEnoughPairedRootsException.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/NotEnoughPairedRootsException.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/NotEnoughPairedRootsException.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/NotEnoughPairedRootsException.java index 16a9582c..2e128551 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/NotEnoughPairedRootsException.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/NotEnoughPairedRootsException.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; public class NotEnoughPairedRootsException extends RuntimeException { diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/NotEnoughPairedTagsException.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/NotEnoughPairedTagsException.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/NotEnoughPairedTagsException.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/NotEnoughPairedTagsException.java index 1f6c5db6..ac4d19a9 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/NotEnoughPairedTagsException.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/NotEnoughPairedTagsException.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; public class NotEnoughPairedTagsException extends RuntimeException { diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistration.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistration.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistration.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistration.java index 7d658bb2..acf6dec1 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistration.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistration.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import net.imglib2.realtransform.AffineTransform3D; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistrationFactory.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistrationFactory.java similarity index 95% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistrationFactory.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistrationFactory.java index d0b2ede2..5ea71d49 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistrationFactory.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistrationFactory.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import org.mastodon.collection.RefRefMap; import org.mastodon.mamut.model.Model; diff --git a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistrationMethod.java b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistrationMethod.java similarity index 96% rename from src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistrationMethod.java rename to src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistrationMethod.java index b6918f06..1388813f 100644 --- a/src/main/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/SpatialRegistrationMethod.java +++ b/src/main/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/SpatialRegistrationMethod.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; /** * An enum that can be used to select between different {@link SpatialRegistration} diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoA.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoA.java similarity index 95% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoA.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoA.java index f4a5bbf9..07c37227 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoA.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoA.java @@ -26,14 +26,14 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; /** - * Example data for testing {@link LineageRegistrationAlgorithm} and {@link LineageRegistrationUtils}. + * Example data for testing {@link SpatialTrackMatchingAlgorithm} and {@link SpatialTrackMatchingUtils}. *
* The graph {@link #graph} is a tree with three lineages, A, B and C. Each * lineage divides once. diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoB.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoB.java similarity index 93% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoB.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoB.java index 96b6dae5..b93abf38 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoB.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoB.java @@ -26,14 +26,14 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import net.imglib2.realtransform.AffineTransform3D; import org.mastodon.mamut.model.Spot; /** - * Example data for testing {@link LineageRegistrationAlgorithm} and {@link LineageRegistrationUtils}. + * Example data for testing {@link SpatialTrackMatchingAlgorithm} and {@link SpatialTrackMatchingUtils}. *
* Very similar to {@link EmbryoA}, but rotated 90 degrees around x-axis and * the positions of the spots B1 and B2 are flipped. diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoBSingleCellStage.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoBSingleCellStage.java similarity index 93% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoBSingleCellStage.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoBSingleCellStage.java index ef5123a4..61375fae 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/EmbryoBSingleCellStage.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/EmbryoBSingleCellStage.java @@ -26,12 +26,12 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import org.mastodon.mamut.model.Spot; /** - * Example data for testing {@link LineageRegistrationAlgorithm} and {@link LineageRegistrationUtils}. + * Example data for testing {@link SpatialTrackMatchingAlgorithm} and {@link SpatialTrackMatchingUtils}. * The graph and coordinates are the similar to {@link EmbryoB}, but the graph in this class has * additional spots abc, bc and beforeA, that are added to the graph before the first spots of {@link EmbryoB}. *
diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/RegisteredGraphsTest.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/RegisteredGraphsTest.java similarity index 96% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/RegisteredGraphsTest.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/RegisteredGraphsTest.java index e5ec78fa..595a0f5c 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/RegisteredGraphsTest.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/RegisteredGraphsTest.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -42,7 +42,7 @@ import org.mastodon.collection.ref.RefRefHashMap; import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistration; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistration; public class RegisteredGraphsTest { diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationAlgorithmTest.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingAlgorithmTest.java similarity index 90% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationAlgorithmTest.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingAlgorithmTest.java index c6503231..656931a8 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationAlgorithmTest.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingAlgorithmTest.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -43,9 +43,9 @@ import org.mastodon.collection.RefDoubleMap; import org.mastodon.collection.RefRefMap; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistrationMethod; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistrationMethod; -public class LineageRegistrationAlgorithmTest +public class SpatialTrackMatchingAlgorithmTest { private final List< String > expected = Arrays.asList( @@ -69,7 +69,7 @@ public void testRun() { EmbryoA embryoA = new EmbryoA(); EmbryoB embryoB = new EmbryoB(); - RegisteredGraphs result = LineageRegistrationAlgorithm.run( embryoA.model, 0, embryoB.model, 0, + RegisteredGraphs result = SpatialTrackMatchingAlgorithm.run( embryoA.model, 0, embryoB.model, 0, SpatialRegistrationMethod.FIXED_ROOTS ); assertEquals( expected, asStrings( result.mapAB ) ); assertEquals( expectedAngles, asStrings( result.anglesA ) ); @@ -80,7 +80,7 @@ public void testDifferentlyStagedEmbryos() { EmbryoA embryoA = new EmbryoA(); EmbryoBSingleCellStage embryoB = new EmbryoBSingleCellStage(); - RegisteredGraphs result = LineageRegistrationAlgorithm.run( embryoA.model, 0, embryoB.model, 2, + RegisteredGraphs result = SpatialTrackMatchingAlgorithm.run( embryoA.model, 0, embryoB.model, 2, SpatialRegistrationMethod.FIXED_ROOTS ); assertEquals( expected, asStrings( result.mapAB ) ); assertEquals( embryoB.beforeA, result.mapAB.get( embryoA.a ) ); diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationDemo.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingDemo.java similarity index 93% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationDemo.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingDemo.java index b60882cd..d42a037e 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationDemo.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingDemo.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import java.io.IOException; @@ -38,7 +38,7 @@ import mpicbg.spim.data.SpimDataException; -public class LineageRegistrationDemo +public class SpatialTrackMatchingDemo { public static final String project1 = "/home/arzt/Datasets/Mette/E1.mastodon"; @@ -49,7 +49,7 @@ public static void main( final String... args ) final Context context = new Context(); openAppModel( context, project1 ); openAppModel( context, project2 ); - context.service( LineageRegistrationControlService.class ).showDialog(); + context.service( SpatialTrackMatchingControlService.class ).showDialog(); } private static void openAppModel( final Context context, final String projectPath ) diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationUtilsTest.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingUtilsTest.java similarity index 88% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationUtilsTest.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingUtilsTest.java index 20c3cf4b..1c7a333d 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/LineageRegistrationUtilsTest.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/SpatialTrackMatchingUtilsTest.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration; +package org.mastodon.mamut.tomancak.trackmatching; import static org.junit.Assert.assertEquals; @@ -42,12 +42,12 @@ import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.spatial_registration.SpatialRegistrationMethod; +import org.mastodon.mamut.tomancak.trackmatching.spatial_registration.SpatialRegistrationMethod; import org.mastodon.model.tag.TagSetStructure; import org.mastodon.util.TagHelper; import org.mastodon.util.TagSetUtils; -public class LineageRegistrationUtilsTest +public class SpatialTrackMatchingUtilsTest { private EmbryoA embryoA; @@ -63,7 +63,7 @@ public void before() // NB: The graphs need to have at least 3 dividing lineages. // Only the root nodes of the dividing lineages are used // to calculate the affine transform between the two "embryos". - registration = LineageRegistrationAlgorithm.run( + registration = SpatialTrackMatchingAlgorithm.run( embryoA.model, 0, embryoB.model, 0, SpatialRegistrationMethod.FIXED_ROOTS ); @@ -75,7 +75,7 @@ public void testSortSecondTrackSchemeToMatch() assertEquals( embryoB.a1, firstChild( embryoB.graph, embryoB.a ) ); assertEquals( embryoB.b1, firstChild( embryoB.graph, embryoB.b ) ); assertEquals( embryoB.c1, firstChild( embryoB.graph, embryoB.c ) ); - LineageRegistrationUtils.sortSecondTrackSchemeToMatch( registration ); + SpatialTrackMatchingUtils.sortSecondTrackSchemeToMatch( registration ); assertEquals( embryoB.a1, firstChild( embryoB.graph, embryoB.a ) ); assertEquals( embryoB.c1, firstChild( embryoB.graph, embryoB.c ) ); assertEquals( embryoB.b2, firstChild( embryoB.graph, embryoB.b ) ); @@ -84,11 +84,11 @@ public void testSortSecondTrackSchemeToMatch() @Test public void testTagCells() { - LineageRegistrationUtils.tagCells( registration, true, true ); - assertEquals( Collections.emptySet(), getTaggedSpots( embryoA.model, "lineage registration", "not mapped" ) ); - assertEquals( set( "B1", "B2" ), getTaggedSpots( embryoA.model, "lineage registration", "flipped" ) ); - assertEquals( Collections.emptySet(), getTaggedSpots( embryoB.model, "lineage registration", "not mapped" ) ); - assertEquals( set( "B1", "B2" ), getTaggedSpots( embryoB.model, "lineage registration", "flipped" ) ); + SpatialTrackMatchingUtils.tagCells( registration, true, true ); + assertEquals( Collections.emptySet(), getTaggedSpots( embryoA.model, "spatial track matching", "not mapped" ) ); + assertEquals( set( "B1", "B2" ), getTaggedSpots( embryoA.model, "spatial track matching", "flipped" ) ); + assertEquals( Collections.emptySet(), getTaggedSpots( embryoB.model, "spatial track matching", "not mapped" ) ); + assertEquals( set( "B1", "B2" ), getTaggedSpots( embryoB.model, "spatial track matching", "flipped" ) ); } @Test @@ -107,7 +107,7 @@ public void testCopyTagSet() bar.tagBranch( embryoA.b1 ); bar.tagLink( embryoA.model.getGraph().getEdge( embryoA.bEnd, embryoA.b1 ) ); // process - LineageRegistrationUtils.copyTagSetToSecondModel( registration, tagSet, "new-tag-set" ); + SpatialTrackMatchingUtils.copyTagSetToSecondModel( registration, tagSet, "new-tag-set" ); // test: tag set for embryoB TagHelper fooB = new TagHelper( embryoB.model, "new-tag-set", "foo" ); TagHelper barB = new TagHelper( embryoB.model, "new-tag-set", "bar" ); @@ -123,7 +123,7 @@ public void testCopyLabels() for ( Spot spot : embryoA.graph.vertices() ) spot.setLabel( spot.getLabel() + "_test" ); // process - LineageRegistrationUtils.copySpotLabelsFromAtoB( registration ); + SpatialTrackMatchingUtils.copySpotLabelsFromAtoB( registration ); // test: labels for embryoB assertEquals( "A_test", embryoB.a.getLabel() ); assertEquals( "A_test", embryoB.a.outgoingEdges().get( 0 ).getTarget().getLabel() ); diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/DynamicLandmarkRegistrationTest.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/DynamicLandmarkRegistrationTest.java similarity index 93% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/DynamicLandmarkRegistrationTest.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/DynamicLandmarkRegistrationTest.java index f0e91caf..72c3b890 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/DynamicLandmarkRegistrationTest.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/DynamicLandmarkRegistrationTest.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -45,8 +45,8 @@ import org.mastodon.collection.ref.RefRefHashMap; import org.mastodon.mamut.model.ModelGraph; import org.mastodon.mamut.model.Spot; -import org.mastodon.mamut.tomancak.lineage_registration.LineageRegistrationAlgorithm; -import org.mastodon.mamut.tomancak.lineage_registration.RegisteredGraphs; +import org.mastodon.mamut.tomancak.trackmatching.SpatialTrackMatchingAlgorithm; +import org.mastodon.mamut.tomancak.trackmatching.RegisteredGraphs; import org.mastodon.mamut.tomancak.sort_tree.SortTreeUtils; import org.mastodon.model.tag.TagSetStructure; import org.mastodon.util.TagHelper; @@ -54,7 +54,7 @@ /** * Tests {@link DynamicLandmarkRegistration} and it's integration in the - * {@link LineageRegistrationAlgorithm}. + * {@link SpatialTrackMatchingAlgorithm}. */ public class DynamicLandmarkRegistrationTest { @@ -136,7 +136,7 @@ private static void addTags( ExampleEmbryo embryo ) @Test public void testLineageRegistrationAlgorithm() { - RegisteredGraphs result = LineageRegistrationAlgorithm.run( embryo1.model, 0, embryo2.model, 0, + RegisteredGraphs result = SpatialTrackMatchingAlgorithm.run( embryo1.model, 0, embryo2.model, 0, SpatialRegistrationMethod.DYNAMIC_ROOTS ); assertEquals( embryo2.c21, result.mapAB.get( embryo1.c21 ) ); assertEquals( embryo2.c22, result.mapAB.get( embryo1.c22 ) ); diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/EstimateTransformationTest.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/EstimateTransformationTest.java similarity index 97% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/EstimateTransformationTest.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/EstimateTransformationTest.java index 27bca2f3..2f3d9e29 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/EstimateTransformationTest.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/EstimateTransformationTest.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import static org.junit.Assert.assertArrayEquals; diff --git a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/ExampleEmbryo.java b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/ExampleEmbryo.java similarity index 97% rename from src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/ExampleEmbryo.java rename to src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/ExampleEmbryo.java index 5325c09f..97c044b3 100644 --- a/src/test/java/org/mastodon/mamut/tomancak/lineage_registration/spatial_registration/ExampleEmbryo.java +++ b/src/test/java/org/mastodon/mamut/tomancak/trackmatching/spatial_registration/ExampleEmbryo.java @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package org.mastodon.mamut.tomancak.lineage_registration.spatial_registration; +package org.mastodon.mamut.tomancak.trackmatching.spatial_registration; import org.mastodon.mamut.model.Model; import org.mastodon.mamut.model.ModelGraph;