Distributed constraint optimization solution method and system based on belief propagation

By constructing a pseudo-tree communication structure and belief propagation framework based on node contribution priority, and dynamically adjusting node states, the adaptability problem of resource scheduling in edge networks of the Decimation Max-Sum algorithm is solved, and optimal allocation of computing resources is achieved.

CN119356853BActive Publication Date: 2025-10-17CHONGQING UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411381359.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-30
Publication Date
2025-10-17
Estimated Expiration
2044-09-30

AI Technical Summary

Technical Problem

The existing Decimation Max-Sum algorithm relies on the initial variable selection order and strategy in edge network computing resource scheduling, and cannot adapt to dynamic environments, resulting in poor computing resource allocation. In particular, it is difficult to achieve optimal task allocation in scenarios with multiple user devices and changing network topology structures.

Method used

A pseudo-tree communication structure based on node contribution priority is constructed, combined with a distributed extraction framework of belief propagation. By iteratively adjusting node status, it dynamically adapts to environmental changes and reasonably allocates computing resources.

Benefits of technology

It achieves optimal allocation of computing resources in dynamic environments, reduces redundant calculations, and improves the efficiency and accuracy of computing resource scheduling.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119356853B_ABST
    Figure CN119356853B_ABST
Patent Text Reader

Abstract

The application provides a belief propagation-based distributed constraint optimization solving method and system, and is applied to scheduling of computing resources, and the method comprises the following steps: based on computing task information of each user equipment and resource conditions of each edge server, a pseudo-tree communication structure based on node contribution priority is constructed; and based on a distributed decimation framework of belief propagation, an optimal allocation scheme of each computing task is obtained according to the pseudo-tree communication structure; according to the method, the node can determine the direction of belief propagation according to the state of the node, the repeated calculation of belief propagation on the loop factor graph is relieved, the state of the node is changed in an iterative mode, the dynamic change of the environment can be adapted, the computing resources can be reasonably allocated, the optimal allocation of tasks is realized, and therefore the problem that the existing Decimation Max-Sum method cannot adapt to a dynamic environment and cannot obtain an optimal allocation scheme of tasks when the computing resource scheduling of the edge network is implemented by relying on an initial variable selection order and strategy is solved from the root.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the field of computer, and particularly relates to a distributed constraint optimization solving method and system based on belief propagation, which is used for scheduling of computing resources. BACKGROUND

[0002] Multi-Agent Systems (MAS) is a system composed of multiple independent agents, which can autonomously make decisions, perform actions, and interact with the environment and other agents. Each agent has its own goals, knowledge and capabilities, and can achieve individual or common goals through communication, cooperation or competition. Distributed Constraint Optimization Problems (DCOP) is an important abstraction of multi-agent system collaboration problems. In DCOP, each agent holds a part of the variables, each variable has its own value domain, and these variables are subject to a set of constraints, which can be represented as constraint cost functions. The goal of the agents is to assign a suitable value to all variables to maximize or minimize the global cost function.

[0003] Among the many algorithms for solving DCOP problems, belief propagation-based approximate reasoning algorithms are an important class of incomplete algorithms. Max-sum algorithm is the first approximate reasoning algorithm that applies belief propagation to solve DCOP problems. Max-sum algorithm is based on generalized distributive law (GDL) and achieves marginalization of global utility function by propagating and accumulating beliefs on factor graphs. Decimation Max-Sum is a variant of Max-Sum algorithm that simplifies the problem by recursively removing or fixing some variables. Although Decimation Max-Sum can effectively reduce computational complexity and speed up convergence, it also has some drawbacks and limitations. Decimation Max-Sum algorithm is very sensitive to the initial selected variable fixing order and strategy, and it is also difficult to adapt to dynamic environments (such as scenarios where variables and constraints change over time). In the computation resource scheduling of edge network, user devices (such as smart phones, Internet of Things devices, etc.) usually rely on edge servers to process computing tasks. The goal of edge computing is to reduce computing delay and improve system computing efficiency as much as possible through distributed manner. Each user device and edge server can be regarded as an agent, and the goal of the system is to achieve optimal allocation of tasks through Decimation Max-Sum algorithm. However, the standard Decimation Max-Sum may choose edge servers for some devices too early, which may limit subsequent scheduling; in addition, once the allocation is fixed, it is difficult to adapt to changes in network topology or task requirements.

[0004] Therefore, how to solve the problem that Decimation Max-Sum algorithm depends on the initial variable selection order and strategy when implementing the computation resource scheduling of edge network, cannot adapt to dynamic environments, and for the computation resource scheduling of edge network, in the scenario where there are multiple user devices and the network topology structure may change, how the system allocates computing resources reasonably to achieve optimal allocation of tasks based on the task requirements of each user device and the resource conditions of edge servers, is a problem to be solved in the field. SUMMARY

[0005] The application aims at the defects of the prior art, and provides a belief propagation-based distributed constraint optimization solving method and system. The belief propagation-based distributed constraint optimization solving method of the application is based on the computing task information of each user equipment and the resource conditions of each edge server, constructs a pseudo-tree communication structure based on node contribution priority, and obtains an optimal allocation scheme of each computing task based on a belief propagation-based distributed extraction framework according to the pseudo-tree communication structure.

[0006] To achieve the above object, the application adopts the following technical scheme:

[0007] The application provides a belief propagation-based distributed constraint optimization solving method applied to the scheduling of computing resources, which comprises the following steps:

[0008] S1, obtaining the computing task information of each user equipment and the resource conditions of each edge server;

[0009] S2, based on the computing task information of each user equipment and the resource conditions of each edge server, constructing a pseudo-tree communication structure based on node contribution priority; the specific steps are as follows:

