Construction of Civil Drone Flight Trajectory Graph Based on Monitoring Data

In recent years, civil drones have become integral to various sectors, including aerial photography, agricultural management, and logistics. However, the rapid proliferation of civil drones has raised significant safety concerns, with numerous incidents reported globally. For instance, the Federal Aviation Administration documented hundreds of drone-related accidents within a short period, highlighting the urgent need for enhanced flight analysis and management systems. Traditional approaches often rely solely on flight trajectory data, which limits the comprehensive understanding of drone operations by ignoring contextual factors like weather conditions and technical specifications. To address these limitations, we propose a novel method for constructing a flight trajectory graph for civil drones by integrating multi-source monitoring data. This approach leverages entity-relationship extraction techniques to derive nodes, relationships, and attributes from trajectory data, technical parameters, and weather information, incorporating temporal relationships to capture the sequential nature of flight paths. The resulting graph is stored in a Neo4j graph database, enabling efficient querying and in-depth analysis of civil drone behaviors. Through experiments with real-world data, we demonstrate that our method not only facilitates a holistic view of flight characteristics but also outperforms traditional databases in aggregate, neighborhood search, and complex conditional queries.

The construction of knowledge graphs has gained traction in domains such as transportation and social networks due to their ability to integrate heterogeneous data sources. For example, previous research has applied graph-based methods to taxi trajectory data and maritime traffic, enabling semantic analysis and route extraction. Similarly, in the context of civil drones, knowledge graphs can unify disparate data types, such as flight paths and environmental factors, to reveal hidden patterns. Existing methods for graph construction include rule-based and machine learning approaches, with hybrid techniques often employed to balance accuracy and interpretability. In this work, we build upon these foundations by developing a structured framework for civil drone monitoring data, focusing on entity and relationship extraction that accounts for the temporal dynamics of flight operations. Our contributions include the formal definition of a flight trajectory graph, algorithms for node and relationship extraction, and a comprehensive evaluation of query efficiency, providing a scalable solution for managing civil drone activities.

We define the flight trajectory graph as a structured representation of civil drone operations, denoted as FG = (V, E, A), where V represents the set of entity nodes, E the set of edges (relationships), and A the set of attributes. The entity nodes are categorized into three types: flight trajectory nodes (F), weather nodes (W), and civil drone technical parameter nodes (U). Specifically, F = {f_s = (N^f_s, A^f_s) | s ∈ N, 1 ≤ s ≤ n}, where N^f_s is the name of the trajectory node (derived from latitude and longitude coordinates), and A^f_s includes attributes such as timestamp, ID, velocity, altitude, longitude, and latitude. Similarly, W = {w_p = (N^w_p, A^w_p) | p ∈ N, 1 ≤ p ≤ q}, with N^w_p based on climate conditions and A^w_p encompassing temperature, climate, wind speed, wind direction, visibility, and timestamp. Lastly, U = {u_i = (N^u_i, A^u_i) | i ∈ N, 1 ≤ i ≤ m}, where N^u_i is the civil drone ID and A^u_i includes type, endurance, range, ID, and model. Here, n, q, and m denote the number of trajectory, weather, and technical parameter nodes, respectively.

The relationships in the flight trajectory graph capture interactions between nodes, including both inter-type and intra-type connections. We identify two primary relationship types: ID-based and temporal relationships. The ID relationship, denoted as UF_ID, links civil drone technical parameter nodes to trajectory nodes based on matching ID attributes, indicating that a specific civil drone traverses a particular trajectory point. Temporal relationships include FW_T, which connects trajectory nodes to weather nodes when the absolute difference between their timestamps is below a threshold ε (e.g., 10 seconds), and FF_T, which establishes sequential order between trajectory nodes of the same civil drone based on timestamp comparisons. The attributes of these relationships are defined as follows: UF_ID has the attribute “CONNECTED_TO”, FW_T has “HAS_WEATHER”, and FF_T has “NEXT”.

To extract nodes and their attributes, we developed an algorithm that processes the structured datasets of flight trajectories, weather, and civil drone technical parameters. The algorithm initializes sets for nodes and attributes, iterates through each data source, and creates nodes using key identifiers (e.g., latitude-longitude pairs for trajectories, climate for weather, and ID for technical parameters). The attributes are then assigned to the respective nodes. For relationships, another algorithm checks conditions such as ID matches and temporal proximity to establish edges. The pseudocode for these algorithms is summarized in the following sections, with key formulas and tables provided for clarity.

