Class CompareAnnotations<T extends Assignment<ObjectMask>>

Object
AnchorBean<Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T>>>
Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T>>
CompareAnnotations<T>
Type Parameters:
T - assignment-type.

public class CompareAnnotations<T extends Assignment<ObjectMask>> extends Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T>>
Task to compare a set of annotations to a segmentation or another set of annotations.

The following outputs are produced:

Output NameDefault?Description
"byImage"yesa single CSV file showing summary statistics of matching for all images.
"byGroup"<T extends Assignment<ObjectMask>>yesa single CSV file showing summary statistics of matching for all groups group of images.
"outline"yesa file per image showing a colored representation of which annotations matched (or didn't) for each image.
outputs from the AnnotationComparisonAssigner in assign
outputs from Task
Author:
Owen Feehan
  • Field Details

    • OUTPUT_BY_GROUP

      public static final String OUTPUT_BY_GROUP
      Output name for the CSV file containing summary statistics for all groups of images.
      See Also:
  • Constructor Details

    • CompareAnnotations

      public CompareAnnotations()
  • Method Details

    • beforeAnyJobIsExecuted

      public ComparisonSharedState<T> beforeAnyJobIsExecuted(Outputter outputter, ConcurrencyPlan concurrencyPlan, List<AnnotationComparisonInput<ProvidesStackInput>> inputs, ParametersExperiment parameters) throws ExperimentExecutionException
      Specified by:
      beforeAnyJobIsExecuted in class Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T extends Assignment<ObjectMask>>>
      Throws:
      ExperimentExecutionException
    • doJobOnInput

      public void doJobOnInput(InputBound<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T>> input) throws JobExecutionException
      Specified by:
      doJobOnInput in class Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T extends Assignment<ObjectMask>>>
      Throws:
      JobExecutionException
    • inputTypesExpected

      public InputTypesExpected inputTypesExpected()
      Specified by:
      inputTypesExpected in class Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T extends Assignment<ObjectMask>>>
    • afterAllJobsAreExecuted

      public void afterAllJobsAreExecuted(ComparisonSharedState<T> sharedState, InputOutputContext context) throws ExperimentExecutionException
      Specified by:
      afterAllJobsAreExecuted in class Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T extends Assignment<ObjectMask>>>
      Throws:
      ExperimentExecutionException
    • hasVeryQuickPerInputExecution

      public boolean hasVeryQuickPerInputExecution()
      Specified by:
      hasVeryQuickPerInputExecution in class Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T extends Assignment<ObjectMask>>>
    • defaultOutputs

      public OutputEnabledMutable defaultOutputs()
      Overrides:
      defaultOutputs in class Task<AnnotationComparisonInput<ProvidesStackInput>, ComparisonSharedState<T extends Assignment<ObjectMask>>>
    • getBackground

      public String getBackground()
      The name of the stack to use as background to the annotations.
    • setBackground

      public void setBackground(String background)
      The name of the stack to use as background to the annotations.
    • getSplitIdentifierRegex

      public String getSplitIdentifierRegex()
      If non-empty, the string (a regular-expression) is used to split the file's identifier into groups.
    • setSplitIdentifierRegex

      public void setSplitIdentifierRegex(String splitIdentifierRegex)
      If non-empty, the string (a regular-expression) is used to split the file's identifier into groups.
    • getMaxSplitGroups

      public int getMaxSplitGroups()
      The maximum number of groups to split the identifier into.
    • setMaxSplitGroups

      public void setMaxSplitGroups(int maxSplitGroups)
      The maximum number of groups to split the identifier into.
    • getNumberLevelsGrouping

      public int getNumberLevelsGrouping()
      The number of levels for grouping.
    • setNumberLevelsGrouping

      public void setNumberLevelsGrouping(int numberLevelsGrouping)
      The number of levels for grouping.
    • isFlatten

      public boolean isFlatten()
      If true, a maximum-intensity-projection is first applied to any 3D objects into a 2D plane, before comparison.
    • setFlatten

      public void setFlatten(boolean flatten)
      If true, a maximum-intensity-projection is first applied to any 3D objects into a 2D plane, before comparison.
    • getOutlineWidth

      public int getOutlineWidth()
      How many pixels should the outline be around objects.
    • setOutlineWidth

      public void setOutlineWidth(int outlineWidth)
      How many pixels should the outline be around objects.
    • getAssigner

      public AnnotationComparisonAssigner<T> getAssigner()
      The assigner used for annotation comparison.
    • setAssigner

      public void setAssigner(AnnotationComparisonAssigner<T> assigner)
      The assigner used for annotation comparison.
    • isReplaceMatchesWithSolids

      public boolean isReplaceMatchesWithSolids()
      If true, matched objects are replaced with solid colors.
    • setReplaceMatchesWithSolids

      public void setReplaceMatchesWithSolids(boolean replaceMatchesWithSolids)
      If true, matched objects are replaced with solid colors.
    • getColorsUnpaired

      public ColorScheme getColorsUnpaired()
      The color scheme for unpaired objects.
    • setColorsUnpaired

      public void setColorsUnpaired(ColorScheme colorsUnpaired)
      The color scheme for unpaired objects.
    • getDisplayer

      public StackDisplayer getDisplayer()
      How to convert an image to be displayed to the user.
    • setDisplayer

      public void setDisplayer(StackDisplayer displayer)
      How to convert an image to be displayed to the user.