[0010] The node contribution degree of the user equipment a i to the controlled computing task t i is c i , c i is calculated by the edge server through a load function, and the specific formula is as follows:

[0011]

[0012] Wherein |D i | represents the value range size of the task state, N i is the neighbor server set of a i , T k \t i represents the task set except t i , and F k (d i ) represents the state value d i of the associated task t i in the load function F k .

[0013] Based on the node contribution degree, a pseudo-tree communication structure is constructed; specifically, in the process of constructing the pseudo-tree, each node needs to calculate its own node contribution degree and broadcast it to the neighbor nodes for sorting, and the node with greater node contribution degree is closer to the root node in the finally formed pseudo-tree;

[0014] S3, based on the belief propagation-based distributed decimation framework, an allocation scheme of each computing task is obtained according to the pseudo-tree communication structure;

[0015] In the belief propagation-based distributed decimation framework, there are three states of variable nodes, namely running state run, decimation state decimation and termination state stop; in the framework, there are eight types of messages, namely query message QueryMessage and response message ResponseMessage in the belief propagation stage; in the decimation stage, Ask message sent by the candidate node to the parent node, response message sent by the parent node to the candidate node, wakeup message sent by the decimation node to the pseudo parent node, accept or reject message returned by the pseudo parent node, and decimation message sent by the decimation node to the child node; in the stop stage, the stop message broadcasted by the node to the upper layer node;

[0016] In the framework, each round of iteration will experience three stages, and the specific process is as follows:

[0017] S31, belief propagation stage;

[0018] In the belief propagation stage, there are three sub-stages: query stage, response stage and decision stage;

[0019] The query stage: QueryMessage message is transmitted on the connected subgraph composed of nodes in the same state;

[0020] The response stage: ResponseMessage message is transmitted on the connected subgraph composed of nodes in the same state;

[0021] The decision phase: the nodes in the decimation state: accumulate the ResponseMessage messages of all neighbors in the decimation state, select the assignment that can make the marginal belief optimal as the assignment of this round, and send the assignment to all pseudo parent nodes in the run state; the nodes in the run state: accumulate the ResponseMessage messages of all neighbors in the run state and the value messages of all AC nodes in the decimation state, select the assignment that can make the marginal belief optimal as the assignment of this round, and the formula is as follows:

[0022]

[0023] where S k represents the edge server set in which all associated user equipment nodes are in the run state; S j represents a i user equipment and the edge server set between the pseudo parent user equipment;

[0024] S32, the decimation phase;

[0025] The decimation phase determines the nodes to be converted from the run state to the decimation state, including determining candidate nodes, sending Ask messages, receiving response messages, and sending decimation messages;

[0026] S33, the stop phase;

[0027] In the stop phase, the node determines the final assignment of itself, obtains the allocation scheme of each computing task, and sends a stop message to all pseudo parent nodes and parent nodes; specifically, the node has two cases to enter the stop phase, one is that the node is a leaf node and its state is decimation, and the other is that the node is a non-leaf node and has received stop messages from all child nodes and pseudo child nodes;

[0028] Finally, it is judged whether the convergence or termination condition is met, if the condition is met, the process is ended, and if the condition is not met, the process returns to the belief propagation phase to start the next round of iteration.

[0029] The query message QueryMessage is specifically: a query message sent by a user equipment to an edge server in a belief propagation process, containing the belief value of the user equipment, and the specific calculation formula is as follows:

[0030]

[0031] where, α ij is a regularization factor to avoid unlimited increase of messages in the factor graph, S i \sj representing all neighbor servers of the user device a j except the target server s i , representing a message sent by the server to the user device.

[0032] The response message ResponseMessage specifically refers to a response message sent by an edge server to a user device in a belief propagation process, and contains a load corresponding to each value of the target user device task state under the current belief and local load function. The specific calculation formula is as follows:

[0033]

[0034] Wherein, A j \a i is a set of neighbor user devices of the edge server s i except a j .

[0035] The Ask message specifically refers to an Ask message sent by a candidate node to a parent node in a decimation phase to inquire whether the parent node can enter a decimation state; the Ask message has two types, if all pseudo-parent nodes of the candidate node are in a run state, the Ask message contains a node contribution degree c i of the current node, if any pseudo-parent node of the candidate node is in a decimation state, the Ask message contains a sum of node contribution degrees of the pseudo-parent nodes in the decimation state minus the node contribution degree of the current node, i.e.

[0036] The response message is sent by the parent node to the child node, if the child node can enter the decimation state, the message is True, otherwise it is False; when the candidate node receives the response message True sent by the parent node, and the candidate node has a pseudo-parent node in the decimation state, the candidate node sends a wakeup message to all pseudo-parent nodes in the decimation state; when the node receives the wakeup message, it is judged whether the Ask message of the child node is received, if yes, a reject message is returned to the message sender, otherwise an accept message is returned.

[0037] The decimation message is used for a node to broadcast its decimation state. If a node receives both the wakeup message and the decimation message from the same node, the node will change its state to run. The stop message contains the node assignment of the message sender.

[0038] The decimation phase includes:

[0039] S321, determining candidate nodes

[0040] Each node determines whether it is a candidate node according to its own state and the state of its neighbor nodes. Specifically, the candidate node must satisfy the following conditions:

[0041]

[0042] Where s i represents the state of node x i , and s parent represents the state of the parent node of x i .

[0043] S322, sending Ask messages

