Record Class AprilTagPoseEstimator.Params

java.lang.Object
java.lang.Record
frc.robot.subsystems.apriltagvision.AprilTagPoseEstimator.Params
Record Components:
fieldLengthMeters - field length for bounds checking in meters
fieldWidthMeters - field width for bounds checking in meters
maxAmbiguity - maximum dimensionless ambiguity for single-tag observations
linearStdDevBaseline - baseline standard deviation for x/y in meters at 1 meter with 1 tag
angularStdDevBaseline - baseline standard deviation for rotation in radians at 1 meter with 1 tag
maxTagDistanceMeters - maximum average tag distance in meters before rejection
maxPoseDeviationMeters - maximum deviation from odometry in meters before rejection
maxMultiTagAmbiguity - maximum ambiguity for multi-tag observations
maxZHeightMeters - maximum absolute Z height in meters for the estimated pose
ignoredTagIds - tag IDs to ignore during estimation
tagSwitchStdDevMultiplier - standard deviation multiplier when tag IDs change between frames
initialPoseAcceptanceCount - number of poses to accept without odometry deviation checking at startup, or 0 to disable
Enclosing class:
AprilTagPoseEstimator

public static record AprilTagPoseEstimator.Params(double fieldLengthMeters, double fieldWidthMeters, double maxAmbiguity, double linearStdDevBaseline, double angularStdDevBaseline, double maxTagDistanceMeters, double maxPoseDeviationMeters, double maxMultiTagAmbiguity, double maxZHeightMeters, int[] ignoredTagIds, double tagSwitchStdDevMultiplier, int initialPoseAcceptanceCount) extends Record
Parameters for pose estimation filtering and uncertainty calculation.
  • Constructor Details

    • Params

      public Params(double fieldLengthMeters, double fieldWidthMeters, double maxAmbiguity, double linearStdDevBaseline, double angularStdDevBaseline, double maxTagDistanceMeters, double maxPoseDeviationMeters, double maxMultiTagAmbiguity, double maxZHeightMeters, int[] ignoredTagIds, double tagSwitchStdDevMultiplier, int initialPoseAcceptanceCount)
      Creates an instance of a Params record class.
      Parameters:
      fieldLengthMeters - the value for the fieldLengthMeters record component
      fieldWidthMeters - the value for the fieldWidthMeters record component
      maxAmbiguity - the value for the maxAmbiguity record component
      linearStdDevBaseline - the value for the linearStdDevBaseline record component
      angularStdDevBaseline - the value for the angularStdDevBaseline record component
      maxTagDistanceMeters - the value for the maxTagDistanceMeters record component
      maxPoseDeviationMeters - the value for the maxPoseDeviationMeters record component
      maxMultiTagAmbiguity - the value for the maxMultiTagAmbiguity record component
      maxZHeightMeters - the value for the maxZHeightMeters record component
      ignoredTagIds - the value for the ignoredTagIds record component
      tagSwitchStdDevMultiplier - the value for the tagSwitchStdDevMultiplier record component
      initialPoseAcceptanceCount - the value for the initialPoseAcceptanceCount record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • fieldLengthMeters

      public double fieldLengthMeters()
      Returns the value of the fieldLengthMeters record component.
      Returns:
      the value of the fieldLengthMeters record component
    • fieldWidthMeters

      public double fieldWidthMeters()
      Returns the value of the fieldWidthMeters record component.
      Returns:
      the value of the fieldWidthMeters record component
    • maxAmbiguity

      public double maxAmbiguity()
      Returns the value of the maxAmbiguity record component.
      Returns:
      the value of the maxAmbiguity record component
    • linearStdDevBaseline

      public double linearStdDevBaseline()
      Returns the value of the linearStdDevBaseline record component.
      Returns:
      the value of the linearStdDevBaseline record component
    • angularStdDevBaseline

      public double angularStdDevBaseline()
      Returns the value of the angularStdDevBaseline record component.
      Returns:
      the value of the angularStdDevBaseline record component
    • maxTagDistanceMeters

      public double maxTagDistanceMeters()
      Returns the value of the maxTagDistanceMeters record component.
      Returns:
      the value of the maxTagDistanceMeters record component
    • maxPoseDeviationMeters

      public double maxPoseDeviationMeters()
      Returns the value of the maxPoseDeviationMeters record component.
      Returns:
      the value of the maxPoseDeviationMeters record component
    • maxMultiTagAmbiguity

      public double maxMultiTagAmbiguity()
      Returns the value of the maxMultiTagAmbiguity record component.
      Returns:
      the value of the maxMultiTagAmbiguity record component
    • maxZHeightMeters

      public double maxZHeightMeters()
      Returns the value of the maxZHeightMeters record component.
      Returns:
      the value of the maxZHeightMeters record component
    • ignoredTagIds

      public int[] ignoredTagIds()
      Returns the value of the ignoredTagIds record component.
      Returns:
      the value of the ignoredTagIds record component
    • tagSwitchStdDevMultiplier

      public double tagSwitchStdDevMultiplier()
      Returns the value of the tagSwitchStdDevMultiplier record component.
      Returns:
      the value of the tagSwitchStdDevMultiplier record component
    • initialPoseAcceptanceCount

      public int initialPoseAcceptanceCount()
      Returns the value of the initialPoseAcceptanceCount record component.
      Returns:
      the value of the initialPoseAcceptanceCount record component