There is an error-prone pattern in the code where users of a class have to remember to call a method on that class on a regular basis (usually via a periodic method). This includes
MultiPhotonPoseEstimator (publishCameraPosesRelativeTo() needs to be called
periodically, and needs to know the drive pose
PhotonVisionPosePublisher (needs to be called regularly with the recent estimates
from PhotonPoseEstimator or MultiPhotonPoseEstimator)
There was a comment about this in the Robot2025 version of MultiPhotonPoseEstimator.setDrivePose() (named `publishCameraPosesRelativeTo() in the lib2813 version):
TODO(vdikov): This method sits very counter-intuitively in this class. The class is
all about estimating pose and feeding it to the drive train pose estimation. Yet, this
method is feeding a drive-train pose back to it. The MultiPhotonPoseEstimator API
would become cleaner if we remove this method and find other ways to report Camera
poses. kcooney@ has provided several ideas on how we can address that with a better
class/interfaces architecture here: Prospect-Robotics/Robot2025#157 (comment)
More comments are here
There is an error-prone pattern in the code where users of a class have to remember to call a method on that class on a regular basis (usually via a periodic method). This includes
MultiPhotonPoseEstimator(publishCameraPosesRelativeTo()needs to be calledperiodically, and needs to know the drive pose
PhotonVisionPosePublisher(needs to be called regularly with the recent estimatesfrom
PhotonPoseEstimatororMultiPhotonPoseEstimator)There was a comment about this in the Robot2025 version of
MultiPhotonPoseEstimator.setDrivePose()(named `publishCameraPosesRelativeTo() in the lib2813 version):More comments are here