[0044] After determining the candidate nodes, each candidate node further determines the type and content of the Ask message to be sent to the parent node according to the state of the AP and the AC, where the AP represents the pseudo parent node device and the parent node device of the user equipment in the pseudo tree, and the AC represents the child node device and the pseudo child node device of the user equipment in the pseudo tree. If all the AP nodes of the candidate node except the parent node are in the run state, the candidate node sends Ask(1, c i ) to the parent node, where 1 is the type of the Ask message, and c i is the node contribution degree of the candidate node. If the candidate node has an AP node in the decimation state, the candidate node sends Ask(2, c ) to the parent node, where 2 is the type of the Ask message, and c is the sum of the node contribution degrees of all the pseudo parent nodes of the candidate node in the decimation state.

[0045] S323, receiving response messages

[0046] After receiving all the Ask messages of the child nodes in the run state, the parent node selects the node with the largest c i as the winning node, and if there is no Ask message with type 1, the parent node selects the node with the largest c The smallest node is the winning node; then, the parent node sends a response message to all child nodes that sent Ask messages, and the winning node receives a True response message and other nodes receive a False response message;

[0047] If a node in the decimation state receives a True response message, the node sends a wakeup message to all pseudo-parent nodes in the decimation state, and the pseudo-parent nodes check whether the Ask message is received in the current round; if the Ask message is received, the pseudo-parent nodes send a reject message to the node, indicating that the state transition is rejected; if the Ask message is not received, the pseudo-parent nodes send an accept message, indicating that the state transition is accepted, and the pseudo-parent nodes change the state from the decimation state to the run state.

[0048] S324, a decimation message is sent.

[0049] The node receiving the accept message changes the state to the decimation state and sends a decimation message to all neighbor nodes, and the neighbor nodes store the state information of the node after receiving the decimation message.

[0050] The application further provides a distributed constraint optimization solving method based on belief propagation, and the method is applied to scheduling of computing resources.

[0051] S1, a node contribution degree of a computing task controlled by a user equipment is calculated.

[0052] S2, a pseudo-tree communication structure based on node contribution degree priority is constructed based on the node contribution degree.

[0053] S3, a belief propagation stage is entered based on the pseudo-tree communication structure; the belief propagation stage includes three sub-stages: a query stage, a response stage and a decision stage; in the query stage, a query message is sent to a neighbor server; after the belief propagation stage, a value of each node in the current round and a response message used in the next round of iteration are obtained.

[0054] S4, a decimation stage is entered, and it is judged whether a decimation condition is met; if yes, an Ask message is sent; specifically, in the decimation stage, all parent nodes of nodes in the decimation state are called candidate nodes, and the candidate nodes send Ask messages to the parent nodes in the stage to inquire whether the parent nodes can enter the decimation state.

[0055] S5. The parent node receives the Ask message and determines the winning node. The parent node sends a response message to all child nodes that sent the Ask message.

[0056] S6. Determine whether the response message is True. If so, proceed to step S7; otherwise, return to step S3. The response message received by the winning node is True, while that received by other nodes is False.

[0057] S7. Determine whether any pseudo-parent node is in the decimation state. If so, the candidate node sends a wakeup message to all pseudo-parent nodes in the decimation state. Otherwise, return to step S3.

[0058] S8. The pseudo-parent node receives the wakeup message and determines whether it has received the Ask message from the child node. If so, it returns a reject message to the message sender; otherwise, it returns an accept message.

[0059] S9, the node receives the message and determines whether the received message is the accept message. If so, the node changes its state to decimation and sends decimation messages to all neighboring nodes. Otherwise, it returns to step S3;

[0060] S10. Determine whether the stop condition is met. If so, the process ends. If not, the process returns to the belief propagation phase in step S3 to start the next iteration. In the stop phase, the node determines its final value, obtains the allocation plan for each computing task, and sends a stop message to all pseudo-parent nodes and parent nodes.

[0061] The present invention also proposes a distributed constraint optimization solution system based on belief propagation for scheduling computing resources, characterized in that the distributed constraint optimization solution system executes the distributed constraint optimization solution method based on belief propagation, including: a data acquisition module, a pseudo-tree communication structure construction module and a distributed constraint optimization solution module;

[0062] The data acquisition module acquires computing task information of each user device and resource status of each edge server;

[0063] The pseudo-tree communication structure construction module constructs a pseudo-tree communication structure based on node contribution priority based on the computing task information of each user device and the resource status of each edge server;

[0064] The distributed constraint optimization solving module obtains an allocation scheme for each computing task according to the pseudo-tree communication structure and based on a distributed extraction framework of belief propagation.

[0065] The application further provides a computer device, which comprises a memory and a processor, the memory stores a computer program, and the processor implements the method described above when executing the computer program.

[0066] Compared with the prior art, the following beneficial effects are achieved:

[0067] The distributed constraint optimization solving method based on belief propagation provided by the application constructs a pseudo-tree communication structure based on node contribution priority according to the computing task information of each user equipment and the resource conditions of each edge server, and obtains an optimal allocation scheme of each computing task based on a distributed extraction framework of belief propagation according to the pseudo-tree communication structure.

[0068] The distributed constraint optimization solving method based on belief propagation provided by the application constructs a pseudo-tree communication structure based on node contribution priority according to the computing task information of each user equipment and the resource conditions of each edge server, and dynamically adjusts the states of part of nodes in the iteration process of belief propagation, so as to form connected subgraphs in different states; the effectiveness of the extraction operation is ensured through the decimation stage; and the convergence process is accelerated by fixing the values of nodes from leaf nodes to upper nodes through the stop stage, so that the optimal allocation scheme of tasks can be more accurately and efficiently obtained. BRIEF DESCRIPTION OF DRAWINGS