The node and node attribute extraction algorithm can be formalized as follows: Let FS, WS, and US represent the sets of flight trajectory, weather, and civil drone technical parameter data, respectively. The algorithm outputs the node set V and attribute set A_v. It initializes V and A_v as empty sets, then processes each civil drone trajectory point f in FS to create a node with name (latitude, longitude) and attributes including timestamp, ID, velocity, altitude, longitude, and latitude. Similarly, for weather data w in WS, it creates a node named after the climate condition with attributes like temperature and wind speed. For technical parameters u in US, nodes are named using the civil drone ID, with attributes such as model and endurance. Finally, the algorithm combines all nodes and attributes into V and A_v.

In mathematical terms, the extraction process for a trajectory node f_s can be represented as:
$$f_s = (\text{latitude}_s, \text{longitude}_s) \quad \text{with} \quad A^f_s = \{\text{timestamp}_s, \text{ID}_s, \text{velocity}_s, \text{altitude}_s, \text{longitude}_s, \text{latitude}_s\}$$
Similarly, for a weather node w_p:
$$w_p = \text{climate}_p \quad \text{with} \quad A^w_p = \{\text{temperature}_p, \text{climate}_p, \text{wind speed}_p, \text{wind direction}_p, \text{visibility}_p, \text{timestamp}_p\}$$
And for a civil drone technical parameter node u_i:
$$u_i = \text{ID}_i \quad \text{with} \quad A^u_i = \{\text{type}_i, \text{endurance}_i, \text{range}_i, \text{ID}_i, \text{model}_i\}$$

The relationship and relationship attribute extraction algorithm takes the node sets F, W, and U as input and outputs the relationship set E and attribute set A_E. It initializes E and A_E as empty sets, then defines ΔT as the absolute difference between trajectory and weather timestamps. For each civil drone trajectory node f and technical parameter node u, if their IDs match, it establishes UF_ID relationships with the attribute “CONNECTED_TO”. Additionally, it iterates through trajectory nodes of the same civil drone to create FF_T relationships with the attribute “NEXT” when the timestamp of one node precedes another. For weather relationships, if ΔT < ε, it creates FW_T relationships with the attribute “HAS_WEATHER”. The algorithm consolidates all relationships and attributes into E and A_E.

The condition for temporal relationships can be expressed as:
$$\Delta T = |f.\text{attribute\_T} – w.\text{attribute\_T}| < \epsilon$$
where ε is a small positive real number, ensuring that weather conditions are associated with relevant trajectory points. For sequential trajectory relationships, the condition is:
$$f[a].\text{attribute\_T} < f[b].\text{attribute\_T}$$
indicating that trajectory node b occurs after node a.

To illustrate the data structure, we present tables summarizing the node types, attributes, and relationships. Table 1 outlines the flight trajectory data fields, Table 2 describes the weather data, and Table 3 details the civil drone technical parameters. Table 4 provides an example of duplicate trajectory data, highlighting the need for data cleaning, while Table 5 summarizes all node and relationship types with their attributes. Table 6 shows the counts of nodes, relationships, and attributes in the constructed graph.

Table 1: Civil Drone Flight Trajectory Data Fields
Data Field Data Type Description
id string Civil drone ID
longitude float Longitude coordinate
latitude float Latitude coordinate
altitude float Altitude above sea level
velocity float Flight velocity
timestamp datetime Time of recording
Table 2: Weather Data Fields
Data Field Data Type Description
temperature float Ambient temperature
climate string Weather condition (e.g., sunny)
wind speed float Wind velocity
wind direction float Wind direction in degrees
visibility float Visibility range
timestamp datetime Time of weather recording
Table 3: Civil Drone Technical Parameter Data Fields
Data Field Data Type Description
id string Civil drone ID
type string Drone type (e.g., multirotor)
endurance float Maximum flight duration
range float Maximum flight distance
model string Drone model name
Table 4: Example of Duplicate Civil Drone Trajectory Data
Index Timestamp Longitude Latitude Altitude
129 1681887215881 120.0569628563 30.3212268258 9.9
130 1681887215881 120.0569628761 30.3212268389 9.9
131 1681887217881 120.0570821667 30.3213506667 32.7
Table 5: Summary of Nodes, Relationships, and Attributes
Element Type Description
Node Trajectory Named using latitude and longitude
Node Weather Named using climate condition
Node Civil Drone Technical Parameters Named using civil drone ID
Node Attribute Trajectory Attributes Timestamp, ID, velocity, altitude, longitude, latitude
Node Attribute Weather Attributes Temperature, climate, wind speed, wind direction, visibility, timestamp
Node Attribute Civil Drone Technical Parameter Attributes Type, endurance, range, ID, model
Relationship ID Relationship (UF_ID) Links civil drone to trajectory points
Relationship Temporal Relationship (FW_T) Connects trajectory to weather based on time
Relationship Temporal Relationship (FF_T) Establishes sequence between trajectory points
Relationship Attribute ID Relationship Attribute “CONNECTED_TO”
Relationship Attribute Weather Temporal Attribute “HAS_WEATHER”
Relationship Attribute Trajectory Temporal Attribute “NEXT”
Table 6: Counts of Nodes, Relationships, and Attributes
Element Type Count
Node Trajectory 14,920
Node Weather 1,520
Node Civil Drone Technical Parameters 41
Relationship ID Relationship (UF_ID) 44,760
Relationship Temporal Relationship (FF_T and FW_T) 143,851
Attribute Node Attributes Combined from all nodes
Attribute Relationship Attributes Associated with each relationship type

