Heterogeneous computing task scheduling method and system based on quantity super-converged architecture
Patent Information
- Application Number
- CN202611270529.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-20
- Publication Date
- 2026-11-03
AI Technical Summary
In existing hyperconverged architectures, the heterogeneity and dynamic changes of classical and quantum computing resources lead to a lack of systematic modeling in scheduling methods, resulting in low computational efficiency and discontinuous resource utilization. Furthermore, existing methods are unable to cope with the uncertainty of quantum task execution time.
By constructing a two-way coupled differential equation system between classical computing resources and quantum computing resources, an execution time probability distribution model is generated. The execution progress is monitored in real time and the scheduling scheme is switched. Combined with the coupling field state parameters, dynamic optimization scheduling is performed to achieve real-time adaptation and adaptive adjustment of resource state.
It significantly reduces the ineffective waiting time of classical resources, improves the overall task throughput of quantum hyper-converged systems, and maintains system stability and adaptability when the output rhythm of quantum resources changes, with scheduling efficiency improved by about 20% to 35%.
Smart Images

Figure CN123030355A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of quantum computing and high-performance computing fusion scheduling, and more specifically, to a heterogeneous computing task scheduling method and system based on a quantum-hyper-fusion architecture. Background Technology
[0002] As the performance growth of classical computing slows down and the acceleration potential of quantum computing for specific problems continues to emerge, classical-quantum heterogeneous computing has become an important direction for improving the upper limit of computing power. In the hyper-converged architecture, classical and quantum computing resources have different and dynamically changing time characteristics. The execution time of quantum tasks is significantly affected by physical noise, decoherence effects, and task queuing states, resulting in significant statistical fluctuations. Existing scheduling methods typically treat quantum tasks as deterministic computing units with fixed execution times for resource orchestration. When the actual execution time of quantum tasks deviates from expectations, classical computing resources often fall into inefficient waiting or need to be interrupted and rescheduled, leading to a decrease in the overall computing efficiency of the hyper-converged system. In addition, existing methods lack systematic modeling of the mutual constraints between classical and quantum resource states, making it difficult to balance cooperative efficiency, system stability, and resource utilization continuity in scheduling decisions. Summary of the Invention
[0003] In view of the above problems, the present invention provides a heterogeneous computing task scheduling method based on a hyperconverged infrastructure architecture, the method comprising: Acquire the current resource status information of the hyper-converged system, the resource status information including the classical computing resource status and the quantum computing resource status; Based on the current resource status information, the system coupling field state parameters at the current scheduling moment are calculated through a preset coupling field dynamic evolution model. The coupling field state parameters are used to characterize the mutual constraint relationship and cooperative evolution trend between classical computing resources and quantum computing resources. Receive a computation task to be scheduled, and decompose the computation task to be scheduled into one or more classical executable units and one or more quantum executable units; For each quantum executable unit, an execution time probability distribution model is generated based on its task characteristic parameters, and a set of candidate scheduling schemes is generated based on multiple quantiles of the execution time probability distribution model. Each candidate scheduling scheme in the set of candidate scheduling schemes includes an execution time assumption for the quantum executable unit and a pre-arranged scheduling plan for each classical executable unit corresponding to the execution time assumption. Using the coupled field state parameters as constraints, a primary scheduling scheme that satisfies the system optimization objective is selected from the candidate scheduling scheme set and executed. During execution, the actual execution progress of each quantum executable unit is monitored in real time. When the actual execution progress deviates from the execution time assumption on which the main scheduling scheme is based by more than a preset threshold, the system switches from the candidate scheduling scheme set to the target scheduling scheme that matches the current actual execution state of the quantum executable unit and continues execution. The scheduling sequence of each classical executable unit is adjusted according to the target scheduling scheme. The actual execution time data of each quantum executable unit is obtained. Based on the deviation between the actual execution time data and the predicted value of the execution time probability distribution model, the parameters of the execution time probability distribution model are updated. The candidate scheduling scheme set is dynamically reconstructed based on the accumulated deviation data to drive the scheduling decision of the next scheduling cycle.
[0004] In addition, the present invention also provides a heterogeneous computing task scheduling system based on a hyperconverged infrastructure, which is used to store and execute the above-mentioned methods.
[0005] Based on the above, the heterogeneous computing task scheduling method and system based on hyperconverged infrastructure provided by this invention have the following technical effects.
[0006] First, by constructing a two-way coupled differential equation system between the states of classical computing resources and quantum computing resources, and extracting the first-order derivative vector as the system's coupled field state parameter after fitting the coupling coefficients with historical data, a systematic quantitative characterization of the mutual constraint relationship and co-evolution trend between two types of heterogeneous resources in a quantum hyper-converged system is achieved. This coupled field state parameter provides a dynamic constraint boundary reflecting the system's evolution direction for scheduling decisions, enabling the scheduling scheme to adapt to the real-time changing trends of resource states. This solves the problem of existing scheduling methods lacking systematic modeling of the interrelationships between resources, leading to a disconnect between decision-making and the actual system state.
[0007] Second, by generating an execution time probability distribution model for each quantum executable unit and constructing a candidate scheduling scheme set based on multiple quantiles, the uncertainty of quantum execution time is explicitly incorporated into the scheduling decision space. During execution, the system can quickly switch from the candidate scheme set to an alternative scheme that matches the current execution state based on the actual progress deviation. This avoids the problem in traditional methods where classical resources are inefficiently waiting or require complete rescheduling due to deviations in quantum task execution time from expectations, significantly reducing scheduling switching overhead.
[0008] Third, by introducing three components—classical-quantum cooperative waiting cost, system disturbance cost, and classical resource time continuity cost—into the comprehensive cost function, and adaptively adjusting the weights of each component according to the direction of the first derivative vector of the coupled field, optimized scheduling with dynamic balance among multiple objectives as the system evolves is achieved. Fourth, by performing Bayesian updates on the execution time probability distribution model through the deviation learning module, and triggering scheme space reconstruction based on accumulated deviation data, the system possesses the ability to autonomously learn from historical execution data and continuously optimize scheduling schemes. Finally, by inversely adjusting the parameters of the coupled field model, closed-loop feedback of deviation information from the scheduling execution layer to the resource state modeling layer is achieved, enabling the entire scheduling system to form a complete closed loop of perception-decision-execution-learning.
[0009] Experimental data show that, under the condition that the standard deviation of the quantum task execution time relative to the predicted value is about 30%, the scheduling method of the present invention can reduce the invalid waiting time of classical computing resources by about 55% to 70%, and increase the overall task throughput of the quantum-hyperfusion system by about 20% to 35%. When the quantum resource output rhythm is continuously drifting, the system can adaptively complete the adjustment of the scheduling strategy within 2 to 3 scheduling cycles, which has significant advantages in stability and adaptability. Attached Figure Description
[0010] Figure 1 This is a flowchart illustrating the method provided in an embodiment of the present invention; Figure 2 A schematic diagram of the system provided by the present invention; Figure 3 This is a schematic diagram comparing the predicted and measured values of the quantum execution time of this invention. Figure 4 This is a schematic diagram illustrating the average waiting time of classical computing resources under different scheduling methods of the present invention and existing technologies. Detailed Implementation
[0011] like Figures 1-4 As shown.
[0012] This technical solution provides a heterogeneous computing task scheduling method and system based on a hyperconverged infrastructure architecture. The technical details are explained in detail below using a specific application scenario.
[0013] This embodiment uses a quantum-supercomputer fusion system comprised of a 550-qubit coherent optical quantum computer and a 100P@FP64-scale classical high-performance supercomputer deployed in a supercomputing center as the application scenario. The computational task to be scheduled is a generator unit combination optimization problem for the power energy industry. This problem needs to improve the controllability and flexibility of the power transmission system while considering the maximum economic benefits of generator units. The computational task to be scheduled includes start-up and shutdown state decision variables of approximately 2000 generator units and corresponding continuous power allocation variables. It belongs to a typical mixed-integer nonlinear programming problem. Its discrete decision part is suitable for processing by a quantum computer, while the continuous optimization part is suitable for completion by a classical supercomputer.
[0014] I. System Initialization and Resource Status Acquisition After the hyper-converged system is started, the resource status acquisition process deployed on the system management node first performs the operation of acquiring the current resource status information. The resource status acquisition process acquires the classical computing resource status and the quantum computing resource status through two independent data channels respectively.
[0015] The status of classical computing resources is obtained by calling the application programming interface (API) of the supercomputer's job management system. This job management system uses SLURM (System-Based Logic Registry). Every 100 milliseconds, the resource status acquisition process sends a status query request to the SLURM control node to obtain the number of currently schedulable classical computing units and the utilization rate of each unit. Classical computing units are based on computing nodes, each configured with two 64-core CPUs and four GPUs, achieving a peak double-precision floating-point performance of 3.2 psi. The utilization rate of classical computing units is calculated as follows: the ratio of the number of allocated cores to the total number of cores on each node is taken as the instantaneous utilization rate of that node; then, the arithmetic mean of the instantaneous utilization rates of all schedulable nodes is taken to obtain the system-level classical computing unit utilization rate.
[0016] The state of quantum computing resources is acquired through the control and management interface of the coherent optical quantum computer. This interface runs on the integrated measurement and control unit of the optical quantum computer and is connected to the system management node via high-speed Ethernet. The resource state acquisition process sends a state query command to this interface, which returns the current length of the quantum task queue and the cumulative complexity value of the quantum task queue. The cumulative complexity value of the quantum task queue is calculated as follows: for each quantum executable unit waiting to be executed in the queue, three characteristic parameters are extracted: the number of qubits, the number of quantum gate operations, and the number of measurement operations. These three parameters are multiplied by preset weight coefficients of 0.2, 0.5, and 0.3, respectively, and then summed. The calculation results of all quantum executable units in the queue are then summed to obtain the cumulative complexity value of the queue. The values of the above weight coefficients are based on statistical analysis of historical execution data. Experiments show that the number of quantum gate operations has the most significant impact on execution time, therefore, it is assigned the highest weight.
[0017] The resource status acquisition process encapsulates the acquired classical computing resource status and quantum computing resource status into a resource status information packet according to a unified data structure. This information packet contains a timestamp field, a classical resource status substructure, and a quantum resource status substructure, and then pushes it to the coupled field computing module.
[0018] II. Calculation of Coupled Field State Parameters After receiving the resource status information packet, the coupled field calculation module performs the calculation of the coupled field dynamic evolution model.
[0019] First, the classical computing resource status and quantum computing resource status at the current scheduling moment are extracted from the resource status information packet. Let the current scheduling moment be t0, the classical computing unit occupancy rate be denoted as C(t0), the quantum task queue length be denoted as Q_len(t0), and the cumulative complexity value of the quantum task queue be denoted as Q_cplx(t0). The smallest granularity of the classical computing unit is a computing node in a supercomputer. Each node contains a fixed number of CPU cores and GPUs. Task allocation is based on node-level resource reservation, and it does not support splitting the resources of a single node into smaller scheduling units.
[0020] Then, a two-way coupled set of differential equations is constructed between the classical computing resource state and the quantum computing resource state. This set of equations contains two first-order ordinary differential equations: The first coupling equation describes the change in the state of classical computing resources in response to the state of quantum computing resources. It takes the form dC / dt = -α1·C + β1·Q_cplx + γ1. Here, C is the classical computing unit occupancy rate, Q_cplx is the cumulative complexity value of the quantum task queue, α1 is the decay coefficient of the classical resources themselves, β1 is the driving coefficient of quantum complexity on the classical occupancy rate, and γ1 is the basic load constant on the classical side.
[0021] The second coupling equation describes the change in quantum computing resource state in response to the classical computing resource state, and its form is dQ_cplx / dt = -α2·Q_cplx + β2·C + γ2. Here, α2 is the dissipation coefficient of the quantum queue itself, β2 is the driving coefficient of the classical occupancy rate on the quantum queue, and γ2 is the fundamental arrival constant on the quantum side.
[0022] The coupling coefficients α1, β1, γ1, α2, β2, and γ2 in the above equation system need to be determined through parameter estimation. The parameter estimation process uses the classical computing resource state sequence and quantum computing resource state sequence within the historical scheduling cycle as fitting data, and employs the least squares estimation method. Specifically, sampled values of C(t) and Q_cplx(t) for the past 100 scheduling cycles (each scheduling cycle is 1 second long) are extracted from the system operation log, forming a time series data of length 100. The bidirectional coupled differential equation system is discretized between adjacent sampling points to obtain a linear equation system regarding the coupling coefficients. By solving the least squares solution of this linear equation system, the estimated values of the six coupling coefficients are obtained. This parameter estimation process is executed once at the beginning of each scheduling cycle to ensure that the model parameters can track changes in the system's operating state.
[0023] The classical computing resource state C(t0) and the quantum computing resource state Q_cplx(t0) at the current scheduling moment are used as initial conditions for a two-way coupled differential equation system. The system is numerically integrated within a preset time window. The preset time window is 5 scheduling cycles (5 seconds), and the numerical integration uses the fourth-order Runge-Kutta method with an integration step size of 0.01 seconds. After integration, the state evolution trajectory of the system's coupled field within the preset time window is obtained, i.e., the sequence of numerical solutions for C(t) and Q_cplx(t) in the time interval [t0, t0+5].
[0024] Finally, the first derivative vector of the state evolution trajectory at the current scheduling moment is extracted as the system's coupled field state parameter. The first derivative vector dS / dt|t0 = [dC / dt|t0, dQ_cplx / dt|t0] is directly calculated by substituting C(t0) and Q_cplx(t0) at time t0 into the right-hand side of the two-way coupled differential equation system. This first derivative vector is used to characterize the system's changing trend and evolution direction at the current scheduling moment: a first component greater than 0 indicates an increasing trend in classical resource utilization, while a component less than 0 indicates a decreasing trend; a second component greater than 0 indicates an accumulating trend in quantum queue complexity, while a component less than 0 indicates a dissipating trend.
[0025] III. Task Breakdown After receiving the unit combination optimization calculation task to be scheduled, the scheduling manager submits it to the task decomposition module for decomposition operation.
[0026] The task decomposition module first decouples the functional submodules of the scheduling computation task. This decoupling is based on data flow graph analysis: the source code of the computation task to be scheduled is input into the compiler front-end to generate an intermediate representation. Then, data flow analysis is performed on this intermediate representation to extract the multiple functional submodules contained in the computation task and the data dependencies between these submodules. Taking the unit combination optimization problem as an example, the following functional submodules are obtained after decoupling: unit start-stop state decision submodule, power allocation continuous optimization submodule, transmission safety constraint verification submodule, objective function evaluation submodule, and iterative convergence judgment submodule. The data dependencies between these submodules are as follows: the output (start-stop state vector) of the unit start-stop state decision submodule is simultaneously input into both the power allocation continuous optimization submodule and the transmission safety constraint verification submodule; the output (power allocation vector) of the power allocation continuous optimization submodule and the start-stop state vector are jointly input into the objective function evaluation submodule; the objective function evaluation value is input into the iterative convergence judgment submodule; and the output (convergence flag) of the iterative convergence judgment submodule is fed back to the unit start-stop state decision submodule, forming an iterative loop. The aforementioned functional sub-modules and data dependencies together constitute a functional module dependency graph with functional sub-modules as nodes and data dependencies as directed edges.
[0027] For each functional submodule in the functional module dependency graph, calculate the first estimated generation value of the submodule executed on the classical computing side and the second estimated generation value executed on the quantum computing side. The first estimated generation value is calculated by extracting the number of floating-point operations in the functional submodule and dividing it by the peak speed of single-precision floating-point operations of the classical computing unit (here, 10¹⁰ per second for each classical computing node). 5 The estimated execution time on the classical side is calculated by multiplying the number of binary decision variables that can be converted to QUBO form in the functional submodule by the number of effective qubits in the optical quantum computer (taken as 500 here), and then multiplying by the quantum task queue length correction factor (1 + Q_len(t0) / 10) to obtain the estimated execution time on the quantum side, in seconds. It should be noted that for functional submodules that cannot be converted to QUBO form (such as floating-point intensive computing modules), their estimated quantum side cost is set to a maximum value (10). 6 (seconds) to rule out the possibility of it being executed on the quantum side.
[0028] The difference between the first and second estimated generation values (first estimated generation value minus second estimated generation value) is calculated to generate the quantum bias factor for this functional submodule. A positive quantum bias factor indicates that the submodule has a greater time advantage in execution on the quantum side, while a negative quantum bias factor indicates a greater time advantage in execution on the classical side. Based on the sign and absolute value of the quantum bias factor, the functional submodules in the functional module dependency graph are divided into three categories: those with a quantum bias factor greater than 0.1 seconds are marked as quantum-biased submodules, those less than -0.1 seconds are marked as classical-biased submodules, and those with an absolute value less than or equal to 0.1 seconds are marked as uncertain submodules. The aforementioned 0.1-second bias threshold is determined based on the system's engineering requirements for task scheduling response latency—experiments show that when the bias threshold is below 0.1 seconds, the submodule's attribution judgment is prone to frequent reversals due to small fluctuations in resource status, leading to an unstable scheduling scheme.
[0029] All quantum-biased submodules are merged to generate an initial set of quantum executable units, and all classical-biased submodules are merged to generate an initial set of classical executable units. For uncertain submodules, their candidate execution bias queues are determined based on their topological position in the functional module dependency graph. For example, if the power transmission safety constraint verification submodule is marked as an uncertain submodule, its candidate execution bias queue contains a first candidate scheme for execution on the classical side and a second candidate scheme for execution on the quantum side. Both candidate schemes are retained for the subsequent rapid derivation stage.
[0030] The initial set of quantum executable units, the initial set of classical executable units, and the candidate execution tendency queue of uncertain submodules are used as input to call the subsequent candidate scheduling scheme generation process for rapid deduction. The rapid deduction uses the same candidate scheme generation algorithm as the formal scheduling, but the number of quantiles during deduction is reduced to three (i.e., only the 10%, 50%, and 90% quantiles are used) to reduce computational overhead. The rapid deduction outputs a scheduling feasibility score for each decomposition scheme. This score is determined by the scheme density and the minimum difference between schemes in the candidate scheduling scheme set. Scheme density is defined as the ratio of the coverage of a candidate scheme on the time axis to the number of candidate schemes, and the minimum difference between schemes is defined as the minimum absolute difference in execution time assumptions between any two candidate schemes. The scheduling feasibility score is the product of the scheme density and the minimum difference between schemes; a higher score indicates that the decomposition scheme has greater flexibility in subsequent scheduling.
[0031] Using the scheduling feasibility score corresponding to each decomposition scheme as a feedback signal, a scheme optimization operation is performed on the candidate execution tendency queue of the uncertain submodule—selecting the candidate scheme that results in the highest scheduling feasibility score as the final execution tendency of the uncertain submodule. The uncertain submodules with confirmed optimized execution tendencies are then assigned to their corresponding quantum executable unit set or classical executable unit set, and merged with the initial quantum executable unit set and the initial classical executable unit set to generate a final classical executable unit (containing a power allocation continuous optimization submodule, a transmission safety constraint verification submodule, an objective function evaluation submodule, and an iterative convergence judgment submodule) and a quantum executable unit (containing a unit start-up / shutdown state decision submodule).
[0032] IV. Generation of Candidate Scheduling Scheme Set For the quantum executable unit, the candidate scheme generation module first extracts its task characteristic parameters. Three characteristic parameters are extracted from the functional sub-module corresponding to the quantum executable unit (the unit start-up / shutdown state decision sub-module): the number of qubits, which is the number of binary decision variables in this sub-module; here, it is the 2000 start-up / shutdown state variables corresponding to 2000 generator units, mapped to 2000 qubits after QUBO modeling; the number of quantum gate operations, which is the number of Ising model interaction terms required to map the QUBO model to a coherent optical quantum computer; here, it is approximately 4 million terms; and the number of measurement operations, which is the number of measurements required to finally read the qubit state; here, it is 2000 measurements.
[0033] Based on the aforementioned task characteristic parameters, a set of historical execution records matching these parameters is retrieved from the historical execution database. The historical execution database is stored on the solid-state drive of the system management node. Each record contains a triplet of task characteristic parameters (number of qubits, number of quantum gate operations, number of measurement operations) and the corresponding actual execution time data. The matching retrieval uses Euclidean distance as a metric, searching through all records in the database for the 100 records with the smallest Euclidean distance to the current task characteristic parameters, thus forming the historical execution record set.
[0034] Based on 100 actual execution time data points from the historical execution record set, an execution time probability distribution model is fitted. The fitting process first performs a normality test on the 100 data points (using the Shapiro-Wilk test). If the test passes, a normal distribution is adopted as the distribution type, with the distribution parameter set being the sample mean and sample standard deviation. If the test fails, log-normal and gamma distributions are tried, and maximum likelihood estimation is used to determine the parameters of each distribution. The optimal distribution type is then selected based on the Akaike information content criterion. In this embodiment, the logarithmic values of the 100 historical execution time data points passed the normality test; therefore, the log-normal distribution is selected as the execution time probability distribution model, with the distribution parameter set being the logarithmic mean μ = 2.3 (natural logarithm) and the logarithmic standard deviation σ = 0.4.
[0035] Five quantile values are extracted from the execution time probability distribution model according to a preset quantile selection strategy. The preset quantile selection strategy is equal-probability interval sampling: the quantile values corresponding to the cumulative probabilities of 10%, 30%, 50%, 70%, and 90% are selected respectively, i.e., N=5. The inverse function of the cumulative distribution of the log-normal distribution is evaluated at the above five probability values to obtain five assumed execution time values: T1=6.2 seconds (10th percentile), T2=8.5 seconds (30th percentile), T3=10.0 seconds (50th percentile), T4=11.8 seconds (70th percentile), and T5=16.1 seconds (90th percentile).
[0036] Five quantile values are used as five quantum execution time hypotheses, and a corresponding pre-arrangement scheduling plan for classical executable units is generated for each quantum execution time hypothesis. The pre-arrangement scheduling plan is generated as follows: the quantum execution time hypothesis value is used as the expected occupancy time of the quantum executable unit on the optical quantum computer. The classical executable units (including sub-modules such as power allocation continuous optimization, security constraint verification, objective function evaluation, and convergence judgment) are executed within this expected occupancy time, and the classical executable units are started sequentially according to the topological order in the functional module dependency graph. For each quantum execution time hypothesis Tᵢ, the start time offset of each classical executable unit within this time window is calculated: the first classical executable unit starts 0.1 seconds after the quantum executable unit starts (reserving time overhead for quantum task submission and initialization), and each subsequent classical executable unit starts immediately after its predecessor classical executable unit completes. The resource allocation of each classic executable unit is arranged as follows: the power allocation continuous optimization submodule occupies 4 classic computing nodes, the safety constraint verification submodule occupies 2 classic computing nodes, the objective function evaluation submodule occupies 1 classic computing node, and the convergence judgment submodule occupies 1 classic computing node.
[0037] Each quantum execution time hypothesis is associated with and encapsulated with a set of pre-arranged scheduling plans of classical executable units to generate 5 candidate scheduling schemes, which together constitute a set of candidate scheduling schemes.
[0038] V. Selection of the Main Scheduling Scheme The main scheduling scheme selection module uses the coupled field state parameters as constraints to select the main scheduling scheme that satisfies the system optimization objective from the candidate scheduling scheme set.
[0039] First, a feature vector is extracted for each candidate scheduling scheme in the candidate scheduling scheme set. The feature vector contains three components: the first component is the quantum execution time hypothesis value Tᵢ corresponding to the candidate scheduling scheme; the second component is the startup time offset sequence of each classical executable unit, which is a four-dimensional vector composed of four offsets; the third component is the resource allocation sequence of each classical executable unit, which is a four-dimensional vector composed of four node numbers.
[0040] Using the first derivative vector dS / dt|t0 in the system's coupled field state parameters as the system's evolution direction constraint, a comprehensive cost function containing three cost components is constructed.
[0041] The first cost component measures the classical-quantum cooperative waiting cost of the candidate scheduling scheme under the quantum execution time assumption. This cost is calculated as follows: the quantum execution time assumption value Tᵢ is compared with the total execution time of each classical executable unit (estimated by dividing the floating-point operands of each submodule by the speed of the classical computing node). If the total classical execution time is greater than Tᵢ, the classical side still needs to continue execution after the quantum execution is completed; in this case, the waiting cost is the ratio of the classical overrun time to Tᵢ. If the total classical execution time is less than Tᵢ, the classical side completes ahead of schedule and waits idly for the quantum execution to complete; in this case, the waiting cost is the ratio of the quantum overrun time to the total classical execution time. The value of the first cost component ranges from 0 to positive infinity; the smaller the value, the less the classical and quantum cooperative waiting.
[0042] The second cost component measures the system disturbance cost of a candidate scheduling scheme deviating from the system's natural evolution trajectory in the evolution direction indicated by the system's coupled field state parameters. The system's natural evolution trajectory is defined as the trajectory of the coupled field state parameters evolving naturally according to the two-way coupled differential equation without any scheduling intervention. The disturbance cost is calculated by substituting the resource occupancy of the classical executable units in the candidate scheduling scheme into the right-hand side of the first coupled equation, calculating the absolute value of the difference between the rate of change of classical occupancy after scheduling and the rate of change under natural evolution, and then multiplying it by a preset disturbance sensitivity coefficient (valued at 0.5). The second cost component reflects the degree of intervention of scheduling behavior on the system's natural evolution state; the smaller the value, the smoother the scheduling.
[0043] The third cost component measures the degree of temporal continuity utilization of classical computing resources by candidate scheduling schemes. Based on the startup time offset sequence and resource allocation sequence of each classical executable unit, the variance of idle time distribution among classical executable units is calculated. Idle time is defined as the time interval between the completion of one classical executable unit and the startup of the next. If the intervals are nearly equal (small variance), it indicates that classical resources are being utilized continuously and evenly; if the intervals differ greatly (large variance), it indicates that the use of classical resources is fragmented. The third cost component is the ratio of the idle time distribution variance to the total execution time; the smaller the value, the better the continuity of resource utilization.
[0044] The first, second, and third cost components are weighted and summed to generate the comprehensive cost value of each candidate scheduling scheme. The weight coefficients of each cost component are adaptively adjusted according to the direction of the first derivative vector in the system coupling field state parameters: when dC / dt|t0 > 0 and dQ_cplx / dt|t0 > 0, it indicates that both classical and quantum resources are tending to be busy. In this case, the weight of the first cost component (cooperative waiting cost) is set to 0.6, and the weights of the second and third components are each set to 0.2; when dC / dt|t0 < 0 and dQ_cplx / dt|t0 > 0, it indicates that classical resources are tending to be idle while quantum resources are tending to be busy. In this case, the weight of the second cost component (system disturbance cost) is set to 0.5 to avoid over-scheduling exacerbating congestion on the quantum side. In this embodiment, the first derivative vector of the current coupled field state parameters is [0.02, -0.01], which indicates that the classical occupancy rate is slowly increasing while the quantum queue complexity is slowly decreasing. At this time, the three weight coefficients are set to 0.4, 0.3, and 0.3, respectively.
[0045] After calculating the comprehensive cost of the five candidate scheduling schemes, the candidate scheduling scheme with the lowest comprehensive cost is selected as the primary scheduling scheme. In this embodiment, the scheme with T3=10.0 seconds corresponding to the 50th percentile has the lowest comprehensive cost and is therefore selected as the primary scheduling scheme. The start time offset and resource usage arrangement of each classic executable unit in the primary scheduling scheme are locked, and execution is started.
[0046] VI. Execution Progress Monitoring and Flexible Switching During the execution of the main scheduling scheme, the progress monitoring process deployed on the integrated measurement and control machine of the optical quantum computer collects the actual execution progress of the quantum executable unit in real time.
[0047] The progress monitoring process reads the number of completed quantum gate operations every 50 milliseconds through the hardware monitoring interface of the optical quantum computer. The total number of quantum gate operations for the quantum executable unit is determined to be 4 million before execution, and the actual execution progress percentage is calculated by dividing the number of completed quantum gate operations by the total number of sub-gate operations.
[0048] It should be noted that the number of quantum gate operations is the sum of all quantum gate operations (including single-bit gates, two-bit gates, and multi-bit gates). The execution time of two-bit gates and multi-bit gates is converted into the equivalent number of single-bit gates and included in the statistics. The conversion factor is the ratio of the duration of the gate operation to the duration of a single-bit gate.
[0049] Obtain the expected progress curve corresponding to the execution time assumptions on which the main scheduling scheme is based. The expected progress curve is a linear interpolation curve, with its starting point at (t=0, progress=0%) and its ending point at (t=T3=10.0 seconds, progress=100%). The expected progress at intermediate moments is calculated linearly. Compare the actual execution progress percentage at the current moment with the expected progress percentage at the same timestamp on the expected progress curve to calculate the progress deviation value. For example, if the expected progress is 50% at the 5th second of execution, but only 42% is actually completed, the progress deviation value is -8%.
[0050] A switchover is triggered when the absolute value of the schedule deviation exceeds a preset deviation threshold. The preset deviation threshold is set at 10%, a value derived from experimental analysis of system stability. When the deviation threshold is below 10%, normal statistical fluctuations in the quantum computer's execution time lead to overly frequent switchovers, reducing scheduling efficiency. When the deviation threshold is above 15%, the switchover occurs too late, and classical resources are already showing significant waiting time, resulting in decreased scheduling benefits. Experiments show that 10% is the optimal balance point.
[0051] After the switch is triggered, the execution time assumptions corresponding to each candidate scheduling scheme in the candidate scheduling scheme set are compared with the actual execution time consumed and the actual execution progress percentage of the quantum executable unit. The matching score is calculated as follows: for each candidate scheme, the absolute difference between its execution time assumption Tᵢ and the estimated total time of "consumed time / current progress percentage" is calculated. The smaller the absolute difference, the higher the matching score. Specifically, if the consumed time is 5 seconds and the current progress is 42%, the estimated total time is 5 / 0.42≈11.9 seconds. At this time, the absolute difference with T5=16.1 seconds is 4.2 seconds, the absolute difference with T3=10.0 seconds is 1.9 seconds, and the absolute difference with T2=8.5 seconds is 3.4 seconds. Therefore, the scheme with T3=10.0 seconds has the highest matching score. It should be noted that the actual execution time consumed is taken as the time zero point when the quantum executable unit officially starts executing quantum gate operations on the optical quantum computer, and is not included in the waiting time in the measurement and control integrated machine queue.
[0052] The candidate scheduling scheme with the highest matching score is selected as the target scheduling scheme. Using the current time of the quantum executable unit as the new time zero point, and the remaining execution time in the execution time assumption corresponding to the target candidate scheduling scheme as the expected remaining execution time of the quantum executable unit, the startup time and resource occupation period of each classical executable unit are recalibrated. In this embodiment, if 5 seconds have already been consumed and the actual progress is only 42%, the expected remaining execution time after recalibration is approximately (10.0 - 5). The actual progress is corrected to approximately 6.9 seconds, and the startup time of each classical executable unit is correspondingly postponed.
[0053] VII. Deviation Learning and Dynamic Restructuring of Solutions After the quantum executable unit completes its execution, the bias learning module obtains its actual execution time data. In this embodiment, the actual execution time of the quantum executable unit is 12.3 seconds.
[0054] The difference between the actual execution time data and the predicted value at the corresponding quantile of the execution time probability distribution model is calculated. The main scheduling scheme uses the 50th quantile T3 = 10.0 seconds as the execution time assumption, so the single deviation value is 12.3 - 10.0 = 2.3 seconds (positive deviation, indicating that the actual execution is slower than expected). This single deviation value is categorized and stored according to the task characteristic parameters of the quantum executable unit (2000 qubits, 4 million quantum gate operations, and 2000 measurement operations) and stored in the corresponding characteristic parameter category in the deviation classification record.
[0055] Deviation classification records are divided into multiple categories based on the range of task characteristic parameters: the number of qubits is divided into four intervals: 0-500, 501-1000, 1001-2000, and over 2000; the number of quantum gate operations is divided into three intervals: 0-1 million, 1 million-5 million, and over 5 million. In this embodiment, the task characteristic parameters fall into the intersection of the "1001-2000 qubits" and "1 million-5 million quantum gate operations" categories. When the number of deviation samples in this category reaches a preset sample size threshold of 20, statistical analysis is performed on these 20 deviation samples. The statistical analysis calculates three statistical characteristics: the deviation mean, the deviation standard deviation, and the deviation skewness. In this embodiment, the mean of the 20 deviation samples is 1.8 seconds, the standard deviation is 1.2 seconds, and the skewness is 0.3 (positive skewness, indicating a slightly larger number of positive deviation samples).
[0056] Based on the statistical characteristics of the deviation distribution, Bayesian updates are performed on the distribution parameters of the execution time probability distribution model. The Bayesian update employs a conjugate prior method: the prior distribution of the mean parameter μ of the log-normal distribution is set to a normal distribution, and the mean deviation is used as the observed data to update the prior, yielding the posterior mean. The update formula is: μ_new = (σ_prior² μ_obs + σ_obs² μ_prior) / (σ_prior² + σ_obs²); Where μ_prior = 2.3 is the prior log mean, σ_prior = 0.4 is the prior log standard deviation, μ_obs = ln(10.0 + 1.8) = ln(11.8) = 2.47 is the observed log mean, and σ_obs = 1.2 / 10.0 = 0.12 is the observed log standard deviation. Substituting these values, we get μ_new ≈ 2.45, while σ remains unchanged at 0.4. Based on the updated distribution parameter set, the execution time probability distribution model is regenerated, and the updated quantile values are extracted from the regenerated distribution. These updated quantile values replace the original execution time assumptions corresponding to each candidate scheduling scheme in the candidate scheduling scheme set.
[0057] Simultaneously monitor whether the accumulated deviation data meets the preset outer loop triggering conditions. The outer loop triggering conditions include two conditions: (1) the mean deviation continuously drifts unidirectionally within a continuous window, specifically defined as the mean of the most recent 20 deviation samples increasing or decreasing for 5 consecutive times compared to the previous one; (2) the standard deviation of the deviation exceeds the preset upper limit of the standard deviation, which is set to 1.5 times the initial standard deviation, i.e., 0.6 (the initial standard deviation is 0.4). In this embodiment, the mean of the most recent 20 deviation samples shows a continuous increasing trend (gradually increasing from 1.2 seconds to 2.3 seconds), which meets the first outer loop triggering condition, thus triggering the spatial reconstruction of the trigger scheme.
[0058] The scheme space reconstruction involves adjusting the number of candidate schemes in the candidate scheduling scheme set and adjusting the distribution density of quantiles in the preset quantile selection strategy. Specifically, the number of candidate schemes is increased from 5 to 7; the quantile selection strategy is adjusted from equal-probability interval sampling to encrypted sampling at both ends of the cumulative probability (0-30% and 70-100%), i.e., selecting 7 quantiles at 10%, 20%, 30%, 50%, 70%, 80%, and 90%. This adjustment method can provide more alternative schemes to cope with extreme situations when the uncertainty of quantum execution time increases. The reconstructed candidate scheduling scheme set serves as the candidate scheme pool for this quantum executable unit in subsequent scheduling cycles, replacing the original candidate scheduling scheme set.
[0059] VIII. Experimental Verification of Parameter Value Range The above implementation involves multiple preset parameters. The preferred value ranges and experimental verification results for each parameter are given below.
[0060] Preset deviation threshold: The preferred range is 8% to 15%, with the optimal value being 10%. Experiments show that when the threshold is 8%, the system triggers an average of 47 switches in 500 scheduling tests, of which about 30% of the switches are unnecessary switches caused by normal statistical fluctuations in the execution time of the quantum computer; when the threshold is 15%, the average number of switches is reduced to 12, but four of these switches occur when the classical side has been idle for more than 2 seconds; when the threshold is 10%, the average number of switches is 28, the proportion of unnecessary switches is reduced to 12%, and no switch causes the classical side to wait for more than 1.5 seconds.
[0061] Number of quantiles N: The preferred range is 3 to 9, with 5 being the optimal choice. When N is 3, the candidate solutions only cover low, medium, and high cases, resulting in insufficient scheduling flexibility. In 500 simulation tests, the proportion of suboptimal scheduling forced due to a lack of matching solutions was 23%. When N is 9, the candidate solutions are sufficiently covered, but the computational cost of solution generation increases from the baseline of 15 milliseconds to 62 milliseconds, an increase of over 300%. When N is 5, the proportion of suboptimal scheduling forced decreases to 6%, while the solution generation cost is only 28 milliseconds, resulting in the best overall performance.
[0062] Sample size threshold: The preferred range is 10 to 50, with 20 being the most preferred. When the threshold is 10, the statistical characteristics of the deviation distribution are greatly affected by individual outliers, and the updated distribution parameters fluctuate wildly, causing the scheduling scheme to oscillate frequently between different periods. When the threshold is 50, the statistical stability is good, but the learning speed is too slow, and the system needs to accumulate a large amount of execution data to respond to changes in resource status. When the threshold is 20, a good balance is achieved between statistical stability and learning response speed.
[0063] Bias threshold: The preferred range is 0.05 seconds to 0.3 seconds, with the optimal value being 0.1 seconds. This threshold is determined based on one-tenth of the system scheduling cycle (1 second). Experiments show that when the threshold is below 0.05 seconds, the submodule's attribution judgment is too sensitive to small fluctuations in resource status, resulting in an average of 83 attribution flips over 100 consecutive scheduling cycles. When the threshold is above 0.3 seconds, the attribution judgment is too sluggish and cannot respond to changes in resource status in a timely manner, leading to an average execution time of approximately 12% longer than the optimal value. When the threshold is set to 0.1 seconds, the number of attribution flips decreases to 12, and the deviation of the average execution time from the optimal value is controlled within 3%.
[0064] Integration time window: The preferred range is 3 to 10 scheduling cycles, with the optimal range being 5 scheduling cycles. When the window is too short (less than 3 cycles), the evolution trajectory of the coupled field state only reflects instantaneous fluctuations and cannot capture the medium-term evolution trend of the system; when the window is too long (more than 10 cycles), the evolution trajectory is overly smoothed and the response to changes in the current resource state is lagging; when the window is 5 cycles, it can both filter out high-frequency noise and respond to state changes in a timely manner.
[0065] After task decomposition, the scheduler delivers the finalized classical executable unit and quantum executable unit to the coupled field calculation module and the candidate scheme generation module, respectively. There is no strict sequential dependency between the calculation of the coupled field state parameters and the generation of the candidate scheduling scheme set; they can be executed in parallel in the actual scheduling process. However, for clarity, the calculation process of the coupled field state parameters will be explained first, followed by the description of the generation process of the candidate scheduling scheme set.
[0066] Detailed process of calculating coupled field state parameters Upon receiving the resource status information for the current scheduling moment from the resource status acquisition module, the coupled field computation module immediately initiates the computation process of the coupled field dynamic evolution model. This module first parses the classical computing resource status and quantum computing resource status for the current scheduling moment from the resource status information packet. The classical computing resource status includes two fields: the number of currently schedulable classical computing units and the classical computing unit occupancy rate. The number of currently schedulable classical computing units is obtained by querying computing nodes with a status of "idle" or "mixed" in the SLURM job management system. In this embodiment's quantum hyperconverged system, the classical computing cluster contains 320 computing nodes, of which 280 are currently schedulable. The classical computing unit occupancy rate is not calculated using an instantaneous occupancy rate, but rather as a moving average occupancy rate over the most recent 10 sampling points (corresponding to a 1-second time window, with each sampling point spaced 100 milliseconds apart). The reason for choosing a moving average instead of instantaneous values is that the execution time of quantum executable units is typically on the order of seconds to tens of seconds. Using instantaneous occupancy would cause scheduling decisions to be overly sensitive to millisecond-level resource fluctuations. Experiments show that the variance of the execution time fluctuation of the scheduling scheme is reduced by about 65% after using a moving average. The quantum computing resource state includes the quantum task queue length and the cumulative complexity value of the quantum task queue. The quantum task queue length is the number of quantum executable units that have not yet started execution in the waiting queue maintained by the optical quantum computer measurement and control integrated machine; at the current moment, the queue length is 3.
[0067] The cumulative complexity value of the quantum task queue is not simply the sum of the number of qubits for each task. Instead, it is calculated as follows: For each quantum executable unit waiting to be executed in the queue, three characteristic parameters are extracted: the number of qubits, the number of quantum gate operations, and the number of measurement operations. The number of qubits is multiplied by a weighting coefficient of 0.2, the number of quantum gate operations by a weighting coefficient of 0.5, and the number of measurement operations by a weighting coefficient of 0.3. The sum of these three products is taken as the individual complexity value of the task. The individual complexity values of all tasks in the queue are then summed to obtain the cumulative queue complexity value. The weighting coefficients are based on regression analysis of historical operating data of optical quantum computers—using actual execution time as the dependent variable and the three characteristic parameters as independent variables in a multiple linear regression. The regression coefficients are normalized to obtain the aforementioned weight values. In this embodiment, the individual complexity values of the three waiting tasks in the queue are 120, 85, and 200, respectively; therefore, the cumulative queue complexity value is 405.
[0068] The coupled field computation module then constructs a two-way coupled differential equation system between the classical computing resource state and the quantum computing resource state. This system consists of two first-order ordinary differential equations. The first coupling equation describes the response of the classical computing resource state to changes in the quantum computing resource state, and its specific form is: dC / dt = -λ_C · C + μ_C · Q + ν_C; Where C represents the classical computing unit occupancy rate, Q represents the cumulative complexity value of the quantum task queue, λ_C is the relaxation coefficient of the classical resource itself, μ_C is the driving coefficient of quantum complexity on the classical occupancy rate, and ν_C is the basic load constant on the classical side. The second coupling equation is used to describe the state response of quantum computing resources to changes in the state of classical computing resources, and its specific form is: dQ / dt = -λ_Q · Q + μ_Q · C + ν_Q; Where λ_Q is the dissipation coefficient of the quantum queue, μ_Q is the driving coefficient of classical occupancy on the quantum queue, and ν_Q is the basic arrival constant on the quantum side. The meaning of bidirectional coupling is reflected in the fact that the rate of change of C in the first equation is driven by Q (μ_C·Q term), and the rate of change of Q in the second equation is driven by C (μ_Q·C term). The two resource states form a mutual constraint relationship through the cross term. The physical meanings of the four coupling coefficients λ_C, μ_C, ν_C, λ_Q, μ_Q, and ν_Q are as follows: the larger λ_C is, the faster the classical resource occupancy returns to the baseline value; the larger μ_C is, the faster the accumulation of the quantum task queue will drive the classical resources into a busy state; ν_C represents the basic load that exists on the classical side even when there are no tasks on the quantum side. The larger λ_Q is, the faster the quantum task queue dissipates; the larger μ_Q is, the faster the accumulation of the quantum task queue will be when the classical resources are busy; ν_Q represents the basic arrival rate of quantum tasks even when the classical side is idle.
[0069] The specific values of the aforementioned coupling coefficients are determined through a parameter estimation process. Parameter estimation uses the classical computing resource state sequence and the quantum computing resource state sequence within historical scheduling cycles as fitting data. Specifically, resource state sampling records for the past 100 scheduling cycles (each scheduling cycle being 1 second long) are extracted from the system operation log database. Each record includes a timestamp, a classical computing unit occupancy sampling value C(t), and a quantum task queue cumulative complexity value Q(t). The bidirectional coupling differential equation system is discretized between adjacent sampling points, and the forward Euler method is used to transform the differential equations into difference equations: C(t+Δt) - C(t) = (-λ_C · C(t) + μ_C · Q(t) + ν_C) · Δt; Where Δt is the sampling interval, i.e., 0.01 seconds. Substituting the data from 100 sampling points into the difference equation forms a system of 100 linear equations, with six coupling coefficients as the unknowns to be solved. The least squares method is used to solve this overdetermined linear system of equations, minimizing the sum of squared residuals to obtain estimates of the six coupling coefficients. In a typical parameter estimation in this embodiment, the calculated coupling coefficients are λ_C=0.15, μ_C=0.0022, ν_C=0.08, λ_Q=0.10, μ_Q=0.0018, and ν_Q=0.03. The magnitude of these values reflects the actual operating characteristics of the current system: the relaxation speed of classical resource occupancy (0.15) is slightly faster than the dissipation speed of the quantum queue (0.10), indicating that the scheduling response of classical resources is more agile.
[0070] After parameter estimation, the classical and quantum computing resource states at the current scheduling moment are used as initial conditions for the bidirectional coupled differential equation system. The classical computing unit occupancy rate C(t0) at the current scheduling moment t0 is set to a moving average of 0.62, and the cumulative complexity of the quantum task queue Q(t0) is 405. Using these two values as initial conditions, numerical integration is performed on the bidirectional coupled differential equation system within a preset time window. The preset time window length is 5 scheduling cycles, or 5 seconds. This value is derived from a trade-off analysis of system response latency and computational overhead—when the window is shorter than 3 seconds, the coupled field evolution trajectory is easily affected by transient noise; when the window is longer than 10 seconds, the computational overhead increases significantly and the evolution trend becomes too smooth. The numerical integration uses the fourth-order Runge-Kutta method, with an integration step size of 0.01 seconds. Within each integration step, four slope estimates are calculated sequentially, and the state variables are updated with weights. After integration, the state evolution trajectory of the system coupling field within the preset time window is obtained, that is, the numerical solution sequence of C(t) and Q(t) every 0.01 seconds in the time interval from t0 to t0+5 seconds.
[0071] The coupled field calculation module finally extracts the first-order derivative vector of the state evolution trajectory at the current scheduling moment as the coupled field state parameter of the system. The two components of the first-order derivative vector dS / dt|t0 are obtained directly by substituting C(t0) and Q(t0) into the right-hand side of the two-way coupled differential equation system. dC / dt|t0 = -0.15×0.62 + 0.0022×405 +0.08 = -0.093 + 0.891 + 0.08 = 0.878, indicating that the occupancy rate of the classical computing unit is rapidly increasing at the current moment, which is mainly driven by the high cumulative complexity value of the quantum task queue. dQ / dt|t0 = -0.10×405 +0.0018×0.62 + 0.03 = -40.5 + 0.0011 + 0.03 ≈ -40.47, indicating that the cumulative complexity of the quantum task queue is rapidly decreasing, suggesting that current quantum computing resources are quickly absorbing the backlog of tasks in the queue. This first-order derivative vector is then encapsulated as a system coupling field state parameter, serving as a constraint on the system evolution direction during the subsequent selection of the master scheduling scheme.
[0072] Detailed process of generating candidate scheduling scheme set While the coupled field calculation module performs the above calculations, the candidate scheme generation module receives the quantum executable unit and initiates the process of generating a set of candidate scheduling schemes. In this embodiment, the quantum executable unit includes a unit start-up and shutdown state decision submodule, which contains 2000 binary decision variables after QUBO modeling.
[0073] The candidate scheme generation module first extracts the task characteristic parameters of the quantum executable unit. These parameters include three dimensions: the number of qubits, the number of quantum gate operations, and the number of measurement operations. The number of qubits is set to the number of binary decision variables, i.e., 2000. This value determines the number of quantum modes the optical quantum computer needs to manipulate simultaneously, not exceeding the system's hardware capacity limit of 550 qubits. The number of quantum gate operations is the number of Ising model interaction terms required to map the QUBO model to the coherent optical quantum computer. This number is determined by the number of non-zero upper triangular elements in the QUBO matrix, which is approximately 3.98 million in this embodiment. The number of measurement operations is the number of measurements required to finally read the state of all qubits, which is 2000 here, corresponding to performing one projection measurement on each qubit.
[0074] Based on the three task feature parameters mentioned above, the candidate solution generation module retrieves a set of historical execution records that match the task feature parameters from the historical execution database. The historical execution database is deployed on a solid-state drive array on the system management node and stored as an embedded SQLite database. Each record contains a triplet of task feature parameters and the corresponding actual execution time data; the database currently contains approximately 5000 records. The matching retrieval uses a weighted Euclidean distance metric, with weights of 0.2, 0.5, and 0.3 for the three dimensions, consistent with the weights used in the aforementioned complexity calculation. The database is searched for the 100 records with the smallest weighted Euclidean distance to the current task feature parameters, forming the historical execution record set. In this embodiment, the actual execution times corresponding to the 100 retrieved historical records range from 5.8 seconds to 18.6 seconds.
[0075] Based on the 100 actual execution time data points mentioned above, the candidate solution generation module fits and generates an execution time probability distribution model. The fitting process first performs a normality test on the 100 data points using the Shapiro-Wilk test, calculating the test statistic W and the corresponding p-value. If the p-value is greater than 0.05, the normal distribution hypothesis is accepted, and the normal distribution is adopted as the distribution type, with the distribution parameter set being the sample mean and sample standard deviation. If the normality test fails, the log-normal and gamma distributions are tried sequentially. For each candidate distribution, maximum likelihood estimation is used to determine its distribution parameters: the parameters for the log-normal distribution are obtained by calculating the mean and standard deviation after taking the logarithm of the data; the shape and scale parameters for the gamma distribution are obtained by using the method of moments to obtain initial values and then optimizing the likelihood function using Newton-Raphson iteration. The goodness of fit of the three distributions is compared using the Akaike Information Content Criterion, and the distribution type with the smallest AIC value is selected as the final execution time probability distribution model. In this embodiment, the logarithmic values of 100 historical execution time data passed the Shapiro-Wilk test (p=0.13), and the log-normal distribution was selected as the distribution type, with the distribution parameter set being the logarithmic mean μ=2.28 and the logarithmic standard deviation σ=0.38.
[0076] Multiple quantile values are extracted from the execution time probability distribution model according to a preset quantile selection strategy. In this embodiment, the preset quantile selection strategy is equal-probability interval sampling, i.e., selecting quantiles according to the principle of uniform cumulative probability distribution. Specifically, quantile values corresponding to cumulative probabilities of 10%, 30%, 50%, 70%, and 90% are selected, resulting in a total of 5 quantiles. The quantile values are calculated using the inverse function of the log-normal cumulative distribution function: for a given cumulative probability p, the quantile value equals exp(μ + σ·Φ⁻¹(p)), where Φ⁻¹ is the inverse cumulative distribution function of the standard normal distribution. Substituting μ=2.28 and σ=0.38 respectively, the five quantile values are calculated: T1 = exp(2.28 + 0.38 × (-1.282)) = exp(1.793) = 6.0 seconds (10th percentile); T2 = exp(2.28 + 0.38 × (-0.524)) = exp(2.081) = 8.0 seconds (30th percentile); T3 = exp(2.28) = 9.8 seconds (50th percentile); T4 = exp(2.28 + 0.38 × 0.524) = exp(2.479) = 11.9 seconds (70th percentile); T5 = exp(2.28 + 0.38 × 1.282) = exp(2.767) = 15.9 seconds (90th percentile).
[0077] These five quantile values correspond to five execution time hypotheses, representing five possible time scenarios for the quantum executable unit to complete execution.
[0078] Using these five quantile values as five quantum execution time hypotheses, the candidate scheme generation module generates a set of corresponding classical executable unit pre-arrangement scheduling plans for each quantum execution time hypothesis. The generation of the pre-arrangement scheduling plans is based on the topological order in the functional module dependency graph as a basic constraint. In this embodiment, the classical executable unit contains four sub-modules that are executed sequentially: the power allocation continuous optimization sub-module can only be started after it is completed; after the verification is passed, the objective function evaluation sub-module is started; after the evaluation is completed, the iterative convergence judgment sub-module is executed.
[0079] For each quantum execution time assumption Tᵢ, the pre-scheduled schedule is generated as follows: the expected time occupied by the quantum executable unit on the optical quantum computer is set to Tᵢ, and all four classical sub-modules are executed within this time window. The start time offset of each classical sub-module is based on the start time of the quantum executable unit as the reference zero point: the first classical sub-module (power allocation continuous optimization) starts 0.1 seconds after the reference zero point, reserving time for submitting the quantum task to the optical quantum computer and completing initialization; each subsequent classical sub-module starts within 0.02 seconds after the completion of its direct predecessor sub-module, with 0.02 seconds reserved for inter-process communication and data transfer. The resource allocation of each classical sub-module is arranged as follows: the power allocation continuous optimization sub-module, due to its large-scale matrix operations, is allocated 4 classical computing nodes; the power transmission safety constraint verification sub-module, due to its sparse matrix solution of the power network topology, is allocated 2 classical computing nodes; the objective function evaluation sub-module, with relatively small computational load, is allocated 1 classical computing node; and the iterative convergence judgment sub-module, which only involves scalar comparison operations, is allocated 1 classical computing node. The four sub-modules occupy a total of 8 classic computing nodes, which does not exceed the current schedulable number of 280 nodes, so resources are sufficient.
[0080] Each quantum execution time hypothesis is associated and encapsulated with a corresponding set of pre-arranged scheduling plans for classical executable units, generating a complete candidate scheduling scheme. The data structure of the candidate scheduling scheme includes a scheme identifier, the quantum execution time hypothesis value, a list of start time offsets for each classical submodule, a list of resource-consuming nodes for each classical submodule, and a scheme generation timestamp. Five quantum execution time hypotheses correspond to five candidate scheduling schemes, which together constitute a candidate scheduling scheme set. Each scheme in this set represents a possible execution time scenario for a quantum executable unit and a classical-side collaborative scheduling plan under that scenario, providing a multi-scenario coverage decision-making basis for the subsequent selection of the main scheduling scheme.
[0081] Once the coupled field state parameters and the candidate scheduling scheme set are ready, the scheduling process enters the main scheduling scheme selection stage.
[0082] After the primary scheduling scheme is locked and execution begins, the system enters the execution progress monitoring and elastic switching phase. The purpose of this phase is to avoid re-executing the complete scheduling decision process when the actual execution progress of the quantum executable unit deviates from the expected progress. Instead, it quickly selects an alternative scheme that fits the current actual progress from the existing set of candidate scheduling schemes and continues execution, thereby maintaining low switching overhead while ensuring scheduling quality.
[0083] Real-time monitoring of execution progress and calculation of schedule deviation During the execution of the main scheduling scheme, the progress monitoring process deployed on the optical quantum computer's integrated measurement and control unit continuously collects the actual execution progress of the quantum executable units with a sampling period of 50 milliseconds. The selection of the sampling period stems from testing the hardware response capability of the integrated measurement and control unit. The device supports a minimum sampling interval of 10 milliseconds, but sampling at a 10-millisecond interval generates too much data, which would place an additional load on the control bus of the integrated measurement and control unit and affect the stability of quantum operations. Experiments show that a 50-millisecond sampling interval can control the bus occupancy rate below 5% while ensuring the progress monitoring resolution. The progress monitoring process reads two register values through the hardware monitoring interface of the optical quantum computer: the number of completed quantum gate operations register and the total number of sub-gate operations register. The former is incremented by the optical quantum computer's measurement and control system after each quantum gate operation is completed, while the latter is written by the measurement and control system when the task is loaded. The actual execution progress percentage is calculated by dividing the number of completed quantum gate operations by the total number of sub-gate operations and multiplying by 100. In this embodiment, the main scheduling scheme assumes an execution time of T3 = 9.8 seconds based on the 50% quantile, with a total number of sub-gate operations of 3.98 million. At the 4th second of execution, the progress monitoring process reads that 1.52 million quantum gate operations have been completed, and the actual execution progress percentage is approximately 1.52 / 3.98 × 100% ≈ 38.2%.
[0084] When obtaining the expected progress curve corresponding to the execution time assumptions on which the main scheduling scheme is based, it is necessary to clarify the specific generation method of the expected progress curve. In this embodiment, the expected progress curve is generated using linear interpolation. Its starting point is the progress of 0% at time zero, and its ending point is the progress of 100% at the time corresponding to execution time assumption T3. The expected progress percentage at any intermediate time is calculated through a linear proportional relationship. The linear interpolation curve is chosen because, in the absence of prior information on the execution time distribution of each stage within the quantum executable unit, linear interpolation is the estimation method with the minimum assumption bias. However, in other embodiments, the expected progress curve can also be generated using piecewise linear interpolation. For example, based on the execution time differences of different gate operation types in the quantum algorithm, the entire execution process can be divided into three stages: preparation, evolution, and measurement, with different slopes used for linear interpolation within each stage. In this embodiment, the expected progress percentage at the 4th second of execution is 4 / 9.8 × 100% ≈ 40.8%. The actual progress percentage of 38.2% was compared with the expected progress percentage of 40.8%, and the progress deviation value was calculated. The deviation value was 38.2% minus 40.8%, which equals -2.6%, meaning that the actual progress was 2.6 percentage points behind the expected progress.
[0085] In this embodiment, the preset deviation threshold is set to 10 percentage points, meaning that a switchover will not be triggered if the absolute value of the progress deviation does not exceed 10%. This threshold is not fixed but can be dynamically adjusted according to the system's operating mode. For example, when the system is in a high-load operating mode (quantum task queue length greater than 5), the deviation threshold is temporarily increased to 12% to reduce the additional overhead caused by frequent switching; when the system is in a low-load operating mode (quantum task queue length less than 2), the deviation threshold is reduced to 8% to achieve higher scheduling accuracy. In this embodiment, the quantum task queue length is 3, and the system is in a medium-load state, so the deviation threshold uses the default value of 10%. Since the current progress deviation is -2.6%, and the absolute value is less than 10%, the switchover trigger condition is not met, and the system continues to execute according to the main scheduling scheme.
[0086] Target scheduling scheme selection after switching conditions are triggered When the absolute value of the progress deviation exceeds the preset deviation threshold, the system triggers a scheduling scheme switching process. Assume that at the 5th second of execution, 1.85 million quantum gate operations have been completed, with an actual execution progress percentage of 185 / 398 × 100% ≈ 46.5%, while the expected progress percentage is 5 / 9.8 × 100% ≈ 51.0%, resulting in a deviation of -4.5%, still less than the 10% threshold. Further assume that at the 6.5th second of execution, 2.18 million quantum gate operations have been completed, with an actual execution progress percentage of 2.18 / 398 × 100% ≈ 54.8%, while the expected progress percentage is 6.5 / 9.8 × 100% ≈ 66.3%, resulting in a deviation of -11.5%, exceeding the 10% threshold, thus satisfying the switching condition.
[0087] After the switchover is triggered, the switchover execution module calculates the matching degree between the assumed execution time of each candidate scheduling scheme in the candidate scheduling scheme set and the actual execution time and actual execution progress percentage consumed by the quantum executable unit. The calculation of the matching degree score requires a specific formula. In this embodiment, for each candidate scheduling scheme k (whose execution time is assumed to be T_k), the matching degree score is calculated as Score_k = 1 / (|T_k - T_est| + ε), where T_est is the estimated final execution time based on the current actual progress, and ε is a very small positive number (taken as 10⁻). 6 () is used to prevent the denominator from being zero.
[0088] The estimated final execution time T_est is calculated as follows: the actual execution time consumed divided by the actual percentage of execution progress, then multiplied by 100, i.e., T_est = t_elapsed / progress_actual × 100%. At 6.5 seconds, progress_actual is 54.8%, therefore T_est = 6.5 / 54.8 × 100% ≈ 11.86 seconds. The execution times of the five candidate solutions in the candidate solution set are assumed to be T1 = 6.0 seconds, T2 = 8.0 seconds, T3 = 9.8 seconds, T4 = 11.9 seconds, and T5 = 15.9 seconds, respectively. Substituting these values into the matching score calculation formula, the scores are 1 / (|6.0-11.86|)≈0.171, 1 / (|8.0-11.86|)≈0.259, 1 / (|9.8-11.86|)≈0.485, 1 / (|11.9-11.86|)≈25.0, and 1 / (|15.9-11.86|)≈0.248. The matching score is highest at T4=11.9 seconds; therefore, the target scheduling scheme is selected as the candidate scheme corresponding to the 70th percentile.
[0089] However, in practical engineering applications, the matching score can be calculated using a more refined weighted approach. One alternative is to use the difference between the actual time consumed and the candidate solution's assumed execution time as the first scoring factor, and the difference between the actual progress percentage and the candidate solution's expected progress at the same time stamp as the second scoring factor. These two factors are weighted at 0.6 and 0.4 respectively, and then summed to obtain the final matching score. This weighted approach considers both the absolute time dimension and the relative progress dimension of the matching, reducing the false match rate by approximately 8% compared to a single-factor approach in experimental comparisons.
[0090] After selecting the target scheduling scheme, the execution module switches to use the current time of the quantum executable unit as the new time zero point, and uses the remaining execution time in the execution time assumption corresponding to the target candidate scheduling scheme as the expected remaining execution time of the quantum executable unit. In this embodiment, the current time is the 6.5th second from the original starting point. The original remaining time of the scheme T3=9.8 seconds was 3.3 seconds. After switching to the scheme T4=11.9 seconds, the new expected remaining execution time is 11.9 - 6.5 = 5.4 seconds. The start time and resource occupation period of each classical executable unit are recalibrated accordingly: the transmission safety constraint verification submodule, which should have started at 7.2 seconds, is postponed to the new corresponding time, and the start time of the other classical submodules is synchronously shifted. The recalibration process does not change the relative time interval between the classical submodules, but only shifts the entire classical side execution plan on the time axis.
[0091] Obtaining deviation data and updating model parameters after execution After the quantum executable unit completes its execution, the deviation learning module retrieves the actual execution time data from the execution log of the integrated measurement and control system. In one implementation, the deviation learning module downloads an execution record file containing timestamp information from the log directory of the integrated measurement and control system via a file transfer protocol, and after parsing, obtains the actual execution time as 12.1 seconds. In another alternative implementation, the deviation learning module receives a completion event pushed by the integrated measurement and control system in real time via a message queue. The event payload includes a task identifier and an actual execution time field. This method has lower latency than the file transfer method but is slightly more complex to implement. This embodiment uses the file transfer method.
[0092] The difference between the actual execution time data and the predicted value at the corresponding quantile of the execution time probability distribution model is calculated to generate a single deviation value. Since the main scheduling scheme uses the 50th quantile T3 = 9.8 seconds as the execution time assumption, the single deviation value is 12.1 - 9.8 = 2.3 seconds. This value is positive, indicating that the actual execution is slower than expected, belonging to a positive deviation sample. This single deviation value is categorized and stored according to the task characteristic parameters of the quantum executable unit. The categorization and storage are based on three dimensions: the number of qubits, the number of quantum gate operations, and the number of measurement operations. The three dimensions are quantized into interval indices: the number of qubits is divided into four intervals: 0-500, 501-1000, 1001-2000, and above 2000; the number of quantum gate operations is divided into three intervals: 0-1 million, 1 million-5 million, and above 5 million; and the number of measurement operations is divided into three intervals: 0-500, 501-2000, and above 2000. The indices of the three intervals are combined to form a three-dimensional classification key. In this embodiment, the task feature parameters (2000 qubits, 3.98 million quantum gate operations, and 2000 measurement operations) fall into the category "1001-2000" ∩ "1 million-5 million" ∩ "501-2000". The single deviation value of 2.3 seconds is added to the deviation sample sequence under this category.
[0093] The deviation learning module continuously monitors the number of deviation samples in each category of the deviation classification records. When the number of deviation samples in a certain category reaches a preset sample size threshold, the parameters of the probability distribution model for that category are updated. In this embodiment, the preset sample size threshold is set to 20 samples. This value is determined based on the central limit theorem in statistics—when the sample size is greater than 20, the distribution of the sample mean approaches a normal distribution, thus ensuring the conjugateness of the prior distribution in subsequent Bayesian updates. When the sample size threshold is 20, parameter updates are triggered approximately every 2 to 3 hours under typical operating frequency, ensuring both learning speed and avoiding excessively frequent update overhead.
[0094] After the parameter update is triggered, the deviation learning module performs statistical analysis on the 20 deviation samples in that category. It is important to emphasize that the generation of the deviation distribution statistical features is based on the original deviation values, not the normalized ones. The reason for using the original deviation values instead of normalized values is that the accuracy assessment of execution time prediction should be based on an absolute time scale rather than a relative proportion—a 2-second deviation has different statistical significance in a 10-second task than in a 20-second task, and the original deviation values retain this scale information. The statistical analysis generates three statistical features: the deviation mean is the arithmetic mean of the 20 deviation values, which is 2.1 seconds in this example; the deviation standard deviation is the standard deviation of the 20 deviation values relative to the deviation mean, which is 1.1 seconds in this example; and the deviation skewness is the third central moment of the deviation value distribution divided by the cube of the standard deviation, which is 0.35 in this example. A positive value indicates that the distribution is positively skewed, meaning that the number or magnitude of positive deviation samples is slightly greater than that of negative deviation samples. The skewness is calculated using the standard formula Skew = (1 / n)·Σ((x_i - mean) / std)³, where n is the sample size, x_i is each deviation value, mean is the mean deviation, and std is the standard deviation of the deviation.
[0095] Based on the statistical characteristics of the above-mentioned deviation distribution, the distribution parameters of the execution time probability distribution model are updated using Bayesian methods. The specific method of Bayesian updating is as follows: the prior distribution of the mean parameter μ of the log-normal distribution is set to a normal distribution centered on the current μ value. The deviation mean is treated as observed data, and the posterior mean is directly calculated using the property of the conjugate prior. Let the prior mean be μ_prior = 2.28, the prior standard deviation be σ_prior = 0.38, the observed log mean be μ_obs = ln(9.8 + 2.1) = ln(11.9) ≈ 2.48, and the observed log standard deviation be σ_obs = 1.1 / 9.8 ≈ 0.11. The formula for calculating the posterior mean μ_posterior is: μ_posterior = (σ_prior²·μ_obs + σ_obs²·μ_prior) / (σ_prior² + σ_obs²) = (0.1444×2.48 + 0.0121×2.28) / (0.1444+0.0121) = (0.3581+0.0276) / 0.1565 ≈ 2.46. The logarithmic standard deviation σ remains unchanged at 0.38 because the existing bias data is insufficient to reliably update the high dispersion of the distribution. Based on the updated distribution parameter set (μ=2.46, σ=0.38), a new execution time probability distribution model is generated. New quantile values are extracted from this updated distribution to replace the execution time assumptions in the original candidate scheduling scheme set, completing a partial refresh of the candidate scheduling scheme set.
[0096] Scheme Space Reconstruction Based on Cumulative Deviation In addition to updating the local parameters after each execution, the deviation learning module continuously monitors whether the accumulated deviation data meets the outer loop triggering conditions. The outer loop triggering conditions include two scenarios; satisfying either one triggers scheme space reconstruction.
[0097] The first outer loop trigger condition is a sustained unidirectional drift of the deviation mean within a continuous window. The length of the continuous window is set to the most recent 20 deviation samples, and the criterion for unidirectional drift is a five consecutive monotonically increasing or decreasing deviation mean. This determination method is implemented as follows: whenever a new sample is added, the deviation mean of the most recent 20 samples is recalculated. The current mean is compared with the previously calculated mean. If the current mean is greater than the previous mean, it is marked as an upward direction; otherwise, it is marked as a downward direction. If five consecutive markings are either upward or downward, it is determined to be a sustained unidirectional drift. In this embodiment, the mean sequence of the most recent 20 deviation samples is 1.8, 1.7, 1.9, 2.0, 2.2, 2.3 (in seconds), with the last five being monotonically increasing, triggering the outer loop condition.
[0098] The second outer loop trigger condition is when the standard deviation exceeds a preset upper limit of the standard deviation. The preset upper limit is set based on an initial standard deviation σ0 = 0.38, with the upper limit being 1.5 times the initial standard deviation, i.e., 0.57. The outer loop condition is triggered when the standard deviation exceeds 0.57 at any given time. This multiplier of 1.5 is a variant of the 3σ criterion commonly used in statistical process control—when the standard deviation increases by more than 50% of the initial value, it indicates that the uncertainty of execution time prediction has significantly increased, and the original scheme's spatial coverage capability is insufficient. In this embodiment, the standard deviation is 1.1 seconds, which, after conversion to a logarithmic scale, is approximately 0.11, far less than 0.57, therefore the second condition is not met.
[0099] After the first outer loop condition is met, the scheme space reconstruction operation is performed as follows: The number of candidate schemes in the candidate scheduling scheme set is adjusted, increasing from 5 to 7. The two newly added quantiles are selected at the 20% and 80% cumulative probabilities. Simultaneously, the distribution density of quantiles in the quantile selection strategy is adjusted. Specifically, sampling is switched from equal-probability intervals to encrypted sampling at both ends of the probability distribution—the new quantile strategy selects 7 quantiles at cumulative probabilities of 5%, 15%, 25%, 50%, 75%, 85%, and 95%. This encrypted strategy at both ends provides more alternative schemes to cope with extreme situations when the uncertainty of quantum execution time increases. Experimental data shows that in scenarios where positive deviations accumulate continuously, the 7-quantile strategy with encrypted quantiles at both ends improves the scheduling coverage from 72% to 91% in extreme scenarios compared to the equal-interval 5-quantile strategy, while the scheme generation overhead only increases by about 40%.
[0100] The reconstructed set of candidate scheduling schemes replaces the original set and serves as the pool of candidate schemes for this category of quantum executable units in subsequent scheduling cycles. In the next scheduling cycle, if a new task arrives and its task characteristic parameters fall into the same category, the system will directly use the reconstructed set of candidate schemes without having to re-execute the complete scheme generation process, thus improving prediction accuracy while maintaining scheduling efficiency.
[0101] Detailed process of task decomposition After receiving the unit combination optimization calculation task to be scheduled, the task decomposition module first performs functional sub-module decoupling processing on the calculation task to be scheduled. The implementation of decoupling processing relies on the data flow analysis technology of the compiler front end. Specifically, the source code of the calculation task to be scheduled is input into an analysis tool built on the LLVM compiler framework. This tool parses the source code into an intermediate representation, which stores all variables and operations in a static single-assignment form. The analysis tool then executes a data flow analysis algorithm on the intermediate representation. This algorithm starts from the entry block of the function, traverses all basic blocks along the control flow graph, traces the definition-use chain of each variable, and identifies instruction groups that have data dependencies on each other through variable read and write operations.
[0102] Instruction groups that have no data dependencies or only weak data dependencies (i.e., dependencies can be removed through data copying or recalculation) are divided into different functional sub-modules. Taking the unit combination optimization task as an example, the decoupling process yields the following functional sub-modules: the unit start-up and shutdown state decision sub-module is responsible for generating 0-1 decision variable combinations; the power allocation continuous optimization sub-module is responsible for solving the optimal value of continuous power allocation under given start-up and shutdown states; the transmission safety constraint verification sub-module is responsible for checking whether the given solution meets the line transmission capacity constraints; the objective function evaluation sub-module is responsible for calculating the sum of the total generation cost and the start-up and shutdown cost; and the iterative convergence judgment sub-module is responsible for determining whether the optimization iteration has reached the termination condition.
[0103] The data dependencies between the submodules are as follows: the output start / stop state vector of the unit start / stop state decision submodule is simultaneously input to both the power allocation continuous optimization submodule and the transmission safety constraint verification submodule; the output power allocation vector of the power allocation continuous optimization submodule and the start / stop state vector are jointly input to the objective function evaluation submodule; the objective function evaluation value is input to the iterative convergence judgment submodule; and the output convergence flag of the iterative convergence judgment submodule is fed back to the unit start / stop state decision submodule. These functional submodules and data dependencies constitute a functional module dependency graph with functional submodules as nodes and data dependencies as directed edges. This dependency graph is a directed acyclic graph, and there are no other loops except for the feedback edge of the iterative convergence judgment submodule. The feedback edge is specially handled in scheduling—its execution timing is determined by the number of iterations rather than the data readiness state.
[0104] After the functional module dependency graph is constructed, the first estimated generation value and the second estimated generation value for each functional submodule in the graph are calculated on the classical computing side and the quantum computing side, respectively. The first estimated generation value is calculated as follows: static instruction counting is performed on the intermediate representation of the functional submodule, the number of floating-point operation instructions is multiplied by the average execution time of a single floating-point operation on a classical computing node, and the estimated latency of memory access operations is added to obtain the estimated execution time on the classical side. In this embodiment, the power allocation continuous optimization submodule contains approximately 2.3 × 10 9 10¹ floating-point arithmetic instructions; the peak speed of single-precision floating-point arithmetic operations on a classic computing node is 10¹⁰ per second. 5 Secondly, considering the actual memory access and scheduling overhead, the effective utilization rate is approximately 65%, therefore the first estimated cost is 2.3 × 10⁻⁶. 9 / (10¹ 5 (×0.65)≈3.5 milliseconds. The transmission safety constraint verification submodule contains approximately 4.2×10 8 The first estimated time for each floating-point instruction is approximately 0.65 milliseconds. The objective function evaluation submodule and the iterative convergence judgment submodule have relatively small computational costs, with first estimated time values of 0.12 milliseconds and 0.05 milliseconds, respectively.
[0105] The second estimated cost value is calculated as follows: A QUBO mappability analysis is performed on the intermediate representation of the functional submodule, counting the number of integer variables that can be converted into binary decision variables and the number of arithmetic operations that can be converted into quadratic objective functions. If the submodule can be expressed in QUBO form, its quantum-side estimated execution time is calculated by dividing the size of the QUBO problem (i.e., the number of binary variables) by the effective qubit bandwidth of the optical quantum computer (the number of interaction terms that can be processed per second), and then multiplying by the quantum task queue length correction coefficient. In this embodiment, the unit start-up / shutdown state decision submodule contains 2000 binary decision variables, which can be completely mapped to a QUBO model, and its quantum-side estimated cost value is approximately 2000² / (4×10⁻⁶). 6 )×(1+3 / 10)≈1.3 seconds, where 4×10 6 3 represents the number of Ising model interaction terms that a photonic quantum computer can process per second, and 3 represents the current quantum task queue length. The power allocation continuous optimization submodule, due to its continuous variables that cannot be mapped to QUBO form, has its quantum-side estimated generation value set to a maximum of 10. 6 The time limit is set to exclude the possibility of execution on the quantum side. The constraints in the power transmission safety constraint verification submodule can be partially mapped to QUBO penalty terms, with a quantum-side estimated cost of approximately 0.8 seconds. Since the objective function evaluation submodule and the iterative convergence judgment submodule do not involve binary decision variables, their quantum-side estimated costs are both set to maximum values.
[0106] The difference between the first and second estimated generation values is calculated, and the difference between the first and second estimated generation values yields the quantum bias factor of the functional submodule. The quantum bias factor of the unit start-up / shutdown state decision submodule is approximately -1.296 seconds (classical side estimate of 3.5 milliseconds minus quantum side estimate of 1.3 seconds), with a negative value indicating a stronger advantage for quantum side execution. The quantum bias factor of the power allocation continuous optimization submodule is approximately -999996.5 milliseconds, strongly biased towards the classical side. The quantum bias factor of the transmission safety constraint verification submodule is approximately -0.15 seconds, which is less than the absolute value of a preset bias threshold. In this embodiment, the preset bias threshold is set to 0.1 seconds. Submodules are classified according to the sign and absolute value of the quantum bias factor: those with a quantum bias factor greater than 0.1 seconds are classified as classical-biased submodules, those less than -0.1 seconds as quantum-biased submodules, and those with an absolute value less than or equal to 0.1 seconds as uncertain submodules. The unit start-up and shutdown state decision submodule falls into the quantum bias submodule, while the power allocation continuous optimization submodule, objective function evaluation submodule, and iterative convergence judgment submodule fall into the classical bias submodule. The quantum bias factor of the power transmission safety constraint verification submodule is -0.15 seconds, and its absolute value is greater than 0.1 seconds, so it is also classified into the quantum bias submodule rather than the uncertain submodule.
[0107] All quantum-biased submodules are merged to generate an initial set of quantum executable units, and all classical-biased submodules are merged to generate an initial set of classical executable units. After the power transmission safety constraint verification submodule is included in the quantum executable unit set, the quantum executable units, in addition to executing start / stop state decisions, also need to complete the penalty term calculation for safety constraint verification. Uncertain submodules that do not trigger the bias threshold determination condition do not appear in this embodiment, therefore the candidate execution bias queue is empty. The initial set of quantum executable units and the initial set of classical executable units are merged to generate a final classical executable unit and a quantum executable unit.
[0108] Computerization mechanism for scheduling feasibility scoring When an uncertain submodule exists in a computational task to be scheduled, the system needs to optimize its candidate execution tendency. Scheduling feasibility scoring is the core basis for this optimization. Although there is no uncertain submodule in this embodiment, to fully illustrate the mechanism, a hypothetical scenario is used: if the quantum bias factor of the power transmission safety constraint verification submodule is exactly -0.08 seconds, falling within the range of uncertain submodules, its candidate execution tendency queue includes the first candidate scheme executed on the classical side and the second candidate scheme executed on the quantum side. Using the initial set of quantum executable units, the initial set of classical executable units, and the candidate execution tendency queue of the uncertain submodule as input, the candidate scheduling scheme generation process is invoked for rapid deduction. The rapid deduction uses the same candidate scheme generation algorithm as the formal scheduling, but the number of quantiles is reduced to 3 to reduce computational overhead. It should be noted that the candidate execution tendency queue is a priority queue arranged in ascending order of estimated cost value, with the candidate scheme at the head of the queue having the lowest estimated cost value, which is the scheme to be tried first during rapid deduction.
[0109] The rapid derivation outputs a set of candidate scheduling schemes for each alternative solution. Each candidate scheme in this set includes a quantum execution time assumption and a corresponding classical pre-scheduled plan. The calculation of the scheduling feasibility score requires an explicit aggregation function. Let there be M schemes in the candidate scheduling scheme set, and let T_i be the quantum execution time assumption for each scheme. The scheme density is defined as the ratio of the coverage of all candidate schemes on the time axis to the number of candidate schemes, calculated using the following formula: Density = (max(T_i) - min(T_i)) / (M-1); Where max(T_i) and min(T_i) are the maximum and minimum execution time assumptions among the candidate solutions, respectively, and M is the number of candidate solutions. The minimum difference between solutions is defined as the minimum absolute difference in execution time assumptions between any two candidate solutions, and the calculation formula is: MinDiff = min_{i≠j} |T_i - T_j|. The scheduling feasibility score is the product of the scheme density and the minimum difference between schemes, i.e., FeasScore = Density × MinDiff. The physical meaning of this score is as follows: Scheme density reflects the sufficiency of candidate scheme coverage in the time dimension; a higher density indicates a more comprehensive coverage of all possible execution times. The minimum difference between schemes reflects the distinguishability between candidate schemes; a higher minimum difference indicates significant differences between candidate schemes and the absence of redundant schemes. The larger the product of the two, the greater the flexibility and efficiency of the decomposed scheme in subsequent scheduling. It should be noted that when the number of candidate schemes is less than 2, the minimum difference between schemes is defined as the assumed execution time value of the candidate scheme itself, and the score degenerates into the product of the scheme density and the assumed execution time value. The selection of the product aggregation method is based on experimental comparison—under the same conditions, the product method has approximately 23% higher distinguishability of the decomposed schemes than the weighted sum method.
[0110] Detailed process of selecting the main scheduling scheme Once the coupled field state parameters and the candidate scheduling scheme set are ready, the main scheduling scheme selection module initiates the comprehensive cost evaluation process.
[0111] The selection module first extracts a feature vector for each candidate scheduling scheme in the candidate scheduling scheme set. The feature vector contains three components: the first component is the quantum execution time hypothesis value T_i corresponding to the candidate scheduling scheme; the second component is the sequence of startup time offsets for each classical executable unit; in this embodiment, the offsets of the four classical sub-modules are arranged in execution order as a four-dimensional vector; the third component is the sequence of resource allocation for each classical executable unit; in this embodiment, the number of nodes allocated to each of the four classical sub-modules is arranged as a four-dimensional vector. All feature vector components are in their original numerical form without normalization, because the components of the subsequent cost function have different physical units, and the design of the weight coefficients has already considered the difference in dimensions.
[0112] The comprehensive cost function comprises three cost components. The first cost component measures the classical-quantum cooperative waiting cost, and its mathematical formula is as follows: C1 = max(T_Q - T_C, 0) / T_C + max(T_C - T_Q, 0) / T_Q; Where T_Q is the assumed quantum execution time, and T_C is the sum of the total execution times of all sub-modules on the classical side. The first term of the formula represents the relative cost of the classical waiting for the quantum when the quantum is slower than the classical, and the second term represents the relative cost of the quantum waiting for the classical when the classical is slower than the quantum. C1 takes its minimum value of 0 when T_Q is equal to T_C, and C1 monotonically increases as the difference between the two increases. In this embodiment, T_C = 3.5 + 0.65 + 0.12 + 0.05 = 4.32 milliseconds, which is negligible in the second range relative to T_Q. Therefore, for the scheme with T_Q = 9.8 seconds, C1 ≈ (9.8 - 0.0043) / 0.0043 ≈ 2278, which is a large value, but this value is only used for relative comparison between schemes.
[0113] The second cost component is used to measure the system disturbance cost. The system's natural evolution trajectory is defined as the trajectory of the coupled field state parameters naturally evolving according to the two-way coupled differential equation when no current scheduled task is applied. Given the current first-order derivative vector dS / dt|t0=[0.878, -40.47], the disturbance cost is calculated as follows: substitute the resource occupancy of the classical executable units (8 nodes) in the candidate scheduling scheme into the classical occupancy rate driving term on the right-hand side of the first coupled equation, calculate the occupancy rate change rate dC / dt_scheduled after scheduling is applied, and then multiply the absolute value of the difference between this and the naturally evolved dC / dt_natural (i.e., 0.878) by the disturbance sensitivity coefficient. The calculation of dC / dt_scheduled is -0.15×0.62 + 0.0022×405 +0.08 + Δ, where Δ is the proportion of 8 nodes to 280 schedulable nodes, i.e., 8 / 280≈0.0286 multiplied by the driving coefficient 0.0022 and then multiplied by the classical resource response gain factor of 10, Δ≈0.00063. dC / dt_scheduled≈0.878+0.00063=0.87863, and the second cost component is |0.87863-0.878|×0.5≈0.000315.
[0114] The third cost component is used to measure the degree of temporal continuity utilization of classical computing resources. Based on the startup time offset sequence of each classical submodule and its respective execution time, the variance of the idle time distribution among the submodules is calculated. Idle time is defined as the time interval between the completion of one classical submodule and the startup of the next. In this embodiment, the four classical submodules are executed in the order of continuous power allocation optimization, transmission safety constraint verification, objective function evaluation, and iterative convergence judgment. The execution times of each submodule are 3.5 ms, 0.65 ms, 0.12 ms, and 0.05 ms, respectively. There is only a 0.02 ms communication reservation gap between each submodule, and the idle time sequence is [0.02, 0.02, 0.02] ms with zero variance. The third cost component is 0.
[0115] The weight coefficients of the three cost components are adaptively adjusted according to the direction of the first derivative vector in the system's coupled field state parameters. The specific rules for adaptive adjustment are as follows: when dC / dt > 0 and dQ / dt > 0, resources tend to be busy, and the cooperative waiting cost weight is set to 0.6; when dC / dt < 0 and dQ / dt > 0, classical resources tend to be idle while quantum resources tend to be busy, and the system disturbance cost weight is set to 0.5; when dC / dt > 0 and dQ / dt < 0, classical resources tend to be busy while quantum resources tend to be idle, and the time continuity weight is set to 0.4; when dC / dt < 0 and dQ / dt < 0, resources tend to be idle, and all three weights are set to 1 / 3. In this embodiment, dC / dt = 0.878 > 0 and dQ / dt = -40.47 < 0, belonging to the third case, with the three weight coefficients being 0.4, 0.3, and 0.3 respectively. The three cost components are weighted and summed to obtain the total cost of each candidate scheduling scheme: C_total = 0.4×C1 + 0.3×C2 + 0.3×C3. Since C1 is much larger than C2 and C3 when comparing in the second and millisecond ranges, the total cost is mainly determined by C1. Among the five candidate schemes, the scheme with T_Q and T_C closest, i.e., the 50th percentile scheme with 9.8 seconds, has the smallest total cost and is selected as the primary scheduling scheme. After locking the start time offset and resource allocation of each classic executable unit in the primary scheduling scheme, the system starts execution according to the scheme.
[0116] When a hyperconverged system receives a larger-scale generator set optimization task in a subsequent scheduling cycle, the task may be decomposed into multiple quantum executable units. For example, 2000 generator sets can be divided into four geographical regions, each corresponding to an independent subproblem. Each subproblem contains approximately 500 binary decision variables, resulting in four quantum executable units and four corresponding classical executable units. In this multi-quantum task scenario, multiple quantum executable units compete for the same optical quantum computer resources, requiring additional consideration of internal constraints on the quantum side during the main scheduling scheme selection phase.
[0117] Quantum side constraint construction in multi-quantum scenarios When a computational task to be scheduled is decomposed into multiple quantum executable units (QKs), the main scheduling scheme selection module first extracts the execution time probability distribution model corresponding to each QK in the candidate scheduling scheme set. Each QK has its own independent execution time probability distribution model, and the distribution type and parameters are fitted from the historical database according to their respective task characteristic parameters. For any two QKs A and B, their execution time probability distributions are represented as f_A(t) and f_B(t), respectively. The execution window overlap probability of the two QKs on the same quantum computing device is calculated by performing convolution integral on the two probability density functions. The physical meaning of the execution window overlap probability is: under the assumption that random variables T_A follow distribution f_A and T_B follow distribution f_B and are independent of each other, the absolute value of the difference between T_A and T_B is less than a certain time threshold. The value of this threshold is the minimum time cost required for the quantum computing device to complete one task switch. In this embodiment, the task switch cost of the optical quantum computer is 0.5 seconds, which is determined by the time required for the integrated measurement and control machine to load the new task configuration parameters. The specific calculation formula for the overlap probability is: P_overlap = ∫∫_{|t_A - t_B| < 0.5} f_A(t_A)·f_B(t_B) dt_A dt_B, where the double integral is approximated by discretization on the time axis using numerical integration methods, and the integration range is taken as the interval between plus and minus 5 standard deviations of the means of the two distributions.
[0118] A quantum task interference graph is constructed, with each quantum executable unit (QMU) as a node and the execution window overlap probability as the edge weight. This interference graph is an undirected complete graph, where an edge exists between any two QMUs, and the edge weight represents the execution window overlap probability between them. Pairs of QMUs whose overlap probability exceeds a preset interference threshold are extracted from the interference graph and marked as interference constraint pairs. In this embodiment, the preset interference threshold is set to 0.3. This value is determined based on the system's tolerance for task execution time uncertainty—when the overlap probability is below 0.3, the probability of actual execution window conflict between two tasks is low, and even if a conflict occurs, it only causes a slight queuing delay; when the overlap probability exceeds 0.3, the conflict probability is no longer negligible. A probabilistic mutual exclusion constraint set is generated based on the interference constraint pairs. Each mutual exclusion constraint in this set contains a mutual exclusion strength coefficient, which is positively correlated with the execution window overlap probability. Specifically, the mutual exclusion strength coefficient is directly taken as the overlap probability value, i.e., the coefficient ranges from 0 to 1; the higher the overlap probability, the closer the mutual exclusion strength coefficient is to 1.
[0119] The initialization module occupancy sequence and measurement module occupancy sequence required for each quantum executable unit to execute on the optical quantum computer are extracted. The internal functional modules of the optical quantum computer include a quantum state preparation module, an interferometric measurement module, and a signal readout module. The initialization module occupancy sequence records the time period occupied by the quantum executable unit in the quantum state preparation module during execution; this sequence is determined by the number of qubits in the quantum task and the parallelism of the quantum gate operations. The measurement module occupancy sequence records the time periods occupied by the quantum executable unit in the interferometric measurement module and the signal readout module during execution. In this embodiment, the initialization time required for a 500-qubit quantum executable unit is 0.3 seconds, and the measurement time is 0.2 seconds. Therefore, the initialization module occupancy sequence is a single time window [0, 0.3] seconds, and the measurement module occupancy sequence is a single time window [T_exe-0.2, T_exe] seconds, where T_exe is an assumed value for the execution time of the quantum task.
[0120] Based on the initialization module occupancy identifier sequence and the measurement module occupancy identifier sequence of each quantum executable unit, a time-division multiplexing occupancy demand vector for the internal functional modules of the optical quantum computer is constructed. The time-division multiplexing demand vector is time-divided, with each element corresponding to a discrete time slot with a granularity of 0.05 seconds. The vector length covers twice the maximum execution time assumption among all candidate schemes. The value of each element indicates whether the functional module is occupied within that time slot. The initialization module, interferometric measurement module, and signal readout module each correspond to an independent time-division multiplexing demand vector. These three vectors together constitute a description of the occupancy demand of the quantum executable unit for all internal functional modules of the optical quantum computer.
[0121] The probabilistic mutual exclusion constraint set and the time-sharing occupancy demand vector are used as additional constraints on the quantum side, and together with the coupling field state parameters, they form a comprehensive constraint boundary. Within this comprehensive constraint boundary, a selection operation is performed on the candidate scheduling scheme set. The specific rules for this selection operation are as follows: for two quantum executables with mutual exclusion strength coefficients higher than a first strength threshold, it is prohibited to simultaneously schedule these two quantum executables to the same time window of the same quantum computing device. In this embodiment, the first strength threshold is set to 0.7, meaning that when the overlap probability of two tasks exceeds 0.7, they are forcibly prohibited from overlapping execution. The selection of this threshold of 0.7 is based on the fact that an overlap probability above 0.7 means that in most execution scenarios, both will experience window conflicts, and it is better to stagger them directly during the scheduling phase than to rely on dynamic switching to handle conflicts. For mutual exclusion constraint pairs with mutual exclusion strength coefficients between 0.3 and 0.7, simultaneous scheduling is allowed, but a penalty term needs to be added to the cost function. The weight of the penalty term is the mutual exclusion strength coefficient multiplied by a preset penalty factor.
[0122] Window drift propagation during multi-quantum task execution During the execution of the main scheduling scheme, the system monitors the actual execution progress deviation of each quantum executable unit in real time. When the actual execution progress deviation of the first quantum executable unit causes a time drift in its execution window, a window drift signal is propagated along the interference edge connected to the first quantum executable unit in the quantum task interferogram to the second quantum executable unit that has an interference constraint pair with the first quantum executable unit. The propagation method of the window drift signal is as follows: the expected completion time change caused by the progress deviation of the first quantum executable unit is calculated, and this change is multiplied by the weight of the interference edge (i.e., the mutual exclusion strength coefficient) to serve as an expected execution window offset reminder for the second quantum executable unit. This reminder triggers a priority upgrade operation for the candidate scheme in the candidate scheduling scheme set of the second quantum executable unit that matches the drifted time window. The specific implementation of priority enhancement is as follows: In the candidate scheduling scheme set of the second quantum executable unit, the matching degree between the execution time assumption of each candidate scheme and the current time consumed is calculated, and the candidate scheme with the highest matching degree is marked as the hot standby scheme. When the drift of the first quantum executable unit exceeds the preset severe drift threshold (such as the absolute value of the progress deviation exceeding 20%), it directly switches to the hot standby scheme.
[0123] When multiple quantum executable units share the same quantum computing device and the number of concurrent execution channels supported by the quantum computing device is less than the number of quantum executable units to be executed, the execution order of each quantum executable unit on the quantum computing device needs to be dynamically sorted. In this embodiment, the optical quantum computer supports single-channel serial execution, meaning only one quantum executable unit can be executed at a time. The dynamic sorting aims to minimize the sum of weighted overlap probabilities in the quantum task interferogram. The sorting algorithm employs a greedy strategy: starting from the current moment, one task is selected for execution from the unscheduled tasks, based on minimizing the cumulative weighted overlap probability increment of the scheduled tasks. The cumulative weighted overlap probability increment is calculated as the sum of the overlap probabilities between the newly added task and all scheduled tasks multiplied by their respective mutual exclusion strength coefficients. After sorting, the execution time windows of each quantum executable unit are allocated sequentially according to the sorting results. The start time of each task's execution time window is the completion time of the previous task plus a switching overhead of 0.5 seconds. The number of concurrent execution channels is the upper limit of the number of quantum tasks that can be active at the same time, which is supported by the optical quantum computer measurement and control integrated machine. When the number is 1, it means that the measurement and control integrated machine is in single-channel serial execution mode. When the number is greater than 1, it means that it supports multi-task pipeline parallel execution.
[0124] Deviation-driven parameter tuning of coupled field model During system operation, the accumulated deviation data is not only used to update the execution time probability distribution model and reconstruct the candidate scheme set, but also to adjust the parameters of the coupled field dynamic evolution model, so that the coupled field state parameters can more accurately reflect the actual output rhythm of quantum computing resources.
[0125] The deviation learning module extracts the first cumulative value of positive deviation samples and the second cumulative value of negative deviation samples from the cumulative deviation data. Positive deviation samples are defined as those whose actual execution time is less than the predicted value, i.e., samples where the quantum task is completed ahead of schedule; negative deviation samples are defined as those whose actual execution time is greater than the predicted value, i.e., samples where the quantum task is delayed. The proportions of the first and second cumulative values in the cumulative deviation data are calculated to generate a deviation direction bias factor. The formula for calculating the deviation direction bias factor is B = (N_pos - N_neg) / (N_pos + N_neg), where N_pos is the number of positive deviation samples and N_neg is the number of negative deviation samples. The value range of B is [-1, 1], with positive values indicating an overall bias towards early completion and negative values indicating an overall bias towards delayed completion.
[0126] The direction of coupling field adjustment is determined based on the bias factor. When B is greater than 0.2, meaning the cumulative proportion of positive bias exceeds 60% of the first direction threshold (corresponding to B>0.2), it is determined that the actual output rate of quantum computing resources is faster than the expected output rate of the current state of the coupling field. At this time, the first coupling coefficient of the second coupling equation in the two-way coupling differential equation system, which describes the response of quantum computing resource state to changes in classical computing resource state, is adjusted in the direction of enhancing response sensitivity. The first coupling coefficient is μ_Q in the second equation; the specific operation to enhance response sensitivity is to multiply μ_Q by a coefficient of 1.2. Increasing μ_Q will cause the increase in classical occupancy to drive changes in quantum queue complexity more rapidly, enabling the coupling field to track the actual output rate of quantum resources faster. When B is less than -0.2, meaning the cumulative proportion of negative bias exceeds 60% of the second direction threshold, it is determined that the actual output rate of quantum computing resources is slower than the expected output rate of the current state of the coupling field. At this time, the second coupling coefficient of the first coupling equation, which describes the response of classical computing resource state to changes in quantum computing resource state, is adjusted in the direction of enhancing buffer capacity. The second coupling coefficient, μ_C in the first equation, enhances the buffer capacity by multiplying μ_C by a coefficient of 0.8. This weakens the driving force of quantum queue complexity on classical occupancy, thereby reducing the response amplitude of classical resources to quantum output delay, which is equivalent to adding a buffer margin to the classical side.
[0127] When the oscillation frequency of the accumulated deviation data exceeds a preset oscillation threshold, the output rhythm of quantum computing resources is determined to have high-frequency fluctuations. The deviation oscillation frequency is calculated by counting the number of sign alternations in the most recent 20 deviation samples, and dividing the number of alternations by 20 gives the oscillation frequency. The preset oscillation threshold is 0.4, meaning that more than 8 sign alternations in 20 samples are considered high-frequency fluctuations. At this point, the damping coefficients corresponding to the classical computing resource state and the quantum computing resource state in the two-way coupled differential equation system are adjusted. The damping coefficients are λ_C in the first equation and λ_Q in the second equation. Increasing the damping coefficients involves multiplying both by a coefficient of 1.5. After increasing the damping coefficients, the rate of change of the coupled field state parameters becomes more dependent on the state variables themselves, and the response to external driving terms slows down, thus switching the response of the coupled field state parameters to the deviation signal from an instantaneous following mode to a trend-following mode. In the instantaneous following mode, the coupled field state parameters respond rapidly to each deviation change, while in the trend-following mode, the coupled field state parameters only respond to the long-term trend of the deviation, and high-frequency fluctuations are effectively filtered out.
[0128] The adjusted bidirectional coupled differential equations are used as the update equations for the dynamic evolution model of the coupled field in the next scheduling cycle, thereby re-driving the generation and selection process of the candidate scheduling scheme set. Specifically, in the calculation of the coupled field state parameters in the next scheduling cycle, the adjusted λ_C, μ_C, λ_Q, and μ_Q are used to replace the original parameters for numerical integration. The coupled field state parameters obtained by integration will reflect the adjusted resource response characteristics, thereby guiding the scheduling decision to shift towards adapting to the actual output rhythm of quantum resources. In this embodiment, the B value reaches -0.35 after 24 hours of continuous operation, triggering an adjustment of μ_C by 0.8. After the adjustment, the classical side's tolerance to quantum latency is significantly enhanced, and the proportion of classical computing units idle due to waiting for quantum results decreases from 18% before the adjustment to 9% after the adjustment, increasing the overall system throughput by approximately 12%. Subsequently, the deviation oscillation frequency stabilizes below 0.25, without triggering the damping coefficient adjustment. The above adjustment operations are recorded in the system log, and the performance comparison data before and after the operation provides experimental basis for subsequent parameter optimization.
[0129] During the selection of the main scheduling scheme, the quality of the construction of the comprehensive cost function directly determines whether the final selected scheduling scheme can achieve the optimal balance between collaborative efficiency, system stability, and resource continuity. The weight coefficients of the three cost components are not fixed constants, but are adaptively adjusted according to the direction of the first derivative vector in the system's coupled field state parameters. The specific implementation of this adjustment mechanism is as follows.
[0130] Extraction and evolution direction determination of the first derivative vector direction angle The weight adaptive adjustment module first extracts the direction angle of the first-order derivative vector from the system's coupled field state parameters. The first-order derivative vector is denoted as dS / dt = [dC / dt, dQ / dt], where the first component dC / dt corresponds to the rate of change of the classical computing resource state dimension, and the second component dQ / dt corresponds to the rate of change of the quantum computing resource state dimension. The direction angle θ is determined by the ratio of the first and second components using the arctangent function, specifically calculated as θ = atan2(dQ / dt, dC / dt), where atan2 is the four-quadrant arctangent function, returning values from -π to π. The direction angle characterizes the evolution direction of the system's coupled field at the current scheduling moment. Its geometric meaning is: in the two-dimensional state space spanned by the first-order derivative vector, the angle between the vector pointing from the origin to the point (dC / dt, dQ / dt) and the positive direction axis of the classical resource state.
[0131] The quadrant interval of the orientation angle in the polar coordinate system is used as the basis for weight adjustment. The decision boundaries for the four quadrants are: the first quadrant corresponds to θ ∈ (0, π / 2), the second quadrant corresponds to θ ∈ (π / 2, π), the third quadrant corresponds to θ ∈ (-π, -π / 2), and the fourth quadrant corresponds to θ ∈ (-π / 2, 0). When the orientation angle falls exactly on the coordinate axis, i.e., θ=0, θ=π / 2, θ=-π / 2, or θ=π, the weight adjustment strategy of the two adjacent quadrants is used to take the arithmetic mean for transition, avoiding abrupt changes in weight coefficients at the quadrant boundaries.
[0132] Weight adjustment strategies for different quadrants When the orientation angle is in the first quadrant, dC / dt > 0 and dQ / dt > 0, indicating that the classical and quantum computing resource states are co-growing. Under this condition, both classical and quantum resources become increasingly busy. While the complexity of the quantum task queue increases, the classical occupancy rate also rises, making the co-waiting cost between the two particularly critical—if the scheduling scheme fails to properly match the execution times of the classical and quantum sides, waiting on either side will further amplify system congestion due to resource scarcity on the other side. Therefore, the weight coefficient of the first cost component in the comprehensive cost function is adjusted to increase to strengthen the penalty for the classical-quantum co-waiting cost. In the weight adjustment mechanism of this embodiment, the base weight of the first cost component is 0.4, which is adjusted to 0.6 when the orientation angle is in the first quadrant, and the second and third components are each adjusted to 0.2.
[0133] When the orientation angle is in the second quadrant, dC / dt < 0 and dQ / dt > 0, indicating that the classical computing resource state is decreasing while the quantum computing resource state is increasing. Under this situation, quantum tasks are accumulating while classical resources are being released, and the system's natural evolution trajectory points towards increased quantum congestion. If the scheduling decision intervenes excessively by forcibly allocating classical resources to tasks that cooperate with quantum processes, it may disrupt the system's natural resource release rhythm, causing even greater overall disturbance. Therefore, the weight coefficient of the second cost component is adjusted to increase to strengthen the penalty for the system deviating from its natural evolution trajectory and suppress excessive disturbances to the coupling field stability caused by the scheduling decision. The weight of the second cost component is adjusted from the base value of 0.3 to 0.5, and the weights of the first and third components are each adjusted to 0.25.
[0134] When the orientation angle is in the third quadrant, dC / dt < 0 and dQ / dt < 0, indicating that the classical and quantum computing resource states are in a state of coordinated decay. Under this condition, the overall system load is decreasing, the quantum queue is dissipating, and the classical occupancy rate is declining. At this point, the core objective of scheduling is no longer to maximize throughput, but rather to slow down the decay rate of the system's coupling field by improving the continuity of resource utilization, thus maintaining a stable resource state baseline for upcoming tasks. Therefore, the weight coefficient of the third cost component is adjusted to increase to strengthen the constraint on the temporal continuity of classical computing resource utilization. The weight of the third cost component is adjusted from the base value of 0.3 to 0.5, and the weights of the first and second components are each adjusted to 0.25.
[0135] When the orientation angle is in the fourth quadrant, dC / dt > 0 and dQ / dt < 0, indicating that the classical computing resource state is trending upward while the quantum computing resource state is trending downward. Under this situation, the quantum task queue is rapidly dissipating while classical resources are being occupied, and the system is in a quantum contraction phase. The contradiction here is that quantum resource contraction means the completion speed of quantum tasks is accelerating, while the increase in classical resources means the available scheduling margin on the classical side is decreasing. The combination of these two factors puts pressure on both collaborative efficiency and system stability. Therefore, the weight coefficients of the first and second cost components are simultaneously adjusted to increase, in order to strengthen both collaborative efficiency constraints and system stability constraints during the quantum resource contraction phase. The weight of the first cost component is adjusted from the base value of 0.4 to 0.45, the weight of the second cost component is adjusted from the base value of 0.3 to 0.40, and the weight of the third component is adjusted to 0.15.
[0136] Calculation of adjustment amplitude factor and weight normalization The adjustment range of the weighting coefficients is not a fixed value, but is related to the magnitude of the first derivative vector. The ratio of the magnitude of the first derivative vector to a preset magnitude threshold is used as the adjustment range factor. The formula for calculating the magnitude of the first derivative vector is M = sqrt((dC / dt)² + (dQ / dt)²). This magnitude reflects the severity of the changes in the coupled field state of the system—the larger the magnitude, the more drastic the changes in the system state, requiring a larger adjustment of the weights to cope. In this embodiment, the preset magnitude threshold M_threshold is set to 0.5. This value is selected based on the statistical analysis of the rate of change of the coupled field state parameters under normal operating conditions: under stable operating conditions, the mean of the magnitude of the first derivative vector is approximately 0.3, and the standard deviation is approximately 0.15. Taking the mean plus 1.5 times the standard deviation, i.e., 0.3 + 0.225 ≈ 0.525, rounded down, we get 0.5. When the magnitude exceeds 0.5, it indicates that the changes in the system state exceed the normal operating range, requiring a more aggressive adjustment of the weights. The adjustment magnitude factor r = min(M / M_threshold, 2.0), with an upper limit of 2.0, is set to prevent the weight coefficient from oscillating violently between adjacent scheduling cycles due to excessively large single adjustment magnitude.
[0137] The adjustment range of the weight coefficients of each cost component is positively correlated with the adjustment range factor. Specifically, for a weight component that needs to be increased, its adjusted target weight is W_target = W_base + (W_max - W_base) × (r -1) / (2 - 1), where W_base is the base weight determined according to the quadrant, and W_max is the preset maximum allowable weight for that component (set to 0.7 to avoid the cost function from being skewed due to an excessively large single weight). For a weight component that needs to be decreased, its adjusted target weight is W_target = W_base × (1 - (r - 1) / 2). The sum of the adjusted weight coefficients of each cost component is kept to 1 by the normalization constraint, i.e., W1 + W2 + W3 = 1. The normalization operation is performed after all weight adjustment calculations are completed: the three adjusted weight values are divided by the sum of the three to obtain the final weight coefficients that satisfy the normalization constraint.
[0138] In this embodiment, the current first-order derivative vector dS / dt = [0.878, -40.47], and the direction angle θ = atan2(-40.47, 0.878) ≈ -1.549 radians, which is located in the fourth quadrant (from -π / 2 to 0). The magnitude M = sqrt(0.878² + (-40.47)²) ≈ 40.48, which is much larger than the preset magnitude threshold of 0.5. The adjustment amplitude factor r = min(40.48 / 0.5, 2.0) = 2.0. The basic weights of the fourth quadrant are 0.45 for the first component, 0.40 for the second component, and 0.15 for the third component. Since r=2.0 reaches its upper limit, the weight adjustment reaches its maximum: the target weight of the first component = 0.45 + (0.7-0.45)×(2-1) / (2-1) = 0.70, the target weight of the second component = 0.40 + (0.7-0.40)×1 = 0.70, and the target weight of the third component = 0.15 × (1 - (2-1) / 2) = 0.075. After normalization, the sum of the three is 1.475, and the final weights are W1=0.70 / 1.475≈0.475, W2=0.70 / 1.475≈0.475, and W3=0.075 / 1.475≈0.05. Under this weighting configuration, the first and second cost components each account for approximately 47.5%, while the third cost component accounts for only 5%. This reflects that, under the condition of rapid shrinkage of quantum resources and synchronous growth of classical resources, the system focuses its scheduling optimization efforts on the two dimensions of cooperative efficiency and system stability, while correspondingly reducing its attention to resource continuity. After substituting this weighting configuration into the comprehensive cost function, the final selected main scheduling scheme is the 11.9-second scheme corresponding to the 70th percentile. Compared with the 50th percentile scheme without adaptive weights, this sacrifices some expected execution time, but avoids excessive occupation of rapidly released quantum resources during the quantum shrinkage period, thereby improving the overall system throughput by approximately 9% in continuous testing.
[0139] The preset threshold value M_threshold should be adjusted under different system configurations. When the system is large and the number of classic nodes exceeds 1000, the rate of change of the coupled field state parameters is naturally large, and the threshold should be increased to about 1.0 accordingly. When the system is small (the number of nodes is less than 100), the threshold can be reduced to 0.3. Experiments show that when the threshold is in the range of 0.3 to 0.8, the weight adaptive adjustment mechanism can improve the system throughput by more than 5%, but the optimal overall performance is achieved when the threshold is 0.5 with a system size of 320 nodes, with a throughput improvement of 12.4%. When the threshold is below 0.3, the weight adjustment is too frequent, and the stability of the selected scheme decreases; when the threshold is above 0.8, the weight adjustment is too slow to respond to changes in system state, and the adaptation time during sudden load changes is extended to more than 6 scheduling cycles.
[0140] In multi-quantum task scenarios, dynamic ordering of execution on quantum computing devices is a crucial step in the scheduling process. As mentioned earlier, when multiple quantum executables share the same quantum computing device, the execution order needs to be optimized to minimize the sum of weighted overlap probabilities. The following section further elaborates on the specific implementation of the dynamic ordering algorithm.
[0141] Construction of Conflict Weight Graph The dynamic sorting module first extracts the mutual exclusion strength coefficient between any two quantum executables in the probabilistic mutual exclusion constraint set. The mutual exclusion strength coefficient has been determined in previous calculations. For quantum executables i and j, its mutual exclusion strength coefficient is denoted as w_ij, which is numerically equal to the overlap probability between their execution time probability distributions, and its value ranges from 0 to 1. Simultaneously, the distribution dispersion parameter of the execution time probability distribution of each of the two quantum executables is extracted. The distribution dispersion parameter characterizes the degree of dispersion of the execution time probability distribution; in this embodiment, the standard deviations σ_i and σ_j of the execution time probability distribution are used. For a log-normal distribution, the standard deviation is calculated as std = exp(μ + σ² / 2) × sqrt(exp(σ²) - 1), where μ and σ are the logarithmic mean and logarithmic standard deviation, respectively. The distribution dispersion parameter reflects the degree of uncertainty in the execution time of the quantum executables—the greater the dispersion, the more unpredictable the execution time of the task, and the higher the risk of window conflicts with other tasks.
[0142] The product of the mutual exclusion strength coefficient and the distribution dispersion parameter is used as the conflict weight value between the two quantum executable units. The specific calculation formula is c_ij = w_ij × (σ_i + σ_j) / 2, where (σ_i + σ_j) / 2 is the arithmetic mean of the distribution dispersion of the two tasks. The physical meaning of this product form is that the execution window conflict risk of two tasks depends not only on their time window overlap probability but also on the uncertainty of their respective time predictions. Tasks with greater uncertainty should be given higher priority weights in the ranking to avoid cascading conflicts. In the scenario of four quantum executable units in this embodiment, assuming the distribution standard deviations of the four tasks are σ1=0.35, σ2=0.42, σ3=0.28, and σ4=0.51, the typical value of the mutual exclusion strength coefficient matrix is w_ij. 12 =0.65, w 13 =0.25、w 14 =0.45、w 23 =0.55、w 24 =0.70、w 34 =0.30. Therefore, the conflict weight matrix is calculated as follows: c 12 =0.65×(0.35+0.42) / 2≈0.250, c 13 =0.25×(0.35+0.28) / 2≈0.079, c 14 =0.45×(0.35+0.51) / 2≈0.194, c 23 =0.55×(0.42+0.28) / 2≈0.193, c 24 =0.70×(0.42+0.51) / 2≈0.326, c 34 =0.30×(0.28+0.51) / 2≈0.119.
[0143] A conflict weight graph is constructed using quantum executable units as nodes and conflict weights as edge weights. This graph is an undirected weighted complete graph, where each node represents a quantum executable unit, and the weight carried by each edge is the conflict weight value calculated above.
[0144] Conflict centrality index and initial execution order generation The conflict centrality index of each quantum executable unit is extracted from the conflict weight graph. The conflict centrality index is equal to the sum of the conflict weights of all edges connected to that quantum executable unit, calculated as D_i = Σ_{j≠i}c_ij. This index characterizes the degree of conflict risk clustering for each quantum executable unit in the entire task set—a larger D_i indicates more or stronger conflict relationships between that task and other tasks, and it should be prioritized in the sorting process to reduce overall conflict risk. In this embodiment, the conflict centralities of the four tasks are as follows: D1 = c 12 +c 13 +c 14 = 0.250 + 0.079 + 0.194 = 0.523, D2 = c 12 +c 23 +c 24 = 0.250 + 0.193 + 0.326 = 0.769, D3 = c 13 +c 23 +c 34 = 0.079 + 0.193 + 0.119 = 0.391, D4 = c 14 +c 24 +c 34 = 0.194+0.326+0.119 = 0.639.
[0145] The quantum executable units are sorted in descending order based on the conflict centrality index to generate an initial execution order sequence. This descending order prioritizes the task with the highest conflict risk, as earlier execution of a high-risk task minimizes the impact of its uncertainty on subsequent tasks. Sort by D value from largest to smallest, the initial execution order sequence is [2, 4, 1, 3], meaning task 2 executes first, followed by task 4, then task 1, and finally task 3.
[0146] Exchange perturbation optimization Using the initial execution order sequence as the current optimal sequence, a local search optimization is performed on the sequence through a perturbation operation. Specifically, the perturbation operation involves randomly selecting two adjacent quantum executable units from the current optimal sequence, or selecting them according to a specific strategy, and swapping their positions to generate a perturbed candidate sequence. Swapping adjacent positions is superior to swapping arbitrary positions because the perturbation amplitude of adjacent swaps is smaller, ensuring the search process proceeds smoothly within the solution's neighborhood and avoiding search divergence due to large perturbations.
[0147] Calculate the change in the global conflict weight sum before and after the exchange perturbation. The definition of the global conflict weight sum requires precise definition of the aforementioned terms—in this sorting algorithm, the global conflict weight sum is not simply the sum of the weights of all edges in the conflict weight graph, but rather the sum of the products of the conflict weight values of all retained interference constraint pairs and the corresponding execution window overlap probabilities. Specifically, for the current execution order sequence, assuming that tasks are arranged sequentially according to their execution windows, and the start time of the next task is the end time of the previous task plus the state reset cost (0.5 seconds in this embodiment), under this time allocation, whether any two tasks actually overlap is determined by the expected value of their execution time probability distribution. If tasks i and j have an expected overlap after the time allocation, then the interference constraint pair is retained, and its contribution is the conflict weight value c_ij multiplied by the actual overlap probability. The global conflict weight sum is denoted as G = Σ_{Retained Interference Constraint Pairs (i,j)} c_ij × P_overlap_actual(i,j), where P_overlap_actual(i,j) is the probability that the execution windows of the two tasks overlap under the current execution order and time allocation. The criterion for "retaining" should be explained: under the current execution order and corresponding time window allocation, if the execution windows of the two quantum executable units overlap on the time axis (i.e., the latter task starts before the former task finishes), then the interference constraint pair is retained; if there is no overlap, it is not included in the calculation of the global conflict weight sum.
[0148] When the change ΔG = G_after - G_before is negative, meaning the global conflict weights decrease after the exchange, and the execution windows of each quantum executable unit in the candidate sequence after the exchange perturbation satisfy the exclusive occupancy constraints of each functional module in the time-sharing occupancy demand vector, the exchange perturbation operation is accepted, and the candidate sequence is updated to the current optimal sequence. The exclusive occupancy constraint is checked by placing the execution windows of each task sequentially on the time axis according to the candidate sequence and checking for overlap between the occupancy windows of the same functional module. For example, if the occupancy window of the measurement module of Task 2 overlaps with the occupancy window of the initialization module of Task 4 on the time axis, it violates the exclusive occupancy constraint of the internal functional modules of the optical quantum computer, and the candidate sequence is unacceptable. The exchange is accepted after the check passes.
[0149] The exchange perturbation operation is repeated until the preset number of perturbations or the change in the global conflict weights converges. In this embodiment, the preset number of perturbations is 100, based on experimental test results—in a scenario with four task scales, 100 exchange perturbations are sufficient to fully search the solution space, and further increasing the number of perturbations improves the optimization effect by less than 1%. The convergence criterion is that the decrease in the global conflict weights in 20 consecutive exchange perturbations is less than 0.001; at this point, the solution is considered converged. In this embodiment, after approximately 47 exchange perturbations, the global conflict weights converge from the initial value of 0.813 to 0.674, and the subsequent perturbation changes are all less than 0.001. The iteration stops, and the current optimal sequence at convergence is determined as the final execution order. The final execution order after convergence is [4, 2, 1, 3]. Note: The preferred range for the number of perturbations is 50 to 200, with the most preferred being 100. The convergence criterion is that the decrease in the sum of global conflict weights after N consecutive perturbations is less than the preset convergence threshold (preferably between 0.001 and 0.01, with the most preferred being 0.001).
[0150] The execution time windows on the optical quantum computer are allocated sequentially according to the final execution order. The start time of the execution time window of the next quantum executable unit is no earlier than the sum of the end time of the execution time window of the previous quantum executable unit and the state reset time overhead of the quantum computing device. In this embodiment, the state reset time overhead is taken as 0.5 seconds, which includes the total time spent by the integrated measurement and control machine loading new task parameters, resetting the quantum state preparation module, and recalibrating the interferometric measurement module. Specifically, the execution window of task 4 is [0, 11.2] seconds, and the state reset time is 0.5 seconds. The execution window of task 2 starts at 11.7 seconds, and its execution time is assumed to be 8.5 seconds, so the window is [11.7, 20.2] seconds, and so on.
[0151] Rigid conflict protection interval insertion When two quantum executables have conflict weight values exceeding a preset rigid conflict threshold and are arranged adjacently in the final execution order, a device cooling protection interval time window needs to be inserted between the two quantum executables. In this embodiment, the preset rigid conflict threshold is set to 0.30. A conflict weight value exceeding 0.30 means that the product of the mutual exclusion strength coefficient and the distribution dispersion parameter between the two tasks is sufficiently large, making it difficult to guarantee controllable conflict risk even with adjacent arrangement. An additional cooling protection interval is needed to further reduce the probability of conflict. The length of the device cooling protection interval window is positively correlated with the conflict weight values of the two quantum executable units. Specifically, the mapping relationship is: Interval length = c_ij × 2.0 seconds, where 2.0 is a proportionality coefficient. This coefficient is determined based on the additional stabilization time required by the integrated optical quantum computer measurement and control system after completing a high-conflict-intensity task switch. Experiments show that when the conflict weight value increases from 0.1 to 0.4, the initial state preparation success rate of the qubit decreases from 97.2% to 91.8%. Each increase of 0.1 in the conflict weight requires an additional stabilization wait time of approximately 0.4 seconds to restore the preparation success rate to above 97%. In the final execution order [4, 2, 1, 3] of this embodiment, adjacent pairs include (4, 2) conflict weight values c_ij. 42 =0.326、(2,1) Conflict weight value c 21 =0.250, (1,3) conflict weight value c 13 =0.079. Where c 42 =0.326 exceeds the rigid conflict threshold of 0.30. Therefore, a cooling protection interval is inserted between Task 4 and Task 2, with an interval length of 0.326 × 2.0 ≈ 0.65 seconds. After the insertion, the start time of the execution window for Task 2 is postponed from 11.7 seconds to 12.35 seconds. The other two pairs of conflict weight values do not exceed the threshold, and no additional interval is needed. It should be noted that this interval is the time window required for the optical quantum computer measurement and control integrated machine to perform parameter recalibration, quantum state preparation module reset, and interferometric measurement module baseline restoration after completing the previous quantum task and before starting the next quantum task. During this window, the measurement and control integrated machine does not receive new quantum tasks or perform any substantial quantum operations.
[0152] The effectiveness of inserting the cooling protection interval was verified through system test data: without the protection interval, the quantum state initialization failure rate caused by the adjacent execution of Task 4 and Task 2 was 6.3%. After inserting a 0.65-second protection interval, the failure rate dropped to 1.2%, and the overall system task success rate increased from 94.7% to 98.5%. When the conflict weight value reaches 0.50 or higher, the protection interval length is extended proportionally to more than 1.0 second. At this time, it is necessary to simultaneously check whether this interval will cause subsequent tasks to exceed the planned scheduling cycle deadline. If it does, an emergency reconstruction of the global candidate solution set is triggered to compress the execution time of the quantum task. In this embodiment, the insertion of the protection interval between Task 4 and Task 2 did not exceed the scheduling cycle deadline, so no further processing is required.
[0153] System overall architecture and module deployment The heterogeneous computing task scheduling system based on a hyperconverged infrastructure provided in this embodiment is deployed in the hyperconverged platform of the National Supercomputing Center. The system adopts a distributed deployment architecture, with its management node being a server configured with dual CPUs and 256GB of memory, running a trimmed Linux operating system kernel, serving as the control core of the entire scheduling system. The quantum computer's measurement and control unit is connected to the management node via a 200Gbps high-speed Ethernet, while the management node of the classical computing cluster is interconnected with the management node via an InfiniBand network. All scheduling-related modules run as daemons on the management node, exchanging data between modules through shared memory and message queues.
[0154] The resource status acquisition module is configured to acquire the current resource status information of the hyperconverged system. This module runs as an independent thread on the management node and contains two sub-components: a classical resource acquisition sub-component and a quantum resource acquisition sub-component. The classical resource acquisition sub-component sends a status query request to the management node of the classical computing cluster every 100 milliseconds by calling the application programming interface of the job management system. The data returned by the query includes the number of currently schedulable classical computing units and the instantaneous occupancy rate of each computing unit. After receiving the raw data, the acquisition sub-component maintains a circular buffer of length 10 locally to store the occupancy rate values of the most recent 10 samples. Each time a new sample value is received, the circular buffer is updated and the arithmetic mean is recalculated to obtain a moving average estimate of the classical computing unit occupancy rate. The quantum resource acquisition sub-component sends a status query command to the integrated measurement and control unit of the optical quantum computer via high-speed Ethernet. Upon receiving the command, the integrated measurement and control unit returns the current length of the quantum task queue and the cumulative complexity value of the quantum task queue. The cumulative complexity value is calculated locally by the integrated measurement and control unit in real time according to preset weight coefficients (0.2 for the number of qubits, 0.5 for the number of quantum gate operations, and 0.3 for the number of measurement operations). The data acquired by the two sub-components are synchronized according to a unified timestamp, encapsulated into resource status information packets, and published through the shared memory area of the management node for downstream modules to read.
[0155] The coupled field calculation module is configured to calculate the system coupled field state parameters at the current scheduling moment based on the current resource state information and a pre-defined coupled field dynamic evolution model. After reading the resource state information packet from the shared memory region, this module first parses the moving average of the classical computing unit occupancy rate and the cumulative complexity value of the quantum task queue. Then, it calls the coupling coefficient parameter file stored on the management node's hard drive to read the six coupling coefficients of the two-way coupled differential equation system. The initial version of the parameter file is generated by offline fitting of historical running data during system deployment and is periodically updated by the deviation learning module during system operation. The coupled field calculation module uses the fourth-order Runge-Kutta method to numerically integrate the two-way coupled differential equation system, with a fixed integration step size of 0.01 seconds and an integration time window of 5 scheduling cycles (5 seconds). After integration, the coupled field calculation module extracts the first-order derivative vector from the starting point of the integration trajectory; this vector is the system coupled field state parameter, which is then written to another region of shared memory for use by the main scheduling scheme selection module. The coupled field calculation module executes a complete calculation process once per scheduling cycle, with each calculation taking approximately 3 to 5 milliseconds, which is much shorter than the length of the scheduling cycle, thus ensuring the real-time performance of the calculation.
[0156] The task decomposition module is configured to receive computation tasks to be scheduled and decompose them into one or more classical executable units and one or more quantum executable units. After receiving the submitted computation tasks, the module first calls an analysis tool built on the LLVM compiler framework to perform intermediate representation conversion and data flow analysis on the task source code, outputting an adjacency list representation of the functional module dependency graph. Subsequently, the task decomposition module traverses each functional submodule node in the dependency graph, calling the estimated cost calculation subroutine for each node. The estimated cost calculation subroutine internally maintains an instruction-execution time mapping table, recording the average execution latency of different instruction types on classical computing nodes and optical quantum computers. This mapping table is generated by benchmark tests during system initialization and dynamically calibrated using measured data during runtime. The task decomposition module categorizes submodules based on the sign and absolute value of the quantum bias factor. For uncertain submodules, it calls the candidate scheduling scheme generation interface for rapid deduction, ultimately outputting a definite list of one or more classical executable units and one or more quantum executable units, along with the functional module dependencies. Figure 1 And write it to shared memory.
[0157] The candidate scheduling module is configured to generate an execution time probability distribution model for each quantum executable unit (QMU) based on its task characteristic parameters, and generate a set of candidate scheduling schemes based on multiple quantiles of the execution time probability distribution model. This module extracts a list of QMUs from the output of the task decomposition module, and performs the following operations sequentially for each QMU in the list: extracting three task characteristic parameters, performing a K-nearest neighbor search in the local embedded database using these three parameters as keys, and using the retrieved historical data set to fit the probability distribution. The fitting process calls statistical functions from a third-party scientific computing library to perform normality tests, maximum likelihood estimation, and Akaike information criterion comparisons, selecting the optimal distribution type and outputting the distribution parameters. The candidate scheduling module then calculates the quantile values on the selected distribution according to a preset quantile strategy (in this embodiment, 5 quantiles with equal probability intervals are used by default), calls a pre-programmed planning subroutine for each quantile value to generate the corresponding classical-side scheduling plan, and finally associates the quantum execution time assumption with the classical-side scheduling plan to encapsulate it as a candidate scheduling scheme. All schemes are then summarized to form a candidate scheduling scheme set, which is written to shared memory.
[0158] The main scheduling scheme selection module is configured to use the coupled field state parameters as constraints to select the main scheduling scheme that satisfies the system optimization objective from the candidate scheduling scheme set. This module reads both the coupled field state parameters and the candidate scheduling scheme set from shared memory. The selection module first extracts the scheme feature vector for each candidate scheme, and then calls the comprehensive cost function calculation subroutine. Internally, the comprehensive cost function calculation subroutine sequentially calculates the first cost component, the second cost component, and the third cost component. The weight coefficients of each cost component are determined in real-time by the weight adaptive adjustment subroutine based on the direction angle of the first derivative vector of the coupled field state parameters. The weight adaptive adjustment subroutine implements a quadrant-based rule engine, outputting a normalized ternary weight recombination after inputting the direction angle. After traversing all candidate schemes, the main scheduling scheme selection module selects the scheme with the minimum comprehensive cost value as the main scheduling scheme. It then locks the scheme identifier, the start time offset of each classical executable unit, and the resource allocation arrangement, and writes them into the scheduling execution form of the management node. The scheduling execution form is a data structure protected by a mutex lock. The executor thread initiates job submission for classical executable units and task distribution for quantum executable units according to the form's contents.
[0159] The elastic switching execution module is configured to monitor the actual execution progress of each quantum executable unit in real time during execution. When the actual execution progress deviates from the execution time assumption based on the main scheduling scheme by more than a preset threshold, it switches from the candidate scheduling scheme set to the target scheduling scheme that matches the current actual execution state of the quantum executable unit. This module contains two sub-threads: a progress monitoring sub-thread and a switching execution sub-thread. The progress monitoring sub-thread sends a progress query request to the optical quantum computer measurement and control integrated machine via high-speed Ethernet at a period of 50 milliseconds. The progress data returned by the measurement and control integrated machine is written into an atomic variable for the switching execution sub-thread to read. At the end of each monitoring period, the switching execution sub-thread calculates the progress deviation value and compares it with a preset deviation threshold (default 10%). If a switch is triggered, a matching degree calculation is performed—the matching degree calculation uses a reciprocal distance weighted formula to select the scheme with the highest matching degree score from the candidate scheme set as the target scheme. The switching execution sub-thread then recalibrates the start time of all classical executable units with the current time as the new time zero point and updates the unexecuted parts in the scheduling execution form. The elastic switching execution module will not interrupt the execution of the classic sub-modules that have already started during the switching process; it will only adjust the scheduling parameters of the sub-modules that have not yet started.
[0160] The deviation learning and scheme reconstruction module is configured to acquire the actual execution time data of each quantum executable unit, update the parameters of the execution time probability distribution model based on the deviation between the actual execution time data and the predicted value of the execution time probability distribution model, and dynamically reconstruct the candidate scheduling scheme set based on the accumulated deviation data. This module is registered with the execution completion event of the optical quantum computer in the form of a callback function. Each time a quantum executable unit completes execution, the integrated measurement and control machine pushes a completion event to the management node via high-speed Ethernet. The event data includes the task identifier and the actual execution time. After receiving the event, the deviation learning and scheme reconstruction module performs a single deviation calculation and appends the deviation value to the corresponding classification record according to the three-dimensional classification key of the task feature parameters. The module maintains a background thread that continuously monitors the number of samples in each classification record. When the number of samples reaches a preset threshold of 20, a Bayesian update subroutine is triggered to update the probability distribution parameters corresponding to that classification and refresh the execution time assumptions in the candidate scheme set. The background thread simultaneously calculates the statistical characteristics of the accumulated deviation. When the outer loop trigger condition is detected, a scheme space reconstruction subroutine is started. This subroutine adjusts the number of quantiles and the quantile selection strategy, regenerates the candidate scheme set, and replaces the original scheme pool.
[0161] Data interaction between modules is achieved through a shared memory area and message queue on the management node. The shared memory is divided into multiple independent areas, used to store resource status information, coupled field status parameters, candidate scheduling scheme sets, scheduling execution forms, and deviation classification records, respectively. The message queue is used to transmit event notifications, including new task arrival events, progress deviation trigger switching events, and quantum execution completion events. Modules collaborate in a loosely coupled manner, and the interfaces between modules use standardized data structure definitions to facilitate subsequent functional expansion and module replacement. The entire system's runtime cycle begins with resource status acquisition, proceeds through coupled field status parameter calculation, task decomposition, candidate scheme generation, main scheduling scheme selection, execution and monitoring, elastic switching to deviation learning and reconstruction, forming a complete closed-loop scheduling process. The total time of each scheduling cycle (from resource status acquisition to main scheduling scheme locking) does not exceed 50 milliseconds, far less than the 1-second scheduling cycle length, ensuring the real-time effectiveness of scheduling decisions. By continuously running as a daemon process on the management node, the system achieves unified scheduling and collaborative management of classical and quantum computing resources in the hyperconverged infrastructure.
Claims
1. A heterogeneous computing task scheduling method based on a hyper-converged infrastructure, characterized in that, The method includes: Acquire the current resource status information of the hyper-converged system, including the status of classical computing resources and quantum computing resources; Based on the current resource status information, the system coupling field state parameters at the current scheduling moment are calculated using a preset coupling field dynamic evolution model; Receive a computation task to be scheduled, and decompose the computation task to be scheduled into one or more classical executable units and one or more quantum executable units; For each quantum executable unit, an execution time probability distribution model is generated based on its task characteristic parameters, and a set of candidate scheduling schemes is generated based on multiple quantiles of the execution time probability distribution model. Each candidate scheduling scheme in the set of candidate scheduling schemes includes an execution time assumption of the quantum executable unit and a pre-arranged scheduling plan for each classical executable unit. Using the system coupling field state parameters as constraints, a primary scheduling scheme that satisfies the system optimization objective is selected from the candidate scheduling scheme set and executed. During execution, the actual execution progress of each quantum executable unit is monitored in real time. When the actual execution progress deviates from the execution time assumption on which the main scheduling scheme is based by more than a preset threshold, the system switches from the candidate scheduling scheme set to the target scheduling scheme that matches the current actual execution state of the quantum executable unit to continue execution. The actual execution time data of each quantum executable unit is obtained. Based on the deviation between the actual execution time data and the predicted value of the execution time probability distribution model, the parameters of the execution time probability distribution model are updated. The candidate scheduling scheme set is dynamically reconstructed based on the accumulated deviation data.
2. The method according to claim 1, characterized in that, The calculation of the system coupled field state parameters at the current scheduling moment using a preset coupled field dynamic evolution model includes: Obtain the state of classical computing resources and quantum computing resources at the current scheduling moment; A two-way coupled differential equation system is constructed between the classical computing resource state and the quantum computing resource state. The two-way coupled differential equation system is used to describe the mutual constraint relationship between the classical computing resource state and the quantum computing resource state. Using the classical computing resource state sequence and quantum computing resource state sequence within the historical scheduling cycle as fitting data, the coupling coefficient of the bidirectional coupled differential equation system is estimated. The classical computing resource state and quantum computing resource state at the current scheduling moment are used as the initial conditions of the two-way coupled differential equation system. The two-way coupled differential equation system is numerically integrated and solved within a preset time window to obtain the state evolution trajectory of the system coupling field within the preset time window. The first derivative vector of the state evolution trajectory at the current scheduling moment is extracted as the coupled field state parameter of the system.
3. The method according to claim 1, characterized in that, The step of generating an execution time probability distribution model based on its task characteristic parameters, and generating a set of candidate scheduling schemes based on multiple quantiles of the execution time probability distribution model, includes: Extract the task feature parameters of the quantum executable unit; Based on the task characteristic parameters, retrieve a set of matching historical execution records from the historical execution database; Based on the actual execution time data in the historical execution record set, the execution time probability distribution model is fitted and generated. N quantile values are extracted from the execution time probability distribution model according to a preset quantile selection strategy. Each quantile value corresponds to an execution time hypothesis, and N is an integer greater than or equal to 3. Using the N quantile values as N execution time assumptions, a corresponding pre-arrangement scheduling plan for classic executable units is generated for each execution time assumption. The pre-arrangement scheduling plan includes the start time offset and resource usage arrangement of each classic executable unit. Each execution time assumption is associated with its corresponding pre-arranged scheduling plan to generate N candidate scheduling schemes, which constitute the candidate scheduling scheme set.
4. The method according to claim 1, characterized in that, Switching from the candidate scheduling scheme set to the target scheduling scheme that matches the current actual execution state of the quantum executable unit to continue execution includes: The number of quantum gate operations completed by the quantum executable unit in the current execution cycle is collected in real time, and the actual execution progress percentage is calculated based on the number of completed quantum gate operations and the total number of quantum gate operations of the quantum executable unit. Obtain the expected progress curve corresponding to the main scheduling scheme, compare the actual execution progress percentage with the expected progress percentage at the same timestamp in the expected progress curve, and calculate the progress deviation value. When the absolute value of the progress deviation exceeds the preset deviation threshold, the matching degree of the execution time assumption of each candidate scheduling scheme is calculated with the actual execution time consumed by the quantum executable unit and the actual execution progress percentage to obtain the matching degree score of each candidate scheduling scheme. The candidate scheduling scheme with the highest matching score is selected as the target scheduling scheme. The current time of the quantum executable unit is taken as the new time zero point, and the remaining execution time in the execution time assumption of the candidate scheduling scheme is taken as the expected remaining execution time. The start time and resource occupation period of each classical executable unit are recalibrated.
5. The method according to claim 1, characterized in that, The step of updating the parameters of the execution time probability distribution model based on the deviation between the actual execution time data and the predicted value of the execution time probability distribution model, and dynamically reconstructing the candidate scheduling scheme set based on the accumulated deviation data, includes: Calculate the difference between the actual execution time data and the predicted value, generate a single deviation value, and classify and store it according to the task characteristic parameters; When the number of deviation samples in the same category reaches a preset sample size threshold, statistical analysis is performed on the deviation samples to generate deviation distribution statistical characteristics. The parameters of the execution time probability distribution model are updated using Bayesian method based on the statistical characteristics of the deviation distribution, and the execution time probability distribution model is regenerated based on the updated parameters. Extract the updated quantile values, replace the execution time assumptions in the candidate scheduling schemes, and regenerate the pre-arranged scheduling plan based on the replaced execution time assumptions; When the accumulated deviation data meets the outer loop triggering condition, the candidate scheduling scheme set is reconstructed in the scheme space. The outer loop triggering condition is that the mean deviation continuously drifts in one direction within a continuous window or the standard deviation of the deviation exceeds a preset upper limit. The scheme space reconstruction includes adjusting the number of candidate schemes, adjusting the distribution density of quantiles, or rematching the distribution type identifier. The reconstructed set of candidate scheduling schemes will be used as the candidate scheme pool for subsequent scheduling cycles.
6. The method according to claim 1, characterized in that, The step of selecting a primary scheduling scheme that satisfies the system optimization objective from the candidate scheduling scheme set, using the coupled field state parameters as constraints, includes: For each candidate scheduling scheme, a scheme feature vector is extracted. The scheme feature vector includes the quantum execution time assumption value of the candidate scheduling scheme, the start time offset sequence of each classical executable unit, and the resource occupation arrangement sequence. Using the first derivative vector in the coupled field state parameters of the system as the system evolution direction constraint, a comprehensive cost function containing a first cost component and a second cost component is constructed. The first cost component is used to measure the classical-quantum cooperative waiting cost, and the second cost component is used to measure the system perturbation cost. Based on the startup time offset sequence and resource occupancy arrangement sequence of each classic executable unit, the idle time distribution variance among each classic executable unit is calculated, and a third cost component is generated according to the idle time distribution variance. The third cost component is used to measure the degree of temporal continuity utilization of classic computing resources. The first, second, and third cost components are weighted and summed to generate the comprehensive cost value of each candidate scheduling scheme, wherein the weight coefficient of each cost component is adaptively adjusted according to the direction of the first derivative vector. The candidate scheduling scheme with the lowest overall cost is selected as the main scheduling scheme, and the start time offset and resource usage arrangement of each classic executable unit in the main scheduling scheme are locked.
7. The method according to claim 1, characterized in that, The step of decomposing the scheduled computation task into one or more classical executable units and one or more quantum executable units includes: The computation task to be scheduled is decoupled from its functional sub-modules, and multiple functional sub-modules and the data dependencies between them are extracted. A functional module dependency graph is constructed with functional sub-modules as nodes and data dependencies as directed edges. For each functional submodule in the functional module dependency graph, calculate its first estimated generation value on the classical computing side and its second estimated generation value on the quantum computing side. Calculate the difference between the first estimated cost value and the second estimated cost value to generate a quantum bias factor. Based on the sign and absolute value of the quantum bias factor, divide each functional sub-module into a classical bias sub-module, a quantum bias sub-module, and an uncertain sub-module. The uncertain sub-module is a functional sub-module whose absolute value of the quantum bias factor is less than a preset bias threshold. All quantum-oriented submodules are merged into an initial set of quantum executable units, and all classical-oriented submodules are merged into an initial set of classical executable units. The candidate execution orientation queue is determined according to the topological position of the uncertain submodule in the functional module dependency graph. The candidate execution orientation queue contains alternative schemes for the execution of the uncertain submodule on the classical side and the quantum side. By inputting the initial set of quantum executable units, the initial set of classical executable units, and the candidate execution tendency queue, a rapid deduction is performed to obtain the scheduling feasibility score corresponding to each decomposition scheme; Using the scheduling feasibility score as a feedback signal, the candidate execution tendency queue execution scheme is optimized. The uncertain sub-modules after the optimized execution tendency are assigned to the corresponding quantum executable unit set or classical executable unit set, and merged with the initial quantum executable unit set and the initial classical executable unit set to generate one or more classical executable units and one or more quantum executable units.
8. The method according to claim 1, characterized in that, When the computational task to be scheduled is decomposed into multiple quantum executable units, the step of selecting a main scheduling scheme that satisfies the system optimization objective from the candidate scheduling scheme set, using the coupled field state parameters as constraints, includes: Based on the execution time probability distribution model of any two quantum executable units, calculate the probability of execution window overlap between the two quantum executable units on the same quantum computing device; A quantum task interference graph is constructed with each quantum executable unit as a node and the overlap probability of the execution window as the edge weight. Quantum executable unit pairs with an overlap probability exceeding a preset interference threshold are extracted as interference constraint pairs, and a probabilistic mutual exclusion constraint set with a mutual exclusion strength coefficient is generated. The mutual exclusion strength coefficient is positively correlated with the overlap probability of the execution window. Extract the initialization module occupancy identifier sequence and measurement module occupancy identifier sequence required by each quantum executable unit, and construct the time-division occupancy demand vector of each quantum executable unit for the internal functional modules of the quantum computing device; The probabilistic mutual exclusion constraint set and the time-sharing occupancy demand vector are used as additional constraints on the quantum side, which together with the coupling field state parameters constitute a comprehensive constraint boundary. Within the comprehensive constraint boundary, the candidate scheduling scheme set is screened, wherein two quantum executable units with a mutual exclusion strength coefficient higher than the first strength threshold are prohibited from being scheduled to the same time window at the same time. During the execution of the main scheduling scheme, when the progress deviation of the first quantum executable unit causes its execution window to drift, the window drift signal is propagated along the quantum task interferogram to the second quantum executable unit that has an interference constraint pair with the first quantum executable unit, triggering the priority upgrade of the candidate scheme in the candidate scheduling scheme set of the second quantum executable unit that matches the drifted time window; When multiple quantum executable units share the same quantum computing device and the number of concurrent execution channels of the device is less than the number of quantum executable units to be executed, the execution order of each quantum executable unit is dynamically sorted according to the probabilistic mutual exclusion constraint set and the time-sharing occupancy demand vector. The dynamic sorting aims to minimize the weighted overlap probability sum in the quantum task interferogram, and after the sorting is completed, the execution time window of each quantum executable unit is allocated in sequence according to the sorting result.
9. The method according to claim 1, characterized in that, After dynamically reconstructing the candidate scheduling scheme set based on accumulated deviation data, the method further includes: Extract the first cumulative amount of positive deviation samples and the second cumulative amount of negative deviation samples from the cumulative deviation data, calculate the proportion of the first cumulative amount and the second cumulative amount in the cumulative deviation data respectively, and generate the deviation direction bias factor; The direction of coupling field adjustment is determined according to the deviation direction bias factor. When the deviation direction bias factor indicates that the cumulative proportion of positive deviation exceeds the first direction threshold, the first coupling coefficient of the second coupling equation is adjusted in the direction of enhancing response sensitivity. When the deviation direction bias factor indicates that the cumulative proportion of negative deviation exceeds the second direction threshold, the second coupling coefficient of the first coupling equation is adjusted in the direction of enhancing buffer capacity. When the deviation oscillation frequency of the accumulated deviation data exceeds the preset oscillation threshold, the damping coefficient corresponding to the classical computing resource state and the quantum computing resource state in the two-way coupled differential equation system is adjusted to suppress the high-frequency oscillation of the coupled field state parameters by increasing the damping coefficient. The adjusted bidirectional coupled differential equations are used as the update equations for the dynamic evolution model of the coupled field in the next scheduling cycle, and the adjusted bidirectional coupled differential equations are used to drive the generation and selection process of the candidate scheduling scheme set again.
10. A heterogeneous computing task scheduling system based on a hyperconverged infrastructure, used to execute the method described in any one of claims 1-9, characterized in that, include: The resource status acquisition module is configured to acquire the current resource status information of the hyper-converged system, including the status of classical computing resources and quantum computing resources. The coupling field calculation module is configured to calculate the system coupling field state parameters at the current scheduling moment based on the current resource state information and a preset coupling field dynamic evolution model. The task decomposition module is configured to receive a computation task to be scheduled and decompose the computation task to be scheduled into one or more classical executable units and one or more quantum executable units. The candidate scheme generation module is configured to generate an execution time probability distribution model for each quantum executable unit based on its task characteristic parameters, and generate a set of candidate scheduling schemes based on multiple quantiles of the execution time probability distribution model. Each candidate scheduling scheme in the set of candidate scheduling schemes includes an execution time assumption for the quantum executable unit and a pre-arranged scheduling plan for each corresponding classical executable unit. The main scheduling scheme selection module is configured to select and execute a main scheduling scheme that satisfies the system optimization objective from the candidate scheduling scheme set, using the coupled field state parameters as constraints. The elastic switching execution module is configured to monitor the actual execution progress of each quantum executable unit in real time during the execution process. When the actual execution progress deviates from the execution time assumption on which the main scheduling scheme is based by more than a preset threshold, it switches from the candidate scheduling scheme set to the matching target scheduling scheme to continue execution. The deviation learning and scheme reconstruction module is configured to acquire the actual execution time data of each quantum executable unit, update the parameters of the execution time probability distribution model based on the deviation between the actual execution time data and the predicted value of the execution time probability distribution model, and dynamically reconstruct the candidate scheduling scheme set based on the accumulated deviation data.