[0069] In order to more clearly illustrate the technical solutions of the embodiments of the application, the following will briefly introduce the drawings needed in the embodiment description. Obviously, the drawings in the following description are some embodiments of the application, and other drawings can also be obtained by those skilled in the art without creative labor.

[0070] Figure 1 The distributed constraint optimization solving method based on belief propagation provided by the embodiment of the application is shown in the schematic diagram.

[0071] Figure 2 The distributed constraint optimization solving method based on belief propagation provided by the embodiment of the application is shown in the flowchart.

[0072] Figure 3 The edge network instance provided by the embodiment of the application is shown in the schematic diagram.

[0073] Figure 4 The pseudo-tree communication structure provided by the embodiment of the application is shown in the schematic diagram.

[0074] Figure 5 A schematic diagram of a belief propagation-based distributed constraint optimization solution system is provided for an embodiment of the present application. DETAILED DESCRIPTION

[0075] The technical solutions in the embodiments of the present application will be clearly and completely described with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are some but not all of the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art without creative work fall within the protection scope of the present application.

[0076] It should be understood that, when used in the specification and the appended claims, the terms "comprise" and "include" indicate the presence of described features, integers, steps, operations, elements, and / or components, but do not exclude one or more other features, integers, steps, operations, components, and / or groups thereof.

[0077] The present application will be further described below with reference to the drawings and specific embodiments, but is not limited to the present application. It should be further understood that the term "and / or" used in the specification and the appended claims indicates any combination of one or more of the associated listed items and all possible combinations, and includes these combinations.

[0078] Character descriptions are shown in the following table:

[0079]

[0080] The present application proposes a belief propagation-based distributed constraint optimization solution method applied to the scheduling of computing resources. As shown in the figure, the belief propagation-based distributed constraint optimization solution method comprises the following steps S1 to S3. Figure 1

[0081] The present application proposes a belief propagation-based distributed constraint optimization solution method applied to the scheduling of computing resources, comprising the following steps:

[0082] S1, obtaining computing task information of each user equipment and resource conditions of each edge server.

[0083] S2, based on the computing task information of each user equipment and the resource conditions of each edge server, a pseudo-tree communication structure based on node contribution priority is constructed; the specific steps are as follows:

[0084] User equipment a i Controlled computing task t i Node contribution degree c i , c i ​The edge server calculates by a load function, and the specific formula is as follows:

[0085]

[0086] Wherein the node is a user equipment, |D i | represents the value range size of the task state, N i is a i neighbor server set of the node, T k \t i represents a task set except t i , F k (d i ) represents the associated task t k in the load function F i , and the state value of d i ;

[0087] Based on the node contribution degree, a pseudo-tree communication structure is constructed; specifically, in the process of constructing the pseudo-tree, each node needs to calculate its own node contribution degree and broadcast it to the neighbor nodes for sorting, and the node with greater node contribution degree is closer to the root node in the finally formed pseudo-tree.

[0088] By constructing the pseudo-tree based on the node contribution degree priority, a basis for guiding the operation of the extraction framework is provided, and the node contribution degree reflects the average influence degree of the node on the final cost, and the higher the average influence degree, the later the value should be determined in the iteration process.

[0089] S3, according to the pseudo-tree communication structure, a distributed extraction framework based on belief propagation is obtained to obtain the allocation scheme of each computing task.

[0090] In the distributed extraction framework based on belief propagation, the variable node has three states, which are running state run, decimation state decimation and termination state stop; in the framework, there are eight types of messages, which are query message QueryMessage and response message ResponseMessage in the belief propagation stage; in the decimation stage, the Ask message sent by the candidate node to the parent node, the response message sent by the parent node to the candidate node, the wakeup message sent by the decimation node to the pseudo parent node, the accept or reject message returned by the pseudo parent node, and the decimation message sent by the decimation node to the child node; in the stop stage, the stop message broadcasted by the node to the upper layer node;

[0091] Further, the query message QueryMessage is specifically: in the belief propagation process, the query message sent by the user equipment to the edge server, containing the belief value of the user equipment, and the specific calculation formula is as follows:

[0092]

[0093] Wherein, α ij is a regularization factor to avoid unlimited increase of the message in the factor graph, S i \s j represents all neighbor servers of the user equipment a j except the target server s i . represents the message sent by the server to the user equipment.

[0094] The response message ResponseMessage is specifically: in the belief propagation process, the response message sent by the edge server to the user equipment, containing the load corresponding to each value of the target user equipment task state under the current belief and local load function. The specific calculation formula is as follows:

[0095]

[0096] Wherein, A j \a i is the neighbor user equipment set of the edge server s i except a j .

[0097] The Ask message is specifically: in the decimation phase, all nodes whose parent nodes are in the decimation state are called candidate nodes, and the candidate nodes send Ask messages to the parent nodes in this phase to inquire whether the parent nodes can enter the decimation state; Ask message has two types, if all pseudo parent nodes of the candidate node are in the run state, the Ask message contains the node contribution degree c i of the current node, if any pseudo parent node state of the candidate node is decimation, the Ask message contains the sum of the node contribution degrees of the pseudo parent nodes in the decimation state minus the node contribution degree of the current node, that is

[0098] The response message is sent by the parent node to the child node, if the child node can enter the decimation state, the message is True, otherwise it is False.

[0099] The wakeup message: when the candidate node receives the response message sent by the parent node as True, and the candidate node has a pseudo-parent node in the decimation state, the candidate node sends the wakeup message to all pseudo-parent nodes in the decimation state.

[0100] The accept or reject message: when the node receives the wakeup message, it is judged whether the Ask message of the child node is received, if the Ask message is received, the reject message is returned to the message sender, otherwise the accept message is returned.

