A port container intelligent scheduling method and system based on real-time data
Patent Information
- Application Number
- CN202611245630.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-17
- Publication Date
- 2026-10-16
AI Technical Summary
[0004]由于不同设备的采样频率、网络传输时延存在差异,调度时刻获取的最新状态实际对应多个不同的物理时刻,将其作为同时刻快照计算易出现时间判断偏差,点值预测未考虑数据时效折减,易出现计算阶段判定可行但实际执行时车辆或设备空等的情况;同时交换位为有限容量资源,前序任务延迟易沿任务链传播造成多设备阻塞,现有方案未对串联交接的阻塞风险进行针对性处理,调度方案的现场适配性存在不足
[0008] The beneficial effects of this application are as follows: This solution addresses scheduling scenarios with inconsistent real-time data from multiple sources. By incorporating the impact of data freshness into scheduling calculations and quantifying the prediction error range of data with different time-sensitive states, it can reduce handover judgment bias caused by state time differences. The solution considers the serial constraints of two handovers, identifying the risk of congestion propagation caused by uneven handover margins, which can reduce the probability of multi-device congestion caused by the spread of local time deviations along the task chain. The solution employs an adaptive inertial particle swarm search method, which can adjust the search intensity according to the feasibility of the current scheduling scheme, balancing the global search range and local convergence accuracy, generating a scheduling scheme adapted to the on-site conditions within the allowable computation time for terminal scheduling. The final scheduling instructions generated by the solution clearly define equipment allocation, work order, and handover time slots, matching the occupancy status of physical equipment and exchange positions, reducing the workload of manual on-site adjustments after the issuance of scheduling instructions.
Smart Images

