Comprehensive management and analysis method and system for all data of bus system combined with big data

By collecting and analyzing bus terminal data, building a knowledge graph and optimizing the model, the problems of rigid scheduling strategies and response delays in the official vehicle management system were solved, and efficient operation and resource optimization of the bus system were achieved.

CN120430587BActive Publication Date: 2025-09-30GUIYANG JINYANG CONSTR DATA SERVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510921876.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-07-04
Publication Date
2025-09-30
Estimated Expiration
2045-07-04

AI Technical Summary

Technical Problem

The existing official vehicle management system relies on single-dimensional data analysis, resulting in a disconnect between scheduling strategies and actual conditions, an inability to dynamically respond to sudden tasks and traffic congestion, a separation between anomaly detection and scheduling decisions, and a lack of deep integration of historical and real-time data, leading to unbalanced resource allocation and task delays.

Method used

By collecting real-time operation data from multiple bus terminals, performing multi-dimensional feature extraction and anomaly detection, building a bus operation knowledge graph, calling a multi-task optimization model for dynamic path planning and resource allocation, generating a scheduling strategy, and optimizing the model based on feedback data to form a closed-loop management.

Benefits of technology

It achieves efficient allocation of bus resources, rapid response to abnormal events, dynamic optimization of scheduling strategies, improved operational efficiency and resource utilization, reduced the need for manual intervention, and adapts to complex traffic environments and emergency tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120430587B_ABST
    Figure CN120430587B_ABST
Patent Text Reader

Abstract

The present invention provides a comprehensive bus system data management and analysis method and system that integrates big data. The method includes: collecting real-time operation data sets uploaded by multiple bus terminals within a target area, performing multi-dimensional feature extraction to generate a bus operation feature set, and performing anomaly identification based on a preset anomaly detection model to determine a set of abnormal operation events; performing spatiotemporal correlation mapping between the bus operation feature set and a historical operation data set to construct a bus operation knowledge graph; performing dynamic path planning and resource allocation analysis on the graph to generate a set of target scheduling strategies, based on which the abnormal operation event set is prioritized, generating a set of bus scheduling optimization instructions, and issuing them to the corresponding bus terminals; and updating the weight parameters of the multi-task optimization model and the historical operation data set based on execution feedback data. The present invention can integrate multi-source real-time data and dynamically optimize scheduling strategies to solve the problems of data silos and policy rigidity.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing, and specifically to a method and system for comprehensive management and analysis of all data of a bus system combined with big data. Background Art

[0002] Currently, most government vehicle management systems rely primarily on manual scheduling and static rules for vehicle allocation, such as fixed route planning or simple task priority assignment. Existing technologies typically formulate scheduling strategies based on a single dimension of data, such as vehicle location or task time. For example, these strategies use GPS positioning data to determine vehicle idleness and assign tasks, or manually set priorities based on historical task records. While some systems incorporate basic data analysis capabilities, these are often limited to independent modules. For example, anomaly detection relies solely on threshold alarms, and resource allocation fails to consider real-time energy consumption fluctuations.

[0003] First, single-dimensional data analysis cannot fully reflect the vehicle's operating status, resulting in a disconnect between scheduling strategies and actual conditions. Second, static rules cannot dynamically respond to complex scenarios such as sudden tasks, traffic congestion, or vehicle failures, which can easily lead to imbalanced resource allocation or task delays. Third, anomaly detection is separated from scheduling decisions, and the root cause cannot be located in a timely manner through data correlation. For example, energy consumption anomalies may be caused by unreasonable route planning or vehicle failures, but existing systems find it difficult to distinguish. Finally, there is a lack of deep integration between historical data and real-time data, and model iteration relies on manual experience adjustment, resulting in delayed scheduling strategy optimization.

[0004] Therefore, the existing official vehicle management system urgently needs an intelligent management solution that can integrate multi-source real-time data, dynamically optimize scheduling strategies, and achieve rapid response to exceptions, in order to solve core problems such as data silos, policy rigidity, and response delays. Summary of the Invention

[0005] This application provides a method and system for comprehensive management and analysis of all data of a bus system combined with big data.

[0006] According to one aspect of the present application, a method for comprehensive management and analysis of all data of a bus system in combination with big data is provided, the method comprising:

[0007] Collecting real-time operation data sets uploaded by multiple bus terminals in the target area, the real-time operation data sets including vehicle location data, energy consumption data and task execution status data;

[0008] Performing multi-dimensional feature extraction on the real-time operation data set to generate a bus operation feature set, and performing anomaly identification on the bus operation feature set based on a preset anomaly detection model to determine an abnormal operation event set;

[0009] Performing spatiotemporal correlation mapping between the bus operation feature set and the historical operation data set to construct a bus operation knowledge graph, and calling a pre-trained multi-task optimization model to perform dynamic path planning and resource allocation analysis on the bus operation knowledge graph to generate a target scheduling strategy set;

[0010] Adjusting the priority of the abnormal operation event set according to the target scheduling strategy set, generating a bus scheduling optimization instruction set and issuing it to the corresponding bus terminal;

[0011] Based on the execution feedback data of the bus scheduling optimization instruction set, the weight parameters of the multi-task optimization model and the historical operation data set are updated.

[0012] According to another aspect of the present application, a computer system is provided, comprising:

[0013] at least one processor;

[0014] and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the above method.

[0015] This application has at least the following beneficial effects:

[0016] The present invention provides a comprehensive management and analysis method for the entire bus system data. By collecting operational data from multiple bus terminals in real time and extracting multi-dimensional features, the method combines an anomaly detection model to quickly identify abnormal events, construct a spatiotemporal bus operation knowledge graph, and invoke a multi-task optimization model to generate a dynamic scheduling strategy. Finally, the model and data are continuously optimized based on execution feedback, forming a closed-loop management system. In this way, the real-time operational data set can comprehensively reflect vehicle location, energy consumption, and task execution status. Multi-dimensional feature extraction can accurately capture high-frequency paths, energy consumption fluctuations, and changes in task efficiency. The anomaly detection model can quickly locate potential faults or inefficient operational events. The bus operation knowledge graph integrates historical and real-time data through spatiotemporal correlation mapping, providing a global perspective for path planning and resource allocation. The multi-task optimization model can generate scheduling strategies that adapt to complex scenarios through collaborative analysis of dynamic path planning and resource allocation. A model update mechanism based on abnormal event priority adjustment and feedback-driven optimization can optimize scheduling instructions in real time and improve the effectiveness of historical data. Through this closed-loop management process, the system enables efficient allocation of bus resources, rapid response to abnormal events, and dynamic optimization of dispatch strategies, thereby improving the bus system's operational efficiency, resource utilization, and task execution reliability. Furthermore, the combination of multi-dimensional data fusion and model self-learning significantly reduces the need for manual intervention and enhances the system's adaptability to complex traffic environments and unexpected tasks.

[0017] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present application, nor is it intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] The accompanying drawings illustrate exemplary embodiments and constitute a part of the specification. Together with the description of the specification, they serve to explain exemplary implementation of the embodiments. The illustrated embodiments are for illustrative purposes only and do not limit the scope of the claims. Throughout the drawings, the same reference numerals designate similar, but not necessarily identical, elements.

[0019] Figure 1 A schematic diagram of an application scenario of a method for comprehensive management and analysis of all data of a bus system combined with big data according to an embodiment of the present application is shown.

[0020] Figure 2 A flowchart of a method for comprehensive management and analysis of all data of a bus system combined with big data according to an embodiment of the present application is shown.

[0021] Figure 3 A schematic diagram of the composition of a computer system according to an embodiment of the present application is shown. DETAILED DESCRIPTION

[0022] The following description of exemplary embodiments of the present application is made in conjunction with the accompanying drawings, including various details of the embodiments of the present application to facilitate understanding, which should be considered as merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the embodiments described herein without departing from the scope of the present application. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0023] Figure 1 A schematic diagram of an application scenario according to an embodiment of the present application is shown, which includes one or more bus terminals 101 , a computer system 120 , and a communication network 110 for communicating between the bus terminals 101 and the computer system 120 .

[0024] In an embodiment of the present application, the computer system 120 may run one or more services or software applications that enable execution of a comprehensive management and analysis method for the entire bus system data in combination with big data.

[0025] Computer system 120 may include one or more general-purpose computers, dedicated server computers (e.g., PC (personal computer) servers, UNIX servers, mid-range servers), blade servers, mainframe computers, server clusters, or any other suitable arrangement and / or combination. Computer system 120 may include one or more virtual machines running virtual operating systems, or other computing architectures involving virtualization (e.g., one or more flexible pools of logical storage devices that may be virtualized to maintain a server's virtual storage device). In various embodiments, computer system 120 may run one or more services or software applications that provide the functionality described below.

[0026] The computing units in computer system 120 may run one or more operating systems including any of the operating systems described above as well as any commercially available server operating systems. Computer system 120 may also run any of a variety of additional server applications and / or middle-tier applications, including HTTP servers, FTP servers, CGI servers, JAVA servers, database servers, and the like.

[0027] In some embodiments, computer system 120 can be a server in a distributed system, or a server integrated with blockchain. Computer system 120 can also be a cloud server, or an intelligent cloud computing server or intelligent cloud host equipped with artificial intelligence technology. A cloud server is a host product within the cloud computing service system that addresses the management difficulties and poor business scalability of traditional physical hosts and virtual private servers (VPS) services.

[0028] The embodiment application scenario may also include one or more databases 130. In certain embodiments, these databases may be used to store data and other information. For example, one or more of the databases 130 may be used to store historical operational data. The databases 130 may reside in various locations. For example, the database used by the computer system 120 may be local to the computer system 120, or may be remote from the computer system 120 and may communicate with the computer system 120 via a network-based or dedicated connection. The databases 130 may be of different types. In certain embodiments, the databases used by the computer system 120 may be, for example, relational databases. One or more of these databases may store, update, and retrieve data to and from the databases in response to commands.

[0029] Please refer to Figure 2 , is a flowchart of a method for comprehensive management and analysis of all data of a bus system combined with big data provided in an embodiment of the present application, comprising the following steps:

[0030] Step 100: Collecting a real-time operation data set uploaded by multiple bus terminals in a target area, wherein the real-time operation data set includes vehicle location data, energy consumption data, and task execution status data.

[0031] The target area can refer to the geographic scope of the bus system, such as a city district or a specific transportation network coverage area. A bus terminal is a data collection and transmission device installed on a public vehicle. It integrates sensors, positioning modules, and communication modules to enable real-time data upload. Vehicle location data includes the vehicle's latitude and longitude coordinates in the Global Positioning System (GPS) coordinate system, travel direction, speed, and timestamp information, reflecting the vehicle's real-time spatial distribution and movement trajectory. Energy consumption data, including parameters such as fuel consumption, battery charge, electric motor power output, and energy recovery efficiency, quantifies the vehicle's energy use during operation. Mission execution status data includes the vehicle's current mission type (e.g., fixed-route operation, temporary shuttle mission, or emergency dispatch mission), mission progress percentage, deviation between planned and actual arrival times, and vehicle passenger capacity statistics. For example, in a certain city's bus system, the target area is divided into 12 operating grids, each containing 20 new energy buses. Each bus terminal uploads real-time operation data to the central server once per second. The vehicle location data is specifically expressed as a dynamic coordinate sequence of 39.9042 degrees north latitude and 116.4074 degrees east longitude. The energy consumption data includes a continuous record of the battery's remaining power dropping from 85% to 78%. The task execution status data includes the "subway shuttle line" task identifier that the vehicle is executing and the 73% task progress value that has been completed.

[0032] Step 200: Perform multi-dimensional feature extraction on the real-time operation data set to generate a bus operation feature set, and perform anomaly identification on the bus operation feature set based on a preset anomaly detection model to determine an abnormal operation event set.

[0033] Multidimensional feature extraction refers to the process of extracting structured features from raw data along three dimensions: time, space, and business attributes. Temporal dimension features include the average speed fluctuation rate of vehicles within a continuous time window, the gradient of energy consumption rate changes, and the regularity index of the task execution cycle; spatial dimension features include the Euclidean distance of vehicles deviating from the preset path, regional thermal distribution density, and the relative position relationship matrix between adjacent vehicles; and business attribute dimension features involve the matching degree between task type and energy consumption pattern, passenger efficiency ratio, and standard deviation of service punctuality. The bus operation feature set is a multidimensional data matrix formed by normalizing and vectorizing the above features. The preset anomaly detection model uses an unsupervised learning framework based on the isolation forest algorithm to determine abnormal events by calculating the anomaly score threshold of each feature vector. For example, when extracting features from a bus's energy consumption data, it was discovered that its battery voltage dropped sharply from 500 volts to 300 volts within 10 minutes, exceeding the normal fluctuation range by three standard deviations. This feature was marked as a high anomaly score. At the same time, the vehicle's location data showed that it entered the outer area of ​​the maintenance base during non-operating hours, and the spatial feature matched the historical trajectory pattern with a degree of match less than 0.2. The anomaly detection model identified this combined feature as an abnormal event of "suspected battery failure and illegal parking" and added it to the abnormal operation event set.

[0034] Step 300: Perform spatiotemporal correlation mapping on the bus operation feature set and the historical operation data set to construct a bus operation knowledge graph, and call a pre-trained multi-task optimization model to perform dynamic path planning and resource allocation analysis on the bus operation knowledge graph to generate a target scheduling strategy set.

[0035] Spatiotemporal correlation mapping aligns and correlates real-time feature data with historical operation records by timestamp and geographic location, forming a network structure that incorporates temporal dependencies and spatial topological relationships. For example, a bus operation knowledge graph uses vehicle entities as nodes and spatiotemporal interaction events between vehicles (such as station intersections and energy refueling collaboration) as edges. Vehicle attributes, task constraints, and environmental conditions are also added as node features. A pre-trained multi-task optimization model employs a graph neural network architecture to achieve multi-objective decision-making by jointly optimizing the path planning objective function and resource allocation constraints. For example, during the morning rush hour, a traffic accident in a certain area caused congestion on three main roads. The knowledge graph revealed that 15 buses were stranded in the area with battery life less than 40 kilometers. The multi-task optimization model first analyzes the real-time traffic flow graph and dynamically adjusts detour routes for affected vehicles. Second, based on the distribution of charging stations and the remaining range of the vehicles, it generates a resource allocation plan that prioritizes five low-battery vehicles to fast-charging stations within 3 kilometers. The model ultimately outputs a target scheduling policy set consisting of 32 route change instructions and 18 charging task assignments.

[0036] Step 400: Prioritize the abnormal operation event set according to the target scheduling strategy set, generate a bus scheduling optimization instruction set, and send it to the corresponding bus terminal.

[0037] Priority adjustment refers to the process of reordering the order in which abnormal events are handled based on the urgency, scope of impact, and resource consumption cost of the scheduling strategy. The bus scheduling optimization instruction set includes a vehicle redirection coordinate sequence, task interruption or restart instructions, energy supply reservation instructions, and collaborative scheduling protocols. For example, for the two types of abnormal events, "battery overheating warning" and "passenger detention timeout" that occur simultaneously, the target scheduling strategy determines that the latter involves a public safety risk and requires priority processing. The system generates an instruction to immediately dispatch the nearest empty vehicle to the detention site, and at the same time sends a command to the overheated vehicle to slow down and turn on the forced cooling mode. This instruction set is encrypted through a dedicated communication protocol and transmitted to the terminal control unit of the corresponding vehicle via the 5G network to ensure that the instruction delay is less than 200 milliseconds.

[0038] Step 500: Based on the execution feedback data of the bus scheduling optimization instruction set, the weight parameters of the multi-task optimization model and the historical operation data set are updated.

[0039] Execution feedback data includes the command response delay time, the degree of consistency between the vehicle's actual driving path and the planned path, resource utilization improvement indicators, and abnormal event resolution status codes. The model weight update adopts an online incremental learning mechanism, which backpropagates the error according to the difference between the feedback data and the expected target, and adjusts the attention weight and feature aggregation coefficient of the graph neural network. The historical operation data set is updated in a rolling manner by adding new data marked with timestamps, and a sliding window mechanism is used to remove expired data to ensure timeliness. For example, a detour instruction reduced the average vehicle delay by 8 minutes but increased energy consumption by 12%. The feedback data triggered the model to reduce the energy consumption weight coefficient in the path planning objective function from 0.6 to 0.55, and added 300 new samples containing the characteristics of this event to the historical database, covering all weekday data from September 2023 to March 2024.

[0040] As an embodiment, in step 200, performing multi-dimensional feature extraction on the real-time operation data set to generate a bus operation feature set includes:

[0041] Step 210: extracting the timestamp sequence and geographic coordinate sequence of the vehicle location data from the real-time operation data set, performing segmented aggregation processing on the timestamp sequence to generate a time window feature sequence, and performing trajectory clustering analysis on the geographic coordinate sequence to generate a high-frequency path feature set.

[0042] The timestamp sequence of vehicle location data refers to the collection of positioning time points uploaded by the bus terminal at a fixed collection frequency. For example, a bus generates a time identifier containing the year, month, day, hour, minute, and second every 10 seconds between 7:00 AM and 9:00 AM. A geographic coordinate sequence is a sequence of longitude and latitude value pairs collected by the Global Positioning System (GPS). For example, the geographic coordinate sequence recorded for a particular trip is [(116.4074°E, 39.9042°N), (116.4085°E, 39.9051°N), …, (116.4120°E, 39.9073°N)]. Segmented aggregation involves dividing continuous timestamps into multiple time intervals based on a preset window length. Within each interval, features such as the number of vehicle stops, standard deviation of travel distance, and average speed are calculated. For example, a 30-minute window is used to divide the timestamp sequence into six intervals. The trend value of the number of vehicle stops at intersections decreasing from 5 to 1 within each interval is calculated, generating a time window feature sequence [0.85, 0.72, 0.63, 0.58, 0.41, 0.33]. Trajectory clustering analysis uses the density-based spatial clustering of applications with noise (DBSCAN) algorithm to identify and classify recurring paths within a sequence of geographic coordinates. For example, from 300 historical trajectories, the path from subway station A to business district B, which appears more than 80% of the time during the morning rush hour, is identified and assigned to a high-frequency path feature set and a unique path code, P001.

[0043] Step 220: Perform energy consumption fluctuation detection on the energy consumption data, extract the energy consumption abnormal time period and the corresponding energy consumption deviation value of each bus terminal, and match the energy consumption abnormal time period with the time window feature sequence to generate an energy consumption related feature set.

[0044] Energy consumption fluctuation detection calculates the ratio of the standard deviation to the mean of energy consumption values ​​within a sliding window to identify abnormal fluctuations exceeding a preset threshold. For example, between 13:15 and 13:30, the battery output power of an electric bus suddenly increased from 50kW to 120kW. The standard deviation ratio reached 2.8, exceeding the threshold of 1.5, marking it as an abnormal energy consumption period. The energy consumption deviation value was the difference between the actual and predicted energy consumption of 85kWh. The generation of energy consumption-related feature sets requires aligning the abnormal period with the corresponding interval in the time window feature sequence. For example, if the abnormal period of 13:15-13:30 corresponds to the fourth window of the time window feature sequence, during which the average vehicle speed within the window suddenly dropped from 25km / h to 8km / h, the system associates this speed drop feature with the energy consumption deviation value, forming a multidimensional vector containing the time window index, the speed change gradient, and the energy consumption deviation value, which is then recorded in the energy consumption-related feature set.

[0045] Step 230: Match the task execution status data with a preset task type label to generate a task status coding sequence, and perform state transition analysis on the task status coding sequence to determine a task execution efficiency feature set.

[0046] Task execution status data includes fields such as task number, task start time, planned completion time, and actual completion time. Preset task type labels are defined according to operational management rules. For example, "regular line operation" is coded as T001, and "temporary connecting task" is coded as T002. Task state coding sequences are generated by matching task state descriptions in the raw data with a label library. For example, the morning task sequence for a vehicle is [T001_start, T001_running, T002_pending, T002_completed]. State transition analysis focuses on the transition patterns between task states. For example, the number of transitions from "standby" to "task executing" increases significantly during peak hours. By analyzing the frequency and duration of each state transition path, key transition nodes that affect efficiency are identified. The task execution efficiency feature set ultimately extracts metrics such as state transition success rate, average response time, and abnormal interruption rate. For example, during the evening peak hour, the average transition time from "T001 task completed to T002 task started" was reduced from 5 minutes to 3 minutes. This efficiency improvement feature was quantified as an efficiency index of 0.4 and included in the feature set.

[0047] Step 240: normalize the high-frequency path feature set, the energy consumption related feature set, and the task execution efficiency feature set, and fuse them to generate the bus operation feature set.

[0048] Normalization can use a minimum-maximum scaling method to map feature values ​​of different dimensions to the range [0, 1]. For example, the original path frequency values ​​in the high-frequency path feature set are [0.82, 0.75, 0.63], which are normalized to [1.0, 0.91, 0.77]. The energy consumption deviation value in the energy consumption correlation feature set is linearly transformed from 85 kWh to 0.93. The efficiency index of 0.4 in the task execution efficiency feature set is converted to 0.67. Feature fusion achieves dimensionality reduction through vector concatenation and principal component analysis (PCA). For example, the 12-dimensional feature vectors in three feature sets are reduced to 5-dimensional principal components, forming a data record in the bus operation feature set. Its numerical example is [0.92, 0.85, 0.78, 0.63, 0.41], representing abstract features such as path stability, energy efficiency, task switching speed, peak load, and abnormal event density, respectively.

[0049] As an embodiment, in step 230, performing state transition analysis on the task state coding sequence to determine a task execution efficiency feature set includes:

[0050] Step 231: Divide the task state code sequence into a plurality of continuous state transition subsequences according to a preset time window parameter, wherein each state transition subsequence contains a change record of the task state code within an adjacent time window.

[0051] For example, the time window parameter can be set to 15 minutes, and the task state coding sequence from 9:00 to 18:00 can be divided into 36 subsequences. Each subsequence records all state transition events within that period. For example, the fifth subsequence (9:00-9:15) contains the coding change chain [T001_start→T001_running→T001_completed→T002_pending], while the sixth subsequence (9:15-9:30) records the transition process [T002_pending→T002_running→T003_aborted].

[0052] Step 232: Count the conversion relationships between adjacent task state codes in each state transition subsequence to generate a state transition frequency distribution table corresponding to each state transition subsequence, wherein the state transition frequency distribution table records the jump times and jump directions between different task state codes.

[0053] The state transition frequency distribution table, for example, stores the frequency of state transitions in matrix form. For example, in the fifth subsequence, the transition from T001_running to T001_completed occurs once, and the transition from T001_completed to T002_pending occurs once. In the sixth subsequence, the transition from T002_pending to T002_running occurs once, and the transition from T002_running to T003_aborted occurs once. The distribution table also records the transition direction, such as forward transitions (task progress advances) and reverse transitions (task rollback or interruption).

[0054] Step 233: Calculate the transition frequency of the high-frequency jump path in each state transition subsequence according to the state transition frequency distribution table, and select a target jump path set that meets a preset frequency threshold based on the transition frequency.

[0055] The formula for calculating transition frequency is the number of jumps in a particular path divided by the total number of jumps in the subsequence. For example, in subsequence 5, the transition frequency of the path T001_running→T001_completed is 1 / 2 = 0.5. If the preset threshold is set to 0.3, this path is selected into the target jump path set. In the subsequence during the morning rush hour, the target jump path set may include high-frequency paths such as "T001_start→T001_running" (frequency 0.7) and "T001_running→T001_completed" (frequency 0.6).

[0056] Step 234: Extract the starting state code and the ending state code of each target jump path from the target jump path set, match the starting state code with the preset inefficient task state label to determine the inefficient path set, and match the ending state code with the preset efficient task state label to determine the efficient path set.

[0057] The default inefficient task status tags include T002_pending (task waiting timeout) and T003_aborted (task aborted); efficient task status tags include T001_completed (task completed normally) and T004_optimized (task optimized execution). For example, if the target jump path T002_pending → T004_optimized has the starting state T002_pending matched with the inefficient tag and the ending state T004_optimized matched with the efficient tag, this path will be added to both the inefficient and efficient path sets for subsequent analysis of the transition from inefficient to efficient.

[0058] Step 235: performing time window correlation analysis on the paths in the inefficient path set and the efficient path set, counting the success rate of conversion from inefficient paths to efficient paths in each time window, and generating a state conversion efficiency curve.

[0059] Time window correlation analysis calculates success rates at a granularity of one hour. For example, between 10:00 and 11:00, the system detected 12 transition attempts from the inefficient path's starting state to the efficient path's ending state, 9 of which were successful, for a success rate of 75%. The state transition efficiency curve uses time as the horizontal axis and success rate as the vertical axis, generating continuous curve data points, such as [9:00, 52%], [10:00, 75%], and [11:00, 68%], reflecting fluctuations in transition efficiency over time.

[0060] Step 236: Extract the task state coding combination corresponding to the peak efficiency period based on the fluctuation amplitude and trend direction of the state transition efficiency curve, map and match the task state coding combination with the preset efficiency evaluation template, and generate the task execution efficiency feature set.

[0061] The fluctuation amplitude is determined by calculating the first-order difference between adjacent points on the curve. For example, the fluctuation amplitude from 10:00 to 11:00 is -7%, indicating a downward trend in efficiency. Peak efficiency periods are defined as periods when the success rate is at least 10% higher than the historical average, for example, peaking at 75% between 10:00 and 10:30. The frequently occurring task state code combination during this period is [T001_running, T004_optimized], which matches the "Dual-Task Concurrency Optimization" mode in the efficiency evaluation template. The generated features include the duration of peak efficiency, the number of concurrent tasks, and resource utilization, forming the core indicators of the task execution efficiency feature set.

[0062] As an implementation method, in step 300, a pre-trained multi-task optimization model is called to perform dynamic path planning and resource allocation analysis on the bus operation knowledge graph to generate a target scheduling strategy set, including:

[0063] Step 310: Extract the spatiotemporal dependency relationship between bus nodes from the bus operation knowledge graph, construct a node association weight matrix, and generate an initial path planning set based on the node association weight matrix.

[0064] Spatiotemporal dependencies in the bus operation knowledge graph refer to the spatiotemporal interactions between vehicle nodes arising from task sequences, path overlap, or resource collaboration. For example, buses A and B need to refuel at the same charging station between 8:00 AM and 8:30 AM, forming a temporal dependency. Buses C and D have 80% trajectory overlap along the route from subway station X to commercial center Y, forming a spatial dependency. The node association weight matrix is ​​an N×N symmetric matrix (N is the total number of bus nodes). Matrix elements represent the strength of the dependency between two nodes. For example, the weight between bus A and the charging station node is 0.92, reflecting its dependency on energy refueling; the weight between bus C and bus D is 0.75, indicating the strength of the path coordination requirement. The initial path planning set is generated by traversing the high-weight connection edges in the node association weight matrix. For example, edges with weight values ​​greater than 0.8 are extracted from the matrix to form a set of 12 candidate paths including "Bus A → Charging Station Z → Bus B" and "Bus C → Subway Station X → Commercial Center Y". Each path is accompanied by a task execution time parameter (such as a 15-minute stay at the charging station and a 10-minute interval at the commercial center).

[0065] Step 320: Input the initial path planning set into the path optimization branch of the multi-task optimization model, and generate an optimized path candidate set through constraint screening and resource occupancy prediction.

[0066] The path optimization branch, for example, employs a deep learning architecture based on a graph attention mechanism to perform multi-dimensional constraint verification and resource consumption estimation on the initial path. The constraint set includes time window restrictions (e.g., charging station availability is 6:00 AM to 10:00 PM), vehicle capacity restrictions (e.g., a maximum passenger capacity of 80), and task urgency restrictions (e.g., medical transfer tasks must be responded to within 15 minutes). For example, the initial path "Bus E → Hospital P → Community Q" is retained due to Hospital P's stop window restriction (access is only permitted between 9:00 AM and 5:00 PM), while "Bus F → Industrial Zone R → Logistics Center S" is eliminated due to excessive passenger capacity (currently carrying 95 passengers). The resource usage prediction module uses a regression model to calculate the total energy consumption, time deviation value, and load fluctuation during path execution. For example, the predicted total energy consumption of the path "bus G→transportation hub T→scenic area U" is 145kWh, the time deviation value is ±3 minutes, and the load fluctuation range is [45 people, 78 people]. If the preset energy consumption threshold is 150kWh, the deviation threshold is 5 minutes, and the load stability range is [40 people, 80 people], then this path is added to the optimization path candidate set.

[0067] Step 330: Synchronously call the resource allocation branch of the multi-task optimization model, perform resource demand matching analysis on each path in the optimization path candidate set, and determine the resource allocation priority of each path.

[0068] The resource allocation branch, for example, employs a reinforcement learning strategy to match route resource requirements with available system resources in real time. Resource requirement type tags include energy supply type (fast charging / slow charging), human resource allocation (driver scheduling), and facility occupancy status (number of available maintenance stations). For example, the resource requirement type tag for the route "Bus H → Fast Charging Station V" is "Fast Charging Station Occupancy," with a demand intensity parameter of 2 stations / 30 minutes; the requirement type tag for the route "Bus I → Maintenance Center W" is "Senior Technician Support," with a demand intensity parameter of 1 technician / 2 hours. The currently available resource pool includes 8 fast charging stations, 15 slow charging stations, and 3 technicians. Resource availability is calculated by matching the requirement tags with the resource pool tags. For example, the fast charging demand availability for route H is 8 / 12 = 0.67, while the technician demand availability for route I is 3 / 5 = 0.6. The resource allocation priority scoring formula is: score = resource satisfiability × (1-demand intensity parameter / maximum intensity). For example, the score of path H is 0.67×(1-2 / 10)=0.536, and the score of path I is 0.6×(1-1 / 10)=0.54. Therefore, path I has a higher priority.

[0069] Step 340: Sort the optimization path candidate set according to the resource allocation priority, and select the path that meets the preset resource threshold as the target scheduling strategy set.

[0070] The preset resource threshold is set as resource availability ≥ 0.5 and a demand intensity parameter ≤ 70% of the system capacity. For example, in the set of optimized path candidates, path J has a resource availability of 0.58 and a demand intensity parameter of 4 charging stations / hour (the system capacity is 6 / hour), meeting the threshold conditions. Path K, with a availability of 0.45 and a demand intensity of 5 / hour, is eliminated due to insufficient availability. The sorting process combines the energy efficiency scores of the optimized path branches (for example, path L has an energy efficiency of 0.92) with the resource allocation priority scores (for example, path L has a priority of 0.61) to generate a comprehensive ranking list. The final target scheduling strategy set selects the top 10 paths with the highest comprehensive scores. For example, path M is included due to its energy efficiency of 0.88 and priority of 0.65. Dynamic adjustment instructions are also added, such as delaying the execution time of path M from 2:00 PM to 2:20 PM during peak charging station usage to match the resource release window.

[0071] As an embodiment, in steps 320 and 330, the initial path planning set is input into the path optimization branch of the multi-task optimization model, and a candidate set of optimized paths is generated through constraint screening and resource occupancy prediction; the resource allocation branch of the multi-task optimization model is simultaneously called to perform resource demand matching analysis on each path in the candidate set of optimized paths and determine the resource allocation priority of each path, which may include:

[0072] Step 321: Extract the spatiotemporal node sequence and the corresponding task execution time parameters of each path from the initial path planning set, match the spatiotemporal node sequence with the preset constraint condition set, and screen out a subset of candidate paths that meet the time window limit, vehicle capacity limit, and task urgency limit.

[0073] A spatiotemporal node sequence refers to the chronological combination of geographic nodes and task nodes within a path. For example, the sequence for path N is [Bus O → School A (8:00-8:15) → Community B (8:20-8:35) → Commercial Street C (8:40-9:00)]. Task execution time parameters include the tolerance between the planned stop duration and the actual arrival time at each node. When constraints are met, the system detects that School A's permitted stop window is 7:30-8:30, and the stop between 8:00 and 8:15 on path N meets this requirement. Furthermore, the vehicle capacity is limited to ≤60 passengers, while the real-time passenger capacity of path N is 55. Therefore, this path is added to the candidate path subset. Regarding task urgency constraints, if path P includes the "Emergency Supplies Transport" task and is required to be completed within 30 minutes, and its predicted execution time is 28 minutes, it passes the urgency verification.

[0074] Step 322: Perform resource occupancy prediction for each path in the candidate path subset, including predicting the total energy consumption required during path execution, task execution time deviation value, and vehicle load fluctuation range, and generate a resource occupancy prediction result for each path.

[0075] Resource utilization prediction uses a time series prediction model, with input parameters including historical energy consumption data, real-time traffic flow, and vehicle operating condition data. For example, the predicted total energy consumption for route Q (bus R → transportation hub D → airport E) is 132 kWh, calculated by multiplying the historical average energy consumption of 120 kWh by the current congestion factor by 1.1. The task execution time deviation is generated through Monte Carlo simulation, with a predicted value of +4 minutes (upper limit deviation). The vehicle load fluctuation range is based on real-time ticket sales data and analysis of passenger boarding and alighting hotspots, with the predicted passenger load fluctuating within the range of [38, 72]. Resource utilization prediction results are stored in a structured data format. For example, the prediction record for route Q is {total energy consumption: 132 kWh, time deviation: +4 minutes, load fluctuation: [38, 72]}, which is used for subsequent optimization decisions.

[0076] Step 323: Sort the candidate path subset based on the resource occupancy prediction result, select paths whose total energy consumption is lower than a preset energy consumption threshold, whose task execution time deviation value is less than a preset deviation threshold, and whose vehicle load fluctuation range is within a preset stable interval, and generate the optimized path candidate set.

[0077] The preset energy consumption threshold is set at 150 kWh, the deviation threshold is ±5 minutes, and the load stability interval is defined as passenger load fluctuations not exceeding ±15% of the rated capacity. For example, path S has a predicted energy consumption of 142 kWh, a deviation of -3 minutes, and a load fluctuation of [50, 82] (rated capacity 80 passengers, fluctuation range +2.5%), meeting all conditions and is ranked higher. Path T, with an energy consumption of 158 kWh, exceeds the threshold and is eliminated. The ranking algorithm combines weighted scores of the three indicators, for example, a weight of 0.5 for energy consumption, 0.3 for deviation, and 0.2 for load stability. Path U, with a total score of 0.87 (0.48 for energy consumption, 0.27 for deviation, and 0.12 for load), ranks first in the set of candidate optimization paths.

[0078] Step 331: Call the resource allocation branch, extract the resource demand type label and demand intensity parameter of each path from the optimized path candidate set, match the resource demand type label with the resource type label in the current available resource pool, and determine the resource satisfiability of each path.

[0079] Resource requirement type labels include discrete labels (such as "fast charging pile" and "maintenance station") and continuous labels (such as "driving staff time" and "power quota"). For example, the resource requirement type label for path V is {fast charging piles: 2, driving staff time: 1.5 hours}, and the demand intensity parameter is {fast charging piles: 2 / hour, driving staff time: 1.5 / 8}. The current available resource pool status is {fast charging piles: 5, driving staff time: 6 hours}. The fast charging pile satisfaction is 5 / 8 = 0.625, the driving staff time satisfaction is 6 / 10 = 0.6, and the overall resource satisfaction takes the minimum value of 0.6. For continuous resources, if path W requires a power quota of 300kW and the remaining power in the resource pool is 500kW, the satisfaction is 500 / 300 = 1.67, which is normalized to 1.0.

[0080] Step 332: Calculate the resource allocation priority score of each path based on the resource satisfiability and the demand intensity parameter, wherein a path with a high resource satisfiability and a low demand intensity parameter obtains a higher priority score.

[0081] The priority scoring formula is designed as: score = resource availability × (1 - demand intensity parameter / total resource pool capacity). For example, if route X has a resource availability of 0.8 and a demand intensity parameter of 3 fast charging stations (total resource pool capacity of 10), the score is 0.8 × (1 - 3 / 10) = 0.8 × 0.7 = 0.56. Route Y has a availability of 0.9 and a demand intensity of 2 stations (total capacity of 10), resulting in a score of 0.9 × 0.8 = 0.72, giving route Y a higher priority. For scenarios with multiple resource types, the scores are weighted averaged by resource type. For example, if route Z has a fast charging station score of 0.56 and a driver hour score of 0.65, with weights of 0.6 and 0.4, respectively, the overall score is 0.56 × 0.6 + 0.65 × 0.4 = 0.336 + 0.26 = 0.596.

[0082] Step 333: Perform weighted fusion of the resource allocation priority score and the path sorting result in the optimized path candidate set to generate a comprehensive priority list, and dynamically adjust the paths in the optimized path candidate set according to the comprehensive priority list to determine the final target scheduling strategy set.

[0083] Weighted fusion uses an entropy weighting method to determine the weight ratio between the path optimization branch and the resource allocation branch. For example, the path optimization branch's energy efficiency and time deviation metrics account for 70% of the weight, while the resource allocation priority score accounts for 30%. Path AA ranks third in the optimization branch ranking (score 0.85), with a resource branch score of 0.72. Its overall score is 0.85 × 0.7 + 0.72 × 0.3 = 0.595 + 0.216 = 0.811. Path BB ranks first in the optimization branch ranking (score 0.92), with a resource branch score of 0.65. Its overall score is 0.92 × 0.7 + 0.65 × 0.3 = 0.644 + 0.195 = 0.839, thus moving it to the top of the overall priority list. The dynamic adjustment module updates the list based on real-time resource changes. For example, when the number of charging piles decreases from 5 to 3, the resource availability of path CC drops from 0.6 to 0.3, triggering its removal from the target scheduling strategy set and its replacement by path DD. The final generated policy set contains 20 paths, each with an execution time, a resource usage list, and dynamic adjustment rules. For example, the instructions for path EE are "start at 14:00, occupy two fast charging piles, and switch to the backup path if no resources are obtained before 14:10."

[0084] As an implementation method, the training process of the multi-task optimization model may include the following steps:

[0085] Step 10: Obtain a historical bus operation data set and a corresponding annotated scheduling strategy set, perform spatiotemporal feature enhancement processing on the historical bus operation data set, and generate an enhanced training data set.

[0086] Historical bus operation datasets are structured data sets accumulated over time from bus terminals, including vehicle locations, energy consumption, mission status, and environmental conditions. For example, the operational records of a city's bus system from 2020 to 2023 cover 500 buses, 12 million trajectory data points, and corresponding dispatch instructions. The annotated dispatch strategy set is compiled by human experts based on historical event response records, such as the detour routes and emergency charging station allocation plans for 30 routes during the July 2022 rainstorm. Spatiotemporal feature enhancement utilizes both temporal and spatial interpolation strategies. Temporal interpolation linearly fills in missing data points. For example, the three missing locations of a vehicle between 10:00 and 10:15 due to GPS failure are supplemented by linearly calculating the latitude and longitude of the preceding and following timestamps. Spatial interpolation uses trajectory clustering to increase the density of sparse paths. For example, for the high-frequency route "Subway Station A to Commercial District B," the number of trajectory points increased from one every 10 seconds to one every 5 seconds. The enhanced training data set also introduces virtual event perturbations, such as superimposing ±10% random fluctuations in the normal energy consumption sequence to simulate the battery aging effect, generating a data set containing 8 million enhanced samples.

[0087] Step 20: Build the initial multi-task neural network and set the path optimization loss function and resource allocation loss function.

[0088] The initial multi-task neural network consists of a shared feature extraction layer, a path optimization branch, and a resource allocation branch. The shared feature extraction layer uses a hybrid structure of a bidirectional long short-term memory (BiLSTM) network and a convolutional neural network (CNN). For example, the BiLSTM layer processes time series dependencies, while the CNN layer extracts spatial topological features. The path optimization loss function is defined as the negative logarithm of the Jaccard similarity between the predicted path and the annotated path, calculated as:

[0089] Loss path =−log(|P pred ∩P gt ∣ / ∣P pred ∪P gt ∣),

[0090] Among them, P pred is the path node set output by the model, P gtis the set of labeled path nodes. The resource allocation loss function uses the weighted mean squared error (WMSE), which weights the prediction deviation of the resource type label according to the demand intensity. For example, the weight of the prediction error of the number of charging piles is 0.7, and the weight of the maintenance personnel allocation error is 0.3.

[0091] Step 30: Input the enhanced training data set into the initial multi-task neural network, and generate a predicted path set through the path optimization branch and a predicted resource allocation set through the resource allocation branch.

[0092] The input data format is a time-space feature matrix. For example, a single sample consists of a continuous one-hour sequence of vehicle trajectory points (3600 time steps), an energy consumption sequence, and a task state encoding. The path optimization branch outputs a probabilistic distribution of path nodes. For example, the predicted node probabilities for the path "Bus X → Charging Station Y → Bus Z" are [0.92, 0.85, 0.78], indicating the confidence level of each node in the selection. The predicted path set is generated through threshold screening (e.g., probability ≥ 0.8) and topology verification (e.g., path connectivity verification). For example, the output is a set of 15 feasible paths. The resource allocation branch outputs a multidimensional resource allocation vector. For example, if a route is predicted to require two fast-charging stations, 1.5 hours of driver time, and zero maintenance stations, this vector forms a record in the predicted resource allocation set.

[0093] Step 40: Calculate the path matching degree between the predicted path set and the marked scheduling strategy set, and generate a first gradient value of the path optimization loss function.

[0094] Path matching is evaluated jointly by node overlap and sequential consistency. The node overlap is calculated as the ratio of the number of nodes shared by the predicted and annotated paths to the total number of nodes in the annotated path. For example, if the predicted path contains 80% of the nodes in the annotated path, the node overlap is 0.8. Sequential consistency is measured using the Dynamic Time Warping (DTW) algorithm to measure the temporal alignment deviation of the node sequences of the two paths. For example, if the annotated path node sequence is [A, B, C, D] and the predicted path is [A, C, D], the DTW distance is 2. The first gradient of the path optimization loss function is calculated as the weighted derivative of the node overlap and the DTW distance. For example, if the node overlap weight is 0.6 and the DTW distance weight is 0.4, the gradient is −0.6*(dLoss / dOverlap)+0.4*(dLoss / d_DTW).

[0095] Step 50: Calculate the difference between the predicted resource allocation set and the resource annotation data in the annotation scheduling policy set to generate a second gradient value of the resource allocation loss function.

[0096] Resource diversity is divided into type bias and intensity bias. Type bias uses cross-entropy to calculate the difference between the predicted resource type distribution and the annotated distribution. For example, if the predicted resource type is [Fast Charging Pile: 0.7, Slow Charging Pile: 0.3] and the annotated resource type is [Fast Charging Pile: 1.0, Slow Charging Pile: 0.0], the cross-entropy is −log(0.7) = 0.356. Intensity bias is calculated as the Euclidean distance between the predicted and annotated values. For example, if the predicted number of fast charging piles is 2 and the annotated number is 3, the bias is √(1²) = 1. The second gradient of the resource allocation loss function is generated by the weighted sum of the cross-entropy gradient and the Euclidean distance gradient. For example, if the type bias weight is 0.5 and the intensity bias weight is 0.5, the gradient is 0.5*(dLoss / d_CrossEntropy) + 0.5*(dLoss / d_EuclideanDistance).

[0097] Step 60: Jointly optimize the parameters of the initial multi-task neural network according to the first gradient value and the second gradient value until the path optimization loss function and the resource allocation loss function converge to obtain the multi-task optimization model.

[0098] The joint optimization uses the adaptive moment estimation (Adam) algorithm to synchronously update the parameters of the shared layer and the branch network. The parameter update formula is θ_new=θ_old−η*(α*Gradient path +β*Gradient_resource), where η is the learning rate (initial value 0.001), and α and β are task weight coefficients (α=0.6, β=0.4). The convergence condition is that the rate of change of the path optimization loss function for five consecutive training cycles is ≤1e-5, and the rate of change of the resource allocation loss function is ≤1e-4. For example, at the 1200th round of training, the path loss value decreased from 0.58 to 0.57, with a rate of change of 0.01; the resource loss value decreased from 0.45 to 0.44, with a rate of change of 0.01, failing to meet the convergence condition. By the 2500th round, the path loss value stabilized at 0.12±0.001, and the resource loss value stabilized at 0.08±0.001, indicating model convergence. The final output multi-task optimization model achieved a path matching degree of 92.7% on the test set, and a resource allocation error rate of less than 5.3%.

[0099] As an implementation method, the step 400, adjusting the priority of the abnormal operation event set according to the target scheduling policy set to generate a bus scheduling optimization instruction set, includes:

[0100] Step 410: extracting the urgency label and impact range parameter of each abnormal operation event from the abnormal operation event set, and constructing an event priority scoring matrix.

[0101] The abnormal operation event collection is a list of abnormal events output by the anomaly detection model, including vehicle failures, task delays, or resource conflicts. Examples include a "battery overheat warning" event reported by a bus terminal and a "passenger delay timeout" event detected by the dispatch center. Urgency labels are categorized into four levels: "urgent," "high," "medium," and "low," based on the event type and pre-set business rules. For example, a battery overheat warning is labeled "urgent" due to the safety risk it involves, and a passenger delay timeout is labeled "high" due to its impact on service quality. The impact range parameter is calculated by quantifying the number of vehicles and passengers affected by the event and the length of the associated task chain. For example, a battery overheating event caused the emergency suspension of three buses, resulting in an impact range parameter of 3; a passenger delay event involved two stations with a total of 85 passengers, resulting in an impact range parameter of 85. The event priority scoring matrix stores the scores of each event in a two-dimensional table. The calculation formula is: Score = Urgency Factor × 0.6 + Impact Factor × 0.4, where the Urgency Factor is mapped to a numeric value (Urgent = 4, High = 3, Medium = 2, Low = 1), and the Impact Factor is normalized to [0, 1]. For example, the score for a battery overheating event is 4 × 0.6 + 0.3 (affecting three buses corresponds to a normalized value of 0.3) = 2.7, and the score for a stranded passenger event is 3 × 0.6 + 0.85 (affecting 85 people corresponds to a normalized value of 0.85) = 2.65, resulting in two rows in the matrix.

[0102] Step 420: Perform weighted fusion on the event priority score matrix and the path resource occupancy rate in the target scheduling policy set to generate a dynamic adjustment weight set.

[0103] The path resource utilization ratio within the target scheduling strategy set refers to the ratio of resources required for each planned route to be executed, including the number of charging piles, driver hours, and duration of stops. For example, the resource utilization ratio for the route "Bus A → Fast Charging Station X" is 2 fast charging piles (20% of the total system capacity) and 1 hour of driver hours (12.5% ​​of a single shift). Weighted fusion uses a linear weighting formula: Dynamically Adjusted Weight = Event Priority Score × 0.7 + Resource Utilization × 0.3, where resource utilization is the weighted sum of the utilization ratios of each resource type (e.g., charging pile weight 0.5, driver hours weight 0.3, and stop duration weight 0.2). For example, the path "Bus A → Fast Charging Station X" corresponding to a battery overheating event has an event priority score of 2.7. The resource utilization is calculated as (2 / 10 × 0.5 + 1 / 8 × 0.3 + 0.2 × 0.2) = 0.1 + 0.0375 + 0.04 = 0.1775, and the dynamically adjusted weight is 2.7 × 0.7 + 0.1775 × 0.3 = 1.89 + 0.053 = 1.943. The dynamically adjusted weight set stores weight values ​​indexed by the path ID for subsequent scheduling optimization.

[0104] Step 430: Rearrange the execution order of the paths in the target scheduling strategy set based on the dynamically adjusted weight set to generate an optimized scheduling sequence.

[0105] The weights in the dynamically adjusted weight set reflect the balance between path execution urgency and resource consumption. Paths with higher weights are prioritized. For example, in the target scheduling policy set, the weight of path B is 1.943, the weight of path C is 1.725, and the weight of path D is 1.602. The system arranges paths B, C, and D in descending order as [B, C, D]. The optimized scheduling sequence further considers overlapping time windows. For example, if path B is scheduled to execute between 2:00 PM and 2:30 PM, and path C is scheduled to execute between 2:15 PM and 2:45 PM, and there is a time conflict between the two during that time, the system delays the start of path C until 2:30 PM to avoid the conflict, generating the adjusted sequence [B, C@14:30, D].

[0106] Step 440: Convert the scheduling sequence into an instruction format executable by the bus terminal to generate the bus scheduling optimization instruction set.

[0107] The command format executable by bus terminals uses the JSON structured data protocol and includes a path node sequence, execution time window, resource usage list, and exception handling rules. For example, the command for Path B is: {"Path ID":"B0021","Node Sequence":["Bus A","Fast Charging Station X","Bus B"],"Start Time":"2:00 PM","End Time":"2:30 PM","Resource Usage":{"Fast Charging Station":2,"Driver":"Zhang San"},"Exception Fallback Rule":"Switch to alternate path B_alt if insufficient charging stations are available"}. The bus scheduling optimization command set is distributed to the corresponding terminals via a message queue service, ensuring command transmission latency of less than 500 milliseconds and a delivery success rate exceeding 99.9%.

[0108] As an implementation manner, the step 430 of rearranging the execution order of the paths in the target scheduling policy set based on the dynamically adjusted weight set includes:

[0109] Step 431: performing conflict detection on each path in the target scheduling policy set according to the weight values ​​in the dynamically adjusted weight set, and determining a set of path pairs with resource conflicts.

[0110] Conflict detection is achieved through analysis of the spatiotemporal overlap of resource occupancy, encompassing two dimensions: time window conflict (two paths requesting the same resource during the same time period) and spatial node conflict (two paths requiring the same geographic node simultaneously). For example, if path E plans to use charging station 3 between 3:00 PM and 3:30 PM, and path F plans to use charging station 3 between 3:15 PM and 3:45 PM, there will be a time window conflict between the two routes during the 3:15 PM and 3:30 PM periods. Alternatively, if both paths G and H need to arrive at transportation hub Y by 3:00 PM, but hub Y only allows one bus to dock, this creates a spatial node conflict. The conflicting path pair collection lists the conflicting path IDs and conflict types, for example, [{"Conflicting Paths":["E","F"],"Type":"Time Window Conflict"},{"Conflicting Paths":["G","H"],"Type":"Spatial Node Conflict"}].

[0111] Step 432: Search for alternative paths for the set of path pairs with resource conflicts, generate an alternative path candidate set, and calculate the resource consumption increment of each alternative path.

[0112] Alternative route search relies on the backup route library in the bus operation knowledge graph. A graph traversal algorithm is used to find routes that meet the same mission objectives but differ in resource usage. For example, a conflict between route E and route F can be resolved by searching for an alternative route, F_alt, for route F. This route uses charging station 5 and adjusts the time between 3:30 PM and 4:00 PM. The incremental resource consumption is calculated as the difference between the alternative route and the original route. For example, F_alt increases the number of charging stations by 1 (from 3 to 4) and reduces the driver hours by 0.5 hours (from 1.5 to 1.0). The incremental values ​​are +1 (for charging stations) and -0.5 (for drivers). The candidate set records the ID, resource incremental value, and feasibility score of each alternative route, for example, {"alternative route ID":"F_alt","charging station incremental value":+1,"driver incremental value":-0.5,"feasibility score":0.85}.

[0113] Step 433: According to the resource consumption increment and the weight values ​​in the dynamically adjusted weight set, an alternative path with the highest comprehensive score is selected to replace the original conflicting path, and an updated scheduling sequence is generated.

[0114] The comprehensive score is calculated as follows: Score = Dynamic Adjustment Weight × 0.6 - Resource Consumption Increment × 0.4. For example, if the dynamic adjustment weight of path F is 1.8, the alternative path F_alt has a +1 charging pile increment (weight 0.5) and a -0.5 driver increment (weight 0.3). The total resource consumption increment score is (+1 × 0.5) + (-0.5 × 0.3) = 0.5 - 0.15 = 0.35; the comprehensive score is 1.8 × 0.6 - 0.35 × 0.4 = 1.08 - 0.14 = 0.94. If the alternative path F_alt2 has a score of 0.87, F_alt is selected and added to the updated scheduling sequence. The updated sequence ensures that at least one of the conflicting paths is replaced. For example, the original sequence [E, F, G, H] is changed to [E, F_alt, G, H_alt], where H_alt is the alternative to path H.

[0115] As an embodiment, step 500, based on the execution feedback data of the bus dispatch optimization instruction set, updates the weight parameters of the multi-task optimization model and the historical operation data set, including:

[0116] Step 510: extracting the actual path execution time, resource consumption deviation value and task completion status indicator from the execution feedback data to generate a model feedback feature set.

[0117] Execution feedback data refers to the actual operational results uploaded by the bus terminal after executing the dispatch instruction. For example, the actual execution time for the route "Bus A → Fast Charging Station X → Bus B" was 2:05 PM to 2:40 PM, a 10-minute delay compared to the predicted time of 2:00 PM to 2:30 PM. The resource consumption deviation value indicates that 3 fast charging stations were actually occupied (predicted to be 2), and the driver actually consumed 1.2 hours (predicted to be 1 hour). The task completion status indicator is "95% completion" (due to premature departure due to incomplete charging). The model feedback feature set is generated by structured storage of this data. For example, a feedback record may be: {"Route ID":"B0021","Actual Execution Time":"14:05-14:40","Resource Deviation":{"Fast Charging Station":+1,"Driver":+0.2},"Task Status":"95%"}, with a timestamp of 2024-03-15 2:45 PM.

[0118] Step 520: Compare the model feedback feature set with the predicted path execution time, predicted resource consumption value and predicted task completion status in the target scheduling strategy set to generate a time error distribution, a resource error distribution and a task error distribution.

[0119] For example, the predicted data for route B0021 in the target scheduling policy set has a predicted execution time of 2:00 PM to 2:30 PM, a predicted consumption of 2 fast charging piles, and a predicted completion status of 100%. When comparing differences, the time error is calculated as the difference between the actual and predicted end times (14:40 - 14:30 = +10 minutes). The resource consumption deviation is calculated as the absolute difference between the actual and predicted values ​​(+1 for the fast charging pile, +0.2 hours for the driver). The task completion status error is 100% - 95% = 5%. The time error distribution is generated by taking the average of the time deviations for all routes within a 1-hour window. For example, the average time error for 50 routes during the 3:00 PM to 4:00 PM period is +8 minutes. The resource error distribution is aggregated by resource type and region. For example, the average deviation for fast charging piles in charging station area X is +0.8. The task error distribution is grouped by task type. For example, the average completion error for medical transfer tasks is 12%, while for conventional route tasks, it is 3%.

[0120] Step 530: Determine the time weight parameter of the path optimization branch, the resource weight parameter of the resource allocation branch, and the task completion weight parameter of the multi-task optimization model based on the time error distribution, the resource error distribution, and the task error distribution.

[0121] The time weight parameter is adjusted based on the variance of the time error distribution. For example, if the time error variance is high during a certain period (e.g., 20 minutes² during the morning rush hour), the weight of the time-related loss function in the path optimization branch is increased from 0.6 to 0.7. The resource weight parameter is dynamically adjusted based on the resource error ratio. For example, if the error ratio of fast-charging piles is consistently above 15%, the fast-charging pile weight coefficient in the resource allocation branch is increased from 0.5 to 0.6. The task completion weight parameter is set based on the error level of the task type. For example, if the error of a medical task exceeds 10%, its weight is increased from 0.3 to 0.4. The parameter adjustment formula is: new weight = original weight × (1 + error ratio × adjustment factor), where the adjustment factor is preset to 0.05 based on model convergence.

[0122] Step 540: Based on the time weight parameter, resource weight parameter and task completion weight parameter, the weight matrices of the path optimization branch and the resource allocation branch of the multi-task optimization model are gradient updated layer by layer.

[0123] Weight matrix updates utilize a backpropagation algorithm combined with adaptive learning rate adjustment. For example, the path optimization branch applies a time weight parameter of 0.7 to the BiLSTM layer's output weight matrix W_t. The gradient is calculated as ∂Loss / ∂W_t = Σ(time error × input features), and the learning rate is set to 0.001. The resource allocation branch applies a fast charging pile weight of 0.6 to the fully connected layer's weight matrix W_r. The gradient is calculated as ∂Loss / ∂W_r = Σ(fast charging pile error × resource features), and the learning rate is set to 0.0005. During layer-by-layer updates, the convolution kernel weights of the shared feature extraction layer are adjusted synchronously. For example, the convolution kernel weights of the CNN layer are updated based on the gradient of the task completion error by ΔW_c = η × (∂Loss_task / ∂W_c + ∂Loss_resource / ∂W_c), where η = 0.0002.

[0124] Step 550: Add the actual path execution time, resource consumption deviation value and task completion status indicator in the execution feedback data to the historical operation data set, and perform feature alignment processing on the updated historical operation data set to ensure consistency with the input format of the multi-task optimization model.

[0125] New data must be converted to a standard format for model input. For example, actual route execution time is converted to seconds relative to a reference time (e.g., midnight of the day) (14:05 → 50,700 seconds, 14:40 → 52,800 seconds), resource consumption deviations are normalized to the [-1, 1] range (a +1 deviation for a fast-charging station is mapped to 0.5, a +0.2 deviation for a driver is mapped to 0.1), and task completion status indicators are converted to decimals (95% → 0.95). Feature alignment involves filling in missing fields (e.g., interpolating unreported passenger volume data to a historical mean of 60 passengers) and standardizing data dimensions (e.g., resampling trajectory data with different sampling frequencies to one point per second). This ultimately generates an updated historical run data set with the same dimensions as the original training data, including the newly added 5,000 samples.

[0126] As an embodiment, step 520 compares the model feedback feature set with the predicted path execution time, predicted resource consumption value, and predicted task completion status in the target scheduling strategy set to generate a time error distribution, a resource error distribution, and a task error distribution, including:

[0127] Step 521: Calculate the time difference between the actual path execution time and the predicted path execution time to generate a time error sequence, and perform sliding window statistics on the time error sequence to generate a time error distribution.

[0128] The time difference is calculated as the difference between the actual end time and the predicted end time (unit: minutes). For example, if the actual execution time of path C, 15:20, is 10 minutes later than the predicted time of 15:10, the time difference is +10. The time difference sequence is sorted by path execution time, forming a sequence such as [+5, -2, +10, ...]. Sliding window statistics are performed with a window length of 1 hour and a step size of 30 minutes. The mean and standard deviation of the error within the window are calculated. For example, the mean for the 9:00-10:00 window is +8 minutes, with a standard deviation of 3 minutes; the mean for the 10:30-11:30 window is +12 minutes, with a standard deviation of 5 minutes. This generates a time difference distribution curve.

[0129] Step 522: Calculate the resource consumption ratio of the resource consumption deviation value and the predicted resource consumption value to generate a resource error ratio sequence, and perform spatial region aggregation on the resource error ratio sequence to generate a resource error distribution.

[0130] Resource consumption ratio is calculated as (actual consumption - predicted consumption) / predicted consumption × 100%. For example, if three fast-charging stations were actually used (predicted to be two), the ratio is (3-2) / 2 × 100% = +50%. If a driver actually used 1.2 hours (predicted to be 1.0 hours), the ratio is +20%. Resource error ratio sequences are associated with resource type and geographic location. For example, the error ratio for fast-charging stations in charging station area X is +50%, while that for charging station area Y is -10%. Spatial region aggregation uses geographic grid division (e.g., 500m×500m grid). The average error ratio for the same type of resource within each grid is calculated to generate a resource error distribution map in the form of a heat map.

[0131] Step 523: Calculate the state matching degree between the task completion state indicator and the predicted task completion state to generate a task error identification sequence, and perform task type grouping statistics on the task error identification sequence to generate a task error distribution.

[0132] The state matching degree is calculated as the absolute difference between the actual completion degree and the predicted value. For example, if the predicted completion degree is 100% and the actual completion degree is 95%, the matching degree error is 5%. The task error identification sequence is marked with a binary label (error ≤5% is 0, >5% is 1). For example, the task error flag for path D is 1, and that for path E is 0. Task type group statistics are calculated by pre-defined categories (such as medical transfer, regular route, and temporary dispatch). For example, the error frequency for medical transfer tasks is 25% (error > 5% in 2 out of 10 tasks), and for regular route tasks it is 8%. This generates a task error distribution table.

[0133] Step 524: Perform three-dimensional spatial mapping on the time error distribution, resource error distribution, and task error distribution to generate a joint error distribution map including the time dimension, resource dimension, and task dimension.

[0134] The three-dimensional spatial mapping uses the time axis (24 hours), resource type axis (fast charging pile, driver, station, etc.), and task type axis (medical, routine, temporary) as the coordinate system. Each cell records the error value for the corresponding time-resource-task combination. For example, in the cell at 15:00 in the time dimension, fast charging pile in the resource dimension, and medical connection in the task dimension, the error value is +15% (a weighted combination of time error +10 minutes, fast charging pile error +20%, and task error +5%). The combined error distribution map is stored in a three-dimensional matrix and visualized as a three-dimensional heat map to facilitate the identification of high-error areas.

[0135] Step 525: Extract areas where the error density exceeds a preset threshold from the joint error distribution map, mark them as high-error areas, and map the high-error areas to the network layer nodes of the multi-task optimization model to determine the set of model nodes that need to be optimized first.

[0136] The preset threshold is set as the area where the error density exceeds two standard deviations of the overall mean. For example, during the 3:00 PM to 4:00 PM period, the error density for fast-charging pile resources and medical tasks is 25% (mean 10%, standard deviation 5%), exceeding the threshold of 15% (10% + 2 × 5%) and thus marked as a high-error area. Model node mapping is achieved by analyzing the sensitivity of network layers to relevant features. For example, this high-error area corresponds to the fully connected layer FC1 node (responsible for fast-charging pile prediction) in the resource allocation branch and the BiLSTM node (responsible for time prediction) in the path optimization branch. This prioritizes optimization of the weight parameters of FC1 and BiLSTM. Optimization strategies include increasing the regularization strength of the FC1 layer (L2 coefficient from 0.01 to 0.05) and increasing the learning rate of the BiLSTM node (from 0.001 to 0.002).

[0137] As an implementation method, the preset anomaly detection model can be trained using the following steps:

[0138] Step 110: extracting normal operation data segments and manually annotated abnormal data segments from the historical operation data set to construct a balanced training data set.

[0139] Historical operation data sets refer to multidimensional time-series data containing vehicle location, energy consumption, mission status, and environmental parameters recorded by bus terminals during long-term operation. For example, a city's bus system stored 12 million data records from 2020 to 2023. Normal operation data segments are continuous data segments that have been manually reviewed and confirmed to be free of abnormal events. For example, the trajectory and energy consumption sequence of a bus running smoothly at an average speed of 25 km / h between 9:00 and 10:00 on May 10, 2023. Manually annotated abnormal data segments are annotated by operations and maintenance experts based on fault logs. For example, the data segment between 2:30 and 3:00 on August 15, 2023, shows a sudden 120% increase in energy consumption due to battery overheating. Balanced training datasets achieve class balance by oversampling abnormal data and undersampling normal data. For example, 100,000 items are randomly sampled from 1 million normal data points, and 10,000 abnormal data points are replicated to expand to 100,000 items, resulting in a balanced dataset containing 200,000 samples.

[0140] Step 120: performing sliding window segmentation on the balanced training data set to generate multiple training sample segments, and performing feature normalization processing on each training sample segment.

[0141] Sliding window segmentation uses a fixed window length and sliding step size strategy. For example, the window length is set to 30 minutes (corresponding to 1800 time steps at a sampling frequency of 1Hz) and the sliding step size is set to 5 minutes. Each data record is divided into multiple overlapping sample segments. For example, 6 hours of continuous data from a vehicle is segmented into 72 sample segments (360 minutes / 5 step size = 72). Feature normalization scales the values ​​of each dimension to a distribution with a mean of 0 and a variance of 1. For example, the original energy consumption data ranges from [0, 150 kWh], but after Z-score normalization, it is mapped to the range [-1.2, 2.1]. The normalization formula is: (x − μ) / σ, where μ is the training set mean and σ is the standard deviation.

[0142] Step 130: construct an initial anomaly detection neural network, and use a contrastive learning strategy to perform feature separation training on the normal operation data segment and the abnormal data segment.

[0143] The initial anomaly detection neural network consists of a temporal convolutional network (TCN) and a fully connected layer. The TCN layer contains four residual blocks, each with 64 convolution kernels, to extract temporally dependent features. The fully connected layer compresses the feature dimensions to 128. A contrastive learning strategy achieves feature separation by maximizing the similarity between similar samples and the difference between heterogeneous samples. For example, two data augmentations are performed on the same anomaly data segment to generate positive pairs, while the normal and anomaly data segments constitute negative pairs. During training, the network parameter optimization goal is to ensure that the feature cosine similarity of positive pairs approaches 1 and that of negative pairs approaches 0.

[0144] Step 140: Optimizing the decision boundary parameters of the initial anomaly detection neural network by calculating the feature distance loss between normal samples and abnormal samples.

[0145] The feature distance loss uses a triplet loss function. It selects anchor samples, positive samples (similar to the same class), and negative samples (different from the same class). It calculates the distance between the anchor and the positive sample, and the difference between the distance between the anchor and the negative sample. For example, the anchor is the feature vector of a normal sample, the positive sample is the feature vector of another normal sample, and the negative sample is the feature vector of an abnormal sample. The loss function is max(d(anchor, positive)−d(anchor, negative)+margin, 0), where margin is set to 1.0. The decision boundary parameter is adjusted through backpropagation to adjust the weight matrix of the fully connected layer, so that normal samples are clustered in the feature space and abnormal samples are kept away from this area.

[0146] Step 150: When the feature distance loss is lower than a preset threshold, the parameters of the initial anomaly detection neural network are frozen to obtain the preset anomaly detection model.

[0147] Preset thresholds are set based on validation set performance. For example, convergence is determined when the triplet loss remains stable at 0.05±0.01 for 10 consecutive training cycles. Parameter freezing utilizes a model save and load mechanism to fix the convolutional kernel weights and fully connected layer biases to their final training values. The resulting anomaly detection model achieved 98.7% accuracy for normal samples, 95.2% recall for anomaly samples, and an F1-score of 96.9% on the test set.

[0148] The step 130 of performing feature separation training on the normal operating data segment and the abnormal data segment using a contrastive learning strategy may include:

[0149] Step 131: Perform data enhancement on each training sample segment to generate positive sample pairs and negative sample pairs, where the positive sample pairs come from the same data category and the negative sample pairs come from different data categories.

[0150] Data augmentation methods include time warping, random noise injection, and segment discarding. For example, time warping is applied to an anomalous data segment, shortening the original 30-minute data segment to 28 minutes or extending it to 32 minutes. This generates two augmented samples as positive pairs. A negative pair is formed by taking one sample from each of the normal and anomalous data segments. Negative pairs must be constructed from strictly distinct categories. For example, a normal sample N1 and an anomalous sample A1 form a negative pair, while a normal sample N1 and another normal sample N2 do not form a negative pair.

[0151] Step 132: Input the positive sample pairs and the negative sample pairs into the initial anomaly detection neural network, extract high-dimensional feature vectors and calculate feature similarity.

[0152] The high-dimensional feature vector is the 128-dimensional vector output by the fully connected layer. For example, the output vector of normal sample N1 is [0.23, −0.56, …, 1.02], and the vector of its enhanced sample N1' is [0.25, −0.54, …, 1.03]. Feature similarity is calculated using cosine similarity, using the formula sim(A, B) = (A·B) / (||A||·||B||). For example, the similarity between N1 and N1' is 0.97, and the similarity between N1 and A1 is 0.12. The similarity results are stored in matrix form and used in subsequent loss calculations.

[0153] Step 133: Construct a contrast loss function based on the feature similarity, and optimize the embedding space parameters of the initial anomaly detection neural network by gradient descent method.

[0154] The contrastive loss function used is NT-Xent (Normalized Temperature-Scaled Cross Entropy Loss), with the formula L = −log(exp(sim(A,B) / τ) / (Σexp(sim(A,neg) / τ))), where τ is the temperature coefficient (set to 0.07). For example, a positive sample pair with a similarity of 0.97 is scaled to 13.86 after temperature scaling, and a negative sample pair with a similarity of 0.12 is scaled to 1.71, resulting in a loss of −log(13.86 / (13.86+1.71+…)) = 0.15. The gradient descent method uses the Adam optimizer with a learning rate of 0.001. The embedding space parameters (i.e., the TCN and fully connected layer weights) are updated to minimize the loss.

[0155] Step 134: Repeat the iteration until the contrast loss function converges, so that normal samples and abnormal samples form a significantly separated area in the embedding space.

[0156] During the iterative process, the validation loss trended downward after each round of training. For example, the initial loss was 2.3, but it dropped to 0.08 after 500 rounds of training. Visualizations of the embedding space (such as t-SNE dimensionality reduction plots) showed that normal samples clustered in the coordinate region [−5, 5], while abnormal samples were scattered in the region [10, −8]. The distance between the cluster centers of the two classes of samples increased from an initial 3.2 to 12.7. After convergence, the average intra-class similarity between normal and abnormal samples reached 0.92, while the average inter-class similarity was only 0.09, meeting the pre-defined separation requirement.

[0157] In summary, the present invention provides a comprehensive management and analysis method for the entire bus system data. By collecting the operating data of multiple bus terminals in real time and extracting multi-dimensional features, the method combines an anomaly detection model to quickly identify abnormal events, constructs a spatiotemporal bus operation knowledge graph, and calls a multi-task optimization model to generate a dynamic scheduling strategy. Finally, the model and data are continuously optimized based on execution feedback to form a closed-loop management. In this way, the real-time operation data set can fully reflect the vehicle location, energy consumption, and task execution status. The multi-dimensional feature extraction can accurately capture high-frequency paths, energy consumption fluctuations, and task efficiency changes. The anomaly detection model can quickly locate potential faults or inefficient operation events. The bus operation knowledge graph integrates historical and real-time data through spatiotemporal correlation mapping, providing a global perspective for path planning and resource allocation. The multi-task optimization model can generate a scheduling strategy that adapts to complex scenarios through collaborative analysis of dynamic path planning and resource allocation. The model update mechanism based on abnormal event priority adjustment and feedback drive can optimize scheduling instructions in real time and improve the effectiveness of historical data. Through this closed-loop management process, the system enables efficient allocation of bus resources, rapid response to abnormal events, and dynamic optimization of dispatch strategies, thereby improving the bus system's operational efficiency, resource utilization, and task execution reliability. Furthermore, the combination of multi-dimensional data fusion and model self-learning significantly reduces the need for manual intervention and enhances the system's adaptability to complex traffic environments and unexpected tasks.

[0158] In addition, as an independently implementable derivative solution, the method provided in the embodiment of the present application may further include:

[0159] Step 600: Monitor in real time the matching degree between the new scheduling strategy set output by the multi-task optimization model and the current bus operation feature set, and generate a dynamic strategy deviation index.

[0160] The dynamic policy deviation metric quantifies the degree of alignment between the new scheduling policy and the real-time operating status. For example, the calculation formula is: Deviation = 1 − (Number of matching features / Total number of features), where the number of matching features refers to the number of parameters in the new policy, such as path execution time and resource utilization, that are consistent with the real-time data reported by the bus terminal. For example, during the 10:00-11:00 period, the new scheduling policy set contains 50 path plans, of which 45 have predicted execution times that deviate from the actual vehicle location by ≤3 minutes. The number of matching features is 45, and the total number of features is 50. The deviation metric is 1 − 45 / 50 = 0.1. If the deviation exceeds a preset threshold (e.g., 0.2), the policy is considered to deviate significantly from the actual operating status, triggering the subsequent conflict analysis process.

[0161] Step 700: According to the time period when the dynamic strategy deviation index exceeds the preset threshold, intercept the intersection of the real-time operation data set and the historical operation data set of the corresponding time period to generate a conflict data segment.

[0162] Conflicting data segments are spatiotemporally overlapping data segments that exist in both real-time and historical data and cause deviations. For example, when the deviation reaches 0.25 between 2:00 PM and 3:00 PM, the system extracts the intersection of the vehicle position sequence in the real-time data during that period (e.g., bus C deviates 50 meters from the preset path at 2:30 PM) and the historical trajectory of the same vehicle during the same period in the historical data (e.g., the path is completely compliant at 2:30 PM on the same day in 2023). This intersection, namely bus C's latitude and longitude coordinates at intersection L (116.4085°E, 39.9051°N) and the corresponding energy consumption spike (from 50 kW to 80 kW), creates the conflicting data segment. This segment is stored using a timestamp and vehicle ID as an index for subsequent pattern mining.

[0163] Step 800: Perform spatiotemporal conflict pattern mining on the conflict data segments, identify recurring resource contention areas and path overlap periods, and generate a high-frequency conflict pattern list.

[0164] Spatiotemporal conflict pattern mining uses the Frequent Pattern Growth (FP-Growth) algorithm to analyze spatiotemporal co-occurrence patterns within conflict data segments. For example, between 2:00 PM and 3:00 PM for three consecutive days, Bus D and Bus E competed for a fast-charging station five times within a 500-meter radius of Charging Station M. Furthermore, the paths "Bus D → Charging Station M → Bus F" and "Bus E → Charging Station M → Bus G" overlapped by over 80% between 2:20 PM and 2:40 PM. A high-frequency conflict pattern list records the spatiotemporal parameters of these recurring conflicts. For example, entry 1: {Conflict Type: Charging Station Competition, Area: Charging Station M, Time: 2:20 PM to 2:40 PM, Frequency: 5 times / 3 days}; entry 2: {Conflict Type: Path Overlap, Area: Intersection L, Time: 2:30 PM to 2:45 PM, Frequency: 8 times / 3 days}.

[0165] Step 900: Dynamically attenuate and adjust the node association weight matrix of the multi-task optimization model based on the high-frequency conflict pattern list to reduce the node weight values ​​associated with the conflict area and time period.

[0166] In the node-association weight matrix, the weights of nodes corresponding to conflict zones and time periods are adjusted using an exponential decay rule. For example, if the original weight of charging station M node is 0.85 and the conflict frequency reaches 5 times / 3 days, the decay coefficient is set to 0.9, resulting in an adjusted weight of 0.85 × 0.9^5 ≈ 0.52. The original weight of intersection node L is 0.78, and the decay coefficient is 0.95, resulting in an adjusted weight of 0.78 × 0.95^8 ≈ 0.57. After the weight adjustment, the model prioritizes nodes in high-conflict zones during route planning. For example, the originally planned route "Bus D → Charging Station M" is replaced with "Bus D → Charging Station N" due to the decreased weight.

[0167] Step 1000: Re-inject the adjusted node association weight matrix into the path optimization branch of the multi-task optimization model to generate path planning constraints for adaptive conflict avoidance.

[0168] Path planning constraints are integrated into the model in the form of a ban list and soft penalties. The ban list directly blocks the selection of specific nodes during periods of high conflict, for example, prohibiting routes from passing through Charging Station M between 2:20 PM and 2:40 PM. Soft penalties impose an additional penalty on the selection of nodes in conflict zones. For example, if the path plan includes intersection L, a penalty of 0.1 × the node weight is added to the loss function. Adaptive constraints are injected into the decision logic of the path optimization branch through the model API. For example, during the path search, Charging Station M is prioritized and the path score of intersection L is reduced.

[0169] Step 1100: pre-screen the real-time operation data set collected in the next period according to the path planning constraint conditions, filter out the bus terminal data that triggers the high-frequency conflict mode, and generate a purified real-time operation data subset.

[0170] Pre-screening rules are set based on the spatiotemporal characteristics of conflict patterns. For example, between 2:20 PM and 2:40 PM, if a bus's reported real-time location falls within 500 meters of Charging Station M, it is flagged as potentially conflicting data and filtered. For example, bus E's reported location at 2:25 PM (116.4080°E, 39.9050°N) is 480 meters away from Charging Station M, triggering the filter and removing this data from the real-time data subset. This cleaned subset only includes data from non-conflicting areas (e.g., bus F's reported location at 2:30 PM, far from Charging Station M), ensuring low conflict in the model input data.

[0171] Step 1200: The cleansed real-time operation data subset is used as input data for the next round of multi-task optimization model analysis to replace the original real-time operation data set, thereby forming a closed-loop dynamic update link.

[0172] The closed-loop update link transmits the cleansed subset to the model input via a data pipeline, replacing the original dataset. For example, if the original real-time operational data set contained 1,000 records, the cleansed subset would retain 850 non-conflicting data items. In the new scheduling strategy set generated by the model based on the cleansed data, the proportion of paths associated with charging station M decreased from 20% to 5%, and the path overlap rate at intersection L decreased from 15% to 3%, forming a closed-loop process of "monitoring-adjustment-filtering-re-optimization."

[0173] In step 1000, after generating the path planning constraint conditions for adaptive conflict avoidance, the method may further include:

[0174] Step 1001: extracting the spatiotemporal conflict parameters in the high-frequency conflict pattern list, performing periodic demand forecasting in combination with the updated historical operation data set, and generating a resource demand density distribution map for each region in the future period.

[0175] Spatiotemporal conflict parameters include conflict type, region coordinates, time period, and frequency. For example, the parameters for item 1 are {Type: Charging Pile Competition, Region: Charging Station M, Time Period: 2:20 PM - 2:40 PM, Frequency: 5 times / 3 days}. Periodic demand forecasting uses a time series forecasting model (such as ARIMA) with historical charging pile usage data as input. The forecast predicts a demand density of 8 vehicles / hour for Charging Station M during the 2:00 PM - 3:00 PM period over the next three days (the historical average is 6 vehicles / hour). The resource demand density distribution map uses geographic grid cells to display demand intensity. For example, the grid cell containing Charging Station M is darkened to red (indicating high demand), while the grid cell containing Charging Station N is green (indicating low demand).

[0176] Step 1002: Determine resource supply gap areas and surplus areas based on a superposition analysis of the resource demand density distribution map and the task execution efficiency feature set in the current bus operation feature set.

[0177] Overlay analysis uses a spatial association algorithm to match resource demand density with real-time supply capacity. For example, if charging station M has a predicted demand of 8 vehicles per hour and 6 available charging piles, the supply gap is 8-6 = 2, resulting in a supply gap area. Meanwhile, charging station N has a predicted demand of 3 vehicles per hour and 6 available charging piles, resulting in a surplus of 3, thus becoming a surplus area. The gap and surplus areas are marked with polygonal boundaries. For example, a 1-kilometer radius around charging station M is designated as a gap area, while a 2-kilometer radius around charging station N is designated as a surplus area.

[0178] Step 1003: Based on the geographical scope of the resource supply gap area and the gap duration, reversely deduce the uncovered path nodes in the multi-task optimization model to generate a set of candidate supplementary path nodes.

[0179] Backward derivation starts from the geographic boundaries of the gap area and searches for adjacent nodes not covered by the model path. For example, if the gap area of ​​charging station M includes an unplanned charging station P (800 meters from M) and a temporary charging station Q, the candidate supplementary path node set includes P, Q, and the connecting road node R. Node search criteria include accessibility (such as road connectivity), resource availability (such as idle charging stations), and time period matching (such as available between 2:00 PM and 3:00 PM).

[0180] Step 1004: Verify the connectivity of the candidate supplementary path node set with the existing nodes in the bus operation knowledge graph, eliminate isolated nodes that cannot form a continuous path, and generate a valid supplementary path segment set.

[0181] Connectivity verification uses a graph traversal algorithm to check the path connectivity between nodes. For example, if a two-way road exists between candidate node P and existing node S, the verification passes; however, node Q has no connection to the main road network and fails verification and is removed. The valid supplementary path segment set records newly added connectable paths, such as the path segments "Charging Station M → Node R → Charging Station P" and "Bus H → Temporary Charging Vehicle Q → Bus I."

[0182] Step 1005: inserting the valid supplementary path segment set into the initial path planning set of the path optimization branch of the multi-task optimization model to expand the path search space.

[0183] After adding additional path segments to the initial set of path optimization branches, the number of paths increased from 500 to 550. For example, the node sequence for the newly added path "Bus J → Charging Station P" is [Bus J, Intersection T, Charging Station P], with resource utilization of one fast charging station and 0.8 hours of driver time. This expanded search space increases the model's planning options by 10%, alleviating resource pressure in previously high-conflict areas.

[0184] Step 1006: Re-calculate the resource allocation priority based on the expanded path search space to generate a set of candidate scheduling strategies including the supplementary path segments.

[0185] Resource allocation priority calculations use the parameters in the dynamically adjusted weight set. For example, the initial weight of the charging station P node in the supplementary route segment is set to 0.7 (lower than the 0.52 of the original charging station M). The candidate strategy set includes 30 newly added routes. For example, route K (bus L → charging station P) has a priority score of 0.75, higher than the 0.65 of the original route L → M, making it a preferred candidate.

[0186] Step 1007: performing parallel simulation tests on the candidate scheduling strategy set and the target scheduling strategy set, and selecting the strategy with the highest resource occupancy balance as the preload strategy to be injected into the cache queue of the bus terminal.

[0187] A parallel simulation runs two strategies simultaneously in a virtual environment to compare resource utilization balance. The balance is calculated as 1 − (maximum resource utilization − minimum resource utilization) / total number of resources. For example, if the alternative strategy has a 70% utilization rate at charging station P and the target strategy has an 85% utilization rate at charging station M, with balances of 0.7 and 0.65, respectively, the alternative strategy is selected as the preload strategy. The preload strategy is pushed to the bus terminal's instruction cache via an OTA update. For example, the instructions for route K are preloaded to bus L's onboard terminal at 1:50 PM.

[0188] Step 1008: When the actual resource demand is monitored to match the predicted resource demand density distribution map in the next cycle, the execution of the preloading strategy is automatically triggered to replace the corresponding part in the original target scheduling strategy set.

[0189] The actual demand match is detected by comparing the real-time charging station utilization rate with the predicted value. For example, at 2:10 PM, the utilization rate of charging station P is 68% (predicted value is 70%), with a deviation of ≤5%, indicating a match. The system automatically activates the preloading strategy, replacing bus L's original route from "charging station M" with "charging station P." This also frees up charging station M's resources for other vehicles to use, achieving dynamic optimization.

[0190] Please refer to Figure 3 , is a block diagram of the structure of the computer system 120 of the present application. The computer system 120 includes a computing unit 1001, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 1002 or a computer program loaded from a storage unit 1008 into a random access memory (RAM) 1003. Various programs and data required for the operation of the computer system 120 can also be stored in the RAM 1003. The computing unit 1001, ROM 1002, and RAM 1003 are connected to each other via a bus 1004. An input / output (I / O) interface 1005 is also connected to the bus 1004.

[0191] Multiple components in the computer system 120 are connected to the I / O interface 1005, including: an input unit 1006, an output unit 1007, a storage unit 1008, and a communication unit 1009. The input unit 1006 can be any type of device that can input information to the computer system 120. The input unit 1006 can receive input digital or character information and generate key signal input related to user settings and / or function control of the server, and can include but is not limited to a mouse, a keyboard, a touch screen, a trackpad, a trackball, a joystick, a microphone, and / or a remote control. The output unit 1007 can be any type of device that can present information, and can include but is not limited to a display, a speaker, a video / audio output terminal, a vibrator, and / or a printer. The storage unit 1008 can include but is not limited to a magnetic disk and an optical disk. The communication unit 1009 allows the computer system 120 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks, and may include, but is not limited to, a modem, a network card, an infrared communication device, a wireless communication transceiver and / or a chipset, such as a Bluetooth™ device, an 802.11 device, a WiFi device, a WiMax device, a cellular communication device, and / or the like.

[0192] The computing unit 1001 can be a variety of general-purpose and / or specialized processing components with processing and computing capabilities. Some examples of the computing unit 1001 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units that run machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The computing unit 1001 performs the various methods and processes described above, such as method 200. For example, in some embodiments, method 200 can be implemented as a computer software program that is tangibly contained in a machine-readable medium, such as storage unit 1008. In some embodiments, part or all of the computer program can be loaded and / or installed on the computer system 120 via ROM 1002 and / or communication unit 1009. When the computer program is loaded into RAM 1003 and executed by the computing unit 1001, one or more steps of the method 200 described above can be performed. Alternatively, in other embodiments, the computing unit 1001 can be configured to perform method 200 in any other appropriate manner (e.g., by means of firmware).

[0193] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this application can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this application can be achieved. This is not limited herein.

[0194] Although the embodiments or examples of the present application have been described with reference to the accompanying drawings, it should be understood that the above-mentioned methods, systems and devices are merely exemplary embodiments or examples, and the scope of the present invention is not limited by these embodiments or examples, but is only limited by the claims after authorization and their equivalents. Various elements in the embodiments or examples may be omitted or replaced by their equivalents. In addition, the steps may be performed in an order different from that described in this application. Further, the various elements in the embodiments or examples may be combined in various ways. It is important that as technology evolves, many of the elements described herein may be replaced by equivalent elements that appear after this application.

Claims

1. A bus system full data comprehensive management and analysis method based on big data, characterized by: The method comprises: Collecting real-time operation data sets uploaded by multiple bus terminals in the target area, the real-time operation data sets including vehicle location data, energy consumption data and task execution status data; Extract the timestamp sequence and geographic coordinate sequence of vehicle location data from the real-time operation data set, perform segmented aggregation processing on the timestamp sequence to generate a time window feature sequence, and perform trajectory cluster analysis on the geographic coordinate sequence to generate a high-frequency path feature set; perform energy consumption fluctuation detection on the energy consumption data, extract the abnormal energy consumption period and the corresponding energy consumption deviation value of each bus terminal, and match the abnormal energy consumption period with the time window feature sequence to generate an energy consumption correlation feature set; match the task execution status data with a preset task type label to generate a task state code sequence, and divide the task state code sequence into multiple continuous state transition subsequences according to a preset time window parameter, wherein each state transition subsequence contains a change record of the task state code within an adjacent time window; perform statistics on the conversion relationship between adjacent task state codes in each state transition subsequence to generate a state transition frequency distribution table corresponding to each state transition subsequence, wherein the state transition frequency distribution table records the number of jumps and jump directions between different task state codes; calculate the high-frequency jumps in each state transition subsequence according to the state transition frequency distribution table. The transfer frequency of the path, and based on the transfer frequency, the target jump path set that meets the preset frequency threshold is screened; the starting state code and the ending state code of each target jump path are extracted from the target jump path set, the starting state code is matched with the preset inefficient task state label to determine the inefficient path set, and the ending state code is matched with the preset efficient task state label to determine the efficient path set; time window association analysis is performed on the paths in the inefficient path set and the efficient path set, and the success rate of the conversion from the inefficient path to the efficient path in each time window is counted to generate a state conversion efficiency curve; according to the fluctuation amplitude and trend direction of the state conversion efficiency curve, the task state code combination corresponding to the peak efficiency period is extracted, and the task state code combination is mapped and matched with the preset efficiency evaluation template to generate the task execution efficiency feature set; the high-frequency path feature set, the energy consumption correlation feature set and the task execution efficiency feature set are normalized, and the bus operation feature set is fused to generate the bus operation feature set, and the bus operation feature set is anomaly identified based on the preset anomaly detection model to determine the abnormal operation event set; Performing spatiotemporal correlation mapping between the bus operation feature set and the historical operation data set to construct a bus operation knowledge graph, and calling a pre-trained multi-task optimization model to perform dynamic path planning and resource allocation analysis on the bus operation knowledge graph to generate a target scheduling strategy set; Adjusting the priority of the abnormal operation event set according to the target scheduling strategy set, generating a bus scheduling optimization instruction set and issuing it to the corresponding bus terminal; Based on the execution feedback data of the bus scheduling optimization instruction set, the weight parameters of the multi-task optimization model and the historical operation data set are updated.

2. The method according to claim 1, characterized in that The pre-trained multi-task optimization model is called to perform dynamic path planning and resource allocation analysis on the bus operation knowledge graph to generate a target scheduling strategy set, including: Extracting the spatiotemporal dependency relationship between bus nodes from the bus operation knowledge graph, constructing a node association weight matrix, and generating an initial path planning set based on the node association weight matrix; Inputting the initial path planning set into the path optimization branch of the multi-task optimization model, and generating an optimized path candidate set through constraint screening and resource occupancy prediction; Synchronously calling the resource allocation branch of the multi-task optimization model, performing resource demand matching analysis on each path in the optimization path candidate set, and determining the resource allocation priority of each path; The optimized path candidate set is sorted according to the resource allocation priority, and a path that meets a preset resource threshold is selected as the target scheduling strategy set.

3. The method according to claim 2, characterized in that The training method of the multi-task optimization model includes: Obtain a historical bus operation data set and a corresponding annotated scheduling strategy set, perform spatiotemporal feature enhancement processing on the historical bus operation data set, and generate an enhanced training data set; Construct an initial multi-task neural network and set the path optimization loss function and resource allocation loss function; Inputting the enhanced training data set into the initial multi-task neural network, generating a predicted path set through the path optimization branch and generating a predicted resource allocation set through the resource allocation branch; Calculating a path matching degree between the predicted path set and the marked scheduling strategy set to generate a first gradient value of the path optimization loss function; Calculating the difference between the predicted resource allocation set and the resource annotation data in the annotation scheduling strategy set to generate a second gradient value of the resource allocation loss function; The parameters of the initial multi-task neural network are jointly optimized according to the first gradient value and the second gradient value until the path optimization loss function and the resource allocation loss function converge, thereby obtaining the multi-task optimization model.

4. The method according to claim 1, wherein The step of adjusting the priority of the abnormal operation event set according to the target scheduling strategy set to generate a bus scheduling optimization instruction set includes: Extracting the urgency label and impact range parameter of each abnormal operation event from the abnormal operation event set, and constructing an event priority scoring matrix; Performing weighted fusion on the event priority scoring matrix and the path resource occupancy rate in the target scheduling strategy set to generate a dynamically adjusted weight set; Rearranging the execution order of the paths in the target scheduling strategy set based on the dynamically adjusted weight set to generate an optimized scheduling sequence; The scheduling sequence is converted into an instruction format executable by the bus terminal to generate the bus scheduling optimization instruction set.

5. The method according to claim 4, characterized in that The re-arranging the execution order of the paths in the target scheduling strategy set based on the dynamically adjusted weight set includes: Performing conflict detection on each path in the target scheduling policy set according to the weight values ​​in the dynamically adjusted weight set to determine a set of path pairs with resource conflicts; Performing an alternative path search on the set of path pairs with resource conflicts, generating an alternative path candidate set, and calculating the resource consumption increment of each alternative path; According to the resource consumption increment and the weight values ​​in the dynamically adjusted weight set, an alternative path with the highest comprehensive score is selected to replace the original conflicting path, and an updated scheduling sequence is generated.

6. The method according to claim 1, characterized in that The updating of the weight parameters of the multi-task optimization model and the historical operation data set based on the execution feedback data of the bus scheduling optimization instruction set includes: Extracting actual path execution time, resource consumption deviation value and task completion status indicator from the execution feedback data to generate a model feedback feature set; Compare the model feedback feature set with the predicted path execution time, predicted resource consumption value, and predicted task completion status in the target scheduling strategy set to generate a time error distribution, a resource error distribution, and a task error distribution; Determining a time weight parameter of a path optimization branch, a resource weight parameter of a resource allocation branch, and a task completion weight parameter of the multi-task optimization model according to the time error distribution, the resource error distribution, and the task error distribution; Based on the time weight parameter, resource weight parameter and task completion weight parameter, the weight matrices of the path optimization branch and the resource allocation branch of the multi-task optimization model are gradient updated layer by layer; The actual path execution time, resource consumption deviation value and task completion status indicator in the execution feedback data are added to the historical operation data set, and the updated historical operation data set is feature aligned to ensure consistency with the input format of the multi-task optimization model.

7. The method according to claim 6, characterized in that The method of comparing the model feedback feature set with the predicted path execution time, predicted resource consumption value, and predicted task completion status in the target scheduling strategy set to generate a time error distribution, a resource error distribution, and a task error distribution includes: Calculating the time difference between the actual path execution time and the predicted path execution time to generate a time error sequence, and performing sliding window statistics on the time error sequence to generate a time error distribution; Calculating a resource consumption ratio between the resource consumption deviation value and the predicted resource consumption value to generate a resource error ratio sequence, and performing spatial region aggregation on the resource error ratio sequence to generate a resource error distribution; Calculating a state matching degree between the task completion state indicator and the predicted task completion state to generate a task error identification sequence, and performing grouping statistics on the task error identification sequence by task type to generate a task error distribution; Performing three-dimensional spatial mapping on the time error distribution, resource error distribution, and task error distribution to generate a joint error distribution map including the time dimension, resource dimension, and task dimension; Regions where the error density exceeds a preset threshold are extracted from the joint error distribution map and marked as high-error regions. The high-error regions are mapped and associated with the network layer nodes of the multi-task optimization model to determine the set of model nodes that need to be optimized first.

8. The method according to claim 1, characterized in that The training method of the preset anomaly detection model includes: Extracting normal operation data segments and manually annotated abnormal data segments from the historical operation data set to construct a balanced training data set; Performing sliding window segmentation on the balanced training data set to generate multiple training sample segments, and performing feature normalization processing on each training sample segment; Constructing an initial anomaly detection neural network and using a contrastive learning strategy to perform feature separation training on the normal operation data segment and the abnormal data segment; Optimizing the decision boundary parameters of the initial anomaly detection neural network by calculating the feature distance loss between normal samples and abnormal samples; When the feature distance loss is lower than a preset threshold, freezing the parameters of the initial anomaly detection neural network to obtain the preset anomaly detection model; The method of performing feature separation training on the normal operation data segment and the abnormal data segment using a contrastive learning strategy includes: Perform data augmentation on each training sample segment to generate positive sample pairs and negative sample pairs, where the positive sample pairs come from the same data category and the negative sample pairs come from different data categories; Inputting the positive sample pairs and the negative sample pairs into the initial anomaly detection neural network, extracting high-dimensional feature vectors and calculating feature similarity; Constructing a contrast loss function based on the feature similarity and optimizing the embedding space parameters of the initial anomaly detection neural network by gradient descent method; The iteration is repeated until the contrast loss function converges, so that normal samples and abnormal samples form a significantly separated area in the embedding space.

9. A computer system, characterized in that: include: at least one processor; and a memory communicatively coupled to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 8.