Blockchain-based power material detection method, device, medium and electronic equipment
By introducing smart contracts and game theory of testing strategies into the power material inspection process using blockchain technology, the problems of data security and low efficiency in power material inspection have been solved, and an automated and efficient power material inspection process has been achieved.
Patent Information
- Application Number
- CN202210960613.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-11
- Publication Date
- 2026-01-02
- Estimated Expiration
- 2042-08-11
AI Technical Summary
Existing methods for detecting power materials suffer from low data security and low detection efficiency, especially due to insufficient efficiency caused by manual intervention.
A blockchain-based method for detecting power materials is adopted. The power materials to be detected are identified through storage nodes, and a transfer request is generated to trigger a smart contract in the blockchain network. The detection nodes are used to play a game of detection strategy to automatically determine the target detection strategy, realizing the entire process of power materials detection without human intervention.
It has improved the automation level and efficiency of power material inspection, ensured the security of power material data, and achieved efficient inspection without human intervention throughout the entire process.
Smart Images

Figure CN115271240B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of computer application, and in particular to a power material detection method and device based on a blockchain, a medium and an electronic device. BACKGROUND
[0002] Power materials such as power cables, transformers, switch cabinets and circuit breakers are the material basis for ensuring power supply, and safe detection of power materials is of great significance to ensuring the safety of the power grid.
[0003] A power material detection base is an important place for detecting power materials, and the power material detection base is equipped with power material storage, material transfer equipment and material detection equipment. Among them, the power material storage is used to store power materials; the material transfer equipment is used to transfer power materials; and the material detection equipment is used to detect the safety of power materials. Safe detection of power materials requires that the material transfer equipment transfer the power materials to be detected from the power material storage to the material detection equipment, and the material detection equipment detects the safety of the power materials to be detected. It can be known that the safety detection of power materials generally includes multiple detection procedures, and the power material detection base sets at least two material detection equipment for each detection procedure. In related technologies, manual intervention is generally used to coordinate the material detection equipment, and the material detection equipment is specified to detect the safety of the power materials to be detected. This manual intervention power material detection method has the problems of low data security of power materials and low detection efficiency. SUMMARY
[0004] The present application provides a power material detection method and device based on a blockchain, a medium and an electronic device, which can improve the detection efficiency of power materials and ensure the data security of power materials.
[0005] According to a first aspect of the present application, a power material detection method based on a blockchain is provided, the method comprising:
[0006] In response to receiving a power material detection task, determining a power material to be detected from the power material storage according to the power material detection task through a storage node;
[0007] Generating a power material transfer request for the power material to be detected through the storage node, and sending the power material transfer request to a blockchain network, so that a transport node in the blockchain network triggers a smart contract in the blockchain network;
[0008] In response to the smart contract being triggered, a detection node in the blockchain network performs a detection strategy game and determines a target detection strategy for the power material to be detected.
[0009] According to a second aspect of the present application, a blockchain-based power material detection device is provided, the device comprising:
[0010] A to-be-detected power material determination module is configured to, in response to receiving a power material detection task, determine, by a warehouse node, a to-be-detected power material from a power material warehouse according to the power material detection task;
[0011] A power material transfer request sending module is configured to generate, by the warehouse node, a power material transfer request for the to-be-detected power material, and send the power material transfer request to a blockchain network, so as to trigger, by a transport node in the blockchain network, a smart contract in the blockchain network;
[0012] A target detection strategy determination module is configured to, in response to the smart contract being triggered, perform, by a detection node in the blockchain network, a detection strategy game, and determine a target detection strategy for the to-be-detected power material.
[0013] According to a third aspect of the present application, a computer readable storage medium is provided, which stores a computer program, and the program is executed by a processor to implement the blockchain-based power material detection method according to the embodiments of the present application.
[0014] According to a fourth aspect of the present application, an electronic device is provided, which comprises a memory, a processor, and a computer program stored in the memory and executable by the processor, and the processor implements the blockchain-based power material detection method according to the embodiments of the present application when executing the computer program.
[0015] The technical solution of the embodiments of the present application determines the to-be-detected power material by the warehouse node, generates the power material transfer request to notify the transport node to trigger the smart contract in the blockchain network, so that the detection node in the blockchain network performs the detection strategy game in response to the smart contract being triggered, and determines the target detection strategy for the to-be-detected power material, thereby improving the automation level of the power material detection. From determining the to-be-detected power material, transferring the power material to the detection power material, to the whole process of the power material detection without manual intervention, the detection efficiency of the power material is effectively improved. The blockchain technology is applied to the power material detection in the embodiments of the present application, and the data security of the power material is ensured.
[0016] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present application, nor is it used to limit the scope of the present application. Other features of the present application will become apparent from the following description. BRIEF DESCRIPTION OF DRAWINGS
[0017] In order to make the technical solutions in the embodiments of the present application clearer, the drawings needed in the embodiment description will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without any creative effort on the basis of these drawings.
[0018] Figure 1 is a flowchart of the power material detection method based on the blockchain provided according to embodiment one;
[0019] Figure 2 is a flowchart of the power material detection method based on the blockchain provided according to embodiment two;
[0020] Figure 3 is a structural schematic diagram of the power material detection system based on the blockchain provided according to the embodiment;
[0021] Figure 4 is a structural schematic diagram of the power material detection device based on the blockchain provided according to the embodiment three of the present application;
[0022] Figure 5 is a structural schematic diagram of an electronic device provided according to the embodiment of the present application. DETAILED DESCRIPTION
[0023] In order to make the technical solutions in the embodiments of the present application clearer, the drawings needed in the embodiment description will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without any creative effort on the basis of these drawings.
[0024] It should be noted that the terms "first", "second", "target" and "candidate" and the like in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily indicate a specific order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device including a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0025] Embodiment one
[0026] Figure 1 is a flowchart of a blockchain-based power material detection method according to Embodiment One. The embodiment can be applied to the case of safe detection of power materials. The method can be executed by a blockchain-based power material detection device, which can be implemented in the form of hardware and / or software and can be integrated into an electronic device running the system.
[0027] As shown in Figure 1 , the method comprises:
[0028] S110, in response to receiving a power material detection task, determining, by a warehouse node, a to-be-detected power material from a power material warehouse according to the power material detection task.
[0029] The power material detection task is completed by the cooperation of the warehouse node, the transportation node and the detection node. Optionally, the warehouse node, the transportation node and the detection node are block nodes in the same blockchain network. The warehouse node is used to store power materials, the transportation node is used to transport power materials, and the detection node is used to detect the safety of power materials. Specifically, the to-be-detected power material is determined by the warehouse node, and the to-be-detected power material is transported to the detection node by the transportation node. The safety of the to-be-detected power material is detected by the detection node. The to-be-detected power material is a power material that needs to be detected.
[0030] The power material detection task can determine the to-be-detected power material and the detection completion time of the to-be-detected power material. The power material detection task is determined according to actual business needs, which is not limited here.
[0031] Optionally, the power material detection system publishes the power material detection task to the blockchain network in which the warehouse node, the transportation node and the detection node are located.
[0032] The warehouse node determines the to-be-detected power material from the power material warehouse according to the power material detection task in response to receiving the power material detection task.
[0033] S120, generating, by the warehouse node, a power material transportation request for the to-be-detected power material, and sending the power material transportation request to the blockchain network to trigger the smart contract in the blockchain network by the transportation node in the blockchain network.
[0034] The power material transportation request is used to request the transportation node to transport the to-be-detected power material. The transportation node in the blockchain network triggers the smart contract in the blockchain network in response to the power material transportation request to determine the transportation destination of the to-be-detected power material.
[0035] The smart contract is specifically a pre-designed, logically complete program or protocol that can be automatically triggered and executed. The smart contract includes the rights and obligations that can be exercised by the user. The smart contract, also known as chaincode, is an extension and upgrade of the traditional smart contract concept. It supports multiple high-level programming languages for writing internal business logic, including mainstream Java, Golang, and Node.js. According to different specific functions, chaincode is divided into two categories: system chaincode, which is used to process various internal events in the blockchain network system; and user chaincode, which is an open callable interface and program for the outside world, and is a unified encapsulation and centralized embodiment of business logic in specific practical application scenarios. The client node can only interact with the blockchain distributed ledger through the user chaincode, and can complete functions such as uploading and retrieving manufacturing data.
[0036] Optionally, the smart contract of the embodiment of the application encapsulates a game interaction method suitable for the power material detection process. Based on the smart contract in the embodiment of the application, the transfer destination of the power material to be detected is determined. The transfer destination is a detection node that performs security detection on the power material to be detected.
[0037] In response to the smart contract being triggered, the detection nodes in the blockchain network perform a detection strategy game to determine a target detection strategy for the power material to be detected.
[0038] In response to the smart contract being triggered, the detection nodes in the blockchain network perform a detection strategy game to determine a target detection strategy for the power material to be detected. The target detection strategy is used to determine a detection node that performs security detection on the power material to be detected. Optionally, the storage node, the transportation node, and the detection node store the locally collected and processed data, such as the power material to be detected data, and the target detection strategy to the blockchain network.
[0039] In one optional embodiment, in response to the smart contract being triggered, the detection nodes in the blockchain network perform a detection strategy game to determine a target detection strategy for the power material to be detected, including: in response to the smart contract being triggered, determining a current detection process of the power material to be detected; based on the detection node belonging to the process and the current detection process, selecting a detection node belonging to a next detection process from the detection nodes of the blockchain network to perform a detection strategy game to determine the target detection strategy for the power material to be detected.
[0040] It can be known that the safety detection of electric power materials generally includes multiple detection procedures. Only after all detection procedures are completed, the safety detection of electric power materials is considered to be completed. Optionally, there is a logical sequence between different detection procedures. For example, in the case that the detection procedures of electric power materials include detection procedure 1 and detection procedure 2, detection procedure 1 is a detection procedure before detection procedure 2, and electric power materials can only proceed to detection procedure 2 after detection procedure 1. Optionally, different detection procedures are completed by different detection nodes. Each detection procedure includes at least two detection nodes, that is, at least two detection nodes can complete the safety detection task of the detection procedure. The circulation of electric power materials between different detection procedures also needs to be completed by a transportation node. Optionally, after the detection node belonging to the current detection procedure completes the safety detection of the to-be-detected electric power materials, an electric power material transfer request is generated for the to-be-detected electric power materials, and the electric power material transfer request is sent to the blockchain network, so that the transportation node in the blockchain network triggers the smart contract in the blockchain network. Among them, the current detection procedure refers to the detection procedure in which the to-be-detected electric power materials are currently located.
[0041] In response to the smart contract in the blockchain network being triggered, the current detection procedure of the to-be-detected electric power materials is determined. Based on the detection node belonging to the procedure and the current detection procedure, the detection node belonging to the next detection procedure is selected from the detection node in the blockchain network, the detection strategy game is performed, and the target detection strategy for the to-be-detected electric power materials is determined. The detection strategy game based on the detection node belonging to the next detection procedure is actually to determine the detection node for the to-be-detected electric power materials to perform the next detection procedure from the detection nodes that can perform the next detection procedure.
[0042] If the safety detection of electric power materials includes multiple detection procedures with a logical sequence, after the target detection strategy for the to-be-detected electric power materials is determined, the determination operation of the current detection procedure is returned to be executed until the current detection procedure is the final detection procedure, and then it is determined that the to-be-detected electric power materials are detected. Optionally, the to-be-detected electric power materials that have completed the detection are transferred back to the storage node by the transportation node. The above technical solution can be applied to the case that the safety detection of electric power materials includes multiple detection procedures with a logical sequence. According to the logical sequence between the detection procedures, the detection strategy game is performed by the detection nodes responsible for the same detection procedure, the target detection strategy for the to-be-detected electric power materials is determined, and the detection efficiency of electric power materials is improved.
[0043] The technical scheme of the embodiment of the application determines the power material to be detected through the warehouse node, generates a power material transfer request, and notifies the transportation node to trigger the smart contract in the blockchain network, so that the detection node in the blockchain network responds to the triggering of the smart contract to perform detection strategy game, and determines the target detection strategy for the power material to be detected, thereby improving the automation level of power material detection. From determining the power material to be detected, transferring the power material to the detection power material, the whole process of power material detection does not need manual intervention, and the detection efficiency of the power material is effectively improved. The embodiment of the application applies the blockchain technology to the detection of the power material, and guarantees the data security of the power material.
[0044] In an optional embodiment, the method further includes: a block node in the blockchain network performs disturbance detection on a local running environment in response to the smart contract being triggered; wherein the block node includes: a warehouse node, a transportation node, and a detection node; in a case where it is detected that there is disturbance in the local running environment, a disturbance type is determined, and the disturbance is processed based on the disturbance type.
[0045] The block node in the blockchain network performs disturbance detection on a local running environment in response to the smart contract being triggered, and detects whether there is disturbance in the local running environment. Wherein, the disturbance will affect the detection strategy game between the detection nodes. Therefore, in a case where the block node detects that there is disturbance in the local running environment, the disturbance type is determined. Optionally, the disturbance type includes explicit disturbance and implicit disturbance. Compared with the implicit disturbance, the explicit disturbance has a greater impact on the detection strategy game between the detection nodes, and the explicit disturbance directly affects the detection strategy game. Exemplarily, the display disturbance includes: detection device failure or emergency detection instruction insertion. The implicit disturbance can be detection cumulative delay, and the implicit disturbance does not directly affect the detection strategy game. The influence of the implicit disturbance on the detection strategy game is indirect and limited. The implicit disturbance will also have a significant impact on the detection strategy game after a period of accumulation.
[0046] The local running environment of the block node such as the warehouse node, the transportation node, and the detection node in the blockchain network may have disturbance. In a case where the running environment of the block node has disturbance, the block node needs to process the disturbance according to the disturbance type. Optionally, the block node excludes explicit disturbance, monitors implicit disturbance, and repairs the implicit disturbance in a case where the block node is in an idle state. Optionally, in a case where the disturbance is excluded, the detection strategy game is performed through the detection node, and the target detection strategy is determined for the power material to be detected.
[0047] The technical scheme, in the disturbance detection of the local running environment, in the case that the disturbance is detected in the local running environment, the disturbance type is determined, and the disturbance is processed based on the disturbance type, so as to provide a stable running environment for subsequent detection node detection strategy game, and the accuracy of the target detection strategy is ensured.
[0048] In an optional embodiment, after the detection node in the blockchain network performs the detection strategy game to determine the target detection strategy for the power material to be detected in response to the smart contract being triggered, the method further includes: determining a target detection node in the detection node of the blockchain network based on the target detection strategy; transferring the power material to be detected from the power material storage to the material detection equipment corresponding to the target detection node by the transportation node control material transfer equipment; and detecting the power material to be detected by the target detection node control material detection equipment.
[0049] The target detection strategy is used to determine the detection node for the safe detection of the power material to be detected in the detection node of the blockchain network. The target detection node is the detection node for the safe detection of the power material to be detected.
[0050] The power material detection system determines the target detection node in the detection node of the blockchain network based on the target detection strategy. The determination of the target detection node is equivalent to the determination of the transfer destination of the power material to be detected.
[0051] The power material detection system transfers the power material to be detected from the power material storage to the material detection equipment corresponding to the target detection node by the transportation node control material transfer equipment, and detects the power material to be detected by the target detection node control material detection equipment. The material transfer equipment corresponds to the transportation node in the blockchain network, and the material transfer equipment is used for transferring the power material. The material detection equipment corresponds to the detection node in the blockchain network, and the material detection equipment is used for the safe detection of the power material.
[0052] The technical scheme, in the disturbance detection of the local running environment, in the case that the disturbance is detected in the local running environment, the disturbance type is determined, and the disturbance is processed based on the disturbance type, so as to provide a stable running environment for subsequent detection node detection strategy game, and the accuracy of the target detection strategy is ensured.
[0053] Embodiment two
[0054] Figure 2is a flowchart of a blockchain-based power material detection method according to embodiment two. This embodiment is further optimized on the basis of the above-mentioned embodiment, and specifically, the operation "in response to the smart contract being triggered, the detection nodes in the blockchain network perform a detection strategy game to determine a target detection strategy for the power material to be detected" is refined.
[0055] As shown in Figure 2 , the method comprises:
[0056] S210, in response to receiving a power material detection task, determining, by a warehouse node, power material to be detected from a power material warehouse according to the power material detection task.
[0057] S220, generating, by the warehouse node, a power material transfer request for the power material to be detected, and sending the power material transfer request to a blockchain network to make a transport node in the blockchain network trigger a smart contract in the blockchain network.
[0058] S230, in response to the smart contract being triggered, determining a game role of a detection node in the blockchain network based on a local detection resource of the detection node.
[0059] Wherein, the local detection resource is used to determine the performance bottleneck of the detection node. The game role refers to the role of the detection node in the detection strategy game. The game role is used to determine the status of the detection node in the detection strategy game. Optionally, the game role includes a leader node and a follower node. Optionally, the detection node that reaches the performance bottleneck is determined as the leader node. The detection node participating in the detection strategy game except the leader node is determined as the follower node.
[0060] Wherein, the smart contract encapsulates a game interaction method adapted to the power material detection process. When the smart contract is triggered, the detection nodes in the blockchain network that meet the game conditions determine the role of the detection node in the detection strategy game based on the local detection resource of the detection node.
[0061] S240, performing, by the detection node, a detection strategy game based on the game role and using the local detection resource to determine the target detection strategy for the power material to be detected.
[0062] The detection nodes participating in the detection strategy game perform the detection strategy game based on their respective game roles and using the local detection resource to determine the target detection strategy for the power material to be detected. Optionally, the detection strategy game performed by the detection node is a non-cooperative subgame.
[0063] In an optional embodiment, the game roles include a leading node and a following node; accordingly, the method for determining the target detection strategy for the power material to be detected based on the game roles by the detection node using the local detection resource includes: determining the material detection strategy of the leading node as an initial detection strategy; generating a reference detection strategy based on the initial detection strategy by the following node; adjusting the initial detection strategy based on the reference detection strategy by the leading node to obtain a new detection strategy, and determining whether the new detection strategy meets a preset equilibrium condition; and determining the new detection strategy meeting the preset equilibrium condition as the target detection strategy.
[0064] The leading node is an organizer of the detection strategy game, and the following node is a participant of the detection strategy game. The position of the leading node in the detection strategy game is higher than that of the following node. The preset equilibrium condition is used to measure whether the detection strategy game reaches equilibrium. The preset equilibrium condition is determined according to actual business requirements, which is not limited here. For example, the preset equilibrium condition can be Nash equilibrium.
[0065] The initial detection strategy is provided by the leading node, and the reference detection strategy is provided by the following node based on the initial detection strategy. The reference detection strategy is used to adjust the initial detection strategy. Specifically, the leading node first provides a material detection strategy, the following node generates a reference detection strategy based on the initial detection strategy of the leading node, the leading node adjusts the initial detection strategy based on the reference detection strategy to obtain a new detection strategy, and determines whether the new detection strategy meets a preset equilibrium condition. The new detection strategy meeting the preset equilibrium condition is determined as the target detection strategy. It can be understood that the new detection strategy is more efficient than the initial detection strategy. The above technical solution guarantees the effectiveness of the target detection strategy, and provides data support for improving the detection efficiency of the power material.
[0066] In an optional embodiment, adjusting the initial detection strategy based on the reference detection strategy by the leading node to obtain a new detection strategy includes: determining strategy evaluation parameters of the initial detection strategy and the reference detection strategy, respectively; adjusting the initial detection strategy based on the strategy evaluation parameters by the leading node to obtain the new detection strategy; wherein the strategy evaluation parameters include at least one of detection time length, equipment idle rate, and detection energy consumption.
[0067] The policy evaluation parameter is used to measure the effectiveness of the detection policy. Specifically, the effectiveness of the reference detection policy and the initial detection policy. The policy evaluation parameter includes at least one of the detection duration, the equipment idle rate, and the detection energy consumption. The detection duration refers to the time required for the detection node to perform safety detection on the power material to be detected. The equipment idle rate refers to the idle rate of the material detection equipment corresponding to the detection node. The detection energy consumption refers to the energy consumed by the detection node to perform safety detection on the power material to be detected.
[0068] The leader node adjusts the initial detection policy based on the policy evaluation parameter to obtain a new detection policy. Optionally, the leader node adjusts the initial detection policy to obtain a new detection policy with the adjustment target of shortening the detection duration, reducing the equipment idle rate, and reducing the detection energy consumption, so that the new detection policy is more effective than the initial detection policy. The above technical solution adjusts the initial detection policy based on the policy evaluation parameter to obtain a new detection policy, which is beneficial to guarantee the effectiveness of the target detection policy and provides data support for improving the detection efficiency of power materials.
[0069] In a specific embodiment, a game interaction model adapted to the power material detection process is encapsulated in the smart contract of the blockchain network. Optionally, the game interaction model is a Stackelberg game model.
[0070] The game interaction model can be described as: {O1, O2,..., O i ,...,O n} represents n power materials to be detected, and {M1, M2,..., M i ,...,M m} represents m detection nodes that can perform safety detection. The power material to be detected O i contains n j detection procedures. M i,j ∈{1,2,...,M} represents the set of detection nodes available for the jth detection procedure of the power material to be detected O i . If the detection equipment M k ∈M i,j is selected to perform the jth detection procedure of the power material O i , the required detection time is t i,j,k .
[0071] The game interaction model is a two-layer game interaction model with one leader node at the upper layer and multiple follower nodes at the lower layer. Optionally, the detection node reaching the performance bottleneck is determined as the leader node. The detection nodes participating in the game of detection strategies other than the leader node are determined as the follower nodes. In each game interaction model, three elements are defined, i.e., the participating nodes, the detection strategies and the utility functions. Let M1, S1 and U1 represent the leader node, its detection strategy and utility function, respectively. Let M f , S f and U f represent the follower nodes and their detection strategies and utility functions, respectively.
[0072] The game interaction model of the leader node can be defined as a three-tuple:
[0073] G=((M1,M f ),(S1,S f ),(U1,U f ))
[0074] The utility function corresponds to the three optimization objectives in the coordination control model: the detection time length, the device idle rate and the detection energy consumption. The three optimization objectives mean that the tasks are distributed to each detection node as much as possible while consuming less time and lower energy.
[0075] The utility function is defined as follows:
[0076] MinU k =[CM k ,ε k ,E k ] T
[0077] s.t.C i,j ≥0,C i,j -C i,j-1 ≥t i,j,k *x i,j,k ,i=1,2,...,n;j=2,...,
[0078]
[0079] k∈[1,m],t∈[1,T k -1]
[0080] s.t represents the constraint condition, the constraint condition in the first row guarantees the logical sequence before and after different detection processes, and the jth detection process needs to be performed on the to-be-detected electric power resources O i before the (j-1)th detection process. i is the label of the to-be-detected electric power resources, and j is the label of the detection process. C i,j represents the to-be-detected electric power resources O iThe detection completion time of the jth detection process. i,j,k is a binary decision variable. The constraint in the second row ensures that each power material O i will only be assigned to one material detection device T k , and T k detection nodes participate in the strategy game, and t is the label of the material detection device corresponding to the detection node. The last constraint in the second row is used to ensure that the start time of the next detection task performed by the material detection device corresponding to the detection node must be after the completion of the current detection task.
[0081] In the process of game interaction, first, the leader node M1 provides the initial detection strategy, and then the follower node M f According to the initial detection strategy s1 of M1, a non-cooperative sub-game is played, and a reference detection strategy is generated, which constitutes a reference detection strategy set:
[0082]
[0083] Then, feedback to M1 for the next iteration until formula (4) (5) is satisfied, and the equilibrium solution of the game is s * = (s1 * , s f * )
[0084]
[0085]
[0086] where,
[0087] represents the decision-making process of the follower node according to the initial detection strategy of the leader node. The whole process is that the leader node makes the initial detection strategy first, and after the leader node makes the decision, the follower node makes the decision to generate the reference detection strategy according to the initial detection strategy of the leader node. Then the leader node adjusts the initial detection strategy according to the decision of the follower node, and so on, until the Nash equilibrium is reached. It is worth noting that in all formulas, the detection strategy with an asterisk represents the adjusted detection strategy, which means that the utility function of the leader node 1 is more efficient after adjusting S1.
[0088] which means that the utility function of the i-th follower node is more efficient after adjusting its original detection strategy.
[0089] which means Except for the i-th slave node, other slave nodes receive the initial detection strategy of the leader node to make a decision process.
[0090] In one specific embodiment, Figure 3 is a structural schematic diagram of a blockchain-based power material detection system provided according to an embodiment.
[0091] Referring to Figure 3 , the blockchain-based power material detection system includes power material detection resources, a blockchain detection unit, a blockchain network, and a smart contract. Among them, the power material detection resources mainly include three categories, namely, storage equipment, transfer equipment, and detection equipment. Through the application of multi-detection unit autonomous technology, the three categories of resources are installed with industrial computers that can record their own state and issue instructions, and then organized through the running mode of the multi-detection unit autonomous system. The storage equipment installed with the industrial computer can serve as a block node in the blockchain network, that is, the block unit for storage equipment in Figure 3 . The block unit for storage equipment corresponds to the storage node of the embodiment. The transfer equipment installed with the industrial computer can serve as a block node in the blockchain network, that is, the block unit for transfer equipment in Figure 3 . The block unit for transfer equipment corresponds to the transfer node of the embodiment. The detection equipment installed with the industrial computer can serve as a block node in the blockchain network, that is, the block unit for detection equipment in Figure 3 . The block unit for detection equipment corresponds to the detection node of the embodiment. It is worth noting that Figure 3 the transfer equipment and the detection equipment in correspond to the material transfer equipment and the material detection equipment in the above embodiment, respectively.
[0092] Embodiment Three
[0093] Figure 4 is a structural schematic diagram of a blockchain-based power material detection device provided by the third embodiment of the present application. The embodiment can be applicable to the case of safe detection of power materials. The device can be realized by software and / or hardware, and can be integrated into an electronic device such as a smart terminal.
[0094] As shown in Figure 4 , the device can include a to-be-detected power material determination module 410, a power material transfer request sending module 420, and a target detection strategy determination module 430.
[0095] The to-be-detected power material determination module 410 is configured to, in response to receiving a power material detection task, determine, by a storage node, to-be-detected power materials from power material storage according to the power material detection task;
[0096] The power material transfer request sending module 420 is configured to generate a power material transfer request for the to-be-detected power material through the warehouse node, and send the power material transfer request to a blockchain network, so that a transport node in the blockchain network triggers a smart contract in the blockchain network.
[0097] The target detection strategy determination module 430 is configured to, in response to the smart contract being triggered, perform a detection strategy game by a detection node in the blockchain network, and determine a target detection strategy for the to-be-detected power material.
[0098] The technical scheme of the embodiment of the application determines the to-be-detected power material through the warehouse node, generates a power material transfer request, notifies the transport node to trigger the smart contract in the blockchain network, so that the detection node in the blockchain network performs the detection strategy game in response to the smart contract being triggered, and determines the target detection strategy for the to-be-detected power material, thereby improving the automation level of the power material detection. From determining the to-be-detected power material to transferring the power material to the detection power material, the whole process of the power material detection does not need manual intervention, and the detection efficiency of the power material is effectively improved. The blockchain technology is applied to the power material detection in the embodiment of the application, and the data security of the power material is ensured.
[0099] Optionally, the target detection strategy determination module 430 includes: a current detection process determination sub-module configured to, in response to the smart contract being triggered, determine a current detection process of the to-be-detected power material; and a target detection strategy determination sub-module configured to select, based on a process to which a detection node belongs and the current detection process, the detection node belonging to a next detection process from the detection nodes in the blockchain network to perform the detection strategy game, and determine the target detection strategy for the to-be-detected power material.
[0100] Optionally, the target detection strategy determination module 430 includes: a game role determination sub-module configured to, in response to the smart contract being triggered, determine a game role of the detection node based on local detection resources of the detection node in the blockchain network; and a detection strategy game sub-module configured to perform, by the detection node, the detection strategy game based on the game role and using the local detection resources, and determine the target detection strategy for the to-be-detected power material.
[0101] Optionally, the game role includes a leader node and a follower node; and correspondingly, the detection strategy game submodule includes an initial detection strategy unit, configured to determine a detection strategy of the leader node as an initial detection strategy; a reference detection strategy generation unit, configured to generate a reference detection strategy based on the initial detection strategy by the follower node; a detection strategy adjustment unit, configured to adjust the initial detection strategy based on the reference detection strategy by the leader node to obtain a new detection strategy, and determine whether the new detection strategy satisfies a preset equilibrium condition; and a target detection strategy determination unit, configured to determine the new detection strategy satisfying the preset equilibrium condition as the target detection strategy.
[0102] Optionally, the detection strategy adjustment unit includes a strategy evaluation parameter determination subunit, configured to determine strategy evaluation parameters of the initial detection strategy and the reference detection strategy respectively; and a detection strategy adjustment subunit, configured to adjust the initial detection strategy based on the strategy evaluation parameters by the leader node to obtain the new detection strategy; wherein the strategy evaluation parameters include at least one of a detection duration, a device idle rate and a detection energy consumption.
[0103] Optionally, the device further includes a disturbance detection module, configured to perform disturbance detection on a local running environment by a block node in the blockchain network in response to the smart contract being triggered; wherein the block node includes a storage node, a transportation node and a detection node; and a disturbance processing module, configured to determine a disturbance type when it is detected that there is a disturbance in the local running environment, and process the disturbance based on the disturbance type.
[0104] Optionally, the device further includes a target detection node determination module, configured to determine a target detection node in the detection nodes of the blockchain network based on the target detection strategy after the detection node in the blockchain network performs detection strategy game to determine the target detection strategy for the power material to be detected in response to the smart contract being triggered; a power material transfer module, configured to control a material transfer device by the transportation node to transfer the power material to be detected from the power material storage to a material detection device corresponding to the target detection node; and a power material detection module, configured to control the material detection device to detect the power material to be detected by the target detection node.
[0105] The blockchain-based power material detection device provided by the embodiments can execute the blockchain-based power material detection method provided by any of the embodiments, and has the corresponding performance modules and beneficial effects of executing the blockchain-based power material detection method.
[0106] In the technical solutions of the present disclosure, the acquisition, storage and application of user personal information comply with relevant laws and regulations and do not violate public order and good customs.
[0107] Embodiment Five
[0108] Figure 5 A structural schematic diagram of an electronic device 510 that can be used to implement an embodiment is shown. The electronic device 510 includes at least one processor 511, and a memory, such as a read-only memory (ROM) 512, a random access memory (RAM) 513, etc., which is communicatively connected to the at least one processor 511. The memory stores a computer program that can be executed by the at least one processor. The processor 511 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 512 or loaded from the storage unit 518 into the random access memory (RAM) 513. In the RAM 513, various programs and data required for the operation of the electronic device 510 can also be stored. The processor 511, the ROM 512, and the RAM 513 are connected to each other through a bus 514. An input / output (I / O) interface 515 is also connected to the bus 514.
[0109] A plurality of components in the electronic device 510 are connected to the I / O interface 515, including an input unit 516, such as a keyboard, a mouse, etc.; an output unit 517, such as various types of displays, a loudspeaker, etc.; a storage unit 518, such as a magnetic disk, an optical disk, etc.; and a communication unit 519, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 519 allows the electronic device 510 to exchange information / data with other devices through a computer network, such as the Internet, and / or various telecommunication networks.
[0110] The processor 511 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the processor 511 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 511 performs various methods and processes described above, such as the blockchain-based power material detection method.
[0111] In some embodiments, the blockchain-based electric power material detection method can be implemented as a computer program tangibly embodied in a computer readable storage medium, e.g., storage unit 518. In some embodiments, parts or all of the computer program can be loaded and / or installed onto electronic device 510 via, e.g., ROM 512 and / or communication unit 519. When the computer program is loaded onto RAM 513 and executed by processor 511, one or more steps of the blockchain-based electric power material detection method described above can be performed. Alternatively, in other embodiments, processor 511 can be configured to perform the blockchain-based electric power material detection method by way of other any suitable means (e.g., by way of firmware).
[0112] Various implementations of the systems and techniques described above can be realized in digital electronic circuitry, integrated circuitry, a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on a chip (SOC), a complex programmable logic device (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.
[0113] Computer programs used to implement the methods of the present application can be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the computer program, when executed by the processor, implements the functions / acts specified in the flowcharts and / or block diagrams. The computer program can be executed entirely on a machine, partially on a machine, partially on a machine as part of a standalone software package, partially on a machine and partially on a remote machine or entirely on a remote machine or server.
[0114] In the context of this application, a computer readable storage medium can be a tangible medium that can contain or store computer programs for use by or in connection with an instruction execution system, apparatus, or device. Computer readable storage media can include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, a computer readable storage medium can be a machine readable signal medium. More specific examples of the machine readable storage medium will include a one or more lines of a electrical connection, a portable computer diskette, 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.
[0115] To provide for interaction with a user, the systems and techniques described here can be implemented on an electronic device having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the electronic device. Other kinds of devices can be used to provide for interaction with a user as well; for example, 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, speech, or tactile input.
[0116] The systems and techniques described here can be implemented in a computing system that includes a back end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front end component (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 here), or any combination of such back end, middleware, or front end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), blockchain networks, and the Internet.
[0117] The computing system can include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system, to solve the defects of large management difficulty and weak business scalability in traditional physical host and VPS service.
[0118] It should be understood that the various forms of flow shown above can be reordered, added to, or have steps deleted. For example, the steps described in this application can be performed in parallel, in series, or in a different order, as long as the desired results of the technical solutions of this application can be achieved, and this application does not limit herein.
[0119] The above detailed description does not constitute a limitation on the scope of protection of the present application. 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 replacements and improvements made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A blockchain-based power material detection method, characterized in that, The method comprises: in response to receiving the power material detection task, determining the power material to be detected from the power material storage according to the power material detection task through the storage node; generating a power material transfer request for the power material to be detected through the storage node, and sending the power material transfer request to the blockchain network, so that the transport node in the blockchain network triggers the smart contract in the blockchain network; in response to the smart contract being triggered, the detection node in the blockchain network carries out detection strategy game, and determines the target detection strategy for the power material to be detected; wherein, in response to the smart contract being triggered, the detection node in the blockchain network carries out detection strategy game, and determines the target detection strategy for the power material to be detected, comprising: in response to the smart contract being triggered, determining the current detection process of the power material to be detected; based on the detection node belonging to the process and the current detection process, selecting the detection node belonging to the next detection process from the detection nodes in the blockchain network to carry out detection strategy game, and determining the target detection strategy for the power material to be detected; wherein, if there are at least two detection processes with logical relationship, after determining the target detection strategy for the power material to be detected, return to execute the determination operation of the current detection process until the current detection process is the final detection process, then determine that the power material to be detected is detected, and the transport node is transported back to the storage node.
2. The method of claim 1, wherein, in response to the smart contract being triggered, the detection node in the blockchain network carries out detection strategy game, and determines the target detection strategy for the power material to be detected, comprising: in response to the smart contract being triggered, determining the game role of the detection node based on the local detection resource of the detection node in the blockchain network; by the detection node, based on the game role, using the local detection resource to carry out detection strategy game, and determining the target detection strategy for the power material to be detected.
3. The method of claim 2, wherein, the game role includes: leader node and follower node; accordingly, by the detection node, based on the game role, using the local detection resource to carry out detection strategy game, and determining the target detection strategy for the power material to be detected, comprising: determining the material detection strategy of the leader node as the initial detection strategy; generating a reference detection strategy through the follower node based on the initial detection strategy; adjusting the initial detection strategy based on the reference detection strategy to obtain a new detection strategy, and judging whether the new detection strategy meets the preset balance condition; determining the new detection strategy meeting the preset balance condition as the target detection strategy.
4. The method of claim 3, wherein, adjusting the initial detection strategy based on the reference detection strategy to obtain a new detection strategy by the leader node, comprising: determining the strategy evaluation parameters of the initial detection strategy and the reference detection strategy respectively; The leader node adjusts the initial detection strategy based on the policy evaluation parameter to obtain the new detection strategy; wherein the policy evaluation parameter comprises at least one of detection duration, equipment idle rate, and detection energy consumption.
5. The method of claim 1, wherein, The method further comprises: The block nodes in the blockchain network perform disturbance detection on the native runtime environment in response to the smart contract being triggered; wherein the block nodes comprise: a storage node, a transportation node, and a detection node; In the case where it is detected that there is disturbance in the native runtime environment, the type of disturbance is determined, and the disturbance is processed based on the type of disturbance.
6. The method of claim 1, wherein, After the detection node in the blockchain network determines the target detection strategy for the power material to be detected in response to the smart contract being triggered, the method further comprises: Based on the target detection strategy, a target detection node is determined in the detection node of the blockchain network; The transportation node controls the material transfer equipment to transfer the power material to be detected from the power material storage to the material detection equipment corresponding to the target detection node; The target detection node controls the material detection equipment to detect the power material to be detected. 7.A blockchain-based electric power material detection device, characterized by, The device comprises: A power material to be detected determination module for determining, by the storage node, the power material to be detected from the power material storage according to the power material detection task in response to receiving the power material detection task; A power material transfer request sending module for generating a power material transfer request for the power material to be detected by the storage node, and sending the power material transfer request to the blockchain network, so that the transportation node in the blockchain network triggers the smart contract in the blockchain network; A target detection strategy determination module for determining, by the detection node in the blockchain network, the target detection strategy for the power material to be detected in response to the smart contract being triggered; The target detection strategy determination module comprises: A current detection process determination submodule for determining the current detection process of the power material to be detected in response to the smart contract being triggered; A target detection strategy determination submodule for selecting the detection node belonging to the next detection process from the detection nodes of the blockchain network based on the detection process to which the detection node belongs and the current detection process, and performing detection strategy game for the target detection strategy determination module to determine the target detection strategy for the power material to be detected; If there are at least two detection processes with logical relationship, after the target detection strategy for the power material to be detected is determined, the determination operation of the current detection process is returned to be executed until the current detection process is the final detection process, then it is determined that the power material to be detected is detected, and the transportation node is used to transfer the detected power material to be detected back to the storage node.
8. A computer-readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the blockchain-based power material detection method of any one of claims 1-6.
9. An electronic device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, The processor implements the blockchain-based power material detection method according to any one of claims 1-6 when the processor executes the computer program.
Citation Information
Patent Citations
Production logistics management system and method based on block chain
CN114663012A