CN117424813B - Node expansion method for block chain - Google Patents

Node expansion method for block chain Download PDF

Info

Publication number
CN117424813B
CN117424813B CN202311688039.2A CN202311688039A CN117424813B CN 117424813 B CN117424813 B CN 117424813B CN 202311688039 A CN202311688039 A CN 202311688039A CN 117424813 B CN117424813 B CN 117424813B
Authority
CN
China
Prior art keywords
node
data
state
expansion
historical
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202311688039.2A
Other languages
Chinese (zh)
Other versions
CN117424813A (en
Inventor
杨琨
苏建新
李辰辉
何立军
王凯飞
葛大伟
李健
刘奎阳
何亘
余纪良
汪进
杨立寨
王振宇
段国强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Yuncheng Financial Information Service Co ltd
Original Assignee
Beijing Yuncheng Financial Information Service Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Yuncheng Financial Information Service Co ltd filed Critical Beijing Yuncheng Financial Information Service Co ltd
Priority to CN202311688039.2A priority Critical patent/CN117424813B/en
Publication of CN117424813A publication Critical patent/CN117424813A/en
Application granted granted Critical
Publication of CN117424813B publication Critical patent/CN117424813B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • H04L41/0816Configuration setting characterised by the conditions triggering a change of settings the condition being an adaptation, e.g. in response to network events
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0894Policy-based network configuration management
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/14Network analysis or design
    • H04L41/145Network analysis or design involving simulating, designing, planning or modelling of a network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/14Network analysis or design
    • H04L41/147Network analysis or design for predicting network behaviour
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention provides a node expansion method for a block chain, which relates to the technical field of block chains and comprises the steps of deploying a block chain network structure, constructing a node set and selecting a representative node; acquiring historical processing data, exchanging the representative node with block chain network structure data, and acquiring historical state data; a state evaluation model is built based on the historical state data to predict the state of the data to be processed, so that node pre-expansion is realized, and a pre-expansion result is obtained; and performing effect evaluation and correction on the pre-expansion result. Selecting representative nodes by constructing a node set in a block chain network structure; constructing a state evaluation model to predict state data of data to be processed of each node in the block chain; realizing node pre-expansion by using representative nodes based on state data; and the expansion effect is evaluated and corrected to obtain a final node expansion scheme, so that the variability of the demand of the block chain service on the computing resource and the storage resource is met, and the data processing efficiency is ensured.

Description

Node expansion method for block chain
Technical Field
The invention relates to the technical field of blockchains, in particular to a node expansion method for a blockchain.
Background
In recent years, china basically forms an environment and soil suitable for the development of a blockchain technology, the application innovation of the blockchain technology is landed and accelerated, and productivity is gradually released under the background of the vigorous development of digital economy; on the other hand, the deepened development of the blockchain industrialization process is accelerated, and the key progress is made in the directions of policy environment, technical development, application innovation, industrial ecology and the like.
In practical applications, the blockchain service has a variable demand for computing resources and storage resources due to a large amount of data to be processed, and the blockchain node may face a bottleneck in computing and storage resources.
Accordingly, the present invention provides a node expansion method for a blockchain.
Disclosure of Invention
The invention provides a node expansion method for a block chain, which is used for selecting representative nodes by constructing a node set in a block chain network structure; constructing a state evaluation model to predict state data of data to be processed of each node in the block chain; realizing node pre-expansion by using representative nodes based on state data; and the expansion effect is evaluated and corrected to obtain a final node expansion scheme, so that the variability of the demand of the block chain service on the computing resource and the storage resource is met, and the data processing efficiency is ensured.
The invention provides a node expansion method for a blockchain, which comprises the following steps:
step 1: deploying a blockchain network structure, constructing a node set in the blockchain network structure, and selecting a representative node from the node set;
step 2: acquiring historical processing data, and exchanging the data between the representative node and the blockchain network structure so as to acquire historical state data of each node;
step 3: constructing a state evaluation model based on historical state data to-be-processed data state prediction, and carrying out node pre-expansion according to a state prediction result to obtain a pre-expansion result;
step 4: and performing effect evaluation and correction on the pre-expansion result to obtain a node expansion scheme.
Preferably, deploying a blockchain network structure, constructing a node set in the blockchain network structure, and selecting a representative node from the node set, including:
determining a topological structure of the blockchain platform and the blockchain network based on data processing requirements;
initializing block chain network parameters after building block chain nodes by using a building method corresponding to the block chain platform;
developing intelligent contracts and deploying application programs through corresponding programming languages and development tools of the block chain platform, and completing deployment of a block chain network structure;
dividing all nodes in the block chain network structure according to a preset dividing rule to obtain a plurality of node sets;
and calculating the average value of the distance between each node and all other nodes in the node set, and selecting the corresponding node with the minimum average value of the distance as a representative node.
Preferably, the preset dividing rule includes a primary dividing rule and a secondary dividing rule, wherein the primary dividing rule refers to dividing corresponding nodes of the same organization or the same unit into node sets, and the secondary dividing rule refers to dividing nodes with node distances not larger than a preset distance threshold value in the remaining nodes into the same node set.
Preferably, the step of obtaining historical processing data and exchanging data between the representative node and the blockchain network structure to obtain historical state data of each node includes:
extracting a preset amount of historical processing data from the cloud server, and communicating and connecting the historical processing data with the representative node through an external block chain structure, so as to transmit the historical processing data to the representative node;
the representative node performs primary division of calculation tasks according to the calculation resources of each node in the corresponding node set to obtain a primary division result;
and dynamically adjusting the primary division result of the computing task of each node according to the current computing resource use state of each node, and collecting the historical state data of each node in real time.
Preferably, a state evaluation model is constructed based on historical state data to predict the state of data to be processed, and node pre-expansion is performed according to the state prediction result to obtain a pre-expansion result, which comprises the following steps:
processing the historical state data to obtain the characteristics of the historical state data;
model training is carried out on a deep learning network algorithm of an attention mechanism through the historical state data characteristics to obtain a state evaluation model;
inputting data to be processed into the state evaluation model to obtain state prediction data of each node for processing the data to be processed;
determining a comprehensive prediction use state value of the corresponding node set by utilizing the state prediction data;
initializing an expansion queue, taking a node set with the comprehensive prediction use state value not smaller than a preset state threshold value as an expandable set, adding the node set into the initial expansion queue according to the order of the comprehensive prediction use state value from large to small, and outputting the node set as a pre-expansion result.
Preferably, the processing the historical state data to obtain the historical state data feature includes:
marking the historical state data to generate preprocessing data with a state data tag;
carrying out data expansion and data normalization processing on the preprocessed data by using a Gaussian noise technology to obtain target data;
calculating similarity conditional probability between any two data in the target data to obtain a first conditional probability and a second conditional probability;
and calculating characteristic data of the target data by using the first conditional probability and the second conditional probability, so as to obtain historical state data characteristics of the historical state data.
Preferably, determining the comprehensive predicted usage state value of the corresponding node set by using the state prediction data includes:
acquiring first computing resource use cost and first communication use cost of each node;
the calculation formula of the first calculation resource use cost is as follows:
in>A first computing resource usage cost represented as a jth node; />Cpu core usage cost denoted as j-th node; a is expressed as the number of cpu cores; />GB memory usage cost expressed as the jth node; b is expressed as the number of gb memories; />GB disk usage cost denoted as jth node; c is expressed as the number of GB magnetic disks; />gMb communication Bandwidth usage fee denoted as jth nodeThe method comprises the steps of carrying out a first treatment on the surface of the d represents the number of gMb communication bandwidths; />Expressed as run time;
the calculation formula of the first communication use cost is as follows:
in>A first communication usage cost denoted as a j-th node; />A connecting edge expressed as a j-th node and a representative node i; />Represented as a node set structure diagram; />Denoted as edge->Weight value of (2);
and calculating the comprehensive predicted use state value of the node set by combining the first calculation resource use cost and the first communication use cost of each node, wherein the formula is as follows:
in (1) the->A comprehensive computing resource usage cost represented as a set of nodes; m is expressed as the total number of nodes in the node set; />First computing resource usage cost expressed as j-th node, and +.>;/>A comprehensive communication usage cost expressed as a set of nodes; />First communication use cost expressed as j-th node, and +.>;/>The impact weight of the comprehensive use cost expressed as the node set on the use state; />The average difference value between the power consumption and the total power consumption generated when each node in the node set operates is expressed; />Represented as impact weights of node performance on usage status.
Preferably, performing effect evaluation and correction on the pre-expansion result to obtain a node expansion scheme, including:
based on the comprehensive prediction use state value of the expandable sets, acquiring the node expansion number of each expandable set by combining the data to be processed;
the representative nodes in the extensible set are utilized to be extended according to the node extension number, and then a new extended set is obtained;
the representative node is utilized to carry out calculation task division and dynamic adjustment according to the calculation resources of each node in the corresponding new expansion set, and then current state data of each node is obtained in real time;
determining new comprehensive prediction use state values corresponding to the new expansion sets by combining the current state data of each node with a state evaluation model;
if a new expansion set with the new comprehensive prediction use state value not smaller than the preset state threshold exists, taking the node set with the comprehensive prediction use state value smaller than the preset state threshold and larger than the preset low state threshold as a re-expansion set, and adding the re-expansion queues according to the sequence from the large to the small of the comprehensive prediction use state value;
and combining the initial expansion queue and the re-expansion queue to obtain a node expansion scheme.
Compared with the prior art, the beneficial effects of the application are as follows:
selecting representative nodes by constructing a node set in a block chain network structure; constructing a state evaluation model to predict state data of data to be processed of each node in the block chain; realizing node pre-expansion by using representative nodes based on state data; and the expansion effect is evaluated and corrected to obtain a final node expansion scheme, so that the variability of the demand of the block chain service on the computing resource and the storage resource is met, and the data processing efficiency is ensured.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention may be realized and attained by the structure particularly pointed out in the written description and drawings.
The technical scheme of the invention is further described in detail through the drawings and the embodiments.
Drawings
The accompanying drawings are included to provide a further understanding of the invention and are incorporated in and constitute a part of this specification, illustrate the invention and together with the embodiments of the invention, serve to explain the invention. In the drawings:
FIG. 1 is a flow chart of a node expansion method for a blockchain in accordance with an embodiment of the present invention.
Detailed Description
The preferred embodiments of the present invention will be described below with reference to the accompanying drawings, it being understood that the preferred embodiments described herein are for illustration and explanation of the present invention only, and are not intended to limit the present invention.
An embodiment of the present invention provides a node expansion method for a blockchain, as shown in fig. 1, including:
step 1: deploying a blockchain network structure, constructing a node set in the blockchain network structure, and selecting a representative node from the node set;
step 2: acquiring historical processing data, and exchanging the data between the representative node and the blockchain network structure so as to acquire historical state data of each node;
step 3: constructing a state evaluation model based on historical state data to-be-processed data state prediction, and carrying out node pre-expansion according to a state prediction result to obtain a pre-expansion result;
step 4: and performing effect evaluation and correction on the pre-expansion result to obtain a node expansion scheme.
In this embodiment, the blockchain network structure is a peer-to-peer network composed of a plurality of nodes, and the nodes communicate with each other using a standardized protocol; the node set is a set obtained by dividing all nodes in the block chain network structure according to a preset dividing rule.
In this embodiment, the preset dividing rule includes a primary dividing rule and a secondary dividing rule, where the primary dividing rule refers to dividing corresponding nodes of the same organization or the same unit into node sets, and the secondary dividing rule refers to dividing nodes with node distances not greater than a preset distance threshold value in the remaining nodes into the same node set.
In this embodiment, the representative node refers to a node with the smallest average value of the distances between the representative node and all the other nodes in the node set, and is used for being connected with an external block chain structure to realize data exchange; the historical processing data is multi-source data extracted from the cloud server, and a data support is laid for model construction; historical state data refers to data generated by computing operations on historical processing data by nodes in a node set, such as power consumption and operation time.
In the embodiment, the state evaluation model is obtained by training a model by using a deep learning network algorithm of an attention mechanism and is used for predicting the state of data to be processed calculated by the node; the state prediction result refers to state prediction data of the data to be processed, such as communication bandwidth and calculation rate, processed by the node; the pre-expansion result refers to a queue formed by a priority expansion node set which is analyzed and screened by the state value; the node expansion scheme is an expansion set obtained by adjusting the effect evaluation of the pre-expansion result.
The beneficial effects of the technical scheme are as follows: selecting representative nodes by constructing a node set in a block chain network structure; constructing a state evaluation model to predict state data of data to be processed of each node in the block chain; realizing node pre-expansion by using representative nodes based on state data; and the expansion effect is evaluated and corrected to obtain a final node expansion scheme, so that the variability of the demand of the block chain service on the computing resource and the storage resource is met, and the data processing efficiency is ensured.
The embodiment of the invention provides a node expansion method for a blockchain, which comprises the steps of deploying a blockchain network structure, constructing a node set in the blockchain network structure, selecting a representative node from the node set, and comprises the following steps:
determining a topological structure of the blockchain platform and the blockchain network based on data processing requirements;
initializing block chain network parameters after building block chain nodes by using a building method corresponding to the block chain platform;
developing intelligent contracts and deploying application programs through corresponding programming languages and development tools of the block chain platform, and completing deployment of a block chain network structure;
dividing all nodes in the block chain network structure according to a preset dividing rule to obtain a plurality of node sets;
and calculating the average value of the distance between each node and all other nodes in the node set, and selecting the corresponding node with the minimum average value of the distance as a representative node.
In this embodiment, the data processing requirement is a processing purpose set in advance based on the data to be processed; the blockchain platform comprises an Ethernet, a super account book, an EOS and the like, and is determined based on the current data processing requirement; the topological structure is selected based on a public chain and a private chain in the form of a blockchain network; blockchain nodes refer to computers running in a blockchain network, each node having an identity and ledger data.
In this embodiment, the blockchain network parameters include consensus algorithm, opening size, transaction confirmation time, etc., and are required to be configured according to the selected blockchain platform document; an intelligent contract is a contract written in a code form and automatically executed, and can realize the automation and the trusted execution of transactions; an application refers to an intelligent contract-based decentralized application or a legacy application that interacts with a blockchain.
In this embodiment, the preset dividing rule includes a primary dividing rule and a secondary dividing rule, where the primary dividing rule refers to dividing corresponding nodes of the same organization or the same unit into node sets, and the secondary dividing rule refers to dividing nodes with node distances not greater than a preset distance threshold value in the remaining nodes into the same node set.
In this embodiment, the node set is a set obtained by dividing all nodes in the blockchain network structure according to a preset division rule; the representative node refers to a node with the minimum average value of the distance between the node and all other nodes in the node set, and is used for being connected with an external block chain structure to realize data exchange.
The beneficial effects of the technical scheme are as follows: the blockchain network structure is effectively deployed by confirming a blockchain platform, a topological structure, building nodes, configuring blockchain network parameters, developing intelligent contracts and deploying application programs; and constructing a node set in the block chain network structure according to a preset partitioning rule, and selecting representative nodes to lay a foundation for subsequent node expansion.
The embodiment of the invention provides a node expansion method for a block chain, which is used for acquiring historical processing data and exchanging data between a representative node and a block chain network structure so as to acquire historical state data of each node, and comprises the following steps:
extracting a preset amount of historical processing data from the cloud server, and communicating and connecting the historical processing data with the representative node through an external block chain structure, so as to transmit the historical processing data to the representative node;
the representative node performs primary division of calculation tasks according to the calculation resources of each node in the corresponding node set to obtain a primary division result;
and dynamically adjusting the primary division result of the computing task of each node according to the current computing resource use state of each node, and collecting the historical state data of each node in real time.
In this embodiment, the cloud server is configured to store data, and establish communication connection with the representative node and the server, so as to implement data transmission; the preset amount is set in advance; the historical processing data is multi-source data extracted from the cloud server, and a data support is laid for model construction.
In this embodiment, the representative node refers to a node with the smallest average value of the distances between the representative node and all the other nodes in the node set, and is used for being connected with an external block chain structure to realize data exchange; the primary division result refers to a result obtained by performing primary division of a calculation task on a representative node according to calculation resources of all nodes in the same node set; historical state data refers to data generated by a node performing calculation operation on historical processing data, such as power consumption and operation time.
The beneficial effects of the technical scheme are as follows: processing the data by extracting the history and transmitting the data to the representative node; the representative node performs calculation task division and dynamic adjustment according to the calculation resources of each node in the same node set, so that the rationality of calculation task division is ensured.
The embodiment of the invention provides a node expansion method for a blockchain, which is used for constructing a state evaluation model based on historical state data to predict the state of data to be processed, carrying out node pre-expansion according to a state prediction result to obtain a pre-expansion result, and comprises the following steps of:
processing the historical state data to obtain the characteristics of the historical state data;
model training is carried out on a deep learning network algorithm of an attention mechanism through the historical state data characteristics to obtain a state evaluation model;
inputting data to be processed into the state evaluation model to obtain state prediction data of each node for processing the data to be processed;
determining a comprehensive prediction use state value of the corresponding node set by utilizing the state prediction data;
initializing an expansion queue, taking a node set with the comprehensive prediction use state value not smaller than a preset state threshold value as an expandable set, adding the node set into the initial expansion queue according to the order of the comprehensive prediction use state value from large to small, and outputting the node set as a pre-expansion result.
In this embodiment, the historical state data refers to data generated by performing calculation operation on the historical processing data by the node, such as power consumption and operation time; the historical state data features are obtained by expanding the historical state data and analyzing the data features after data normalization processing.
In this embodiment, the attention mechanism is a method that mimics the human visual and cognitive system and that can process input data to focus on relevant parts to improve model performance and generalization ability; the state evaluation model is obtained by training a model through a deep learning network algorithm by using an attention mechanism and is used for predicting the state of the data to be processed calculated by the node; the state prediction data is the prediction data output after the data to be processed is input into the state evaluation model, such as communication bandwidth and calculation rate.
In the embodiment, the comprehensive prediction use state value is a state value obtained by calculating resource cost, communication cost and performance power consumption based on state prediction data in combination with analysis node sets, and is used for representing the use state of the node sets to calculate data to be processed; the preset state threshold is set in advance.
In this embodiment, for example, there are node sets 1, 2, 3, and the corresponding comprehensive predicted usage state values are respectively、/>Wherein->Is greater than a preset state threshold and +.>,/>And when the state threshold value is smaller than the preset state threshold value, taking the node sets 1 and 2 as expandable sets, and sequentially adding the node sets 2 and 1 into the initial expansion queue.
The beneficial effects of the technical scheme are as follows: model training is carried out through a deep learning network algorithm based on an attention mechanism to obtain a state evaluation model; acquiring state prediction data of the data to be processed by using the state evaluation model so as to obtain comprehensive prediction use state values of the node set; the comprehensive prediction using state value is analyzed, and the node set with the expanded priority can be effectively screened out.
The embodiment of the invention provides a node expansion method for a block chain, which is used for processing historical state data to obtain historical state data characteristics and comprises the following steps:
marking the historical state data to generate preprocessing data with a state data tag;
carrying out data expansion and data normalization processing on the preprocessed data by using a Gaussian noise technology to obtain target data;
calculating similarity conditional probability between any two data in the target data to obtain a first conditional probability and a second conditional probability;
and calculating characteristic data of the target data by using the first conditional probability and the second conditional probability, so as to obtain historical state data characteristics of the historical state data.
In this embodiment, the historical state data refers to data generated by performing calculation operation on the historical processing data by the node, such as power consumption and operation time; the preprocessing data refers to the marked historical state data with the state label; the purpose of the data normalization process is to eliminate the dimension effect so as to facilitate the subsequent calculation of the data.
In this embodiment, the target data refers to data obtained by performing data expansion and data normalization processing on the preprocessed data; the first conditional probability refers to the similarity conditional probability of the first data to the second data between the two data; the second conditional probability refers to the similarity conditional probability of the second data to the first data between the two data; the historical state data features are generated by utilizing feature data of the target data calculated by the first conditional probability and the second conditional probability.
The beneficial effects of the technical scheme are as follows: the historical state data is marked, expanded and normalized to obtain target data, and the data similarity concept is introduced to calculate the characteristic data of the target data, so that the historical state data characteristics are obtained, and a data support is laid for model training.
The embodiment of the invention provides a node expansion method for a block chain, which utilizes the state prediction data to determine a comprehensive prediction use state value of a corresponding node set, and comprises the following steps:
acquiring first computing resource use cost and first communication use cost of each node;
the calculation formula of the first calculation resource use cost is as follows:
in>A first computing resource usage cost represented as a jth node; />Cpu core usage cost denoted as j-th node; a is expressed as the number of cpu cores; />GB memory usage cost expressed as the jth node; b is expressed as the number of gb memories; />Represented as j-th sectionThe use cost of the GB disk is counted; c is expressed as the number of GB magnetic disks; />gMb communication bandwidth usage fee denoted as j-th node; d represents the number of gMb communication bandwidths; />Expressed as run time;
the calculation formula of the first communication use cost is as follows:
in>A first communication usage cost denoted as a j-th node; />A connecting edge expressed as a j-th node and a representative node i; />Represented as a node set structure diagram; />Denoted as edge->Weight value of (2);
and calculating the comprehensive predicted use state value of the node set by combining the first calculation resource use cost and the first communication use cost of each node, wherein the formula is as follows:
in (1) the->A comprehensive computing resource usage cost represented as a set of nodes; m is expressed as the total number of nodes in the node setA number; />First computing resource usage cost expressed as j-th node, and +.>;/>A comprehensive communication usage cost expressed as a set of nodes; />First communication use cost expressed as j-th node, and +.>;/>The impact weight of the comprehensive use cost expressed as the node set on the use state; />The average difference value between the power consumption and the total power consumption generated when each node in the node set operates is expressed; />Represented as impact weights of node performance on usage status.
In this embodiment, the first computing resource usage cost refers to a cost determined by computing a resource usage amount, a running time, and the like, based on the respective nodes being located at different physical locations and different resource configurations; the first communication usage cost refers to that calculated by using the bandwidth, the transmission data amount, and the delay of each node.
In this embodiment, the comprehensive prediction use state value is a state value obtained by calculating resource cost, communication cost and performance power consumption based on the state prediction data in combination with the analysis node set, and is used for representing the use state of the node set to calculate the data to be processed.
The beneficial effects of the technical scheme are as follows: the method comprises the steps of calculating the first calculation resource use cost and the first communication use cost generated when each node calculates data to be processed, determining the comprehensive prediction use state value of a corresponding node set by combining node performance analysis, and providing a data basis for node expansion.
The embodiment of the invention provides a node expansion method for a block chain, which carries out effect evaluation and correction on the pre-expansion result to obtain a node expansion scheme, and comprises the following steps:
based on the comprehensive prediction use state value of the expandable sets, acquiring the node expansion number of each expandable set by combining the data to be processed;
the representative nodes in the extensible set are utilized to be extended according to the node extension number, and then a new extended set is obtained;
the representative node is utilized to carry out calculation task division and dynamic adjustment according to the calculation resources of each node in the corresponding new expansion set, and then current state data of each node is obtained in real time;
determining new comprehensive prediction use state values corresponding to the new expansion sets by combining the current state data of each node with a state evaluation model;
if a new expansion set with the new comprehensive prediction use state value not smaller than the preset state threshold exists, taking the node set with the comprehensive prediction use state value smaller than the preset state threshold and larger than the preset low state threshold as a re-expansion set, and adding the re-expansion queues according to the sequence from the large to the small of the comprehensive prediction use state value;
and combining the initial expansion queue and the re-expansion queue to obtain a node expansion scheme.
In this embodiment, the extensible set refers to a node set in which the comprehensive prediction use state value is not less than a preset state threshold; the comprehensive prediction use state value is a state value obtained by combining the state prediction data with the analysis node set to calculate the resource cost, the communication cost and the performance power consumption, and is used for representing the use state of the node set to calculate the data to be processed.
In this embodiment, the representative node refers to a node with the smallest average value of the distances between the representative node and all the other nodes in the node set, and is used for being connected with an external block chain structure to realize data exchange; the new expansion set refers to a set obtained by expanding the expandable set by using the representative node according to the node expansion number.
In this embodiment, the current state data refers to data generated by performing calculation processing on data to be processed by a node in the new extended set, such as power consumption and operation time; the state evaluation model is obtained by training a model through a deep learning network algorithm using an attention mechanism and is used for predicting the state of the data to be processed calculated by the nodes.
In this embodiment, the new comprehensive prediction usage state value refers to state prediction data obtained by evaluating current state data based on a state evaluation model, and is used for representing a usage state of data to be processed calculated by the new expansion set in combination with a state value obtained by analyzing a new expansion set calculation resource cost, a communication cost and performance power consumption; the re-expanding set refers to a node set with a comprehensive prediction use state value smaller than a preset state threshold and larger than a preset low state threshold.
In this embodiment, the preset low state threshold is set in advance.
The beneficial effects of the technical scheme are as follows: the node expansion scheme meeting the data processing requirement is obtained by correcting the pre-expansion result after evaluating the state of the data processing by using the generated new expansion set after the node expansion of the pre-expansion result, so that the variability of the block chain service on the computing resource and the storage resource requirement is met, and the data processing efficiency is ensured.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present invention without departing from the spirit or scope of the invention. Thus, it is intended that the present invention also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.

Claims (4)

1. A node expansion method for a blockchain, comprising:
step 1: deploying a blockchain network structure, constructing a node set in the blockchain network structure, and selecting a representative node from the node set;
step 2: acquiring historical processing data, and exchanging the data between the representative node and the blockchain network structure so as to acquire historical state data of each node;
step 3: constructing a state evaluation model based on historical state data to-be-processed data state prediction, and carrying out node pre-expansion according to a state prediction result to obtain a pre-expansion result;
step 4: performing effect evaluation and correction on the pre-expansion result to obtain a node expansion scheme;
wherein, step 3 includes:
processing the historical state data to obtain the characteristics of the historical state data;
model training is carried out on a deep learning network algorithm of an attention mechanism through the historical state data characteristics to obtain a state evaluation model;
inputting data to be processed into the state evaluation model to obtain state prediction data of each node for processing the data to be processed;
determining a comprehensive prediction use state value of the corresponding node set by utilizing the state prediction data;
initializing an expansion queue, taking a node set with the comprehensive prediction use state value not smaller than a preset state threshold value as an expandable set, adding the node set into the initial expansion queue according to the order of the comprehensive prediction use state value from large to small, and outputting the node set as a pre-expansion result;
the processing of the historical state data to obtain the historical state data features comprises the following steps:
marking the historical state data to generate preprocessing data with a state data tag;
carrying out data expansion and data normalization processing on the preprocessed data by using a Gaussian noise technology to obtain target data;
calculating similarity conditional probability between any two data in the target data to obtain a first conditional probability and a second conditional probability;
calculating characteristic data of the target data by using the first conditional probability and the second conditional probability, so as to obtain historical state data characteristics of the historical state data;
the method for obtaining the node expansion scheme comprises the following steps of:
based on the comprehensive prediction use state value of the expandable sets, acquiring the node expansion number of each expandable set by combining the data to be processed;
the representative nodes in the extensible set are utilized to be extended according to the node extension number, and then a new extended set is obtained;
the representative node is utilized to carry out calculation task division and dynamic adjustment according to the calculation resources of each node in the corresponding new expansion set, and then current state data of each node is obtained in real time;
determining new comprehensive prediction use state values corresponding to the new expansion sets by combining the current state data of each node with a state evaluation model;
if a new expansion set with the new comprehensive prediction use state value not smaller than the preset state threshold exists, taking the node set with the comprehensive prediction use state value smaller than the preset state threshold and larger than the preset low state threshold as a re-expansion set, and adding the re-expansion queues according to the sequence from the large to the small of the comprehensive prediction use state value;
and combining the initial expansion queue and the re-expansion queue to obtain a node expansion scheme.
2. The node extension method for a blockchain of claim 1, wherein deploying a blockchain network structure and constructing a set of nodes in the blockchain network structure, and selecting a representative node from the set of nodes, comprises:
determining a topological structure of the blockchain platform and the blockchain network based on data processing requirements;
initializing block chain network parameters after building block chain nodes by using a building method corresponding to the block chain platform;
developing intelligent contracts and deploying application programs through corresponding programming languages and development tools of the block chain platform, and completing deployment of a block chain network structure;
dividing all nodes in the block chain network structure according to a preset dividing rule to obtain a plurality of node sets;
and calculating the average value of the distance between each node and all other nodes in the node set, and selecting the corresponding node with the minimum average value of the distance as a representative node.
3. The node extension method for a blockchain of claim 2, wherein the preset partitioning rule includes a preliminary partitioning rule and a sub-partitioning rule, wherein the preliminary partitioning rule refers to partitioning corresponding nodes of a same organization or a same unit into node sets, and the sub-partitioning rule refers to partitioning nodes with a node pitch of no more than a preset pitch threshold value in remaining nodes into the same node set.
4. The node extension method for a blockchain of claim 1, wherein obtaining historical processing data and exchanging data between the representative node and a blockchain network structure to obtain historical state data for each node comprises:
extracting a preset amount of historical processing data from the cloud server, and communicating and connecting the historical processing data with the representative node through an external block chain structure, so as to transmit the historical processing data to the representative node;
the representative node performs primary division of calculation tasks according to the calculation resources of each node in the corresponding node set to obtain a primary division result;
and dynamically adjusting the primary division result of the computing task of each node according to the current computing resource use state of each node, and collecting the historical state data of each node in real time.
CN202311688039.2A 2023-12-11 2023-12-11 Node expansion method for block chain Active CN117424813B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311688039.2A CN117424813B (en) 2023-12-11 2023-12-11 Node expansion method for block chain

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311688039.2A CN117424813B (en) 2023-12-11 2023-12-11 Node expansion method for block chain

Publications (2)

Publication Number Publication Date
CN117424813A CN117424813A (en) 2024-01-19
CN117424813B true CN117424813B (en) 2024-03-22

Family

ID=89523390

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311688039.2A Active CN117424813B (en) 2023-12-11 2023-12-11 Node expansion method for block chain

Country Status (1)

Country Link
CN (1) CN117424813B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107045518A (en) * 2016-10-18 2017-08-15 北京天德科技有限公司 A kind of extension design method of block chain
CN111625196A (en) * 2020-05-26 2020-09-04 北京海益同展信息科技有限公司 Block chain node capacity expansion method and device, computer equipment and storage medium
CN114915404A (en) * 2022-05-13 2022-08-16 北京邮电大学 Block chain data storage extension model construction method for Internet of things
CN115623004A (en) * 2022-11-03 2023-01-17 济南轨道交通集团有限公司 Block chain-based rail transit equipment management system and method
CN115686368A (en) * 2022-10-28 2023-02-03 蚂蚁区块链科技(上海)有限公司 Method, system, apparatus and medium for storage capacity expansion of nodes of block chain network

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114462628A (en) * 2020-11-09 2022-05-10 华为技术有限公司 Data enhancement method, device, computing equipment and computer readable storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107045518A (en) * 2016-10-18 2017-08-15 北京天德科技有限公司 A kind of extension design method of block chain
CN111625196A (en) * 2020-05-26 2020-09-04 北京海益同展信息科技有限公司 Block chain node capacity expansion method and device, computer equipment and storage medium
CN114915404A (en) * 2022-05-13 2022-08-16 北京邮电大学 Block chain data storage extension model construction method for Internet of things
CN115686368A (en) * 2022-10-28 2023-02-03 蚂蚁区块链科技(上海)有限公司 Method, system, apparatus and medium for storage capacity expansion of nodes of block chain network
CN115623004A (en) * 2022-11-03 2023-01-17 济南轨道交通集团有限公司 Block chain-based rail transit equipment management system and method

Also Published As

Publication number Publication date
CN117424813A (en) 2024-01-19

Similar Documents

Publication Publication Date Title
Xu et al. Trust-aware service offloading for video surveillance in edge computing enabled internet of vehicles
CN111629380B (en) Dynamic resource allocation method for high concurrency multi-service industrial 5G network
CN109885397B (en) Delay optimization load task migration algorithm in edge computing environment
CN114189892A (en) Cloud-edge collaborative Internet of things system resource allocation method based on block chain and collective reinforcement learning
CN108052387B (en) Resource allocation prediction method and system in mobile cloud computing
CN115358487A (en) Federal learning aggregation optimization system and method for power data sharing
CN110162390B (en) Task allocation method and system for fog computing system
CN105205052B (en) A kind of data digging method and device
CN109639833A (en) A kind of method for scheduling task based on wireless MAN thin cloud load balancing
CN112287990A (en) Model optimization method of edge cloud collaborative support vector machine based on online learning
CN107786989B (en) Lora intelligent water meter network gateway deployment method and device
CN117896384B (en) Internet of things communication method, device, equipment and storage medium
CN117424813B (en) Node expansion method for block chain
CN117391858A (en) Inductive blockchain account distribution method and device based on graphic neural network
CN116055330A (en) Digital twin network slicing method and device based on knowledge graph
Chen et al. A derivative-free hybrid optimization model for short-term operation of a multi-objective reservoir system under uncertainty
CN115499876A (en) Computing unloading strategy based on DQN algorithm under MSDE scene
CN116109058A (en) Substation inspection management method and device based on deep reinforcement learning
CN112738225B (en) Edge calculation method based on artificial intelligence
Chen et al. Sublessor: A cost-saving internet transit mechanism for cooperative MEC providers in industrial internet of things
Fu et al. Policy network assisted Monte Carlo Tree search for intelligent service function chain deployment
CN106357676A (en) Method for optimizing overhead of cloud service resource
Ayyadurai et al. Cloud Computing Based Workload Optimization using Long Short Term Memory Algorithm
CN117237004B (en) Energy storage device transaction processing method and device and storage medium
CN116957067B (en) Reinforced federal learning method and device for public safety event prediction model

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant