Class AlgorithmFaceAnonymizerBET.BitSetUtility

java.lang.Object
gov.nih.mipav.model.algorithms.AlgorithmFaceAnonymizerBET.BitSetUtility
Enclosing class:
AlgorithmFaceAnonymizerBET

private class AlgorithmFaceAnonymizerBET.BitSetUtility extends Object
Private utility class for operations on BitSets
Author:
senseneyj
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) static final int
     
    (package private) static final int
     
    (package private) static final int
     
    (package private) static final int
     
    (package private) static final int
     
    (package private) static final int
     
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
     
  • Method Summary

    Modifier and Type
    Method
    Description
    (package private) BitSet
    connectNearNeighbors(int loc, BitSet connectingRegion, int maxNeighborDistance)
    Set elements of the returned BitSet meet at least one of the following criteria: Element is set in connectingRegion. Walking up, down, right, and/or left from loc to this element requires less than or equal to maxNeighborDistance steps.
    (package private) BitSet
    connectNearNeighbors(int loc, BitSet connectingRegion, BitSet connectingRegionCopy, int maxNeighborDistance)
    A helper method for connectNearNeighbors(int, BitSet, int) that allows faster copies
    private boolean
    connectNearNeighborsUtil(int loc, BitSet connectingRegion, BitSet connectingRegionCopy, int level, int dir, int levelCut)
     
    private Vector<Point3D>
     
    (package private) int
    getBoundaryCode(BitSet set, int value)
     
    (package private) BitSet
    Finds the points of the given BitSet which has at least one neighbor (not including diagonals) not in the BitSet.
    (package private) float
    getMinDistance(int value, BitSet set)
    Calculates the distance between the closest point in this BitSet and the given value.
    (package private) float
    getMinDistance(int value, Vector<Point3D> setPoints)
    Calculates the distance between the closest point in this Vector and the given value.
    (package private) boolean
    isBoundaryPoint(BitSet set, int value)
     
    (package private) boolean
    isInScan(int value)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • BitSetUtility

      private BitSetUtility()
  • Method Details

    • getMinDistance

      float getMinDistance(int value, BitSet set)
      Calculates the distance between the closest point in this BitSet and the given value.
    • getMinDistance

      float getMinDistance(int value, Vector<Point3D> setPoints)
      Calculates the distance between the closest point in this Vector and the given value.
    • getEdgePoints

      BitSet getEdgePoints(BitSet set)
      Finds the points of the given BitSet which has at least one neighbor (not including diagonals) not in the BitSet.
    • isBoundaryPoint

      boolean isBoundaryPoint(BitSet set, int value)
    • getBoundaryCode

      int getBoundaryCode(BitSet set, int value)
    • isInScan

      boolean isInScan(int value)
    • connectNearNeighbors

      BitSet connectNearNeighbors(int loc, BitSet connectingRegion, int maxNeighborDistance)
      Set elements of the returned BitSet meet at least one of the following criteria:
      1. Element is set in connectingRegion.
      2. Walking up, down, right, and/or left from loc to this element requires less than or equal to maxNeighborDistance steps.
    • connectNearNeighbors

      BitSet connectNearNeighbors(int loc, BitSet connectingRegion, BitSet connectingRegionCopy, int maxNeighborDistance)
      A helper method for connectNearNeighbors(int, BitSet, int) that allows faster copies
    • connectNearNeighborsUtil

      private boolean connectNearNeighborsUtil(int loc, BitSet connectingRegion, BitSet connectingRegionCopy, int level, int dir, int levelCut)
    • convertSetToPoints

      private Vector<Point3D> convertSetToPoints(BitSet set)