Class ImageLabelStrategy

Object
org.anchoranalysis.bean.AnchorBean<org.anchoranalysis.annotation.io.bean.AnnotatorStrategy>
org.anchoranalysis.annotation.io.bean.AnnotatorStrategy
org.anchoranalysis.plugin.annotation.bean.strategy.SinglePathStrategy
org.anchoranalysis.plugin.annotation.bean.strategy.ImageLabelStrategy

public class ImageLabelStrategy
extends SinglePathStrategy
Assigns a single label per image, as a whole.
Author:
Owen Feehan
  • Constructor Details

  • Method Details

    • annotationLabelFor

      public Optional<String> annotationLabelFor​(org.anchoranalysis.image.io.stack.input.ProvidesStackInput item, org.anchoranalysis.core.time.OperationContext context) throws org.anchoranalysis.core.exception.OperationFailedException
      Specified by:
      annotationLabelFor in class org.anchoranalysis.annotation.io.bean.AnnotatorStrategy
      Throws:
      org.anchoranalysis.core.exception.OperationFailedException
    • groupedLabels

      public GroupedAnnotationLabels groupedLabels()
      Creates a GroupedAnnotationLabels from the current labels.

      This is actually called twice during a typical opening of an annotation. But overhead is minor (assuming not very many labels).

      Returns:
      a new GroupedAnnotationLabels instance.
    • weightWidthDescription

      public int weightWidthDescription()
      Specified by:
      weightWidthDescription in class org.anchoranalysis.annotation.io.bean.AnnotatorStrategy
    • getLabels

      public List<AnnotationLabel> getLabels()
      List of AnnotationLabels available for annotation.
    • setLabels

      public void setLabels​(List<AnnotationLabel> labels)
      List of AnnotationLabels available for annotation.
    • getWeightWidthDescription

      public int getWeightWidthDescription()
      The weight to use for the width of the description.
    • setWeightWidthDescription

      public void setWeightWidthDescription​(int weightWidthDescription)
      The weight to use for the width of the description.