## 1 Introduction  
Pipeline systems are critical infrastructures used to transport liquids and gases over long distances. Maintaining their integrity is essential to prevent failures that may lead to environmental damage and economic losses [1, 2, 3]. In-line inspection (ILI) plays a vital role in ensuring pipeline safety by identifying corrosion, cracks, and deformation [1, 2]. ILI utilizes an in-pipe robot equipped with various sensors, such as magnetic flux leakage, ultrasonic, electromagnetic acoustic transducer, caliper, and optical sensors, to record the pipe condition and navigate through the pipeline effectively [2, 4]. Two key functions of ILI robots are estimating their pose and measuring pipe diameter. Pose estimation refers to the estimation of the orientation and displacement of the robot inside the current pipe. It is different from the well-studied localization problem which finds the global location along the pipeline [5]. Accurate pose estimation is essential for precise robot control and spatial alignment during inspection. In addition to pose estimation, accurately determining pipe diameter is equally critical for ensuring inspection precision and assessing structural integrity. Diameter estimation addresses pipe deformations caused by manufacturing imperfections or non-uniform external pressures. Pipes are often approximated as elliptic cylinders, and diameter estimation involves measuring the major- and minor-axis lengths of their elliptical cross-sections. Pipe diameter serves as a key indicator of structural deformation and supports the calibration of sensor measurements with respect to orientation, displacement, and pipe geometry. The accurate estimation of robot pose and pipe diameter not only supports effective inspection but also improves robot control and sensor calibration, which are the main focus of this paper. To estimate robot pose and pipe diameter, existing approaches rely on structured light, 2D cameras, and stereo cameras. The first approach relies on analyzing the deformation of a light pattern to compute either robot pose or pipe diameter [6; 7; 8; 9; 10; 11]. This approach does not fully estimate robot pose and pipe diameter due to the lack of depth information. The second approach applies visual odometry on consecutive images from a 2D camera to determine robot pose [12; 13]. It relies on features extracted from the pipe inner surface. However, these features may become unclear or unreliable due to lighting conditions, dust, or reflective surfaces inside the pipeline, leading to matching errors and pose estimation failures. The third approach relies on a system of multiple stereo cameras [14; 15]. However, this method requires high processing costs for multiple cameras and also needs multiple frames to estimate robot pose and pipe diameter. On the other hand, 3D time-of-flight (ToF) sensors, such as lidar [16] or 3D ToF cameras [17], can preserve the full geometry of the pipe without requiring feature extraction or multi-frame processing. Therefore, we focus on solving the estimation problem using a single frame from a single 3D ToF camera. Despite their advantages compared to other approaches, 3D ToF sensors are susceptible to depth errors caused by factors such as infrared modulation inaccuracies, integration time variations, and temperature changes [18]. These errors are generally classified into outliers, depth biases, and random depth errors [19; 20; 21; 22]. While outliers can be removed by clustering the data [22] and depth biases can be compensated through sensor calibration [19; 20], random depth errors are typically corrected only for standstill sensors [21]. Although random depth errors may appear less significant, their impact on precision-demanding applications such as robot pose and pipe diameter estimation can result in substantial inaccuracies and inconsistencies. This paper specifically addresses the effect of random depth errors in the estimation of robot pose and pipe diameter.