Self-Supervised Monocular Depth and Pose Estimation for Endoscopy With Latent Priors