For data preprocessing, we addressed issues such as missing values and duplicates in the civil drone trajectory data. Fields with low missing rates were filled based on adjacent data points, while high-missing-rate fields of low importance were discarded. Critical fields with high missing rates were handled using interpolation techniques. Duplicate entries, often caused by civil drone hovering, were identified and removed by comparing timestamps, longitude, latitude, and altitude, with duplicates defined as points having identical coordinates up to seven decimal places.

The overall workflow for constructing the civil drone flight trajectory graph begins with data integration from trajectory, weather, and technical parameter sources. After preprocessing, the node and relationship extraction algorithms are applied, and the graph is stored in a Neo4j database. This allows for advanced querying and analysis of civil drone flight patterns. The process is depicted in the following diagram, which illustrates the flow from data collection to graph storage and querying.

In our experiments, we utilized a dataset collected from civil drone operations conducted between August and December 2022 in a campus airspace. The data encompassed flight paths of 10 different civil drone models under varying weather conditions, including temperature, wind speed, and climate types such as sunny and rainy. The trajectory data included parameters like velocity, altitude, and timestamps, while weather data was obtained via API calls. Technical parameters for each civil drone model were sourced from manufacturer specifications. After cleaning, the dataset was used to construct the flight trajectory graph, with nodes and relationships populated as described.

The graph storage was implemented on a system with an Intel Core i7-12700H CPU, RTX3070 GPU, 32 GB RAM, and Windows 10, using Neo4j for graph database management. Python libraries such as Pandas and NumPy facilitated data processing, while py2neo enabled interaction with Neo4j. The resulting graph contained thousands of nodes and relationships, as summarized in Table 6. Visualization through Neo4j’s interface allowed for intuitive exploration of civil drone trajectories, as shown in the inserted image, which depicts a sample flight path with connected trajectory, weather, and technical parameter nodes.

To demonstrate the utility of the civil drone flight trajectory graph, we executed several query examples using Cypher, Neo4j’s query language. For instance, we generated a subgraph for specific weather conditions, such as sunny skies with wind force level 4, by matching trajectory nodes connected to weather nodes with the corresponding attributes. This query revealed all civil drone paths under those conditions, aiding in the analysis of weather impact on flight operations. Another query involved constraints on altitude and velocity, retrieving trajectory nodes where altitude exceeded 300 meters and velocity was above 20 m/s. This enabled the identification of high-performance civil drone behaviors, supporting optimized mission planning.

The query efficiency of the Neo4j-based graph was evaluated against traditional databases like MySQL and Redis. We created five datasets by randomly selecting 20% to 100% of the civil drone technical parameter data and matching it with trajectory and weather data. For each dataset, we measured the average response time over 30 queries for basic, aggregate, neighborhood search, and complex conditional queries. The results showed that while MySQL and Redis performed well in basic queries, Neo4j excelled in complex queries, such as those involving multiple conditions and relationships. For example, in aggregate queries, Neo4j maintained stable response times under 10 ms, whereas MySQL and Redis exhibited fluctuations. In neighborhood search queries, Neo4j’s response times were consistently lower, and for complex conditional queries, Neo4j achieved response times below 15 ms, compared to over 40 ms for the others. This highlights the advantage of graph databases for managing interconnected civil drone data.

The efficiency comparison can be quantified using the following formula for average response time:
$$\text{Average Response Time} = \frac{1}{N} \sum_{i=1}^{N} T_i$$
where \(T_i\) is the response time for the i-th query, and N = 30. The results confirmed that Neo4j outperforms traditional databases in handling the graph-based structure of civil drone monitoring data.

In conclusion, our method for constructing a civil drone flight trajectory graph effectively integrates multi-source monitoring data, enabling comprehensive analysis and efficient querying. By incorporating temporal relationships and leveraging graph database capabilities, we address the limitations of traditional approaches that focus solely on trajectory data. The experiments validate the method’s practicality, showing enhanced query performance and insightful pattern discovery. Future work will expand the data sources to include heterogeneous information, such as aerial images and geographic data, and explore advanced graph algorithms for deeper insights into civil drone behaviors. This approach lays a foundation for improved safety and management in the rapidly evolving domain of civil drone operations.

Scroll to Top