Load balancing method and system based on dream optimization algorithm
The objective function and search space are constructed through the dream optimization algorithm, and the population is initialized for exploration and development, solving the limitations of the existing load balancing method in complex network environments, achieving global and local optimization balance, and improving the resource allocation efficiency and system performance of network equipment.
Patent Information
- Application Number
- CN202510574585.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-06
- Publication Date
- 2025-07-08
AI Technical Summary
The existing load balancing methods are difficult to dynamically adapt to the rapid changes in network traffic under complex and changeable network environments, resulting in some nodes being overloaded while other nodes being idle, unable to achieve efficient resource utilization, and difficult to take into account real-time and stability, and cannot meet the needs of modern communication networks for efficient and dynamic load balancing.
The dream optimization algorithm is used to build the objective function. By initializing the population and exploring and developing it, the optimal resource allocation plan for network nodes is obtained, combined with the multi-objective optimization objective function, taking into account node load, energy consumption and delay, avoiding falling into local optimization and achieving global and local optimization balance.
Quickly respond to traffic changes in complex network environments, improve the efficiency of load balancing, improve the overall performance of the network, reduce energy consumption, enhance the dynamic adaptability and flexibility of the system, alleviate the pressure in hot spots, and improve the resource allocation efficiency of network equipment.
Smart Images