Figure CN122927976A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent scheduling technology, specifically to a port container intelligent scheduling method and system based on real-time data. Background Technology
[0002] Port container handling operations employ a sequential operation mode involving quayside lifting equipment, horizontal transport equipment, and yard lifting equipment. Containers complete the entire process by sequentially passing through two physical handover stages: quayside pickup, horizontal transport, and yard unloading. With the increasing automation level of terminals, existing scheduling systems generally integrate various real-time data such as equipment positioning, controller status, task queues, and exchange occupancy. Based on real-time status calculations of equipment arrival times, task allocation and operation sequence schemes are generated to support on-site operations.
[0003] Existing scheduling schemes typically read the latest status values reported by various data sources, stitch together the status values from different sources into a system snapshot at the same moment, determine the feasibility of handover based on the equipment arrival time in point value form, and allocate transportation equipment and arrange the order of operations in combination with rules or heuristic algorithms. Some schemes use intelligent optimization algorithms to search for the optimal scheduling scheme and generate scheduling instructions with the goal of shortening the overall operation time.
[0004] Due to differences in sampling frequency and network transmission latency among different devices, the latest state obtained at the scheduling moment actually corresponds to multiple different physical moments. Using these as snapshots of the same moment for calculation can easily lead to time judgment errors. Point value prediction does not take into account the reduction of data timeliness, which can easily result in situations where the calculation stage determines that it is feasible, but the actual execution is delayed due to vehicles or equipment being idle. At the same time, the exchange bit is a limited capacity resource, and the delay of the preceding task can easily propagate along the task chain, causing multiple devices to be blocked. The existing solution does not specifically address the blocking risk of serial handover, and the field adaptability of the scheduling solution is insufficient. Summary of the Invention
[0005] This application provides a port container intelligent scheduling method and system based on real-time data, which solves the technical problems in the background art mentioned above.
[0006] This application provides a port container intelligent scheduling method based on real-time data, including the following steps: Step S1: Collect real-time data of candidate tasks, horizontal transportation equipment, lifting equipment and exchange positions, and generate data age based on the decision time and message source time; Step S2: Based on the baseline scheduling instance, remaining distance, equipment operation time, and queuing time, generate the transportation arrival time and lifting readiness time for container pick-up and unloading handover. Step S3: Generate the median of absolute error based on the arrival prediction absolute error of the completed handover, and generate the time uncertainty envelope by combining the data age, transportation error growth coefficient, lifting error growth coefficient and median of absolute error; Step S4: Generate a handover time margin based on the waiting time window, the time of transport arrival, the time of hoisting readiness, and the time uncertainty envelope; and generate a series handover margin based on the smallest value of the two handover time margins and the square of the difference. Step S5: Encode and initialize the particle positions and generate initial particle velocities. After decoding and conflict repair based on serial handover margin, obtain a particle scheduling instance. Step S6: Regenerate the serial handover margin based on the particle scheduling instance, update the particle velocity and particle position using the handover margin gap, generate the objective function value, and determine the global optimal scheduling instance accordingly. Step S7: Based on the global optimal scheduling instance, lock the start and end times of the lock for the two handover events, and generate a scheduling instruction sequence by combining the final horizontal transport equipment identifier and the final task execution order.
[0007] This application provides a port container intelligent scheduling system based on real-time data, including: The data age generation module is used to collect real-time data from candidate tasks, horizontal transportation equipment, lifting equipment, and exchange points, and generate data age based on the decision time and message source time. The handover time calculation module is used to generate the transportation arrival time and lifting readiness time for container pick-up and unloading handover based on the baseline scheduling instance, remaining distance, equipment operation time and queuing time. The uncertain envelope generation module is used to generate the median absolute error based on the arrival prediction absolute error of the completed handover, and to generate the time uncertain envelope by combining the data age, transportation error growth coefficient, lifting error growth coefficient and median absolute error. The handover margin generation module is used to generate a handover time margin based on the waiting time window, the time of transport arrival, the time of hoisting readiness, and the time uncertainty envelope, and to generate a series handover margin based on the minimum value of the two handover time margins and the square of the difference. The particle initialization module is used to encode and initialize particle positions and generate initial particle velocities. After decoding and conflict repair based on serial handover margin, a particle scheduling instance is obtained. The global optimal instance generation module is used to regenerate the serial handover margin based on the particle scheduling instance, update the particle velocity and particle position using the handover margin gap, generate the objective function value, and determine the global optimal scheduling instance accordingly. The scheduling instruction generation module is used to generate a sequence of scheduling instructions by locking the start and end times of the lock between two items according to the globally optimal scheduling instance, and combining the final horizontal transport equipment identifier and the final task execution order.
[0008] The beneficial effects of this application are as follows: This solution addresses scheduling scenarios with inconsistent real-time data from multiple sources. By incorporating the impact of data freshness into scheduling calculations and quantifying the prediction error range of data with different time-sensitive states, it can reduce handover judgment bias caused by state time differences. The solution considers the serial constraints of two handovers, identifying the risk of congestion propagation caused by uneven handover margins, which can reduce the probability of multi-device congestion caused by the spread of local time deviations along the task chain. The solution employs an adaptive inertial particle swarm search method, which can adjust the search intensity according to the feasibility of the current scheduling scheme, balancing the global search range and local convergence accuracy, generating a scheduling scheme adapted to the on-site conditions within the allowable computation time for terminal scheduling. The final scheduling instructions generated by the solution clearly define equipment allocation, work order, and handover time slots, matching the occupancy status of physical equipment and exchange positions, reducing the workload of manual on-site adjustments after the issuance of scheduling instructions. Attached Figure Description
[0009] To more clearly illustrate the technical solutions in the specific embodiments of this application or the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0010] Figure 1 A flowchart illustrating the calculation process of a port container intelligent scheduling method based on real-time data, provided in this application embodiment; Figure 2 A schematic diagram of candidate task time uncertainty envelope comparison provided in the embodiments of this application; Figure 3 This is a schematic diagram of the adaptive particle swarm scheduling iterative convergence provided in an embodiment of this application. Detailed Implementation
[0011] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.
[0012] It should be noted that, in the description of this application, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. The terms "first," "second," etc., in this application are used to distinguish similar objects and are not used to describe a specific order or sequence.
[0013] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0014] like Figure 1 As shown, a port container intelligent scheduling method based on real-time data includes the following steps: Step S1: Collect real-time data of candidate tasks, horizontal transportation equipment, lifting equipment and exchange positions, and generate data age based on the decision time and message source time; Step S2: Based on the baseline scheduling instance, remaining distance, equipment operation time, and queuing time, generate the transportation arrival time and lifting readiness time for container pick-up and unloading handover. Step S3: Generate the median of absolute error based on the arrival prediction absolute error of the completed handover, and generate the time uncertainty envelope by combining the data age, transportation error growth coefficient, lifting error growth coefficient and median of absolute error; Step S4: Generate a handover time margin based on the waiting time window, the time of transport arrival, the time of hoisting readiness, and the time uncertainty envelope; and generate a series handover margin based on the smallest value of the two handover time margins and the square of the difference. Step S5: Encode and initialize the particle positions and generate initial particle velocities. After decoding and conflict repair based on serial handover margin, obtain a particle scheduling instance. Step S6: Regenerate the serial handover margin based on the particle scheduling instance, update the particle velocity and particle position using the handover margin gap, generate the objective function value, and determine the global optimal scheduling instance accordingly. Step S7: Based on the global optimal scheduling instance, lock the start and end times of the lock for the two handover events, and generate a scheduling instruction sequence by combining the final horizontal transport equipment identifier and the final task execution order.
[0015] In one optional implementation, step S1 includes the following steps: Step S101: The operation of delivering the container from the starting lifting equipment to the target lifting equipment via the horizontal transport equipment is identified as a candidate task. A set of candidate tasks, a set of available horizontal transport equipment, and a set of handover stages are established. The set of handover stages includes container retrieval handover and container unloading handover. The candidate task set refers to all container loading and unloading tasks with pending resource allocation and execution order within the current scheduling period; The set of available horizontal transport equipment refers to horizontal transport equipment that is fault-free, unlocked, and capable of performing transport tasks within the current scheduling cycle. The handover phase refers to the two necessary physical handover processes during container loading and unloading, including container retrieval handover and container unloading handover. Step S102: At the decision time, collect the message source time, horizontal transport equipment position, effective average speed, remaining distance, remaining operation time of lifting equipment, transport queuing time, lifting queuing time, exchange position occupancy data and arrival prediction absolute error; for duplicate messages, only the one with the largest message source time value is retained, and if the message source time is later than the decision time, the corresponding candidate task is deleted from the candidate task set. The message source time refers to the device's local timestamp that is attached when the status message is generated, which is collected by reading the time field in the header of the message reported by the device controller; The location of horizontal transport equipment refers to the current coordinates of the dock road where the horizontal transport equipment, such as container trucks, is located. This data is collected in real time at a frequency of once per second through an on-board differential positioning terminal. Effective average speed refers to the actual average speed of horizontal transport equipment on the current operating section, which is calculated by collecting wheel speed pulse data within the past 30 seconds from the on-board controller. The remaining distance refers to the path length from the current location of the horizontal transport equipment to the target handover point, which is calculated and collected in real time through the path planning module of the dock's electronic map. The remaining operation time of the lifting equipment refers to the remaining time before the completion of the lifting action currently being performed by the quay crane or yard crane. The current action progress is collected by reading the programmable controller of the lifting equipment. Transportation queuing time refers to the estimated waiting time for the current candidate task to be transported by the preceding transportation task before the target exchange position of the horizontal transportation equipment, under the corresponding scheduling instance; The hoisting queue time refers to the estimated total operation time of all tasks in the hoisting equipment task queue that are ahead of the current task. It is collected and statistically analyzed in real time through the task queue module of the dock operating system. The occupancy data of the exchange position refers to the current occupancy status and release time of the exchange position on the shore or in the yard. The data is collected by photoelectric sensors at the exchange position and by equipment operation. The absolute error of arrival prediction refers to the absolute value of the difference between the predicted arrival time and the actual arrival time in historical handover tasks. It is collected by comparing historical prediction records with actual arrival timestamps. The decision moment refers to the trigger moment when the scheduling system initiates a scheduling calculation. It is set within 100 milliseconds after a new task enters the queue or an equipment status update event occurs, to match the real-time response requirements of the dock scheduling system with the balance of computing load. Step S103: Subtract the time of each message source from the decision time to obtain the data age of each candidate task at each handover stage and each resource category, and form real-time data that has passed the time verification. Data age refers to the difference between the decision time and the corresponding state message source time, which is obtained by subtracting the message source time from the decision time. Specifically, the formula for calculating the age of the data is as follows: ; in, Indicates the first The candidate task in the ... Each handover stage corresponds to a resource category Data age, Indicates the moment of decision-making. Indicates the first The candidate task in the ... Each handover stage corresponds to a resource category News source time, resource category Pick or , respectively, represent horizontal transport equipment or lifting equipment.
[0016] Furthermore, before a candidate task enters the scheduling process, four checks are performed sequentially: container number check to verify that the container number matches the container number recorded in the work order in the terminal operating system; container location check to verify that the target container location exists in the yard or ship bay and is not locked by other tasks; operation direction check to verify that the task is a legal operation type among loading, unloading, stacking, or moving containers; and equipment accessibility check to verify that the operation range of the assigned horizontal transport equipment and lifting equipment covers the start and end points of the task. Only tasks that pass all four checks can enter the candidate task set. For example, if the container number of a certain unloading task matches the container number recorded in the work order, the target container location is in bay 5 of zone 3 of the yard, the operation direction is unloading from the ship to the container, and the assigned truck operation range covers the travel path from the quay crane to zone 3, then the task passes the checks and enters the candidate set.
[0017] For duplicate messages, only the message with the largest value at the time of the message source is retained, and the rest of the duplicate messages are discarded.
[0018] If the message source time is later than the decision time, the corresponding candidate task is removed from the candidate task set for this scheduling.
[0019] Understandably, multi-source real-time data comes from different device controllers and systems, with differences in sampling frequency and network transmission latency. The latest state read is not a snapshot of the same physical moment. Defining data age by the difference between the decision time and the message source time can unify state data from different sources under the same decision time benchmark, quantify the freshness of each type of state data, and provide a unified metric for subsequent time uncertainty calculations. Message deduplication can avoid calculation errors caused by the same state being counted repeatedly, and clock anomaly verification can filter invalid data caused by device clock drift. Both types of verification together ensure that the input data for subsequent timeliness loss calculations is consistent and valid, reducing scheduling misjudgments caused by invalid data.
[0020] In one optional implementation, step S2 includes the following steps: Step S201: Maintain the device allocation and task execution order of locked tasks, arrange the unlocked tasks in ascending order of their original task numbers to form a baseline scheduling instance; set a scheduling instance index for marking the baseline scheduling instance and the particle scheduling instance, wherein a scheduling instance index of 0 represents a baseline scheduling instance, and a combination of the particle index and the iteration index represents a particle scheduling instance. The baseline scheduling instance construction rule refers to the task sorting and device allocation rules for constructing the baseline scheduling instance. It is set that locked tasks remain unchanged, unlocked tasks are sorted in ascending order of their original task numbers, and devices are allocated according to their current idle priority. This is used to reflect the current system's default scheduling state and serve as a comparison reference for other scheduling instances. The scheduling instance index is a unique identifier used to distinguish different scheduling schemes. The baseline instance index is 0, and the particle scheduling instance index is generated by combining the particle number and the iteration number. Step S202: Determine the remaining distance based on the location of the horizontal transport equipment, divide the remaining distance by the effective average speed to obtain the time, add it to the transport queuing time, and then add it to the decision time to obtain the transport arrival time of each candidate task in the container pick-up and drop-off handover. The transport arrival time refers to the absolute time when the horizontal transport equipment is expected to arrive at the target handover point. It is obtained by adding the remaining distance to the decision time, dividing the travel time by the effective average speed, and then adding the transport queuing time. Specifically, the formula for calculating the arrival time of transportation is as follows: ; in, Represents a scheduling instance Next The candidate task in the ... The arrival time of transportation at each handover stage, Indicates the moment of decision-making. Represents a scheduling instance Lower horizontal transport equipment to the first The first candidate task The remaining distance of each handover phase Represents a scheduling instance Next execution The effective average speed of the horizontal transport equipment for each candidate task Represents a scheduling instance The next transport task is to the first The first candidate task Transportation queuing time formed during each handover phase, scheduling example Pick The time represents the baseline scheduling instance, and takes Time indicates the first In the nth iteration A particle scheduling instance of one particle.
[0021] Step S203: Add the remaining time of the lifting equipment operation to the lifting queuing time, and then add it to the decision time to obtain the lifting readiness time of each candidate task in the container retrieval and unloading handover. The lifting readiness time refers to the absolute moment when the lifting equipment is expected to complete its current task and the tasks preceding it in the queue, and can then execute the current task. It is obtained by adding the decision time to the remaining time of the lifting equipment's operation and the lifting queuing time. Specifically, the formula for calculating the lifting readiness time is as follows: ; in, Represents a scheduling instance Next The candidate task in the ... The moment of hoisting readiness during the handover phase. Indicates the moment of decision-making. Represents a scheduling instance Lower lifting equipment for the first The first candidate task Remaining time for lifting equipment operation during the handover phase. Represents a scheduling instance The next lifting task is to the first The first candidate task The hoisting queue time formed during each handover phase, scheduling example Pick The time represents the baseline scheduling instance, and takes Time indicates the first In the nth iteration A particle scheduling instance of one particle.
[0022] Step S204: Obtain the transport arrival time and lifting readiness time of the baseline scheduling instance at the container pick-up and drop-off handover. The particle scheduling instance generates the corresponding transport arrival time and lifting readiness time using the same calculation order.
[0023] Furthermore, the remaining distance is calculated based on the preset drivable routes on the terminal's electronic map. During the calculation process, temporarily closed sections and restricted areas are excluded, and temporary detour distances caused by dynamic obstacle avoidance are not considered. Only the shortest path length under the current drivable route is counted. For example, if a truck is currently located below the No. 1 quay crane operation point and the target handover point is the exchange position in the No. 2 storage yard, and the No. 1 section of the main road is temporarily closed, the remaining distance is calculated as 1200 meters based on the path length of detouring through the No. 2 section of the main road.
[0024] Both transport queuing time and hoisting queuing time are calculated by adding up the estimated operation time of the preceding tasks one by one. The transport queuing time is calculated by adding up the estimated handover time of all horizontal transport equipment waiting to enter before the target exchange position. The hoisting queuing time is calculated by adding up the estimated hoisting operation time of all tasks in the hoisting equipment task queue that are ahead of the current task. Random disturbance time generated during the actual waiting process is not counted.
[0025] The particle scheduling instance reuses all the fixed parameters of the baseline scheduling instance, including fixed configuration parameters such as dock path length, equipment operation standard duration, and exchange capacity. Only the execution order of unlocked tasks and the allocation results of horizontal transportation equipment are adjusted. All particle scheduling instances use the same time calculation formula and parameter caliber as the baseline instance to ensure that the prediction results of different scheduling instances can be compared.
[0026] Understandably, the baseline scheduling instance is generated according to the current system's default scheduling rules, reflecting the system's operational status before optimization and adjustment. Applying the same time prediction rules to all particle scheduling instances can eliminate the differences in results caused by different calculation methods, giving the time prediction results of different scheduling schemes a unified comparison benchmark and avoiding errors in judging the merits of schemes due to different calculation rules.
[0027] In one optional implementation, step S3 includes the following steps: Step S301: Select the handover records with complete timestamps from the completed handover records of the same equipment combination and the same handover stage, calculate the rolling median of the absolute error of the prediction, and obtain the median of the absolute error. The median absolute error refers to the median of the historical prediction absolute errors of the same type of handover task with the same equipment combination. It is obtained by taking the middle value after sorting the absolute error values of the most recent 50 handover tasks of the same type. Step S302: Add the product of the data age of the horizontal transport equipment and the transport error growth coefficient, the product of the data age of the lifting equipment and the lifting error growth coefficient, and the median of the absolute error to obtain the time uncertainty envelope of each candidate task in each handover stage. The transport error growth coefficient refers to the time error conversion ratio corresponding to the data age of horizontal transport equipment. It is obtained by collecting prediction error data of horizontal transport equipment at different data ages over the past 30 days and fitting it using the least squares method. The value ranges from 0.1 to 0.3. The lifting error growth coefficient refers to the time error conversion ratio corresponding to the data age of the lifting equipment. It is obtained by collecting the prediction error data of different data ages of the lifting equipment in the past 30 days and fitting it with the least squares method. The value range is from 0.05 to 0.2. The time uncertainty envelope refers to the range of uncertainty in the handover time prediction caused by the combined effects of data age and historical errors. It is obtained by multiplying the transportation error growth coefficient by the transportation data age, adding the lifting error growth coefficient by the lifting data age, and then adding the median of the absolute error. Specifically, the formula for calculating the time-determined envelope is as follows: ; in, Indicates the first The candidate task in the ... The time envelope for each handover phase is uncertain. This represents the growth factor of transportation errors. Indicates the first The candidate task in the ... The data age of the horizontal transport equipment corresponds to each handover stage. This represents the lifting error growth factor. Indicates the first The candidate task in the ... The age of the lifting equipment corresponds to each handover stage. Indicates the first The device combination corresponding to the candidate task is in the first The median absolute error of each handover stage.
[0028] Furthermore, the statistical window for the rolling median is set to the 50 most recently completed handover tasks of the same type. If the sample size is less than 50, all completed handover tasks of the same type are taken. Each time a new handover task is completed, the oldest record is removed from the statistical window and the latest handover error record is added. For example, if the container pick-up handover between a certain quay crane and container truck No. 1 has been completed 32 times, the median is calculated after sorting the prediction absolute errors of these 32 handovers. After the 51st handover is completed, the record of the first handover is removed and the record of the 51st handover is added.
[0029] For identical equipment combinations, the specific equipment number combination is used for determination. That is, container pick-up handover is divided into statistical groups according to the combination of quay crane number and horizontal transport equipment number, and container drop-off handover is divided into statistical groups according to the combination of yard crane number and horizontal transport equipment number. The handover error of different number combinations is counted separately and is not combined according to equipment type.
[0030] The two types of error growth coefficients were obtained through offline calibration. During the calibration process, actual prediction error samples were collected under different data ages. The linear coefficients were fitted with the goal of minimizing the sum of squared errors. After calibration, the values were fixed and put into use. Subsequently, the coefficients were recalibrated every 30 days using newly added historical operation data. The coefficient values were adjusted according to the equipment performance and network status of different terminals. Larger values were used for terminals with large network latency fluctuations, and smaller values were used for terminals with stable networks.
[0031] Understandably, the older the data is, the greater the deviation between the current state data and the actual state, and the greater the corresponding prediction error. By multiplying the data ages of the two types of equipment by the corresponding error growth coefficients and then adding the median of the prediction error from historical statistics, a time uncertainty envelope can be linearly synthesized. This allows for an intuitive quantification of the confidence interval for the handover time prediction under the current state data, avoiding the use of point value prediction results as certain values to judge the feasibility of the handover.
[0032] In one optional implementation, step S4 includes the following steps: Step S401: Determine the waiting time window for each candidate task in each handover stage based on the exchange capacity, safe occupancy time limit, and the maximum allowable waiting time for non-preemptive lifting action; The waiting time window refers to the maximum allowed waiting time on one side during a single handover, ranging from 30 seconds to 120 seconds. It is determined by combining the exchange capacity, the safe occupancy time limit, and the maximum allowable waiting time for non-preemptive lifting actions. Step S402: Calculate the absolute value of the difference between the transportation arrival time and the hoisting readiness time, subtract the absolute value and the time uncertainty envelope from the waiting time window to obtain the handover time margin; The handover time margin refers to the remaining waiting time after deducting the time difference and uncertainty envelope for a single handover. It is obtained by subtracting the absolute value of the difference between the arrival time of transportation and the ready-to-lift time from the waiting time window, and then subtracting the time uncertainty envelope. Specifically, the formula for calculating the handover time margin is as follows: ; in, Represents a scheduling instance Next The candidate task in the ... The handover time margin for each handover stage. Indicates the first The candidate task in the ... The waiting time window for each handover phase. Represents a scheduling instance Next The candidate task in the ... The arrival time of transportation at each handover stage, Represents a scheduling instance Next The candidate task in the ... The moment of hoisting readiness during the handover phase. Indicates the first The candidate task in the ... The time envelope of the handover phase is uncertain.
[0033] Step S403: Calculate the square of the difference between the handover time margin of the box pick-up handover and the box drop-off handover. Divide the square of the difference by the sum of the absolute values of the two handover time margins and the sum of the numerical stability time term. Then multiply it by the margin imbalance penalty coefficient to obtain the margin imbalance deduction amount. The margin imbalance penalty coefficient refers to the penalty intensity coefficient for the difference in margin between two handovers. The value ranges from 0.2 to 0.5, and is determined in combination with the probability of blockage propagation caused by the imbalance of handover margins in dock operations. The numerical stability time term refers to a fixed time value in the calculation formula that avoids the denominator being zero; the preferred value is 1 second. The margin imbalance deduction refers to the margin reduction value of the series system caused by the difference in margins between two handovers. It is obtained by multiplying the margin imbalance penalty coefficient by the square of the difference between the two handover margins, dividing by the sum of the absolute values of the two handover margins, and adding the numerical stability time term. Step S404: Subtract the unbalanced margin deduction from the smallest value of the handover time margin between the box pick-up handover and the box drop-off handover to obtain the serial handover margin of the baseline scheduling instance. The series handover margin refers to the comprehensive executable margin after considering the series constraints and imbalance effects of the two handovers. It is obtained by subtracting the margin imbalance deduction from the minimum of the two handover timeliness margins. Specifically, the formula for calculating the series connection margin is as follows: ; in, Represents a scheduling instance Next The concatenation and handover margin of each candidate task. Represents a scheduling instance Next The handover time margin for each candidate task in the box retrieval and handover process. Represents a scheduling instance Next The handover time margin for each candidate task in the box handover process. Indicates the penalty coefficient for uneven balance of margin and , Indicates a numerically stable time term and greater than .
[0034] Furthermore, the waiting time window is the minimum of the average waiting time when the exchange station is at full capacity, the maximum waiting time required by the safety occupancy time limit, and the maximum waiting time allowed for non-rushing lifting operations. For example, if a certain shore-side exchange station has 2 parking spaces, the average waiting time at full capacity is 90 seconds, the safety regulations require that the single occupancy of the exchange station not exceed 120 seconds, and the maximum waiting time allowed for non-rushing operations of the quay crane is 60 seconds, then the waiting time window for this handover point is 60 seconds.
[0035] The penalty coefficient for unbalanced margin is set based on the probability of blockage caused by unbalanced margin in the terminal's historical operations. When historical data shows that the difference between two margins exceeds 30 seconds, the probability of blockage increases by more than 30%, so a larger penalty coefficient is used. If the probability of blockage increases by less than 10%, a smaller penalty coefficient is used. Once the coefficient is fixed, it remains unchanged within a scheduling cycle and is not adjusted with individual tasks.
[0036] The numerical stability time term is fixed at 1 second to avoid the anomaly of the denominator being zero during the calculation process.
[0037] It is understandable that the two handovers of container loading and unloading are in a series relationship. Failure of either handover will cause the entire task to be blocked. Taking the minimum value of the two handover margins is difficult to identify the risk of blockage propagation caused by one being lenient and the other being urgent. By adding a margin imbalance penalty to the minimum value, the weakest link of the series system and the chain blockage risk caused by the margin imbalance can be identified at the same time, which more accurately reflects the actual executability of the task.
[0038] In one optional implementation, step S5 includes the following steps: Step S501: Set the particle position dimension to twice the number of candidate tasks, with the first half of the particle position used as the task priority key and the second half used as the device allocation key. The particle position dimension rule refers to the rule for setting the dimension of the particle position vector. It is set to twice the number of candidate tasks. The first half of the dimension corresponds to the task priority, and the second half of the dimension corresponds to the device allocation. The task priority key refers to the continuous values of the first half of the particle's position dimension, which are used to determine the execution order of tasks. The smaller the value, the higher the task execution priority. The device allocation key refers to the continuous value of the second half of the dimension of the particle's position, which is used to determine the horizontal transport device assigned to the task. If the particle falls into the corresponding device range, that device will be assigned. Specifically, the formula for calculating the particle position dimension is as follows: ; in, Indicates the dimension of the particle position. This indicates the number of candidate tasks.
[0039] Step S502: Set the center order of the task priority key according to the ascending order of the serial handover margin of the baseline scheduling instance, and add different continuous perturbations between particles around the center order; divide the equipment allocation key into equal-width intervals according to the number of equipment in the available horizontal transport equipment set, and map each equal-width interval to a horizontal transport equipment identifier. The device allocation key interval mapping rule refers to the rule for mapping continuous values of device allocation keys to specific devices. It is set to divide the continuous interval from 0 to 1 into a corresponding number of sub-intervals according to the number of available devices. Each sub-interval corresponds to a device number, which satisfies the unique mapping requirement from continuous values to discrete devices. Step S503: Generate the task execution order according to the ascending order of the task priority key, and determine the horizontal transportation equipment according to the equal width interval where the equipment allocation key is located, and obtain the particle scheduling instance; Step S504: Recalculate the serial handover margin for tasks with overlapping time slots at the same exchange position; if there are tasks with a serial handover margin less than 0, assign the task sequentially to the available horizontal transport equipment that minimizes the sum of the absolute values of the differences between the transport arrival time of the container pick-up handover and the container drop-off handover and the hoisting ready time; if there are no tasks with a serial handover margin less than 0, arrange them in ascending order according to the serial handover margin, and if the values are the same, arrange them in ascending order according to the original task number. The conflict resolution priority rule refers to the task adjustment priority rule when there is a swap conflict. It is set to prioritize the task with the smaller serial handover margin to occupy the earlier time slot. When the margins are the same, the task with the smaller original task number is prioritized. This matches the scheduling principle of prioritizing vulnerable tasks. Step S505, conflict resolution only changes the horizontal transport equipment allocation and task execution order for tasks that have not yet started, and generates initial particle positions, initial particle velocities, and initial particle scheduling instances.
[0040] The initial particle position refers to the position vector of each particle when the particle swarm is initialized. The first half of the dimension is generated with random perturbation centered on the order corresponding to the ascending order of the baseline concatenation and intersection margin. The second half of the dimension is randomly generated in the interval between 0 and 1. Initial particle velocity refers to the velocity vector of each particle when the particle swarm is initialized, with all dimensions randomly generated within the range of -0.1 to 0.1; An initial particle scheduling instance refers to an executable scheduling scheme obtained after decoding the initial particle positions and repairing conflicts, which includes the task order and device allocation results. Furthermore, continuous perturbations are generated using uniform random numbers in the range of -0.2 to 0.2. Values exceeding the range of 0 to 1 after perturbation are truncated to the boundary value. For example, if the center value of the priority key for a certain task is 0.3, and the generated random perturbation is 0.15, the priority key for that task is 0.45; if the generated random perturbation is -0.2, the priority key for that task is 0.1.
[0041] The equipment allocation key has a fixed value range of 0 to 1. It is divided into left-closed and right-open intervals according to the number of available horizontal transport equipment. The first interval is 0 to 1 divided by the number of equipment, corresponding to the available equipment with the smallest number. Subsequent intervals are arranged sequentially. The last interval contains the value 1. For example, if there are 5 available equipment, then 0 to 0.2 corresponds to equipment number 1, 0.2 to 0.4 corresponds to equipment number 2, and so on. 0.8 to 1 corresponds to equipment number 5. The equipment allocation key is assigned to the equipment with the corresponding number depending on which interval it falls into.
[0042] The determination of overlapping time slots for swapping positions is based on the existence of an intersection between the handover time intervals of two tasks. When the handover start time of the latter task is earlier than the handover end time of the former task, it is determined to be a time slot overlap. No additional buffer threshold is set. After the overlap is detected, conflict repair is performed. The earlier time slot of the task with the smaller serial handover margin is retained, and the task with the larger serial handover margin is adjusted to the time slot after the swapping position is released. If the margins are the same, the task with the larger original task number is adjusted.
[0043] Understandably, if priority keys are generated completely randomly during particle initialization, a large number of infeasible initial solutions will be produced, increasing the computational burden of subsequent iterations. Determining the center order of priority keys by ascending order of the baseline concatenation handover margin allows tasks with smaller concatenation margins and a higher likelihood of handover mismatch to receive higher scheduling priority during initialization, prioritizing stable handover slots and improving the overall quality of initial solutions. Initialization based on margin priority combined with deterministic conflict resolution ensures that all scheduling instances corresponding to initial particles satisfy the swap position occupancy constraint, reducing the number of infeasible solutions in subsequent iterations, compressing the invalid search space, and improving the optimization efficiency of the particle swarm.
[0044] In one optional implementation, step S6 includes the following steps: Step S601: Using the initial particle scheduling instance as the particle scheduling instance for the first iteration, recalculate the transportation arrival time, hoisting readiness time, handover time margin, and series handover margin for each particle scheduling instance in each iteration. Step S602: Take the absolute value of the serial handover margins that are less than 0 and sum them up. Divide the sum by the product of the number of candidate tasks and the reference time to obtain the handover margin gap. Reference time refers to a fixed time value used for normalization of time-related targets. The preferred value is 600 seconds, which is 10 times the average operation time of a single task at the dock, to ensure that the normalized value is within a reasonable range. The handover margin gap refers to the normalized value of the sum of the negative margins of all infeasible tasks in the scheduling instance, which is obtained by dividing the sum of the absolute values of the negative margins of all tasks by the number of tasks and then by the reference time. Specifically, the formula for calculating the handover margin gap is as follows: ; in, Indicates the first In the nth iteration The gap in the transfer of individual particles Indicates the number of candidate tasks. Indicates greater than Reference time, Indicates the first In the nth iteration In the particle scheduling instance of the nth particle, the first The concatenation and handover margin of each candidate task.
[0045] Step S603: Divide the handover margin gap by the sum of the handover margin gap and 1, multiply the resulting ratio by the difference between the upper bound and the lower bound of the inertia coefficient, and then add it to the lower bound of the inertia coefficient to obtain the adaptive inertia coefficient. The lower bound of the inertia coefficient refers to the minimum value of the particle's inertia coefficient, preferably 0.4, to ensure the particle's local search capability during the convergence phase. The upper bound of the inertia coefficient refers to the maximum value of the particle's inertia coefficient, with a preferred value of 0.9 to ensure the particle's global search capability during the exploration phase. The adaptive inertia coefficient refers to the particle inertia coefficient that is dynamically adjusted according to the handover margin gap. It is obtained by multiplying the difference between the lower and upper bounds of the inertia coefficient by the handover margin gap, dividing by 1, and then adding the handover margin gap. Specifically, the formula for calculating the adaptive inertia coefficient is as follows: ; in, Indicates the first In the nth iteration The adaptive inertia coefficient of each particle. This indicates the lower bound of the inertia coefficient. Indicates the upper bound of the inertia coefficient and , Indicates the first In the nth iteration The gap in the transfer of individual particles.
[0046] Step S604: Perform discrete event calculation on the particle scheduling instance to obtain the task completion time; normalize the task completion time, the handover synchronization deviation formed by the absolute value of the difference between the transportation arrival time and the hoisting ready time, and the handover reserve gap respectively, and multiply them by the completion time weight, the handover synchronization deviation weight and the reserve gap weight respectively, and then sum them to obtain the objective function value. The completion time weight refers to the weight coefficient of the total completion time term in the objective function. The preferred value is 0.4, which corresponds to the degree of importance the scheduling scheme attaches to the overall operation efficiency. The handover synchronization deviation weight refers to the weight coefficient of the handover waiting time term in the objective function. The preferred value is 0.3, which corresponds to the degree of importance the scheduling scheme attaches to the equipment waiting time. The margin gap weight refers to the weight coefficient of the infeasible handover term in the objective function. The preferred value is 0.3, which corresponds to the degree of importance the scheduling scheme attaches to the feasibility of the scheme. Task completion time refers to the total time from the start of the first task to the completion of the last task in a scheduling instance, which is obtained by simulating the entire task execution process through discrete event deduction. The objective function value is a comprehensive indicator that measures the quality of scheduling instances. It is obtained by multiplying the completion time weight by the normalized completion time, adding the handover synchronization deviation weight by the normalized handover waiting time, and adding the margin gap weight by the handover margin gap. Specifically, the formula for calculating the objective function value is as follows: ; in, Indicates the first In the nth iteration The objective function value of each particle. Indicates the weight of completion time. Indicates the first In the nth iteration The time required for each particle to complete its task. Indicates reference time. Indicates the handover synchronization deviation weight. Indicates the number of candidate tasks. This represents the set of handover stages, including both container retrieval and container unloading. Indicates the first In the nth iteration In the particle scheduling instance of the nth particle, the first The candidate task in the ... The arrival time of transportation at each handover stage, Indicates the first In the nth iteration In the particle scheduling instance of the nth particle, the first The candidate task in the ... The moment of hoisting readiness during the handover phase. Indicates the weight of the margin gap. Indicates the first In the nth iteration The handover margin gap for each particle, the completion time weight, the handover synchronization deviation weight, and the margin gap weight are all not less than [amount missing]. And the sum of the three is .
[0047] Step S605: Update the individual optimal position and the global optimal position based on the objective function value; when the objective function values are the same, determine the corresponding positions in ascending order of the absolute value of the maximum negative surplus and in lexicographical order of task execution order. The optimal position of an individual particle refers to the position vector in which it obtains the minimum objective function value from initialization to the current iteration. The global optimal position refers to the position vector where all particles obtain the minimum objective function value from initialization to the current iteration. Step S606: Using the initial particle position and initial particle velocity as the particle position and particle velocity for the first iteration, update the particle velocity and particle position based on the adaptive inertia coefficient, particle velocity, particle position, individual optimal position, global optimal position, acceleration coefficient, first random number and second random number; after each particle position update, perform decoding and conflict repair. When the maximum number of iterations is reached, determine the global optimal scheduling instance based on the particle scheduling instance corresponding to the global optimal position. The acceleration factor refers to the acceleration factor for particles to converge to the individual optimum and the global optimum. The preferred value is 1.494, which adopts the standard convergence parameter setting of the particle swarm algorithm. The maximum number of iterations refers to the maximum number of iterations in the particle swarm search, with a preferred value of 200, to match the computation time constraints and convergence characteristics of the dock scheduling algorithm. The first random number refers to the random number corresponding to the individual's optimal term in the particle velocity update, which is uniformly and randomly generated within the interval of 0 to 1; The second random number refers to the random number corresponding to the global optimal term in the particle velocity update, which is uniformly and randomly generated in the interval between 0 and 1. Particle velocity refers to the change in particle position in each iteration, which is obtained by multiplying the adaptive inertia coefficient by the current velocity plus the acceleration coefficient plus the first random number plus the difference between the individual optimal and the current position plus the acceleration coefficient plus the second random number plus the difference between the global optimal and the current position. The particle position refers to the particle's current position vector in the solution space, which is obtained by adding the updated particle velocity to the current position. Specifically, the formula for calculating particle velocity is as follows: ; in, Indicates the first In the nth iteration The particle in the first Particle velocity in each position dimension Indicates the first In the nth iteration The adaptive inertia coefficient of each particle. Indicates the first In the nth iteration The particle in the first Particle velocity in each position dimension Indicates greater than acceleration coefficient, Indicates the first In the nth iteration The particle in the first The first random number in each position dimension Indicates as of the date The second iteration The particle in the first The optimal position of an individual in each location dimension. Indicates the first In the nth iteration The particle in the first Particle position in one position dimension Indicates the first In the nth iteration The particle in the first The second random number in the position dimension, Indicates as of the date In the next iteration, all particles are in the... The globally optimal position in each position dimension, where the first and second random numbers are independent and their values belong to... .
[0048] Specifically, the formula for calculating the particle position is as follows: ; in, Indicates the first In the nth iteration The particle in the first Particle position in one position dimension Indicates the first In the nth iteration The particle in the first Particle position in one position dimension Indicates the first In the nth iteration The particle in the first Particle velocity in each position dimension.
[0049] Furthermore, discrete event simulation includes four types of events: task start, equipment arrival, handover start, and handover completion. Events are processed sequentially in chronological order. When an event is triggered, the status and availability of the corresponding equipment are updated. For example, when the simulation reaches the event of a truck arriving at the exchange station, if the corresponding quay crane is idle and the exchange station is not occupied, the handover start event is triggered. After the handover operation time has elapsed, the handover completion event is triggered, and the availability of the truck and quay crane is updated. After all events have been processed, the time of the last handover completion event is taken and the time of the first task start event is subtracted from the time of the last task start event to obtain the task completion time.
[0050] The sum of the three weights is fixed at 1, prioritizing the feasibility of the plan. The weight of the margin gap is no less than 0.2. Based on this, the other two weights are adjusted according to the current operation status of the terminal. During peak operation periods, when the overall operation efficiency is improved, the weight of completion time is increased. When equipment is idle and waiting is severe, the weight of handover synchronization deviation is increased. For example, during the peak unloading period, when the quay crane operation is under great pressure, the weight of completion time is set to 0.5, the weight of handover synchronization deviation is 0.3, and the weight of margin gap is 0.2. The three weights remain fixed within a scheduling cycle.
[0051] The values of all dimensions of particle position are fixed to 0 to 1, and the values of all dimensions of particle velocity are fixed to -0.2 to 0.2. After the position is updated, dimensions that exceed the range of 0 to 1 are directly truncated to the nearest boundary value, and dimensions that exceed the range of -0.2 to 0.2 after the velocity is updated are directly truncated to the nearest boundary value to prevent particles from jumping out of the effective solution space.
[0052] Understandably, particle swarm optimization with a fixed inertia coefficient struggles to balance global exploration with local convergence. Excessive inertia can cause it to skip the optimal solution, while insufficient inertia can lead to getting stuck in local optima. By dynamically adjusting the inertia coefficient using the handover margin gap, the search range can be expanded when there are many infeasible handovers, and the local search can be strengthened when the margin gap is close to zero. This approach can adaptively match different stages of the search process, improving optimization efficiency and solution quality.
[0053] In one optional implementation, step S7 includes the following steps: Step S701: Process candidate tasks sequentially according to the final task execution order in the global optimal scheduling instance, determine the swap bits used for bin pick-up and bin drop-off based on the swap bit mapping, and obtain the earliest release time of each swap bit based on the swap bit occupancy data. The exchange position mapping refers to the exchange position number corresponding to the two handovers of each task, which is determined according to the fixed correspondence between the lifting equipment operation position and the exchange position at the start and end points of the task; The earliest release time refers to the handover end time of the last task among all tasks currently locked by the corresponding swap bit; The final task execution order refers to the order in which all tasks are executed in the globally optimal scheduling instance; Step S702: Select the largest value among the transport arrival time, hoisting ready time and earliest release time as the locking start time, and add the locking start time to the handover operation duration to obtain the locking end time; The handover operation duration refers to the standard operation time from the start to the completion of a single handover, which is obtained by collecting the average operation time of the same type of equipment and the same type of handover in history. Different equipment types and handover types are statistically analyzed separately. The lock start time refers to the final start time of the current task handover, which is the maximum value of the transport arrival time, the hoisting ready time, and the earliest release time of the swap position. The lock end time refers to the final end time of the current task handover, which is obtained by adding the lock start time to the handover operation duration; Specifically, the formula for calculating the lock start time is as follows: ; in, Indicates the first The candidate task in the ... The final locking start time of each handover phase Represents the first globally optimal scheduling instance. The candidate task in the ... The arrival time of transportation at each handover stage, Represents the first globally optimal scheduling instance. The candidate task in the ... The moment of hoisting readiness during the handover phase. Indicates processing the first The first candidate task Before each handover phase, positions are exchanged. The earliest release time, Indicates the first The candidate task in the ... The bitmap used in each handover phase.
[0054] Specifically, the formula for calculating the lock-off end time is as follows: ; in, Indicates the first The candidate task in the ... The final locking point at the end of each handover phase. Indicates the first The candidate task in the ... The final locking start time of each handover phase Indicates the first The candidate task in the ... The duration of the handover process in each handover phase.
[0055] Step S703: Take the locking end time of the task that has locked the same swap bit as the earliest release time of the subsequent task, until the candidate task set completes the slot locking. Step S704: Obtain the final horizontal transport equipment identifier and the final task execution order from the global optimal scheduling instance. Write the final horizontal transport equipment identifier, the final task execution order, and the lock start and lock end times for container pick-up and drop-off handover into the task instruction to generate a scheduling instruction sequence.
[0056] The final horizontal transport device identifier refers to the horizontal transport device number assigned to each task in the globally optimal scheduling instance; The scheduling instruction sequence refers to a set of instructions that includes the device allocation, execution order, and two handover time slots for each task, and is generated by arranging them according to the task execution order; Furthermore, the exchange point mapping adopts a fixed correspondence relationship. Each quay crane operation point corresponds to 2 fixed quayside exchange points, and each yard crane operation point corresponds to 1 fixed yard exchange point. The container retrieval exchange point for a task is allocated according to the operation point of the starting lifting equipment, and the container drop-off exchange point is allocated according to the operation point of the target lifting equipment. It is not dynamically adjusted according to the real-time position of the equipment. For example, if the starting point of a task is operation point 1 of quay crane 1, then the container retrieval handover will always use operation point 1 of quay crane 1. If the target point is operation point 2 of yard crane 3, then the container drop-off handover will always use operation point 2 of yard crane 3.
[0057] The scheduling instruction sequence adopts the standard instruction message format of the terminal operating system. Each instruction contains eight fields: task number, container number, horizontal transport equipment number, task execution order, container retrieval start time, container retrieval end time, container drop start time, and container drop end time. It is sent through the standard industrial Ethernet interface between the terminal operating system and the equipment control system. The sending adopts a combination of periodic polling and event triggering. All instructions are sent at once after the scheduling is completed. Incremental update instructions are sent when the equipment status changes.
[0058] During the time slot locking process, tasks that have already started executing and locked tasks that have been assigned to the device have the highest priority. Their device allocation and time slots cannot be adjusted. Only the order and device allocation of pending tasks that have not been assigned to the device can be adjusted. After each scheduling is completed, the newly locked time slots will start from after the current time. The time slots of jobs that have been completed or are being executed before the current time will not be modified.
[0059] It is understandable that the start of a physical handover must simultaneously satisfy three conditions: the arrival of transport equipment, the readiness of lifting equipment, and the vacancy of the exchange slot. Locking the time slot solely based on the predicted equipment arrival time ignores the occupancy constraints of the exchange slot. Taking the maximum value of the three times as the locking start time satisfies the readiness conditions of all three types of resources, aligning the predicted results with the time of physical resource occupancy, and ensuring that the locked time slots do not conflict with resources during actual execution. Recursively locking the occupied time slots of each exchange slot according to the task execution order ensures that the handover time slots of all tasks do not overlap or conflict at the physical resource level. The generated scheduling instructions can be issued to the equipment for execution without additional adjustments, reducing the number of on-site adjustments after the scheduling instructions are issued.
[0060] It should be noted that during actual operation, the system first verifies the reported status data, removes duplicate messages and clock error messages, calculates the data age of each status, performs time prediction based on the benchmark scheduling instance, generates time uncertainty envelope and serial handover margin, and then completes particle swarm initialization and iterative optimization. After reaching the maximum number of iterations, it outputs the globally optimal scheduling scheme and generates instructions by locking the handover time slot for each task. For example, a container terminal is equipped with 3 quay cranes, 12 container trucks, and 6 yard cranes. When 8 unloading tasks are triggered in a single batch, the system completes status collection and verification, and outputs the scheduling results after 200 iterations. Among them, the unloading task numbered X001 is assigned to container truck number 3, with the second execution order. The container pick-up handover lock time period is from 14:22:15 to 14:22:45 on the same day, and the container drop-off handover lock time period is from 14:26:08 to 14:26:38 on the same day. The remaining 7 tasks correspond to different container trucks, execution orders, and handover time periods. All exchange slots do not overlap, and there are no equipment conflicts. After the instructions are issued, the container trucks and lifting equipment can perform operations according to the time periods.
[0061] During system operation, the historical error record is automatically updated after each handover is completed, and the error growth coefficient is automatically recalibrated every 30 days to adapt to changes in the dock operation status. If equipment failure or temporary road closure occurs, the system will automatically trigger rescheduling, adjust the allocation and time slots of tasks that have not yet started, and keep the tasks that have already been issued and executed unchanged to avoid affecting ongoing on-site operations.
[0062] like Figure 2As shown in the figure, this graph illustrates the changes in the time uncertainty envelope of 30 candidate tasks during the container retrieval and unloading phases. The horizontal axis represents the candidate task number, and the vertical axis represents the time uncertainty envelope. A larger value indicates a wider prediction range for the handover time corresponding to the current real-time data, and a more significant impact of data timeliness and historical arrival errors on the prediction results. Both sets of curves generally show an upward trend in the three segments of tasks 01 to 12, 13 to 23, and 24 to 30, indicating that the uncertainty of the handover time increases with the age of the transport and lifting equipment data. The unloading handover data is generally higher than the retrieval handover data, indicating that the unloading phase is more strongly affected by data timeliness and historical errors under these simulation conditions.
[0063] like Figure 3 As shown in the figure, this graph illustrates the changes in metrics and convergence characteristics of the adaptive particle swarm optimization (PSO) algorithm during 200 iterations. The horizontal axis represents the number of iterations, and the vertical axis represents the normalized metric value. The graph also shows the changes in completion time, handover synchronization deviation, handover margin gap, and objective function value. All metrics continuously decrease with each iteration, indicating that the PSO search can gradually improve the task execution order and the allocation of horizontal transport equipment. The handover margin gap decreases the fastest in the early stages and approaches zero in the later stages, indicating that infeasible handover tasks and negative margin risks are prioritized for repair. The handover synchronization deviation then gradually decreases, reflecting the continuous improvement of the time mismatch between the arrival of transport equipment and the readiness of lifting equipment. The completion time decreases relatively slowly, indicating that the overall operational efficiency gradually improves while meeting handover feasibility. The objective function value tends to stabilize in the later stages, indicating that the algorithm has formed a relatively stable globally optimal scheduling scheme.
[0064] Although embodiments of this application have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of this application, and all such modifications and variations fall within the scope defined by the appended claims.
Claims
1. A port container intelligent scheduling method based on real-time data, characterized in that, Includes the following steps: Step S1: Collect real-time data of candidate tasks, horizontal transportation equipment, lifting equipment and exchange positions, and generate data age based on the decision time and message source time; Step S2: Based on the baseline scheduling instance, remaining distance, equipment operation time, and queuing time, generate the transportation arrival time and lifting readiness time for container pick-up and unloading handover. Step S3: Generate the median of absolute error based on the arrival prediction absolute error of the completed handover, and generate the time uncertainty envelope by combining the data age, transportation error growth coefficient, lifting error growth coefficient and median of absolute error; Step S4: Generate a handover time margin based on the waiting time window, the time of transport arrival, the time of hoisting readiness, and the time uncertainty envelope; and generate a series handover margin based on the smallest value of the two handover time margins and the square of the difference. Step S5: Encode and initialize the particle positions and generate initial particle velocities. After decoding and conflict repair based on serial handover margin, obtain a particle scheduling instance. Step S6: Regenerate the serial handover margin based on the particle scheduling instance, update the particle velocity and particle position using the handover margin gap, generate the objective function value, and determine the global optimal scheduling instance accordingly. Step S7: Based on the global optimal scheduling instance, lock the start and end times of the lock for the two handover events, and generate a scheduling instruction sequence by combining the final horizontal transport equipment identifier and the final task execution order.
2. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, Step S1 includes: Container operations that transport containers from the initial lifting equipment to the target lifting equipment via horizontal transport equipment are identified as candidate tasks. A set of candidate tasks, a set of available horizontal transport equipment, and a set of handover stages are established. The set of handover stages includes container retrieval handover and container unloading handover. At the decision-making time, the following data are collected: message source time, horizontal transport equipment location, effective average speed, remaining distance, remaining operation time of lifting equipment, transport queuing time, lifting queuing time, exchange position occupancy data, and arrival prediction absolute error. For duplicate messages, only the one with the largest message source time value is retained, and the corresponding candidate task is deleted when the message source time is later than the decision-making time. By subtracting the message source time from the decision time, the data age of each candidate task at each handover stage and each resource category is obtained, and real-time data that has passed time verification is formed.
3. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, Step S2 includes: Maintain the device allocation and task execution order of locked tasks, arrange the unlocked tasks in ascending order of their original task numbers to form a baseline scheduling instance, and set the scheduling instance index for the baseline scheduling instance and the particle scheduling instance; The remaining distance is determined based on the location of the horizontal transport equipment. The ratio of the remaining distance to the effective average speed, the transport queuing time, and the decision time are added together to obtain the transport arrival time. Add the remaining time of the lifting equipment operation, the lifting queuing time, and the decision time to obtain the lifting readiness time; Obtain the arrival time and lifting readiness time of the base scheduling instance at the container pick-up and drop-off handover. The particle scheduling instance generates the corresponding arrival time and lifting readiness time using the same calculation order.
4. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, Step S3 includes: Select complete handover records with complete timestamps from the completed handover records of the same equipment combination and the same handover stage, calculate the rolling median of the absolute error of the prediction, and obtain the median of the absolute error. The time uncertainty envelope is obtained by adding the product of the data age of horizontal transport equipment and the transport error growth coefficient, the product of the data age of lifting equipment and the lifting error growth coefficient, and the median of the absolute error.
5. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, Step S4 includes: The waiting time window is determined based on the exchange capacity, the safe occupancy time limit, and the maximum allowable waiting time for non-preemptive lifting actions. Subtract the absolute value of the difference between the arrival time of the transport and the time of hoisting and the time uncertainty envelope from the waiting time window to obtain the handover time margin; The square of the difference between the handover time margin of the box pick-up handover and the box drop-off handover is divided by the sum of the absolute values of the two handover time margins and the sum of the numerical stability time term, and then multiplied by the margin imbalance penalty coefficient to obtain the margin imbalance deduction. The serial handover margin of the baseline scheduling instance is obtained by subtracting the margin imbalance deduction from the smallest value of the handover time margin between the box pick-up handover and the box drop-off handover.
6. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, Step S5 includes: Set the particle position dimension to twice the number of candidate tasks, with the first half of the particle position being the task priority key and the second half being the device assignment key; The task priority key is set in ascending order of the serial handover margin of the baseline scheduling instance, and different continuous perturbations between particles are added around the central order; the equipment allocation key is divided into equal-width intervals according to the number of equipment in the available horizontal transport equipment set, and each equal-width interval is mapped to a horizontal transport equipment identifier. The task execution order is generated in ascending order according to the task priority key, and the horizontal transportation equipment is determined according to the equal-width interval where the equipment allocation key is located, thus obtaining a particle scheduling instance; For tasks with overlapping time slots at the same exchange point, recalculate the series handover margin; if there is a task with a series handover margin less than 0, assign the task sequentially to the available horizontal transport equipment that minimizes the sum of the absolute values of the differences between the transport arrival time of the container pick-up handover and the container drop-off handover and the hoisting ready time; if there is no task with a series handover margin less than 0, arrange them in ascending order according to the series handover margin, and if the values are the same, arrange them in ascending order according to the original task number. Conflict remediation only changes the horizontal transport equipment allocation and task execution order for tasks that have not yet started, and generates initial particle positions, initial particle velocities, and initial particle scheduling instances.
7. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, In step S6, regenerating the serial handover margin and generating the objective function value based on the particle scheduling instance includes: Using the initial particle scheduling instance as the particle scheduling instance for the first iteration, the transportation arrival time, hoisting readiness time, handover time margin, and serial handover margin are recalculated for each particle scheduling instance in each iteration. The handover margin gap is obtained by dividing the sum of the absolute values of the serial handover margins that are less than 0 by the product of the number of candidate tasks and the reference time. Divide the handover margin gap by the sum of the handover margin gap and 1, multiply the resulting ratio by the difference between the upper and lower bounds of the inertia coefficient, and then add the lower bound of the inertia coefficient to obtain the adaptive inertia coefficient. Discrete event calculations are performed on the particle scheduling instance to obtain the task completion time. The task completion time, the handover synchronization deviation formed by the absolute value of the difference between the transportation arrival time and the hoisting ready time, and the handover margin gap are normalized respectively, and then multiplied by the completion time weight, the handover synchronization deviation weight, and the margin gap weight respectively, and then summed to obtain the objective function value.
8. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, In step S6, the particle velocity and particle position are updated using the handover margin gap, and the globally optimal scheduling instance is determined accordingly, including: Update the individual optimal position and the global optimal position based on the objective function value; when the objective function values are the same, determine the corresponding positions in ascending order of the absolute value of the maximum negative surplus and in lexicographical order of task execution. The initial particle position and initial particle velocity are used as the particle position and particle velocity for the first iteration. The particle velocity and particle position are updated based on the adaptive inertia coefficient, particle velocity, particle position, individual optimal position, global optimal position, acceleration coefficient, first random number and second random number. After each particle position update, decoding and conflict repair are performed. When the maximum number of iterations is reached, the global optimal scheduling instance is determined based on the particle scheduling instance corresponding to the global optimal position.
9. The intelligent port container scheduling method based on real-time data according to claim 1, characterized in that, Step S7 includes: Candidate tasks are processed sequentially according to the final task execution order in the globally optimal scheduling instance. The swap bits used for bin pick-up and bin drop-off are determined based on the swap bit mapping, and the earliest release time of each swap bit is obtained based on the swap bit occupancy data. The largest of the following values—transportation arrival time, hoisting readiness time, and earliest release time—is used as the locking start time. The locking start time is then added to the handover operation duration to obtain the locking end time. The locking end time of the task that has already locked the same swap bit is taken as the earliest release time of the subsequent task, until the candidate task set completes the slot locking; Obtain the final horizontal transport equipment identifier and the final task execution order from the globally optimal scheduling instance. Write the final horizontal transport equipment identifier, the final task execution order, and the lock start and lock end times for container retrieval and unloading handover into the task instructions to generate a scheduling instruction sequence.
10. A port container intelligent scheduling system based on real-time data, characterized in that, The method for intelligent port container scheduling based on real-time data as described in any one of claims 1 to 9 includes: The data age generation module is used to collect real-time data from candidate tasks, horizontal transportation equipment, lifting equipment, and exchange points, and generate data age based on the decision time and message source time. The handover time calculation module is used to generate the transportation arrival time and lifting readiness time for container pick-up and unloading handover based on the baseline scheduling instance, remaining distance, equipment operation time and queuing time. The uncertain envelope generation module is used to generate the median absolute error based on the arrival prediction absolute error of the completed handover, and to generate the time uncertain envelope by combining the data age, transportation error growth coefficient, lifting error growth coefficient and median absolute error. The handover margin generation module is used to generate a handover time margin based on the waiting time window, the time of transport arrival, the time of hoisting readiness, and the time uncertainty envelope, and to generate a series handover margin based on the minimum value of the two handover time margins and the square of the difference. The particle initialization module is used to encode and initialize particle positions and generate initial particle velocities. After decoding and conflict repair based on serial handover margin, a particle scheduling instance is obtained. The global optimal instance generation module is used to regenerate the serial handover margin based on the particle scheduling instance, update the particle velocity and particle position using the handover margin gap, generate the objective function value, and determine the global optimal scheduling instance accordingly. The scheduling instruction generation module is used to generate a sequence of scheduling instructions by locking the start and end times of the lock between two items according to the globally optimal scheduling instance, and combining the final horizontal transport equipment identifier and the final task execution order.