[0101] The decimation message is used for the node to broadcast its decimation state, and if a node receives the wakeup message and the decimation message of the same node, the node will change its state to run.

[0102] The stop message contains the node assignment of the message sender.

[0103] In the framework, each round of iteration will undergo three stages, and the specific process is as follows:

[0104] S31, belief propagation stage;

[0105] In the belief propagation stage, there are three sub-stages: query stage, response stage and decision stage.

[0106] The query stage: the QueryMessage message is transmitted on the connected subgraph composed of nodes in the same state;

[0107] The response stage: the ResponseMessage message is transmitted on the connected subgraph composed of nodes in the same state;

[0108] The decision stage: the nodes in the decimation state: accumulate the ResponseMessage messages of all neighbors in the decimation state, select the assignment that can make the marginal belief optimal as the assignment of this round, and send the assignment to all pseudo-parent nodes in the run state; the nodes in the run state: accumulate the ResponseMessage messages of all neighbors in the run state and the value messages of all AC nodes in the decimation state, select the assignment that can make the marginal belief optimal as the assignment of this round, and the formula is as follows:

[0109]

[0110] Where S k represents the edge server set in which all associated user equipment nodes are in the run state; S jrepresents a i a set of edge servers between the user device and the pseudo parent user device;

[0111] S32, decimation phase;

[0112] The decimation phase determines the nodes to be transferred from the run state to the decimation state, including determining candidate nodes, sending Ask messages, receiving response messages, and sending decimation messages;

[0113] S321, determining candidate nodes

[0114] Each node determines whether it is a candidate node according to the state of itself and the neighbor nodes, specifically, the candidate node must satisfy the following conditions:

[0115]

[0116] Where s i represents the state of node x i , s parent represents the state of the parent node of x i ;

[0117] S322, sending Ask messages

[0118] After determining the candidate nodes, each candidate node will further determine the type and content of the Ask message to be sent to the parent node according to the state of the AP and the AC, wherein the AP represents the pseudo parent node device and the parent node device of the user device in the pseudo tree, and the AC represents the child node device and the pseudo child node device of the user device in the pseudo tree; if all AP nodes of the candidate node except the parent node are in the run state, the candidate node sends Ask(1, c i ) to the parent node, wherein 1 is the type of the Ask message, and c i is the node contribution degree of the candidate node; if the candidate node has AP nodes in the decimation state, the candidate node sends Ask(2, c ) to the parent node, wherein 2 is the type of the Ask message, and c is the sum of the node contribution degrees of all pseudo parent nodes of the candidate node in the decimation state;

[0119] S323, receiving response messages;

[0120] After receiving all Ask messages of the child nodes in the run state, the parent node will select the node with the largest c i as the winning node, and if there is no Ask message type 1, it will select the type 2 and c The smallest node is the winning node; then, the parent node sends a response message to all child nodes that send the Ask message, and the winning node receives a True response message and other nodes receive a False response message;

[0121] If a node in the decimation state receives True, the node sends a wakeup message to all pseudo-parent nodes in the decimation state, and the pseudo-parent node checks whether the Ask message is received in the current round; if the Ask message is received, the pseudo-parent node sends a reject message to the node, indicating that the state transition is rejected; if not, the pseudo-parent node sends an accept message, indicating that the state transition is accepted, and the state of the pseudo-parent node is changed from decimation to run;

[0122] S324, a decimation message is sent;

[0123] The node receiving the accept message changes the state of the node to decimation, and sends a decimation message to all neighbor nodes; after receiving the decimation message, the neighbor node stores the state information of the node, so as to use the state information in the belief propagation process;

[0124] S33, a stop phase;

[0125] In the stop phase, the node determines the final assignment of the value of the node, obtains the allocation scheme of each computing task, and sends a stop message to all pseudo-parent nodes and parent nodes; specifically, the node has two conditions to enter the stop phase, one is that the node is a leaf node and the state of the node is decimation, and the other is that the node is a non-leaf node and receives stop messages from all child nodes and pseudo-child nodes;

[0126] Finally, it is judged whether the convergence or termination condition is met; if the condition is met, the process is ended; if the condition is not met, the process returns to the belief propagation phase to start the next iteration.

[0127] The convergence or termination condition is that the preset maximum iteration number is reached, or all nodes are in the stop state.

[0128] The application further provides a distributed constraint optimization solving method based on belief propagation, which is applied to the scheduling of computing resources, such as Figure 2 As shown in the figure, the method comprises the following steps:

[0129] S1, the node contribution degree of a computing task controlled by a user equipment is calculated;

[0130] S2, a pseudo-tree communication structure based on node contribution degree priority is constructed based on the node contribution degree.

[0131] S3, entering a belief propagation phase based on the pseudo-tree communication structure; the belief propagation phase includes three sub-phases: a query phase, a response phase and a decision phase; wherein a query message is sent to a neighbor server in the query phase; after the belief propagation phase, an assignment of each node in the current round and a response message used in the next round of iteration are obtained;

[0132] S4, entering a decimation phase, and determining whether a decimation condition is met, and if so, sending an Ask message; specifically, in the decimation phase, all parent nodes of a node in a decimation state are referred to as candidate nodes, and the candidate nodes send Ask messages to the parent nodes in the phase to inquire whether the parent nodes can enter the decimation state;

[0133] S5, the parent nodes receive the Ask messages, determine a winning node, and the parent nodes send response messages to all child nodes that send the Ask messages;

[0134] S6, determining whether the response message is True, and if so, entering step S7, otherwise returning to step S3; wherein the response message received by the winning node is True, and the response message received by other nodes is False;

