Class BrightestStars

All Implemented Interfaces:

public class BrightestStars extends Object implements IAggregationAlgorithm
  • Constructor Details

    • BrightestStars

      public BrightestStars(int maxDepth, int maxPart, int minPart, boolean discard)
      Constructor using fields
      maxDepth - Maximum depth of the octree
      maxPart - Number of objects in the densest node of this level
      minPart - Number of objects below which we do not further break the octree
      discard - Whether to discard stars due to density or not
  • Method Details

    • sample

      public boolean sample(List<IParticleRecord> inputStars, OctreeNode octant, float percentage)
      Description copied from interface: IAggregationAlgorithm
      Creates the sub-sample from the given input stars. All these stars should be in the box defined by the center and the sizes.
      Specified by:
      sample in interface IAggregationAlgorithm
      inputStars - The actual stars that are inside the octant.
      octant - The octant that characterizes the box with its center, size and depth well set.
      percentage - The percentage of objects to be included in the octant.
      True if we are in a leaf.
    • getMaxPart

      public int getMaxPart()
      Description copied from interface: IAggregationAlgorithm
      Gets the maximum number of particles in a single node
      Specified by:
      getMaxPart in interface IAggregationAlgorithm
      maximum number of particles in a node
    • getDiscarded

      public int getDiscarded()
      Description copied from interface: IAggregationAlgorithm
      Returns the number of discarded stars by this algorithm so far.
      Specified by:
      getDiscarded in interface IAggregationAlgorithm
      The number of stars discarded.
    • getMaxDepth

      public int getMaxDepth()
      Description copied from interface: IAggregationAlgorithm
      Returns the max depth setting.
      Specified by:
      getMaxDepth in interface IAggregationAlgorithm
      The max depth