# 3D Positioning of Drones through Images
## 1 Introduction
Multi-sensor fusion methods for altitude determination have achieved good accuracy, but each individual sensor has its own limitations. Accelerometers and gyroscopes are low-cost and widely carried by UAVs, but the altitude they measure is obtained through double integration calculations, which leads to continuously accumulating errors that increase over time. Additionally, the vibrations of the UAV during movement affect the operation of accelerometers and gyroscopes. Barometers use pressure sensors to measure the altitude of the UAV during flight. Their advantages include relatively low cost and good real-time performance, providing immediate altitude data without complex data processing. However, barometers are affected by weather conditions (such as pressure changes, temperature variations, etc.). In conditions of significant pressure changes and extreme weather, the accuracy of barometers decreases. Moreover, barometers cannot provide absolute altitude. They only provide relative altitude information, i.e., height relative to ground atmospheric pressure. Therefore, in most application scenarios, they need to be combined with other altitude measurement techniques. Compared to accelerometers and barometers, GPS obtains altitude information through distance intersections without accumulating errors. However, GPS performs poorly in z-direction altitude measurement compared to its horizontal positioning accuracy. In the denial environment proposed in this paper, GPS signals face risks of interruption and loss. In this paper, we expanded the range of the dataset, with drone image capture heights ranging from 80 m to 200 m. Specific details will be introduced in Section 2.3. Considering that drone images at different altitudes have features of different natures, based on OS-FPI(An overall architecture for extracting UAV and satellite image features in a single channel. In Section 2.2, we will provide further introduction) [6], we designed a dual-stream network with multi-scale drone image input. After obtaining a drone image, we crop input 1 and input 2 of sizes 256 \(\times\) 256 and 152 \(\times\) 152, respectively, from the center point of the drone image, and interact them with the satellite image separately. The significance of this approach is that the smaller-sized satellite image represents low-altitude drone images with richer details, while the larger-sized satellite image represents high-altitude drone images with broader ground features. Multi-scale input has a good effect on solving localization when the drone altitude varies between 80 m and 200 m.  
In addition, we propose a method for assisting altitude estimation through image analysis. In ground images captured vertically downward by a UAV, if the actual ground distance between two points at a considerable distance in the image is known, the flight altitude can be calculated using the fixed parameters of the camera. Therefore, we crop a drone image into left and right halves, input them separately into the network, and calculate the latitude and longitude information of the center points of the left and right images, thereby obtaining the absolute ground distance represented by the original drone image. Finally, combined with camera parameters, we estimate the absolute altitude of the UAV above the ground. The contributions of this paper are summarized as follows:  
1. Based on the UL14 dataset [6], we added more drone images at various altitudes, expanding from 80 to 100 m to 80 to 200 m. We designed a dual-stream network with multi-scale drone image input, inputting two drone images with the same center point and using a cross-attention mechanism for the two inputs. This improved the model's generalization within the 80m-200m range, achieving the RDS metric of 76.3. 2. We proposed an image-assisted altitude determination method to compensate for the loss of z-direction GPS signals in denial environments. Within the 80-200 m range, the total error rate is 18.1%.