[0135] S7, determining whether a pseudo-parent node is in a decimation state, and if so, the candidate node sends a wakeup message to all pseudo-parent nodes in the decimation state, otherwise returning to step S3;

[0136] S8, the pseudo-parent nodes receive the wakeup messages, determine whether an Ask message is received from a child node, and if so, return a reject message to the message sender, otherwise return an accept message;

[0137] S9, the nodes receive the messages, determine whether the received message is the accept message, and if so, the state of the node is changed to the decimation state, and a decimation message is sent to all neighbor nodes, otherwise returning to step S3;

[0138] S10, determining whether a stop condition is met, and if so, ending, otherwise returning to the belief propagation phase of step S3 to start the next round of iteration; in the stop phase, a final assignment of the node is determined, a distribution scheme of each calculation task is obtained, and a stop message is sent to all pseudo-parent nodes and parent nodes.

[0139] The belief propagation-based distributed constraint optimization solving method provided by the application constructs a pseudo-tree communication structure based on node contribution priority based on the computing task information of each user equipment and the resource conditions of each edge server; and the best allocation scheme of each computing task is obtained based on the belief propagation-based distributed extraction framework according to the pseudo-tree communication structure.

[0140] The belief propagation-based distributed constraint optimization solving method provided by the application constructs a pseudo-tree communication structure based on node contribution priority based on the computing task information of each user equipment and the resource conditions of each edge server; and the best allocation scheme of each computing task is obtained based on the belief propagation-based distributed extraction framework according to the pseudo-tree communication structure.

[0141] In a specific implementation, under an edge network instance as shown in FIG. Figure 3 the steps include:

[0142] 1. First, a pseudo-tree communication structure is constructed based on the size of the node contribution, taking user equipment a4 as an example, the node contribution value of a4 is c4=8. Similarly, the contribution degrees of other nodes can be calculated as c1=6, c2=6.5, and c3=8, and according to the size of the node contribution, a pseudo-tree communication structure as shown in FIG. Figure 4 is constructed, wherein the dashed line represents a pseudo-edge, and the solid line represents a tree edge.

[0143] 2. Then, belief propagation is run, taking a3 as an example, in the query phase, a3 sends a query message to its neighbor servers s1, s2, and s4. Since it is the first round of iteration, the query message is initialized to all zeros.

[0144] 3. In the response phase, s1, s2, and s4 calculate the response message through the formula and send the response message to a3.

[0145] 4. In the decision phase, after a3 receives the response message, the response message is accumulated, and the assignment that can minimize the belief is selected as the assignment of the current round.

[0146] 5、decimation stage, at this time, since a3 is the root node, the decimation operation can be performed, a3 has no parent node, the Ask message and the response message process are skipped, and the state of a3 is directly converted to decimation. Broadcast the state of a3 to the neighbor nodes.

[0147] 6、stop stage, if the stop condition is met at this time, the variable node will perform the stop operation, and broadcast the value to the upper node.

[0148] 7、determine whether the termination cycle condition is met, if the condition is met, the loop ends, otherwise, return to step 2 and continue to execute.

[0149] Figure 5 It is a kind of distributed constraint optimization solving system based on belief propagation provided by the embodiment of the application. As shown in Figure 5 The distributed constraint optimization solving system based on belief propagation includes a data acquisition module, a pseudo-tree communication structure construction module and a distributed constraint optimization solving module.

[0150] The data acquisition module acquires the computing task information of each user equipment and the resource situation of each edge server.

[0151] The pseudo-tree communication structure construction module constructs the pseudo-tree communication structure based on node contribution priority based on the computing task information of each user equipment and the resource situation of each edge server.

[0152] The distributed constraint optimization solving module obtains the allocation scheme of each computing task based on the pseudo-tree communication structure and the distributed extraction framework based on belief propagation.

[0153] The above-mentioned distributed constraint optimization solving system based on belief propagation can be realized in the form of a computer program, which can run on a computer device.

[0154] The computer device includes a processor, a memory and a network interface connected through a system bus, wherein the memory can include a non-volatile storage medium and an internal memory.

[0155] The non-volatile storage medium can store an operating system and a computer program. The computer program includes program instructions, which, when executed, can make the processor execute a distributed constraint optimization solving method based on belief propagation.

[0156] The processor is used to provide computing and control capabilities to support the operation of the entire computer device.

[0157] The memory provides an environment for running a computer program in a nonvolatile storage medium, and the computer program is executed by the processor to enable the processor to perform a belief propagation based distributed constraint optimization solving method.

[0158] The network interface is used for network communication with other devices. Those skilled in the art can understand that the above computer device structure is only part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. A specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different component arrangement.

[0159] The processor is configured to run a computer program stored in the memory, and the computer program implements the belief propagation based distributed constraint optimization solving method of embodiment one.

[0160] It should be understood that in the embodiments of the present application, the processor can be a central processing unit (CPU), and the processor can also be other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor.

[0161] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiments can be completed by a computer program instructing related hardware. The computer program includes program instructions, and the computer program can be stored in a storage medium, which is a computer readable storage medium. The program instructions are executed by at least one processor in the computer system to implement the process steps of the above-mentioned embodiments.

[0162] The present application also provides a storage medium. The storage medium can be a computer readable storage medium. The storage medium stores a computer program, wherein the computer program is executed by the processor to enable the processor to perform the belief propagation based distributed constraint optimization solving method of embodiment one.

[0163] The storage medium can be a U disk, a mobile hard disk, a read-only memory (ROM), a magnetic disk or an optical disk, and various computer readable storage media that can store program codes.

