-
Notifications
You must be signed in to change notification settings - Fork 0
Description
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 posePhotonVisionPosePublisher(needs to be called regularly with the recent estimates
fromPhotonPoseEstimatororMultiPhotonPoseEstimator)
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-trainposeback 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