Figure CN120281716A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of communication networks, and particularly to a load balancing method and system based on a dream optimization algorithm. Background Art
[0002] In modern communication networks, with the explosive growth of data traffic and the increasing diversification of user demands, network load balancing has become a key technology for improving network performance and user experience. Traditional load balancing methods, such as round-robin method, least-connection method, and weight-based allocation strategies, although they can achieve basic load distribution in simple scenarios, their limitations gradually emerge when facing complex and changing network environments. For example, it is difficult for them to dynamically adapt to the rapid changes in network traffic, which easily leads to overloading of some nodes while other nodes are idle, thus unable to achieve efficient utilization of resources; in addition, some existing load balancing methods based on intelligent algorithms, such as genetic algorithms, particle swarm optimization, etc., although they have improved the optimization ability to a certain extent, still have deficiencies in global optimization ability and convergence speed, and are prone to falling into local optima and difficult to find the global optimal solution in a short time; at the same time, these methods are difficult to balance real-time performance and stability in complex network environments and cannot meet the requirements of modern communication networks for efficient and dynamic load balancing. Therefore, developing a new method that can efficiently solve the communication network load balancing problem is of great significance for improving network performance, reducing energy consumption, and improving user experience. Summary of the Invention
[0003] The present disclosure provides a load balancing method and system, device, and storage medium based on a dream optimization algorithm.
[0004] According to a first aspect of the present disclosure, there is provided a load balancing method based on a dream optimization algorithm. The method includes:
[0005] Construct a target function according to the load, energy consumption, and delay of each node in the network topology structure;
[0006] Construct a search space according to the network topology structure and optimization requirements;
[0007] Use the dream optimization algorithm to initialize the population in the search space and explore and develop the initialized population to obtain the optimal solution of the target function; wherein, the population includes multiple individuals, each individual represents a node, and the position of each individual represents a solution of the target function;
[0008] Use the optimal solution of the target function as a resource allocation scheme to allocate resources to each node.
[0009] In some realizable ways of the first aspect, the target function is calculated by the following formula:
[0010]
[0011] Among them, f(X) represents the objective function, N represents the number of nodes, and L i represents the load of the i-th node, and C i represents the data processing capacity of the i-th node, and E i represents the energy consumption of the i-th node, and E max represents the maximum energy consumption of the node, and D i represents the delay of the i-th node, and α, β, and γ are the corresponding weight coefficients.
[0012] In some realizable ways of the first aspect, the dream optimization algorithm is used to initialize the population in the search space, including:
[0013] Initializing the population using the population initialization formula; among them, the population initialization formula includes:
[0014] X i = X l + rand × (X u - X l ), i = 1, 2,..., N
[0015] Among them, X i represents the i-th individual in the population, and X l , X u respectively represent the lower and upper bounds of the search space, and rand is a random number between 0 and 1.
[0016] In some realizable ways of the first aspect, exploring and exploiting the initialized population includes:
[0017] Taking the initialized population as the initial population, exploring the initial population using the first memory strategy, the first forgetting and replenishing strategy, or the dream sharing strategy, and repeating the exploration process until the first preset number of times is reached;
[0018] Exploiting the individuals obtained from the exploration using the second memory strategy and the second forgetting and replenishing strategy, and repeating the exploitation process until the second preset number of times is reached;
[0019] Taking the population obtained from the exploitation as the new initial population, and repeating the exploration and exploitation until the dream optimization algorithm converges.
[0020] In some realizable ways of the first aspect, exploring the initial population using the first memory strategy, the first forgetting and replenishing strategy, or the dream sharing strategy includes:
[0021] At the first exploration, dividing the initial population into multiple groups according to the forgetting dimensions of the individuals in the initial population;
[0022] Update all the individual positions in the same group to the individual positions corresponding to the minimum objective function value in the same group before the current exploration stage according to the first memory strategy;
[0023] Randomly select the forgetting dimension for each group, and make the individuals in each group forget according to the corresponding forgetting dimension. Update the positions of each individual on the forgetting dimension by using the first forgetting supplement strategy or the dream sharing strategy; among them, the randomly selected forgetting dimension for each group is positively correlated with the group number.
[0024] In some implementable ways of the first aspect, updating the positions of each individual on the forgetting dimension by using the first forgetting supplement strategy or the dream sharing strategy includes:
[0025] If the position update parameter meets the preset condition, then use the first forgetting supplement strategy to update the positions of each individual on the forgetting dimension by using the first position update formula;
[0026] Otherwise, use the dream sharing strategy to update the positions of each individual on the forgetting dimension by using the second position update formula; among them,
[0027] The position update parameter meets the preset condition, including that the position update parameter is greater than or equal to the random number in the first position update formula.
[0028] In some implementable ways of the first aspect, the method further includes:
[0029] When repeating the exploration process, according to the forgetting dimension corresponding to the individual positions updated in the previous exploration process, re-group all the individuals whose positions are updated into multiple groups, and re-explore according to the initial exploration method based on the re-grouping situation.
[0030] In some implementable ways of the first aspect, using the second memory strategy and the second forgetting supplement strategy to develop the individuals obtained by exploration includes:
[0031] When developing for the first time, according to the second memory strategy, take the individual position corresponding to the minimum objective function value among the individuals obtained by exploration as the global optimal individual position, and update the positions of all individuals to the global optimal individual position;
[0032] Let all individuals forget according to the same randomly selected forgetting dimension, and update the positions of each individual on the same forgetting dimension by using the second forgetting supplement strategy and the third position update formula.
[0033] In some implementable ways of the first aspect, the method further includes:
[0034] When repeating the development process, the individual position corresponding to the minimum objective function value among the objective function values corresponding to the individual positions updated in the previous round of development process is used as the new global optimal individual position. Based on the new global optimal individual position, the development is carried out again according to the initial development method.
[0035] According to a second aspect of the present disclosure, a load balancing system based on a dream optimization algorithm is provided. The system includes:
[0036] An objective function construction module, configured to construct an objective function according to the load, energy consumption, and delay of each node in the network topology;
[0037] A search space construction module, configured to construct a search space according to the network topology and optimization requirements;
[0038] An optimal solution obtaining module, configured to initialize a population in the search space by using the dream optimization algorithm and explore and develop the initialized population to obtain an optimal solution of the objective function; wherein, the population includes multiple individuals, each individual represents a node, and each individual position represents a solution of the objective function;
[0039] A load balancing module, configured to use the optimal solution of the objective function as a resource allocation scheme to allocate resources to each node.
[0040] According to a third aspect of the present disclosure, an electronic device is provided. The electronic device includes: at least one processor; and a memory communicatively connected to the at least one processor; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method as described above.
[0041] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, and the computer instructions are used to cause a computer to execute the method as described above.
[0042] In the present disclosure, a load balancing method and system based on a dream optimization algorithm are provided. The method specifically includes: constructing an objective function according to the load, energy consumption, and latency of each node in the network topology; constructing a search space according to the network topology and optimization requirements; using the dream optimization algorithm to initialize a population within the search space and explore and develop the initialized population to obtain the optimal solution of the objective function. Among them, the population includes multiple individuals, each individual represents a node, and the position of each individual represents a solution of the objective function. The optimal solution of the objective function is used as a resource allocation scheme to allocate resources to each node. In this way, it effectively avoids falling into the local optimal trap, achieves the optimization balance between the global and local, quickly responds to traffic changes in a complex network environment, improves the efficiency of load balancing, takes into account energy consumption and latency through the multi-objective optimized objective function, and enhances the overall performance of the network. The system has dynamic adaptability, flexibility, and scalability.
[0043] It should be understood that the content described in the summary of the invention section is not intended to limit the key or important features of the embodiments of the present disclosure, nor is it used to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. Brief Description of the Drawings
[0044] In combination with the accompanying drawings and referring to the following detailed description, the above and other features, advantages, and aspects of the embodiments of the present disclosure will become more obvious. The drawings are used to better understand the solution and do not constitute a limitation to the present disclosure. In the drawings, the same or similar reference numerals represent the same or similar elements, where:
[0045] Figure 1 Shows a flowchart of a load balancing method based on a dream optimization algorithm provided by an embodiment of the present disclosure;
[0046] Figure 2 Shows a structural diagram of a load balancing system based on a dream optimization algorithm provided by an embodiment of the present disclosure;
[0047] Figure 3 Shows a structural diagram of an exemplary electronic device capable of implementing the embodiments of the present disclosure. Detailed Description of the Embodiments
[0048] To make the objectives, technical solutions, and advantages of the embodiments of the present disclosure clearer, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are some, but not all, of the embodiments of the present disclosure. All other embodiments obtained by those of ordinary skill in the art without creative efforts based on the embodiments of the present disclosure belong to the scope of protection of the present disclosure.
[0049] In addition, the term "and / or" in this text is merely a description of the association relationship between associated objects, indicating that there can be three relationships. For example, A and / or B can represent three situations: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in this text generally represents an "or" relationship between the associated objects before and after.
[0050] In view of the problems in the background art, embodiments of the present disclosure provide a load balancing method and system based on a dream optimization algorithm. The method specifically includes: constructing an objective function according to the load, energy consumption, and delay of each node in the network topology; constructing a search space according to the network topology and optimization requirements; using the dream optimization algorithm to initialize a population in the search space and explore and develop the initialized population to obtain the optimal solution of the objective function. Among them, the population includes multiple individuals, each individual represents a node, and the position of each individual represents a solution of the objective function; using the optimal solution of the objective function as a resource allocation scheme to allocate resources to each node. In this way, it effectively avoids falling into the local optimal trap, realizes the optimization balance between the global and local, quickly responds to traffic changes in a complex network environment, improves the efficiency of load balancing, takes into account energy consumption and delay through the objective function of multi-objective optimization, and improves the overall performance of the network. The system has dynamic adaptability, flexibility, and scalability.
[0051] The following combines the accompanying drawings to specifically illustrate the load balancing method and system based on the dream optimization algorithm provided by the embodiments of the present disclosure through specific embodiments.
[0052] Figure 1 The flowchart of a load balancing method based on a dream optimization algorithm provided by an embodiment of the present disclosure is shown. Method 100 includes the following steps:
[0053] S110, construct an objective function according to the load, energy consumption, and delay of each node in the network topology.
[0054] In some embodiments, the objective function is calculated by the following formula:
[0055]
[0056] Among them, f(X) represents the objective function, N represents the number of nodes, L i represents the load of the i-th node, C i represents the data processing capacity of the i-th node, E i represents the energy consumption of the i-th node, E max represents the maximum energy consumption of the node, D iDenote the delay of the \(i\) -th node, and \(\alpha\), \(\beta\), and \(\gamma\) are the corresponding weight coefficients; this objective function simultaneously considers three key indicators: node load, energy consumption, and delay; further, the optimization objectives of the objective function include, but are not limited to, node load, energy consumption, and delay.
[0057] In some embodiments, the objective function of the introduced multi - objective optimization can more comprehensively reflect the actual requirements of the communication network, ensure that the optimization direction is consistent with the actual application scenario. Compared with the existing methods, the present disclosure not only optimizes the load distribution, but also takes into account energy consumption and delay, improving the overall performance of the network.
[0058] S120, construct a search space according to the network topology structure and optimization requirements.
[0059] In some embodiments, the optimization requirements include node load, energy consumption, delay, etc.
[0060] S130, use the dream optimization algorithm to initialize the population in the search space and explore and develop the initialized population to obtain the optimal solution of the objective function; wherein, the population includes multiple individuals, each individual represents a node, and the position of each individual represents a solution of the objective function.
[0061] In some embodiments, using the dream optimization algorithm to initialize the population in the search space includes:
[0062] Initialize the population using the population initialization formula; wherein, the population initialization formula includes:
[0063] X i =X l +rand×(X u -X l ), i = 1, 2,..., N
[0064] wherein, X i represents the \(i\) -th individual in the population, X l , X u respectively represent the lower bound (the minimum value of resource allocation) and the upper bound (the maximum value of resource allocation) of the search space, and rand is a random number between 0 and 1, used to generate random solutions.
[0065] In some embodiments, exploring and developing the initialized population includes:
[0066] Take the initialized population as the initial population, and use the first memory strategy, the first forgetting and replenishment strategy, or the dream sharing strategy to explore the initial population, and repeat the exploration process until the first preset number of times is reached;
[0067] Develop the individuals obtained through exploration using the second memory strategy and the second forgetting supplement strategy, and repeat the development process until the second preset number of times is reached;
[0068] Use the developed population as the new initial population, and repeat exploration and development until the dream optimization algorithm converges.
[0069] In some embodiments, exploring the initial population using the first memory strategy, the first forgetting supplement strategy, or the dream sharing strategy includes:
[0070] During the initial exploration, divide the initial population into multiple groups according to the forgetting dimensions of each individual in the initial population;
[0071] According to the first memory strategy, update the positions of all individuals in the same group to the position of the individual corresponding to the minimum objective function value in the same group before the current exploration stage;
[0072] Randomly select the forgetting dimension of each group, and make the individuals in each group forget according to the corresponding forgetting dimension. Use the first forgetting supplement strategy or the dream sharing strategy to update the positions of each individual in the forgetting dimension; wherein, the randomly selected forgetting dimension of each group is positively correlated with the group number;
[0073] Furthermore, the first memory strategy is:
[0074]
[0075] wherein, represents the individual with the best position in the q-th group at time t, that is, the individual with the minimum objective function value in the q-th group at time t, represents the i-th individual in the q-th group at time t + 1;
[0076] The first forgetting supplement strategy combines global and local search functions. This strategy follows the first memory strategy and allows individuals to forget information in the forgetting dimension and self-update their individual positions;
[0077] The dream sharing strategy enhances the escape ability from local optima. This strategy also follows the first memory strategy and allows individuals to randomly update their own position information from other individuals in the forgetting dimension.
[0078] In some embodiments, randomly select the forgetting dimension of each group from the problem dimensions; wherein, the problem dimensions include node load, energy consumption, delay, etc.
[0079] In some embodiments, using the first forgetting supplement strategy or the dream sharing strategy to update the positions of each individual in the forgetting dimension includes:
[0080] If the position update parameter meets the preset condition, the first forgetting supplement strategy is adopted to update the positions of individuals in the forgetting dimension using the first position update formula;
[0081] Otherwise, the dream sharing strategy is adopted to update the positions of individuals in the forgetting dimension using the second position update formula; where
[0082] The position update parameter meeting the preset condition includes that the position update parameter is greater than or equal to the random number in the first position update formula;
[0083] Furthermore, the first position update formula is as follows:
[0084]
[0085] j = K1, K2,...K q
[0086] Where represents the position of the i-th individual at the (t + 1)-th moment in the j-th dimension, represents the best individual position of the entire population at the t-th moment in the j-th dimension (i.e., the position of the individual with the minimum objective function value of the entire population at the t-th moment in the j-th dimension), x l,j x u,j respectively represent the lower bound and upper bound of the search space in the j-th dimension, rand is a random number between 0 and 1, T d T max are the first preset number of times and the maximum number of iterations respectively, where the sum of the first preset number of times and the second preset number of times is the maximum number of iterations, K1, K2......K q respectively represent the forgetting dimension of the first group, the forgetting dimension of the second group......the forgetting dimension of the q-th group;
[0087] The second position update formula is as follows:
[0088]
[0089] Where respectively represent the position of the m-th individual at the t-th moment in the j-th dimension and the position of the m-th individual at the (t + 1)-th moment in the j-th dimension, and m is a natural number randomly selected within the range of [1, N].
[0090] In some embodiments,
[0091] where Dim is the number of problem dimensions, represents a random integer selected within the range of range.
[0092] In some embodiments, method 100 further includes:
[0093] When repeating the exploration process, according to the forgotten dimensions corresponding to the individual positions updated in the previous exploration process, all the individuals with updated positions are re-grouped into multiple groups, and exploration is carried out again based on the re-grouping situation according to the initial exploration method.
[0094] In some embodiments, each group is independently optimized during the exploration phase, and the individuals in each group update their positions according to the first memory strategy, the first forgotten supplement strategy, or the dream sharing strategy.
[0095] In some embodiments, the second memory strategy and the second forgotten supplement strategy are used to develop the individuals obtained through exploration, including:
[0096] During the initial development, according to the second memory strategy, the individual position corresponding to the minimum objective function value among the individuals obtained through exploration is used as the global optimal individual position, and the positions of all individuals are updated to the global optimal individual position;
[0097] Let all individuals forget according to the same randomly selected forgotten dimension, and update the positions of each individual on the same forgotten dimension by using the third position update formula through the second forgotten supplement strategy;
[0098] Furthermore, the second memory strategy is as follows:
[0099]
[0100] Wherein, represents the v-th individual at time t + 1, represents the global optimal individual at time t, that is, the individual with the minimum objective function value among all individuals at time t;
[0101] The second forgotten supplement strategy uses the global optimal individual position to guide the search direction of the population, avoiding falling into local optima. The development phase pays more attention to the guidance of the global optimal solution, and accelerates the convergence of the algorithm by dynamically adjusting the search step size.
[0102] In some embodiments, the third position update formula is as follows:
[0103]
[0104] y = K 1, K 2, ...K r
[0105] Wherein, represents the position of the v-th individual at time t + 1 in the y-th dimension, represents the best individual position of the entire population at time t in the y-th dimension, x l,y 、x u,yrespectively represent the lower bound and the upper bound of the search space in the y-th dimension, K1, K2......K r is the forgotten dimension randomly selected from the problem dimensions, and this forgotten dimension is the forgotten dimension of all individuals.
[0106] In some embodiments,
[0107] In some embodiments, method 100 further includes:
[0108] When repeating the development process, the individual position corresponding to the minimum objective function value among the objective function values corresponding to the individual positions updated in the previous round of development process is used as the new global optimal individual position, and based on the new global optimal individual position, development is carried out again according to the initial development method.
[0109] In some embodiments, in the exploration stage and the development stage, after each update of the individual position, it is necessary to determine whether the updated individual position exceeds the boundary of the search space. If so, boundary processing is performed on the individuals that exceed the boundary of the search space according to the problem dimensions, so that all the updated individual positions are located within the search space;
[0110] Further, when the problem dimension is less than or equal to 15, there are relatively few local optimal solutions, and a random method is used to perform boundary processing on the individuals that exceed the boundary of the search space. The formula used in this random method is as follows:
[0111]
[0112] When the problem dimension is greater than 15, there are relatively many local optimal solutions, and it is necessary to enhance the global optimization ability and the ability to escape local optima. Therefore, a method similar to the dream sharing strategy is used to perform boundary processing on the individuals that exceed the boundary of the search space, as follows:
[0113]
[0114] Each time the position is updated, m and i are different.
[0115] In some embodiments, the optimal solution of the objective function is the individual position with the smallest objective function value obtained after exploration and development. If this individual position remains unchanged in consecutive multiple iterations, it indicates that the dream optimization algorithm converges.
[0116] In some embodiments, the dream optimization algorithm achieves a balance between global and local optimization by simulating the memory retention, forgetting, and logical self-organization behaviors in human dreams. By dynamically adjusting the search step size, it can quickly converge to the global optimal solution. This feature enables the present disclosure to quickly respond to changes in network traffic in a complex network environment and achieve efficient load balancing. The method can also effectively relieve the pressure in hot spots and improve the overall network performance. In the Internet of Things network, the present disclosure can reduce the pressure on the central server and improve the overall efficiency of the system.
[0117] S140. Use the optimal solution of the objective function as a resource allocation scheme to allocate resources to each node.
[0118] In some embodiments, method 100 can be applied to an architecture composed of a network device layer, a control layer, and an application layer. Specifically, the application layer sends a service request to the control layer, and the network devices report the resource occupancy of each device to the control layer in real time. The control layer dynamically adjusts the resource distribution of the network devices according to the real-time monitored network traffic, resource occupancy, and service request. The network devices respond to the service request. Among them, the control layer uses the load balancing method of the present disclosure to dynamically adjust the resource distribution of the network devices.
[0119] Furthermore, the network device layer includes network devices such as routers, switches, and servers. The application layer supports various communication applications, such as video streams and online games.
[0120] In some embodiments, the architecture composed of the network device layer, the control layer, and the application layer can improve the availability and elasticity of the system and can handle sudden traffic peaks and high-concurrency requests.
[0121] The above is the introduction of the method embodiments. The following further illustrates the solution of the present disclosure through specific embodiments using this method.
[0122] Construct the objective function and the search space, set initial parameters for each node in the network topology, initialize the population, where an individual in the population represents a node. Set the first preset number of times and the second preset number of times according to the dynamic change frequency of the network and the optimization objective. Use the dream optimization algorithm to explore the population. When exploring, first divide the population into 3 groups according to the number of forgetting dimensions of each individual. Update the position of each individual in the first group to the position of the individual with the minimum objective function value in the first group before the current exploration stage. Update the position of each individual in the second group to the position of the individual with the minimum objective function value in the second group before the current exploration stage. Similarly, update the position of each individual in the third group to the position of the individual with the minimum objective function value in the third group before the current exploration stage; randomly select the forgetting dimensions of each group. Assume that the number of forgetting dimensions in the first group is K1, the number of forgetting dimensions in the second group is K2, and the number of forgetting dimensions in the third group is K3, and K1 < K2 < K3. Each individual in the first group forgets according to the number of forgetting dimensions of K1, each individual in the second group forgets according to the number of forgetting dimensions of K2, and each individual in the third group forgets according to the number of forgetting dimensions of K3. Assume that the position update parameter meets the preset condition, then use the first forgetting supplement strategy to update the corresponding individual position in the corresponding forgetting dimension. After each update of the individual position, it is necessary to perform boundary processing on the individuals that exceed the search boundary to make the updated individual position within the search space; repeat the exploration process according to the above exploration method until the first preset number of times is reached;
[0123] Use the dream optimization algorithm to develop each individual. In the development stage, cancel the grouping. Take the position of the individual corresponding to the minimum objective function value among all individuals as the global optimal individual position, and update the positions of all individuals to the global optimal individual position; randomly select Kr numbers of forgetting dimensions, and let each individual forget according to the same number of forgetting dimensions (Kr), and use the third position update formula to update the position of each individual in the Kr forgetting dimension. After each update of the individual position, it is necessary to perform boundary processing on the individuals that exceed the search boundary to make the updated individual position within the search space; calculate the objective function value corresponding to the updated individual position, take the position of the individual corresponding to the minimum objective function value as the new global optimal individual position, and repeat the above development process until the second preset number of times is reached;
[0124] The exploration and development processes are alternately carried out until the dream optimization algorithm converges. Take the individual position obtained after convergence as the optimal solution of the objective function, that is, the optimal resource allocation scheme, and allocate resources to each node according to the optimal resource allocation scheme.
[0125] According to an embodiment of the present disclosure, a load balancing method and system based on a dream optimization algorithm are provided. The method specifically includes: constructing an objective function based on the load, energy consumption, and latency of each node in the network topology; constructing a search space according to the network topology and optimization requirements; using the dream optimization algorithm to initialize a population in the search space and explore and develop the initialized population to obtain the optimal solution of the objective function. Among them, the population includes multiple individuals, each individual represents a node, and the position of each individual represents a solution of the objective function; using the optimal solution of the objective function as a resource allocation plan to allocate resources to each node. In this way, it effectively avoids falling into the local optimum trap, realizes the optimization balance between the global and local, quickly responds to traffic changes in a complex network environment, improves the efficiency of load balancing, takes into account energy consumption and latency through the multi-objective optimization objective function, and improves the overall performance of the network. The system has dynamic adaptability, flexibility, and scalability.
[0126] It should be noted that for the foregoing method embodiments, for the sake of simple description, they are all expressed as a series of action combinations. However, those skilled in the art should know that the present disclosure is not limited by the described action sequence, because according to the present disclosure, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily essential to the present disclosure.
[0127] The above is the introduction of the method embodiments. The following further illustrates the solution of the present disclosure through device embodiments.
[0128] Figure 2 The structural diagram of a load balancing system based on a dream optimization algorithm provided by an embodiment of the present disclosure is shown. The system 200 includes:
[0129] An objective function construction module 210, configured to construct an objective function according to the load, energy consumption, and latency of each node in the network topology.
[0130] In some embodiments, the objective function construction module 210 is specifically configured to:
[0131] The objective function is calculated by the following formula:
[0132]
[0133] Among them, f(X) represents the objective function, N represents the number of nodes, L i represents the load of the i-th node, C i represents the data processing capacity of the i-th node, E i represents the energy consumption of the i-th node, E max represents the maximum energy consumption of the node, Di represents the delay of the i-th node, and α, β, and γ are the corresponding weight coefficients.
[0134] The search space construction module 220 is used to construct a search space according to the network topology structure and optimization requirements.
[0135] The optimal solution acquisition module 230 is used to initialize a population in the search space by using the dream optimization algorithm and explore and develop the initialized population to obtain the optimal solution of the objective function; where the population includes multiple individuals, each individual represents a node, and each individual position represents a solution of the objective function.
[0136] In some embodiments, the optimal solution acquisition module 230 is specifically used for:
[0137] Initializing the population in the search space by using the dream optimization algorithm, including:
[0138] Initializing the population by using the population initialization formula; where the population initialization formula includes:
[0139] X i = X l + rand × (X u - X l ), i = 1, 2,..., N
[0140] where X i represents the i-th individual in the population, and X l , X u represent the lower bound and upper bound of the search space respectively, and rand is a random number between 0 and 1.
[0141] In some embodiments, the optimal solution acquisition module 230 is specifically further used for:
[0142] Exploring and developing the initialized population, including:
[0143] Taking the initialized population as the initial population, exploring the initial population by using the first memory strategy, the first forgetting and replenishment strategy, or the dream sharing strategy, and repeating the exploration process until the first preset number of times is reached;
[0144] Developing the individuals obtained by exploration by using the second memory strategy and the second forgetting and replenishment strategy, and repeating the development process until the second preset number of times is reached;
[0145] Taking the developed population as the new initial population, repeating the exploration and development until the dream optimization algorithm converges.
[0146] In some embodiments, the optimal solution acquisition module 230 is specifically further used for:
[0147] Explore the initial population using the first memory strategy, the first forgetting supplement strategy, or the dream sharing strategy, including:
[0148] During the initial exploration, divide the initial population into multiple groups according to the forgetting dimensions of each individual in the initial population;
[0149] According to the first memory strategy, update the positions of all individuals in the same group to the position of the individual corresponding to the minimum objective function value in the same group before the current exploration stage;
[0150] Randomly select the forgetting dimension of each group, make the individuals in each group forget according to the corresponding forgetting dimension, and update the positions of each individual in the forgetting dimension using the first forgetting supplement strategy or the dream sharing strategy; among them, the randomly selected forgetting dimension of each group is positively correlated with the group number.
[0151] In some embodiments, the optimal solution acquisition module 230 is further specifically configured to:
[0152] Update the positions of each individual in the forgetting dimension using the first forgetting supplement strategy or the dream sharing strategy, including:
[0153] If the position update parameter meets the preset condition, use the first forgetting supplement strategy to update the positions of each individual in the forgetting dimension using the first position update formula;
[0154] Otherwise, use the dream sharing strategy to update the positions of each individual in the forgetting dimension using the second position update formula; among them,
[0155] The position update parameter meets the preset condition, including that the position update parameter is greater than or equal to the random number in the first position update formula.
[0156] In some embodiments, the system 200 is further specifically configured to:
[0157] When repeating the exploration process, according to the forgetting dimensions corresponding to the individual positions updated in the previous exploration process, re-divide all the individuals with updated positions into multiple groups, and re-explore according to the initial exploration method based on the re-grouping situation.
[0158] In some embodiments, the optimal solution acquisition module 230 is further specifically configured to:
[0159] Develop the individuals obtained from the exploration using the second memory strategy and the second forgetting supplement strategy, including:
[0160] During the initial development, according to the second memory strategy, use the position of the individual corresponding to the minimum objective function value among the individuals obtained from the exploration as the global optimal individual position, and update the positions of all individuals to the global optimal individual position;
[0161] Let all individuals forget according to the same randomly selected forgetting dimension, and update the positions of each individual on the same forgetting dimension by using the third position update formula through the second forgetting supplement strategy.
[0162] In some embodiments, the system 200 is specifically further configured to:
[0163] When repeating the development process, use the individual position corresponding to the minimum objective function value among the objective function values corresponding to the individual positions updated in the previous round of development process as the new global optimal individual position, and based on the new global optimal individual position, perform development again according to the initial development method.
[0164] The load balancing module 240 is configured to allocate resources to each node by using the optimal solution of the objective function as a resource allocation scheme.
[0165] It can be understood that Figure 2 Each module / unit in the illustrated system 200 has the function of implementing each step in the method 100 provided in the embodiments of the present disclosure, and can achieve its corresponding technical effects. For the sake of brevity, details are not described herein again.
[0166] Figure 3 The figure shows a structural diagram of an exemplary electronic device capable of implementing the embodiments of the present disclosure. The electronic device 300 is intended to represent various forms of digital computers, such as, a laptop computer, a desktop computer, a workbench, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The electronic device 300 can also represent various forms of mobile devices, such as, a personal digital processor, a cellular phone, a smart phone, a wearable device, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0167] As Figure 3 shown, the electronic device 300 includes a computing unit 301, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 302 or a computer program loaded from a storage unit 308 into a random access memory (RAM) 303. In the RAM 303, various programs and data required for the operation of the electronic device 300 can also be stored. The computing unit 301, the ROM 302, and the RAM 303 are connected to each other through a bus 304. An I / O interface 305 is also connected to the bus 304.
[0168] Multiple components in the electronic device 300 are connected to the I / O interface 305, including: an input unit 306, such as a keyboard, a mouse, etc.; an output unit 307, such as various types of displays, speakers, etc.; a storage unit 308, such as a disk, an optical disc, etc.; and a communication unit 309, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 309 allows the electronic device 300 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.
[0169] The computing unit 301 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 301 include but are not limited to a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 301 executes the various methods and processes described above, such as method 100. For example, in some embodiments, method 100 can be implemented as a computer software program that is tangibly contained in a machine-readable medium, such as the storage unit 308. In some embodiments, part or all of the computer program can be loaded and / or installed onto the electronic device 300 via the ROM 302 and / or the communication unit 309. When the computer program is loaded into the RAM 303 and executed by the computing unit 301, one or more steps of the method 100 described above can be executed. Alternatively, in other embodiments, the computing unit 301 can be configured to execute method 100 in any other suitable manner (e.g., by means of firmware).
[0170] The various embodiments of the systems and techniques described above in this document can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems on a chip (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a dedicated or general-purpose programmable processor, receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting the data and instructions to the storage system, the at least one input device, and the at least one output device.
[0171] The program code for implementing the methods of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing devices, such that when executed by the processor or controller, the program codes cause the functions / operations specified in the flowchart and / or block diagram to be implemented. The program code can be executed entirely on the machine, partially on the machine, executed partially on the machine as an independent software package and partially on a remote machine, or executed entirely on a remote machine or server.
[0172] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0173] It should be noted that the present disclosure also provides a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause a computer to execute method 100 and achieve the corresponding technical effects achieved by the method of the embodiments of the present disclosure. For the sake of brevity of description, details are not repeated herein.
[0174] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) through which the user can provide input to the computer. Other kinds of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0175] The systems and techniques described herein can be implemented in a computing system including backend components (e.g., as a data server), or a computing system including middleware components (e.g., an application server), or a computing system including frontend components (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described herein), or a computing system including any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected to each other by digital data communication in any form or medium (e.g., a communication network). Examples of communication networks include: local area network (LAN), wide area network (WAN), and the Internet.
[0176] A computer system can include a client and a server. The client and the server are generally far from each other and typically interact through a communication network. The client - server relationship is created by computer programs running on the respective computers and having a client - server relationship with each other. The server can be a cloud server, can also be a server of a distributed system, or a server incorporating a blockchain.
[0177] It should be understood that various forms of the processes shown above can be used, with steps reordered, added, or deleted. For example, the steps recited in this disclosure can be executed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and no limitation is imposed herein.
[0178] The above - described specific embodiments do not constitute a limitation on the protection scope of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub - combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the protection scope of this disclosure.
Claims
1. A load balancing method based on a dream optimization algorithm, characterized in that, Including: Construct an objective function according to the load, energy consumption, and latency of each node in the network topology; Construct a search space according to the network topology and optimization requirements; Use the dream optimization algorithm to initialize the population within the search space and explore and develop the initialized population to obtain the optimal solution of the objective function; wherein, the population includes multiple individuals, each individual represents a node, and the position of each individual represents a solution of the objective function; Use the optimal solution of the objective function as a resource allocation scheme to allocate resources to each node.
2. The method according to claim 1, wherein The objective function is calculated by the following formula: Among them, f(X) represents the objective function, N represents the number of nodes, and L i represents the load of the i-th node, and C i represents the data processing capacity of the i-th node, and E i represents the energy consumption of the i-th node, and E max represents the maximum energy consumption of the node, and D i represents the delay of the i-th node, and α, β, and γ are the corresponding weight coefficients.
3. The method according to claim 1, wherein The step of using the dream optimization algorithm to initialize the population within the search space includes: Initialize the population using the population initialization formula; wherein, the population initialization formula includes: X i = X l + rand × (X u - X l ), i = 1, 2, ..., N where X i represents the i-th individual in the population, and X l , X u represent the lower and upper bounds of the search space respectively, and rand is a random number between 0 and 1.
4. The method according to claim 1, wherein The step of exploring and developing the initialized population includes: Take the initialized population as the initial population, explore the initial population using the first memory strategy, the first forgetting and replenishment strategy, or the dream sharing strategy, and repeat the exploration process until the first preset number of times is reached; Develop the individuals obtained from the exploration using the second memory strategy and the second forgetting and replenishment strategy, and repeat the development process until the second preset number of times is reached; Take the population obtained from the development as the new initial population, and repeat the exploration and development until the dream optimization algorithm converges.
5. The method according to claim 4, wherein The step of exploring the initial population using the first memory strategy, the first forgetting and replenishment strategy, or the dream sharing strategy includes: At the first exploration, divide the initial population into multiple groups according to the forgetting dimension of each individual in the initial population; According to the first memory strategy, update the positions of all individuals in the same group to the position of the individual corresponding to the minimum objective function value in the same group before the current exploration stage; Randomly select the forgetting dimension of each group, and make the individuals in each group forget according to the corresponding forgetting dimension, and update the positions of each individual in the forgetting dimension using the first forgetting and replenishment strategy or the dream sharing strategy; wherein, the randomly selected forgetting dimension of each group is positively correlated with the group number.
6. The method according to claim 5, characterized in that, The step of updating the positions of each individual in the forgetting dimension using the first forgetting and replenishment strategy or the dream sharing strategy includes: If the position update parameter meets the preset condition, use the first forgetting and replenishment strategy to update the positions of each individual in the forgetting dimension using the first position update formula; Otherwise, use the dream sharing strategy to update the positions of each individual in the forgetting dimension using the second position update formula; wherein, The position update parameter meets the preset condition, including that the position update parameter is greater than or equal to the random number in the first position update formula.
7. The method according to claim 5, wherein The method further includes: When repeating the exploration process, re-divide all the individuals with updated positions into multiple groups according to the forgetting dimension corresponding to the updated individual positions in the previous exploration process, and re-explore according to the initial exploration method based on the re-grouping situation.
8. The method according to claim 4, wherein The step of developing the individuals obtained from the exploration using the second memory strategy and the second forgetting and replenishment strategy includes: At the first development, according to the second memory strategy, take the position of the individual corresponding to the minimum objective function value among the individuals obtained from the exploration as the global optimal individual position, and update the positions of all individuals to the global optimal individual position; Let all individuals forget according to the same randomly selected forgetting dimension, and update the positions of each individual on the same forgetting dimension by using the third position update formula through the second forgetting supplement strategy.
9. The method according to claim 8, wherein The method further includes: When repeating the development process, use the individual position corresponding to the minimum objective function value among the objective function values corresponding to the individual positions updated in the previous round of development process as the new global optimal individual position, and based on the new global optimal individual position, perform development again according to the initial development method.
10. A load balancing system based on a dream optimization algorithm, characterized in that, It includes: An objective function construction module for constructing an objective function according to the load, energy consumption, and delay of each node in the network topology structure; A search space construction module for constructing a search space according to the network topology structure and optimization requirements; An optimal solution acquisition module for initializing a population within the search space by using the dream optimization algorithm and exploring and developing the initialized population to obtain the optimal solution of the objective function; wherein, the population includes multiple individuals, each individual represents a node, and each individual position represents a solution of the objective function; A load balancing module for allocating resources to each node by using the optimal solution of the objective function as a resource allocation scheme.
Citation Information
Cited By
Parallel robot trajectory optimization method based on improved dream optimization algorithm
CN120909216A
FPSO deck parallel cable layout method
CN121093540A
Lithium battery product carbon footprint evaluation method and system based on carbon footprint factor database and life trajectory disassembly, medium and processor
CN121352814A