[0164] Those skilled in the art can understand that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be realized in electronic hardware, computer software or a combination of both. In order to clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been described in the above description in a general manner. Whether the functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. A person skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0165] In several embodiments provided by the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of each unit is only a logical function division, and actual implementation can have another division manner. For example, a plurality of units or components can be combined or integrated into another system, or some features can be ignored or not executed.

[0166] The steps in the method embodiments of the present application can be sequentially adjusted, combined and deleted according to actual needs. The units in the device embodiments of the present application can be combined, divided and deleted according to actual needs. In addition, each functional unit in each embodiment of the present application can be integrated in one processing unit, or each unit can exist physically, or two or more units can be integrated in one unit.

[0167] The integrated unit, if realized in the form of a software functional unit and sold or used as an independent product, can be stored in a storage medium. Based on such understanding, the technical solutions of the present application essentially or the parts that make contributions to the prior art, or all or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and includes a plurality of instructions for causing a computer device (which can be a personal computer, a terminal or a network device, etc.) to execute all or part of the steps of the methods described in each embodiment of the present application.

[0168] Note that the above is only the preferred embodiment of the present application and the technical principle applied. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and those skilled in the art can make various obvious changes, re-adjustments and substitutions without departing from the scope of the present application. Therefore, although the present application has been described in more detail through the above embodiments, the present application is not limited to the above embodiments, and can include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the appended claims.

Claims

1. A distributed constraint optimization solution method based on belief propagation, applied to the scheduling of computing resources, characterized by: Including steps: S1. Obtain computing task information of each user device and resource status of each edge server; S2. Based on the computing task information of each user device and the resource status of each edge server, a pseudo-tree communication structure based on node contribution priority is constructed; the specific steps are: User equipment a i Controlled computing task t i The node contribution is c i , c i The edge server calculates the load function using the following formula: Wherein, node represents user equipment; |D i |Represents the value range size of the task status, N i is a i The set of neighbor servers, T k \t i Indicates the difference between t i The external task set, F k (d i ) represents the load function F k The associated task t i The status value is d i ; Based on the node contribution, a pseudo-tree communication structure is constructed. Specifically, in the process of constructing the pseudo-tree, each node needs to calculate its own node contribution and broadcast it to neighboring nodes for sorting. The node with a greater node contribution is closer to the root node in the final pseudo-tree. S3. Obtaining an allocation plan for each computing task based on the pseudo-tree communication structure and a distributed extraction framework based on belief propagation; In the distributed extraction framework based on belief propagation, variable nodes have three states, namely, run state, decimation state, and stop state; in the framework, there are eight types of messages transmitted, namely, query message QueryMessage and response message ResponseMessage in the belief propagation phase; in the decimation phase, the Ask message sent by the candidate node to the parent node, the response message sent by the parent node to the candidate node, the wakeup message sent by the decimation node to the pseudo-parent node, the accept or reject message returned by the pseudo-parent node, and the decimation message sent by the decimation node to the child node; in the stop phase, the stop message broadcast by the node to the upper-level node; In the framework described above, each iteration goes through three phases, as follows: S31, belief dissemination stage; The belief propagation stage includes three sub-stages: query stage, response stage and decision stage; The query phase: transmitting QueryMessage messages on the connected subgraph composed of nodes in the same state; In the response phase, the ResponseMessage message is transmitted on the connected subgraph composed of nodes in the same state; In the decision phase, nodes in the decimation state accumulate the ResponseMessage messages of all neighbors in the decimation state, select the assignment that optimizes the marginal belief as the assignment for this round, and send the assignment to all pseudo-parent nodes in the run state. Nodes in the run state accumulate the ResponseMessage messages of all neighbors in the run state and the value messages of all AC nodes in the decimation state, and select the assignment that optimizes the marginal belief as the assignment for this round. The formula is as follows: Among them S k Indicates the set of edge servers whose associated user device nodes are in the run state; S j Indicates a i a set of edge servers between the user device and the pseudo-parent user device; Indicates the message sent by the server to the user device; S32, decimation stage; The decimation phase determines the nodes that need to transition from the run state to the decimation state, including determining candidate nodes, sending Ask messages, receiving response messages, and sending decimation messages; S33, stop stage; In the stop phase, the node determines its final assignment, obtains the allocation plan for each computing task, and sends a stop message to all pseudo-parent nodes and parent nodes. Specifically, a node enters the stop phase in two situations: one is when the node is a leaf node and its state is decimation; the other is when the node is a non-leaf node and has received stop messages from all child nodes and pseudo-child nodes. Finally, determine whether the convergence or termination conditions are met. If the conditions are met, the process ends. If not, the process returns to the belief propagation stage and starts the next round of iteration.

2. The method according to claim 1, characterized in that The query message QueryMessage is specifically: during the belief propagation process, the user device sends a query message to the edge server, which includes the belief value of the user device. The specific calculation formula is as follows: Among them, α ij is a regularization factor to prevent the message from increasing without limit in the factor graph, S i \s j Represents the target server s j External user equipment a i All neighbor servers of Indicates the message sent by the server to the user device.

3. The method according to claim 1, characterized in that The response message ResponseMessage is specifically: a response message sent by the edge server to the user device during the belief propagation process, which includes the load corresponding to each value of the task state of the target user device under the current belief and the local load function; the specific calculation formula is as follows: Among them, A j \a i Except a i Edge servers other than j The set of neighboring user devices.

4. The method according to claim 1, wherein The Ask message is specifically: in the decimation stage, all nodes whose parent nodes are in the decimation state are called candidate nodes. In this stage, the candidate node sends an Ask message to the parent node to ask the parent node whether it can enter the decimation state. There are two types of Ask messages. If all pseudo-parent nodes of the candidate node are in the run state, the Ask message contains the node contribution c of the current node. i If any pseudo-parent node of the candidate node is in the decimation state, the Ask message contains the sum of the node contributions of the pseudo-parent nodes of the current node in the decimation state minus the node contribution of the current node, that is, 5. The method according to claim 1, wherein The response message is sent by the parent node to the child node. If the child node can enter the decimation state, the message is True, otherwise it is False. When the candidate node receives the response message sent by the parent node as True, and the candidate node has a pseudo-parent node in the decimation state, the candidate node sends a wakeup message to all pseudo-parent nodes in the decimation state. After receiving the wakeup message, the node determines whether it has received the Ask message from the child node. If so, it returns a reject message to the message sender, otherwise it returns an accept message.

6. The method according to claim 1, characterized in that The decimation message is used by a node to broadcast its own decimation status. If a node receives a wakeup message and a decimation message from the same node, the node will change its status to run. The stop message contains the node assignment of the message sender.

7. The method according to claim 1, characterized in that Step S32, the decimation stage includes: S321, determine candidate nodes Each node determines whether it is a candidate node based on its own status and the status of its neighboring nodes. Specifically, the conditions that a candidate node must meet are as follows: where s i Represents node x i Status, s parent Represents x i The status of the parent node; S322, Send Ask message After determining the candidate nodes, each candidate node will further determine the type and content of the Ask message to be sent to the parent node based on the status of AP and AC, where AP represents the pseudo-parent node device and parent node device of the user device in the pseudo-tree, and AC represents the child node device and pseudo-child node device of the user device in the pseudo-tree; if all AP nodes of the candidate node except the parent node are in the run state, the candidate node sends Ask(1,c i ), where 1 is the Ask message type, c i Is the node contribution of the candidate node; if the candidate node has an AP node in the decimation state, the candidate node sends Among them, 2 is the Ask message type, It is the sum of the node contributions of all pseudo-parent nodes of the candidate node that are in the decimation state; S323, receiving a response message; After receiving the Ask message from all the child nodes in the run state, the parent node will select the Ask message type 1 and c i The largest node is the winning node. If there is no Ask message type 1, the node with type 2 is selected. The smallest node is the winner. Then, the parent node sends a response message to all child nodes that sent the Ask message. The response message received by the winning node is True, and the response messages received by other nodes are False. If a node with a pseudo-parent node in the decimation state receives True, the node will send a wakeup message to all pseudo-parent nodes in the decimation state. After receiving the wakeup message, the pseudo-parent node checks whether it has received the Ask message in this round. If it has, it sends a reject message to the node to indicate that it refuses this state transfer. If not, it sends an accept message to indicate that it accepts this state transfer and changes its own node state from decimation to run. S324, send a decimation message; The node that receives the accept message changes its state to decimation and sends a decimation message to all neighboring nodes. After receiving the decimation message, the neighboring nodes store the node's state information.

8. A distributed constraint optimization solution method based on belief propagation, applied to the scheduling of computing resources, characterized in that: Including steps: S1. Calculate the node contribution of the computing task controlled by the user device; S2. Based on the node contributions, construct a pseudo-tree communication structure based on node contribution priority; S3. Based on the pseudo-tree communication structure, the belief propagation phase is entered. The belief propagation phase includes three sub-phases: query phase, response phase, and decision phase. In the query phase, a query message is sent to its neighboring servers. After the belief propagation phase, the value assigned to each node in this round and the response message to be used in the next iteration are obtained. S4: Enter the decimation phase and determine whether the decimation conditions are met. If so, send an Ask message. Specifically, in the decimation phase, all nodes whose parent nodes are in the decimation state are called candidate nodes. In this phase, the candidate nodes send Ask messages to their parent nodes, asking whether they can enter the decimation state. S5. The parent node receives the Ask message and determines the winning node. The parent node sends a response message to all child nodes that sent the Ask message. S6. Determine whether the response message is True. If so, proceed to step S7; otherwise, return to step S3. The response message received by the winning node is True, while that received by other nodes is False. S7. Determine whether any pseudo-parent node is in the decimation state. If so, the candidate node sends a wakeup message to all pseudo-parent nodes in the decimation state. Otherwise, return to step S3. S8. The pseudo-parent node receives the wakeup message and determines whether it has received the Ask message from the child node. If so, it returns a reject message to the message sender; otherwise, it returns an accept message. S9, the node receives the message and determines whether the received message is the accept message. If so, the node changes its state to decimation and sends decimation messages to all neighboring nodes. Otherwise, it returns to step S3; S10. Determine whether the stop condition is met. If so, the process ends. If not, the process returns to the belief propagation phase in step S3 to start the next iteration. In the stop phase, the node determines its final value, obtains the allocation plan for each computing task, and sends a stop message to all pseudo-parent nodes and parent nodes.

9. A distributed constraint optimization solving system based on belief propagation for scheduling computing resources, characterized in that: The distributed constraint optimization solving system executes the distributed constraint optimization solving method based on belief propagation according to claim 1, comprising: a data acquisition module, a pseudo-tree communication structure construction module and a distributed constraint optimization solving module; The data acquisition module acquires computing task information of each user device and resource status of each edge server; The pseudo-tree communication structure construction module constructs a pseudo-tree communication structure based on node contribution priority based on the computing task information of each user device and the resource status of each edge server; The distributed constraint optimization solving module obtains an allocation scheme for each computing task according to the pseudo-tree communication structure and based on a distributed extraction framework of belief propagation.

10. A computer device, characterized in that: The device includes a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Asymmetric distributed constrained optimization method for multi-Agent system

    CN103995750A

  • Continuous distributed constraint optimization problem solving method based on distribution estimation algorithm

    CN115099033A