CN115866071A - Method and device for determining reporting path of initial equipment attribute information - Google Patents

Method and device for determining reporting path of initial equipment attribute information Download PDF

Info

Publication number
CN115866071A
CN115866071A CN202310174893.0A CN202310174893A CN115866071A CN 115866071 A CN115866071 A CN 115866071A CN 202310174893 A CN202310174893 A CN 202310174893A CN 115866071 A CN115866071 A CN 115866071A
Authority
CN
China
Prior art keywords
initial
processing chain
node
reporting processing
reporting
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.)
Pending
Application number
CN202310174893.0A
Other languages
Chinese (zh)
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.)
Citic Cloud Network Co ltd
Original Assignee
Citic Cloud Network 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 Citic Cloud Network Co ltd filed Critical Citic Cloud Network Co ltd
Priority to CN202310174893.0A priority Critical patent/CN115866071A/en
Publication of CN115866071A publication Critical patent/CN115866071A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention provides a method and a device for determining a reporting path of initial equipment attribute information, belonging to the technical field of Internet of things and comprising the following steps: determining initial reporting processing chains respectively corresponding to at least one upper-layer application, wherein a starting node of the initial reporting processing chain is a message platform, a destination node of the initial reporting processing chain is the upper-layer application, and at least one information processing node included in the initial reporting processing chain is used for processing initial equipment attribute information to obtain target equipment attribute information subscribed by the upper-layer application; and determining a target reporting processing chain based on the initial reporting processing chain, wherein the initial node of the target reporting processing chain is a message platform, the terminal node comprises at least one upper layer application, and the target reporting processing chain does not comprise a repeated path. According to the invention, by combining the repeated paths in the initial reporting processing chain, the initial equipment attribute information is quickly and effectively extracted from the mass equipment attributes and reported to the upper layer application, so that the resource loss is avoided and the production efficiency is improved.

Description

Method and device for determining reporting path of initial equipment attribute information
Technical Field
The invention relates to the technical field of Internet of things, in particular to a method and a device for determining a reporting path of initial equipment attribute information.
Background
In the field of internet of things, initial device attribute information in a message platform needs to be extracted to provide information for applications reported by upper layers depending on the device attribute information, and the reporting mode of the device attribute information is generally processed in such a way that every time an application is added, a whole amount of device attribute information is subscribed from an initial device attribute information queue, then the device attribute information is processed by a series of nodes (processing chains) again, and finally the device attribute information is transmitted to the upper layer applications.
When a plurality of processing chains exist, a large number of repeated processing processes of node equipment attribute information can be generated, so that the consumption and waste of computing resources are caused, and even hazards such as deadlock or resource exhaustion can be generated.
Therefore, how to provide a fast and effective method for reporting the initial device attribute information becomes a problem to be solved urgently.
Disclosure of Invention
The invention provides a method and a device for determining a reporting path of initial equipment attribute information, which are used for solving the defects of long time consumption and poor flexibility of an equipment attribute information extraction process caused by methods such as manual processing, equipment restarting and the like in the prior art, and realizing the purposes of quickly and effectively extracting the equipment attribute information and reporting the equipment attribute information to an upper layer application.
In a first aspect, the present invention provides a method for determining a reporting path of initial device attribute information, including:
determining initial reporting processing chains respectively corresponding to at least one upper-layer application, wherein a starting node of each initial reporting processing chain is a message platform where initial equipment attribute information is located, an end node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in each initial reporting processing chain is used for processing the initial equipment attribute information to obtain target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
and determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper-layer application, wherein a starting node of the target reporting processing chain is the message platform, an end node of the target reporting processing chain comprises the at least one upper-layer application, and the target reporting processing chain does not comprise a repeat path.
According to a method for determining a reporting path of initial device attribute information provided by the present invention, determining a target reporting processing chain based on initial reporting processing chains respectively corresponding to the at least one upper layer application includes:
and sequentially searching repeated paths for paths included in the initial reporting processing chain respectively corresponding to at least one upper-layer application, and combining the repeated paths under the condition that the repeated paths are searched until a target reporting processing chain not including the repeated paths is obtained.
According to a method for determining a reporting path of initial device attribute information provided by the present invention, determining a target reporting processing chain based on initial reporting processing chains respectively corresponding to the at least one upper layer application includes:
and acquiring a target reporting processing chain without the repeated path based on the nodes included in the initial reporting processing chain respectively corresponding to the depth-first search algorithm and the at least one upper-layer application.
According to the method for determining a reporting path of initial device attribute information provided by the present invention, before obtaining a target reporting processing chain that does not include a duplicate path, at a node included in an initial reporting processing chain corresponding to the at least one upper application based on a depth-first search algorithm, the method further includes:
and constructing an initial multi-branch tree, wherein the initial multi-branch tree is used for representing the initial reporting processing chain.
According to the method for determining the reporting path of the initial equipment attribute information, the establishment of the initial multi-branch tree comprises the following steps:
and taking nodes included in the initial reporting processing chain respectively corresponding to the at least one upper-layer application as nodes of an initial multi-branch tree, and constructing the initial multi-branch tree by directionally connecting the nodes of the initial multi-branch tree based on the time sequence relation among the nodes of the initial multi-branch tree.
According to the method for determining the reporting path of the initial device attribute information provided by the present invention, the obtaining of the target reporting processing chain not including the duplicate path based on the nodes included in the initial reporting processing chain respectively corresponding to the depth-first search algorithm and the at least one upper layer application comprises:
and sequentially performing recursive depth traversal and repeated node retrieval on the nodes of the initial multi-branch tree based on a tree depth-first traversal algorithm, and combining the repeated nodes under the condition that the repeated nodes are retrieved until a target multi-branch tree which does not include the repeated nodes is obtained, wherein the target multi-branch tree is used for representing the target reporting processing chain.
According to the method for determining the reporting path of the initial device attribute information provided by the invention, the method further comprises the following steps:
determining an initial reporting processing chain corresponding to a newly added upper layer application based on a subscription request of the newly added upper layer application, wherein the subscription request is used for subscribing target device attribute information corresponding to the newly added upper layer application;
and updating the target reporting processing chain based on the initial reporting processing chain corresponding to the newly added upper-layer application.
In a second aspect, the present invention further provides an apparatus for determining a reporting path of initial device attribute information, including:
a first determining module, configured to determine initial reporting processing chains corresponding to at least one upper-layer application, where a starting node of each initial reporting processing chain is a message platform where initial device attribute information is located, a destination node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in the initial reporting processing chain is configured to process the initial device attribute information to obtain target device attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
a second determining module, configured to determine a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper-layer application, where a starting node of the target reporting processing chain is the message platform, a destination node of the target reporting processing chain includes the at least one upper-layer application, and the target reporting processing chain does not include a duplicate path.
In a third aspect, the present invention further provides an electronic device, including a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor implements any one of the above methods for determining a reporting path of initial device attribute information when executing the program.
In a fourth aspect, the present invention further provides a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the method for determining a reporting path of initial device attribute information according to any one of the above methods.
According to the method and the device for determining the reporting path of the initial equipment attribute information, the initial equipment attribute information is processed through the information processing node to obtain the target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain, the target reporting processing chain without the repeated path is determined by combining the repeated paths in the initial reporting processing chain, the initial equipment attribute information is quickly and effectively extracted from mass equipment attributes and reported to the upper-layer application, information is timely provided for the upper-layer application, loss and waste of computing resources are avoided, and the production efficiency is improved.
Drawings
In order to more clearly illustrate the technical solutions of the present invention or the prior art, the drawings needed for the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and those skilled in the art can also obtain other drawings according to the drawings without creative efforts.
Fig. 1 is a schematic flow chart of a method for reporting initial device attribute information provided in the related art;
fig. 2 is a schematic flow diagram of a method for determining a reporting path of initial device attribute information according to the present invention;
FIG. 3 is a schematic structural diagram of a directed graph provided by the present invention;
fig. 4 is a second schematic flow chart of the method for determining a reporting path of initial device attribute information according to the present invention;
fig. 5 is a third schematic flow chart of a method for determining a reporting path of initial device attribute information according to the present invention;
fig. 6 is a fourth schematic flow chart of the method for determining a reporting path of initial device attribute information according to the present invention;
FIG. 7 is a schematic flow chart of combining duplicate paths using an optimal path algorithm according to the present invention;
FIG. 8 is a schematic diagram of a digital triangle formed by nodes of the device provided by the present invention;
FIG. 9 is a schematic diagram of a digital triangle using a dynamic programming algorithm for device nodes according to the present invention;
FIG. 10 is a schematic diagram of the structure of an initial multi-way tree provided by the present invention;
FIG. 11 is a schematic flow chart of generating nodes based on a tree depth-first traversal algorithm according to the present invention;
FIG. 12 is a structural diagram of a target multi-way tree provided by the present invention;
fig. 13 is a schematic structural diagram of a device for determining a reporting path of initial device attribute information according to the present invention;
fig. 14 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is obvious that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
First, the following is introduced:
in the field of internet of things, processing of reporting of mass device attributes is an important and tedious task, and in a related technology, processing of reporting of device attributes is performed in a manner that each time an application is added, a full quantity of device attributes are subscribed from an original attribute queue, then a series of node (processing chain) processing is performed again, such as transcoding, filtering, conversion (new information nodes are calculated through device attribute information statistics), and finally the new information nodes are transmitted to an upper layer application.
Fig. 1 is a schematic flow chart of a method for reporting initial device attribute information provided in the related art, and as shown in fig. 1, initial device attribute information in a message platform may be extracted first.
Optionally, a reporting processing chain corresponding to the application a may be determined, where a starting node of the reporting processing chain may be a message platform, and a destination node may be the application a;
optionally, the processing node of the reporting processing chain may include a reset (Representational State Transfer) interface;
optionally, the processing node may be configured to process the initial device attribute information, calculate a new information node by counting the initial device attribute information, obtain the target device attribute information subscribed by the application a, and finally transmit the target device attribute information to the application a.
Optionally, a reporting processing chain corresponding to the application B may be determined, where a starting node of the reporting processing chain may be a message platform, and a destination node may be the application B;
optionally, the processing node of the reporting processing chain may include: an API (Application Programming Interface) Interface for device attribute transcoding and output nodes;
optionally, the processing node may be configured to process the initial device attribute information, perform device attribute transcoding on the initial device attribute information, calculate a new information node by counting the initial device attribute information, obtain target device attribute information subscribed by the application B, and finally transmit the target device attribute information to the application B.
Optionally, a reporting processing chain corresponding to the application C may be determined, where a starting node of the reporting processing chain may be a message platform, and a destination node may be the application C;
optionally, the processing node of the reporting processing chain may include: equipment attribute transcoding, equipment attribute filtering and an output node API interface;
optionally, the processing node may be configured to process the initial device attribute information, perform device attribute transcoding and filtering on the initial device attribute information, calculate a new information node by counting the initial device attribute information, obtain target device attribute information subscribed by the application C, and finally transmit the target device attribute information to the application C.
Optionally, a reporting processing chain corresponding to the application D may be determined, where a starting node of the reporting processing chain may be a message platform, and a destination node may be the application D;
optionally, the processing node of the reporting processing chain may include: equipment attribute transcoding, equipment attribute filtering and an output node API (application program interface);
optionally, the processing node may be configured to process the initial device attribute information, perform device attribute transcoding and filtering on the initial device attribute information, calculate a new information node by counting the initial device attribute information, obtain target device attribute information subscribed by the application D, and finally transmit the target device attribute information to the application D.
Optionally, a reporting processing chain corresponding to different upper layer applications may be determined, where a starting node of the reporting processing chain may be a message platform, and a destination node may be the upper layer application;
optionally, the processing node of the reporting processing chain may include: device attribute transcoding, device attribute grouping, device attribute storage, device attribute filtering, device attribute sorting, interrupt processing, normalization processing, output node API interface and the like;
optionally, the processing node may be configured to process the initial device attribute information, perform device attribute transcoding and filtering on the initial device attribute information, calculate a new information node by counting the initial device attribute information, obtain target device attribute information subscribed by the upper application, and finally transmit the target device attribute information to the upper application.
In order to effectively extract the initial device attribute information, the related technology mainly depends on intervention methods such as manual processing and device restarting, and is long in time consumption, high in cost and poor in flexibility in the extraction process of the initial device attribute information.
The method starts from the edge side of the Internet of things, integrates various algorithm technologies such as dynamic planning and deep learning, solves the defects of long time consumption, high cost, poor flexibility and the like in the process of extracting the equipment attributes by combining the repeated paths in the initial reporting processing chain, avoids repeated processing of equipment nodes, extracts the optimal path based on the basic principle of a directed acyclic graph, completes the processing process of reporting the equipment attributes, provides information for upper-layer application in time, avoids the loss and waste of computing resources and improves the production efficiency.
The invention determines the target reporting processing chain without the repeated path by combining the repeated paths in the initial reporting processing chain, solves the defects of long time consumption and poor flexibility of the equipment attribute information extraction process caused by methods such as manual processing, equipment restarting and the like in the prior art, and realizes the quick and effective extraction of the equipment attribute information and the reporting to the upper layer application.
The following is explained in detail based on a plurality of embodiments.
Fig. 2 is a schematic flowchart of a method for determining a reporting path of initial device attribute information according to the present invention, as shown in fig. 2, the method includes the following steps:
200, determining initial reporting processing chains corresponding to at least one upper-layer application respectively, wherein a starting node of each initial reporting processing chain is a message platform where initial equipment attribute information is located, an end node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in each initial reporting processing chain is used for processing the initial equipment attribute information to obtain information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
step 210, determining a target reporting processing chain based on the initial reporting processing chain corresponding to each of the at least one upper layer application, where a starting node of the target reporting processing chain is the message platform, an end node of the target reporting processing chain includes the at least one upper layer application, and the target reporting processing chain does not include a repeated path.
Optionally, the upper layer application may be an internet of things application for direct use by a user.
Optionally, the upper layer application may include: the present invention is not limited to the above applications, but may be applied to intelligent control, security, power meter reading, remote medical, and intelligent agriculture.
Optionally, the initial reporting processing chain starting node may be a message platform where the initial device attribute information is located.
Optionally, the end node of the initial reporting processing chain may be an upper layer application corresponding to the initial reporting processing chain.
Optionally, the message platform may be an internet of things cloud platform.
Optionally, the initial reporting processing chain may include at least one information processing node.
Alternatively, the information processing node may include: the device attribute transcoding, or the device attribute grouping, or the device attribute storage, or the device attribute filtering, or the device attribute sorting, or the interrupt processing, or the normalization processing, or the output node Rest interface, or the output node API interface, or the output node Dubbo interface, and the like, which is not limited in this invention.
Alternatively, device attribute transcoding may be a conversion between different encodings for converting the original device information to another format.
Alternatively, device attribute filtering may filter initial device attribute information that is not needed by upper layer applications.
Alternatively, rest may be a World Wide Web (World Wide Web) communication protocol.
Optionally, the Rest interface may provide simple and easy-to-use API call services for third-party applications, and third-party developers may integrate APIs to realize mutual communication between computer software.
Alternatively, an API may be a set of definitions, procedures and protocols for enabling intercommunication between computer software.
Alternatively, the API may be a kind of middleware for implementing data sharing between various platforms.
Alternatively, the Dubbo interface may be a distributed Service framework for providing a high-performance and transparent Remote Procedure Call (RPC) scheme and a Service-Oriented Architecture (SOA) scheme.
Optionally, the information processing node may be configured to process the initial device attribute information to obtain information subscribed by an upper application corresponding to the initial reporting processing chain.
Optionally, the information processing node may transcode and filter the device attribute of the initial device attribute information, calculate a new information node by counting the initial device attribute information, obtain the target device attribute information subscribed by the upper application, and finally transmit the target device attribute information to the upper application.
Optionally, the duplicate paths of the initial reporting processing chain may be merged, and a target reporting processing chain that does not include the duplicate paths may be obtained.
Optionally, the starting node of the target reporting processing chain may be a message platform.
Optionally, the end node of the target reporting processing chain may include at least one upper layer application.
Fig. 3 is a schematic structural diagram of a directed graph provided by the present invention, and as shown in fig. 3, a data structure between objects may be represented.
Alternatively, the data structure may be made up of a plurality of vertices and edges between the vertices.
Alternatively, if all edges in the data structure are undirected (bidirectional), the graph formed by the data structure may be referred to as an undirected graph;
alternatively, if all edges in the data structure are directed (unidirectional), the graph formed by the data structure may be referred to as a directed graph;
alternatively, if there are both undirected edges and directed edges in the data structure, the graph formed by the data structure may be referred to as a hybrid graph.
Alternatively, a path may be a sequence of alternating vertices and edges, which may represent the vertices and edges that pass through to transition from one vertex to another.
Fig. 4 is a second flowchart of the method for determining a reporting path of initial device attribute information according to the present invention.
Alternatively, the initial device attribute information node in the message platform may be defined as the start node V0.
Alternatively, each subsequent information processing node may be defined as Vi.
Alternatively, all nodes may form a set V.
Alternatively, if there is a context between two nodes Vi and Vj, then a directed edge ei (Vi, vj) may be defined, and all directed edges may form a set E.
Alternatively, fig. 4 may represent a node processing flow of the initial device attribute information, and as shown in fig. 4, the set V may be { V0, V1, V2, V3, V4, V5, …, vn }, and the set E may be { E1 (V0, V1), E2 (V0, V2), E3 (V2, V3), E4 (V0, V2), E5 (V2, V4), E6 (V4, V5), …, en (Vn-1, vn) }.
Fig. 5 is a third flowchart of the method for determining a reporting path of initial device attribute information according to the present invention, where as shown in fig. 5, three initial reporting processing chains exist.
Optionally, the directed edges of the three initial reporting processing chains in fig. 5 may be { (V0, V2), (V2, V6) }; { (V0, V2), (V2, V3), (V3, V4) }; { (V0, V2), (V2, V3), (V3, V5) }.
Alternatively, a set formed by directional edges of the three initial reporting processing chains in fig. 5 may be { (V0, V2), (V2, V6), (V0, V2), (V2, V3), (V3, V4), (V0, V2), (V2, V3), (V3, V5) }, where the repeated path is: (V0, V2) and (V2, V3).
Fig. 6 is a fourth schematic flowchart of the method for determining a reporting path of initial device attribute information according to the present invention, and fig. 6 may show a target reporting processing chain formed after algorithm processing.
Optionally, the directional edges of the three target reporting processing chains in fig. 6 may be { (V0, V2), (V2, V6) }; { (V2, V3), (V3, V4) }; { (V3, V5) }.
Alternatively, in the case of merging the duplicate paths (V0, V2) and (V2, V3), the set of directed edges of the three target reporting processing chains in fig. 6 may be { (V0, V2), (V2, V6), (V2, V3), (V3, V4), (V3, V5) }.
The method for determining the reporting path of the initial equipment attribute information processes the initial equipment attribute information through the information processing node to obtain the target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain, determines the target reporting processing chain without the repeated path by combining the repeated paths in the initial reporting processing chain, realizes the purpose of quickly and effectively extracting the initial equipment attribute information from mass equipment attributes and reporting the initial equipment attribute information to the upper-layer application, provides information for the upper-layer application in time, avoids the loss and waste of computing resources and improves the production efficiency.
Optionally, the determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper layer application includes:
and sequentially searching repeated paths for paths included in the initial reporting processing chain respectively corresponding to at least one upper-layer application, and combining the repeated paths under the condition that the repeated paths are searched until a target reporting processing chain not including the repeated paths is obtained.
Alternatively, the number of upper layer applications may be one, or two, or six, which is not limited by the present invention.
Optionally, an upper layer application may correspond to an initial reporting processing chain.
Optionally, an initial reporting processing chain may include one path, two paths, or five paths, which is not limited in the present invention.
Optionally, in a case that a duplicate path in paths included in all the initial reporting processing chains is merged, the target reporting processing chain may include the initial reporting processing chain after merging the duplicate path.
Optionally, based on an optimal path algorithm, a scene is acquired at an edge side of the internet of things by combining initial equipment attribute information in actual production, and a topological sorting, a Depth-First-Searching (DFS), a Breadth-First-Searching (BFS), a Floyd-Warshall algorithm (freouard algorithm), a Dijkstra algorithm (dixtra algorithm), a Prim-Jarnik algorithm (Prim algorithm), an Ant Colony Algorithm (ACO), a simulated annealing algorithm and a genetic algorithm are fused, all initial reporting processing chains are processed in a circulating manner, an optimal path is planned, and repeated paths are combined until a target reporting processing chain not including the repeated paths is acquired.
Fig. 7 is a schematic flow chart of merging duplicate paths by using an optimal path algorithm according to the present invention, and as shown in fig. 7, if a path from a node Vi to a node V0 has the same path in a subsequent processing chain, it may be determined that the path from the node Vi to the node V0 is a duplicate path, and the duplicate paths may be merged until all processing chains are retrieved, so as to obtain a target reporting processing chain that does not include the duplicate path.
Alternatively, one processing chain may be selected from all processing chains, and the repeated path retrieval may be performed starting from the 2 nd node of the processing chain.
Alternatively, it may be determined first whether the path from V0 to the 2 nd node in the processing chain exists the same path in the subsequent processing chain.
Alternatively, if the path from V0 to the 2 nd node has the same path in the subsequent processing chain, the repeated paths may be merged, and then the processing chain may be moved to the 3 rd node of the processing chain for subsequent determination.
Alternatively, if the path from V0 to the 2 nd node does not have the same path in the subsequent processing chain, the node may move to the 3 rd node of the processing chain to perform subsequent determination.
Alternatively, it may be determined whether there is a 3 rd node and a duplicate path in the processing chain.
Alternatively, if there is a 3 rd node and a duplicate path in the processing chain, it may be determined whether the path from V0 to the 3 rd node in the processing chain has the same path in the subsequent processing chain.
Alternatively, if the path from V0 to the 3 rd node has the same path in the subsequent processing chain, the repeated paths may be merged, and then the processing chain may move to the 4 th node of the processing chain for subsequent determination.
Alternatively, if the path from V0 to the 3 rd node does not have the same path in the subsequent processing chain, the node may move to the 4 th node of the processing chain to perform subsequent determination.
Alternatively, if there is no 4 th node in the processing chain and no duplicate path, the next processing chain may be processed.
Alternatively, if there is a 4 th node in the processing chain but no duplicate path, the next processing chain may be processed.
Alternatively, it may be determined whether there is a next processing chain.
Alternatively, if there is a next processing chain, another processing chain may be selected from all the processing chains, and the duplicate path search may be performed starting from the 2 nd node of the processing chain until a target reporting processing chain that does not include the duplicate path is obtained.
Optionally, if there is no next processing chain, the retrieval of the duplicate path may be ended, and a target reporting processing chain that does not include the duplicate path is obtained.
Alternatively, if there are two paths: v0 → V1 → V3, V0 → V1 → V2 → V4, then the merging of the repeated paths may be deleting the path (V0, V1) in the second path, reconstructing the path (V1, V2), and after processing, finally forming a directed acyclic graph, that is, a target reporting processing chain without the repeated path.
The method for determining the reporting path of the initial equipment attribute information provided by the invention can be used for rapidly and effectively extracting the initial equipment attribute information from mass equipment attributes and reporting the initial equipment attribute information to an upper-layer application by combining the repeated paths through sequentially searching the repeated paths included by all the initial reporting processing chains under the condition that the repeated paths are searched until a target reporting processing chain not including the repeated paths is obtained, so that the information is provided for the upper-layer application in time, the loss and waste of computing resources are avoided, and the production efficiency is improved.
Optionally, the determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper layer application includes:
and acquiring a target reporting processing chain which does not comprise the repeated path based on the nodes which are respectively included in the initial reporting processing chain corresponding to the depth-first search algorithm and the at least one upper layer application.
Optionally, the repeated paths may be retrieved and combined and repeated based on a depth-first search algorithm and nodes included in the initial reporting processing chain respectively corresponding to all upper-layer applications, so as to obtain a target reporting processing chain not including the repeated paths.
Alternatively, a depth first search algorithm may be used to detect whether one vertex can lead to another vertex.
Alternatively, a depth-first search algorithm may be used to detect whether a directed graph is a connected graph.
Alternatively, when one of the vertices is visited, the vertex may be marked as visited;
alternatively, all the unlabeled adjacent vertices of the vertex can be recursively accessed, and whether a ring exists in the directed graph can be determined by recursively searching for a path in the directed graph and finding a connected component.
For example, the process of detecting by the depth-first search algorithm may be similar to a process of drawing a rope to go into a maze, one corner may be a vertex, when a dead angle is reached, the dead angle is recorded, and a next corner may be searched along a route of the rope.
Alternatively, a recursive idea may be introduced in the depth-first search algorithm, such as cutting out multiple rope ends for searching in different directions every corner.
Optionally, the depth first search algorithm may be modified to:
Algorithm DFS(U, Visited, path):
Input: The point of search origin U, object Visited recording visited vertices, and path started from Vertex.
Output: N/A.
call process(U, path) # code block for processing vertex, i.e. export path or break recursion.
for each downstream neighbor V near U do
 if V not in Visited then
  add V into Visited and path
  recursively call DFS(V, Visited, path)
optionally, the breadth-first search algorithm may divide the vertices into different levels, and check the vertices layer by layer, where the basis of the level may be the number of edges included in the path.
Alternatively, the breadth-first search algorithm may guarantee that the retrieved path between two vertices is shortest in number of edges, as opposed to the depth-first search algorithm.
Alternatively, the breadth-first search algorithm may be:
Algorithm BFS(U):
 Input: The point of search origin U.
 Output: N/A.
 initialize queue level which includes the initial vertex U
 initialize queue next_level in concern of address of vertices in the next level
 initialize array visited recording visited vertices
 while level is non-empty do
 for each vertax V in level do
  call process(V)   # code block for processing vertex, i.e. export path or break
  add unvisited neighbors of V into next_level and visited
 replace the vertices in level with the ones in next_level
 empty next
optionally, the nodes included in the initial reporting processing chains respectively corresponding to all upper-layer applications may be subjected to topology sorting, repeated paths are retrieved, and the repeated paths are combined and repeated, so as to obtain a target reporting processing chain not including the repeated paths.
Optionally, the optimal path may be searched based on nodes included in the initial reporting processing chains respectively corresponding to all upper-layer applications, the repeated paths are retrieved, and the repeated paths are combined and repeated, so as to obtain a target reporting processing chain that does not include the repeated paths.
Alternatively, in the case that the data structure diagram is a directed acyclic graph, as shown in fig. 3, the topological ordering may include uniformly ordering all vertices Vi (i = 1.., n) in the graph, obtaining a directed edge Va → Vb (a < b).
Optionally, when obtaining the initial device attribute information, if the processing object is a Directed Acyclic Graph (DAG), the DAG may be converted into an ordered list by using a topological sorting algorithm.
For example, G = (V, E) may be set as a directed graph with n vertices, the sequence of vertices in V is V1, V2, …, vn, the sequence may be referred to as a topological sequence, if and only if the sequence satisfies the following condition: if there is a path from vertex Vi to Vj in directed graph G, vertex Vi must be ranked before vertex Vj in the sequence.
Alternatively, topological sorting can speed up the retrieval of duplicate paths, while the upstream and downstream locations between two vertices can be quickly obtained.
Alternatively, the topology-ordered application scenario may include context of information processing nodes, inheritance between information processing nodes, and scheduling relationship of upper-layer applications.
Optionally, a directed acyclic graph may have one topological rank result, or five topological rank results, which is not limited in the present invention.
Alternatively, based on iteration, the topological sorting algorithm may pull out vertices without incomes (without upstream vertices) from the original acyclic graph and put them into a queue until all vertices are sorted.
Alternatively, the pseudo code for topological ordering may be as follows:
Algorithm Topological_Sort(Graph):
 Input: A directed and acyclic graph Graph.
 Output: Topological sorting array of vertex objects.
 initiate empty array sort
 while Graph is not empty do
  extract vertices with 0 in-degree from Graph to sort
 return sort
fig. 8 is a schematic diagram of a digital triangle formed by the nodes of the equipment provided by the invention, and the digital triangle has five layers of numbers as shown in fig. 8.
Alternatively, a path from the top to the bottom may be obtained in the digital triangle formed by the device nodes of fig. 8, so that the sum of the numbers passed on the path is maximized.
Optionally, a device node dynamic planning algorithm may be adopted to avoid repeated calculation of a device node path.
Alternatively, the device node may be an information processing node.
Optionally, the node path may be decomposed layer by using the array elements to store the node information of the device, defining the relational expression between the array elements.
For example, a node path may be decomposed into: dp [ n ] = dp [ n-1] + dp [ n-2], dp [ n-1] and dp [ n-2] can be the upper-level path of dp [ n ], and all node paths are decomposed until dp [1] = 1, dp [2] = 2 is obtained.
FIG. 9 is a schematic diagram of a digital triangle using a device node dynamic programming algorithm provided by the present invention, as shown in FIG. 9, in the case where n =5, dp [5] can be decomposed into dp [4] and dp [3], dp [4] can be decomposed into dp [3] and dp [2], and dp [3] can be decomposed into dp [2] and dp [1].
Alternatively, a path from the top to the bottom may be obtained in a digital triangle formed by the device nodes of fig. 9, so that the sum of numbers passed on the path is maximized.
Alternatively, a recursive approach may be used to traverse each path deeply, in which case there are a large number of iterations and the temporal complexity may be
Figure SMS_1
In>
Figure SMS_2
May result in a request timeout.
Optionally, each MaxSum (r, j) may be calculated and stored, and the MaxSum (r, j) may be directly used next time, so that repeated calculation may be avoided, and the calculation time may be set to
Figure SMS_3
The total number of triangle numbers can be->
Figure SMS_4
According to the method for determining the reporting path of the initial equipment attribute information, provided by the invention, the optimal path is searched by applying the depth-first search algorithm to all nodes until a target reporting processing chain without the repeated path is obtained, and the repeated calculation of the information processing nodes is avoided by combining the repeated paths, so that the calculation time is saved, and the equipment attribute information reporting efficiency is improved.
Optionally, before obtaining a target reporting processing chain that does not include a duplicate path, by a node included in an initial reporting processing chain corresponding to the depth-first search algorithm and the at least one upper-layer application, the method further includes:
and constructing an initial multi-branch tree, wherein the initial multi-branch tree is used for representing the initial reporting processing chain.
Optionally, there is one data item per node in the multi-way tree.
Optionally, there are three, or five, or eleven child nodes per node in the multi-way tree.
Optionally, before obtaining a target reporting processing chain that does not include a repeated path based on a node included in an initial reporting processing chain corresponding to the depth-first search algorithm and the at least one upper-layer application, an initial multi-way tree may be constructed based on the initial reporting processing chain.
The method for determining the reporting path of the initial equipment attribute information constructs the initial multi-branch tree based on the initial reporting processing chain and prepares for subsequently acquiring the target multi-branch tree.
Optionally, the constructing an initial multi-way tree includes:
and taking nodes included in the initial reporting processing chain respectively corresponding to the at least one upper-layer application as nodes of an initial multi-branch tree, and constructing the initial multi-branch tree by directionally connecting the nodes of the initial multi-branch tree based on the time sequence relation among the nodes of the initial multi-branch tree.
Alternatively, the starting node of the initial reporting processing chain may be used as the starting node of the initial multi-way tree.
Alternatively, the end node of the initial reporting processing chain may be used as the end node of the initial multi-way tree.
Alternatively, the starting node of the initial multi-way tree may be defined as V0.
Optionally, the node of each subsequent initial multi-way tree can be defined as Vi.
Alternatively, all the nodes of the initial multi-way tree may form a set V.
Alternatively, if there is a context between two nodes Vi and Vj, then a directed edge ei (Vi, vj) may be defined, and all directed edges may constitute a set E.
Fig. 10 is a schematic structural diagram of the initial multi-way tree provided by the present invention, and as shown in fig. 10, the set V may be { V0, V1, V2, V3, V4, V5 }, and the set E may be { E1 (V0, V1), E2 (V0, V2), E3 (V2, V3), E4 (V0, V2), E5 (V2, V4), E6 (V4, V5) }.
Alternatively, the Floyd-Warshall algorithm may be an algorithm that resolves the shortest path between any two points.
Alternatively, the Floyd-Warshall algorithm may be used in any graph, such as a directed graph, or a graph with negative weighted edges.
Alternatively, the Floyd-Warshall algorithm may be used to pass closures.
Alternatively, a depth-first search or a breadth-first search may be performed from the beginning each time two vertices are retrieved for reachability.
Alternatively, in the case where it is not desirable to perform depth-first search or breadth-first search from the beginning each time, the Floyd-Warshall algorithm may be used for information enhancement to speed up subsequent retrieval.
Optionally, at each iteration, the Floyd-Warshall algorithm can link all the Vk-1 → Vk → Vk +1 Vk-1 and Vk +1 meeting the reachability requirement separately to construct a new edge Vk-1 → Vk +1.
Alternatively, after a number of iterations, all accessible pairs (Va, vb) can be directly connected and the shortest distance in all paths between two points can be obtained.
Alternatively, the pseudo-code of the Floyd-Warshall algorithm may be as follows:
Algorithm Floyd_Warshall(Graph, max_iter):
Input: A graph Graph either unweighted or weighted.
Output: Transitive closure of Graph.
for each epoch in {1,…,max_iter} do
 for each vertex V in Graph do
  for each pair (Va,Vb) in Graph with Va,Vb = V do
   if both edge (Va->V) and edge (V>Vb) are in Graph then
    add the bridge (Va->Vb) as new edge into Graph # if it’s not already present
   else
    replace existing edge weight if the bridge implies a shorter path
return Graph
the method for determining the reporting path of the initial equipment attribute information provided by the invention realizes the construction of the initial multi-branch tree by taking the nodes included in the initial reporting processing chain respectively corresponding to at least one upper-layer application as the nodes of the initial multi-branch tree and directionally connecting the nodes of the initial multi-branch tree based on the time sequence relation among the nodes of the initial multi-branch tree, thereby preparing for obtaining the target multi-branch tree subsequently.
Optionally, the obtaining, based on the depth-first search algorithm and the node included in the initial reporting processing chain corresponding to the at least one upper-layer application, a target reporting processing chain that does not include the duplicate path includes:
and sequentially performing recursive depth traversal and repeated node retrieval on the nodes of the initial multi-branch tree based on a tree depth-first traversal algorithm, and combining the repeated nodes under the condition that the repeated nodes are retrieved until a target multi-branch tree which does not include the repeated nodes is obtained, wherein the target multi-branch tree is used for representing the target reporting processing chain.
Alternatively, based on the tree depth-first traversal algorithm, the nodes of the initial multi-way tree may be sequentially subjected to recursive depth traversal along the depth of the initial multi-way tree.
Alternatively, in the case of sequentially performing recursive depth traversal on the nodes of the initial multi-way tree, repeated node retrieval may be performed on the nodes of the initial multi-way tree.
Alternatively, where duplicate nodes are retrieved, the duplicate nodes of the initial multi-way tree may be merged until a target multi-way tree is obtained that does not include duplicate nodes.
Fig. 11 is a schematic flow diagram of generating a node based on a tree depth-first traversal algorithm provided by the present invention, and as shown in fig. 11, the node may be set as a current node from a start node V0 of an initial multi-way tree, recursive depth traversal may be performed on the initial multi-way tree, and then the start node V0 may be retrieved to determine whether the start node V0 has been accessed.
Alternatively, if the start node V0 is accessed, the next adjacent point of the start node V0 may be set as the current node.
Alternatively, it may be determined whether the next adjacent point exists at the start node V0.
Alternatively, if the next adjacent point (node V1) exists at the starting node V0, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V1 may be retrieved to determine whether the node V1 has been accessed.
Alternatively, if the node V1 is visited, the next adjacent point of the node V1 may be set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V1.
Alternatively, if there is a next adjacent point (node V2) in the node V1, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V2 may be retrieved to determine whether the node V2 has been accessed.
Alternatively, if the node V2 has not been accessed, the node V2 may be output, and then the recursive deep traversal of the initial multi-way tree is continued, and the next adjacent point of the node V2 is set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V2.
Optionally, if the node V2 does not have a next adjacent point, the start node V0 may be set as the current node, recursive deep traversal may be performed on the initial multi-way tree, and then the start node V0 may be retrieved to determine whether the start node V0 has been accessed.
Alternatively, if the start node V0 is accessed, the next adjacent point of the start node V0 may be set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the start node V0.
Alternatively, if the next adjacent point (node V3) exists at the starting node V0, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V3 may be retrieved to determine whether the node V3 has been accessed.
Alternatively, if the node V3 is visited, the next adjacent point of the starting node V3 may be set as the current node.
Alternatively, it may be determined whether the next adjacent point exists at the start node V3.
Optionally, if the node V3 does not have a next adjacent point, the start node V0 may be set as the current node, recursive deep traversal may be performed on the initial multi-way tree, and then the start node V0 may be retrieved to determine whether the start node V0 has been accessed.
Alternatively, in the case where the start node V0 has been accessed, the next adjacent point of the start node V0 may be set as the current node.
Alternatively, it may be determined whether the next adjacent point exists at the start node V0.
Optionally, if the node V0 does not have a next adjacent point, the recursive depth traversal and the repeated node search of the initial multi-way tree may be finished, and based on the output nodes and their timing relationships, the target multi-way tree is obtained by directionally connecting all the output nodes.
Fig. 12 is a schematic structural diagram of a target multi-way tree provided by the present invention, and as shown in fig. 12, a starting node V0 may be set as a current node from a starting node V0 of an initial multi-way tree, recursive deep traversal may be performed on the initial multi-way tree, and then the starting node V0 may be retrieved to determine whether the starting node V0 has been accessed.
Alternatively, in the case that the start node V0 has not been accessed, the start node V0 may be output, and then the recursive deep traversal of the initial multi-way tree is continued, and the next adjacent point of the start node V0 is set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the start node V0.
Optionally, in a case that a next adjacent point (node V1) exists in the starting node V0, the node V1 is set as the current node, the recursive deep traversal may be continued on the initial multi-way tree, and then the node V1 may be retrieved to determine whether the node V1 has been accessed.
Alternatively, in the case that the node V1 has not been accessed, the node V1 may be output, and then the recursive deep traversal of the initial multi-way tree is continued, and the next adjacent point of the node V1 is set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V1.
Optionally, in a case that the node V1 does not have a next adjacent point, the start node V0 may be set as the current node, the initial multi-way tree may be subjected to recursive deep traversal, and then the start node V0 may be retrieved to determine whether the start node V0 has been accessed.
Alternatively, in the case where the start node V0 has been accessed, the next adjacent point of the start node V0 may be set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the start node V0.
Alternatively, in the case that the next adjacent point (node V2) exists at the starting node V0, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V2 may be retrieved to determine whether the node V2 has been visited.
Alternatively, in the case that the node V2 is not accessed, the node V2 may be output, and then the recursive depth traversal of the initial multi-way tree is continued, and the next adjacent point of the node V2 is set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V2.
Alternatively, in the case that the next adjacent point (node V3) exists in the node V2, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V3 may be retrieved to determine whether the node V3 has been visited.
Alternatively, in the case that the node V3 has not been accessed, the node V3 may be output, and then the recursive deep traversal of the initial multi-way tree is continued, and the next adjacent point of the node V3 is set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V3.
Alternatively, in the case that the node V3 does not have the next adjacent point, the start node V0 may be set as the current node, the initial multi-way tree may be subjected to recursive deep traversal, and then the start node V0 may be retrieved to determine whether the start node V0 has been accessed.
Alternatively, in a case where the start node V0 is accessed, the next adjacent point of the start node V0 may be set as the current node.
Alternatively, it may be determined whether the next adjacent point exists at the start node V0.
Alternatively, in the case where the next adjacent point (node V2) exists at the starting node V0, a recursive deep traversal may be performed on the initial multi-way tree, and then the node V2 may be retrieved to determine whether the node V2 has been visited.
Alternatively, in the case where the node V2 has been visited, the next adjacent point of the node V2 may be set as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V2.
Alternatively, in the case that the next adjacent point (node V4) exists in the node V2, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V4 may be retrieved to determine whether the node V4 has been visited.
Alternatively, in the case that the node V4 has not been accessed, the node V4 may be output, and then the recursive deep traversal of the initial multi-way tree is continued to set the next adjacent point of the node V4 as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V4.
Alternatively, in the case that the next adjacent point (node V5) exists at the node V4, the recursive deep traversal of the initial multi-way tree may be continued, and then the node V5 may be retrieved to determine whether the node V5 has been visited.
Alternatively, in the case that the node V5 has not been accessed, the node V5 may be output, and then the recursive deep traversal of the initial multi-way tree is continued to set the next adjacent point of the node V5 as the current node.
Alternatively, it may be determined whether or not the next adjacent point exists at the node V5.
Alternatively, in the case that the node V5 does not have the next adjacent point, the start node V0 may be set as the current node, the initial multi-way tree may be subjected to recursive deep traversal, and then the start node V0 may be retrieved to determine whether the start node V0 has been accessed.
Alternatively, in the case where the start node V0 has been accessed, the next adjacent point of the start node V0 may be set as the current node.
Alternatively, it may be determined whether the next adjacent point exists at the start node V0.
Optionally, in a case that the node V0 does not have a next adjacent point, the recursive depth traversal and the repeated node search of the initial multi-way tree may be ended, and based on the output nodes (V0, V1, V2, V3, V4, V5) and their timing relationships, all the output nodes (e 1, e2, e3, e5, e 6) are directionally connected to obtain the target multi-way tree.
As shown in fig. 12, in the structure of the target multi-way tree, the set V may be { V0, V1, V2, V3, V4, V5 }, and the set E may be { E1 (V0, V1), E2 (V0, V2), E3 (V2, V3), E5 (V2, V4), E6 (V4, V5) }.
Optionally, based on Dijkstra algorithm, an optimal path between the message platform and the upper-layer application may be searched, and the optimal path may be reported as a target processing chain.
Alternatively, the Dijkstra algorithm may be used to obtain the shortest path from one vertex to the remaining vertices.
Alternatively, dijkstra's algorithm may start from the start point, and employ the strategy of greedy algorithm, each time traversing the neighboring nodes of the vertex that are closest to the start point and have not been visited, until extending to the end point.
Optionally, in the process of obtaining the device attribute information, the edges may have unequal information, the lengths of the device nodes may be inconsistent, and the transmission rates between the network lines may be different.
Alternatively, the optimal path can be processed using a weighted approach, not just the number of edges in the DFS.
Alternatively, a graph with edge-to-edge disparity information may be referred to as a weighted graph.
Alternatively, the weight may represent a distance.
Alternatively, the process of solving the shortest path may include a process of acquiring a path having the smallest total distance between two vertices.
Alternatively, dijkstra's algorithm may start from a source point and construct a gradually expanding "cloud", and each iteration may pull the vertex closest to the source point outside the "cloud" into the "cloud" so that the "cloud" gradually spreads over the whole graph.
Alternatively, the Dijkstra algorithm pseudo-code may be as follows:
Algorithm Dijkstra(U,Graph):
Input: The point of search origin U and the weighted graph Graph .
Output: Hash table recording shorted path distance from U to each vertex in Graph.
 initialize array cloud recording vertices which are drawn into the “cloud”
initialize hash table dist as expected output
while there is unvisited neighbor outside cloud do
 find nearest neighbor V* outside cloud
 pull V* from Graph to cloud
 update dist(V*)
 for each downstream neighbor V of V* that is already in cloud do
  if dist(V*) plus the weight between V* and V gets smaller than dist(V) then
   update dist(V)
 return dist
optionally, based on Prim-Jarnik algorithm, an optimal path between the message platform and the upper layer application may be searched, and the optimal path may be reported as a target processing chain.
Alternatively, prim-Jarnik algorithms may be used to obtain the minimum spanning tree.
Optionally, in the case of connecting 1, …, n all vertices, in order to obtain the shortest path, adjustment may be performed based on the Prim-Jarnik algorithm on the basis of the Dijkstra algorithm.
Optionally, a plurality of zero-in vertices (without upstream vertices) may be used as an initial state of the "cloud", and the nearest neighboring point of the vertex in the "cloud" is continuously pulled into the "cloud", so as to iterate until all vertices are accessed.
Alternatively, if there are no zero-in vertices, one can be randomly chosen to join the "cloud".
Alternatively, the pseudo code of Prim-Jarnik algorithm may be as follows:
Algorithm Prim_Jarnik(Graph):
Input: A weighted graphGraph.
Output: Minimum overall weights along the optimal spanning path.
initialize array cloud recording vertices which are drawn into the“cloud”
initialize scalar dist with 0
extract 0 in-degree from Graph into cloud
while Graph is not empty do
 find nearest neighbor V* outside cloud
 extract V* from Graph to cloud
 add in the edge length into dist
return dist
optionally, based on the ant colony algorithm, an optimal path between the message platform and the upper layer application may be searched, and the optimal path is reported as a target to the processing chain.
Alternatively, the ant colony algorithm may be a probabilistic algorithm for obtaining the optimized path.
Alternatively, ant colony algorithms may be used to obtain the optimal path.
Optionally, in the process of acquiring the device attribute information, a path may be searched from the root node to the full graph based on an ant colony algorithm, without considering the relationship between the leaf node and the root node.
Alternatively, the ant colony algorithm may simulate ant colony foraging behavior.
Optionally, the ants can release pheromones on the passing roads in the foraging process, the longer the distance, the lower the concentration of the pheromones, the subsequent ants can judge whether to follow the path according to the pheromones, and the pheromones of the roads without the ants pass will gradually volatilize;
optionally, as more and more ants travel, the concentration of pheromones on the optimal path will be higher and higher, and finally, the concentration will be highlighted.
Optionally, the ant colony algorithm may be used to optimize the non-closed path and obtain the optimal path.
Alternatively, in the case where the computer cannot quickly find the optimal solution by traversal or recursion, a termination condition may be added to the traversal algorithm.
Alternatively, for paths that have terminated, the superior path may be given a higher feedback weight by calculating a loss function, thereby quickly approaching the optimal solution.
Alternatively, when the device node data is updated (e.g., a shortcut is newly added between some two vertices), the new data may be adapted based on the ant colony algorithm.
Alternatively, the pseudo code for the ant colony algorithm may be as follows:
Algorithm ACO(Graph,M,max_iter):
Input: A weighted and cyclic graph Graph, number of ants sent each epoch M, and maximum number of iterations max_iter.
Output: The best closed-loop path and overall path distance.
 initiate pheromore parameter info for each edge at each vertex 
# assign equal weights for all linked edges at a vertex
for each epoch t in {1,…,max_iter} do
 arbitrarily select vertex U as start position
 initiate M ants at U
 initiate object Yield recording sets of valid path with its last number of ants m
 algorithm recursion(U,M,path,Yield):
  for each unvisited vertex neighbor V of U do
   distribute m = M × info(U,V) / ∑iinfo(U,Vi) ants to vertex V ) ants to vertex V
   add V into path
   if searching ends then
    yield path and m into Yield
   else
    recursively call recursion(V,m,path,Yield)
 call algorithm recursion(U,M,path,Yield) and obtain set of pairs (path,m)
 if t equals to max_iter then
  return pair (path,m) with largest m
 else
  for each pair (path,m) do
   calculate dist as the overall length of edges on path
   for each vertex V on path do
    set Vnext _{next} next
as the vertex next to V on path
    update info(V,Vn e x t _{next} next ) by Δ \DeltaΔinfo(V,Vnext _{next} next ) = m / // dist   # edges on shorter path obtain higher weights
optionally, based on the simulated annealing algorithm, an optimal path between the message platform and the upper layer application may be searched, and the optimal path is reported as a target to the processing chain.
Optionally, the simulated annealing algorithm can effectively avoid trapping into local minima and finally tending to global optimum by endowing the search process with a time-varying and finally tending to zero probability snapback property.
Alternatively, a simulated annealing algorithm may be used to obtain the optimal path.
Alternatively, the simulated annealing algorithm may use the solid annealing principle and the random optimization process of the monte carlo simulation, and each iteration generates random adjustment on the algorithm parameters.
For example, when the ant colony algorithm is applied to find the optimal path, the road weight on the non-optimal path may be increased.
Optionally, the benefit of the random adjustment may be evaluated.
Alternatively, the adjustment may be accepted and applied directly if an optimization effect is produced for the current optimal solution.
Alternatively, if the adjustment does not optimize the current optimal solution, a certain acceptance ratio may be given, which may be a function related to the number of iterations.
Alternatively, the acceptance rate may be decreased as the number of iterations is gradually increased.
Optionally, in an application scenario of acquiring the device attribute with fewer device nodes, difficult parameter adjustment and overlong operation time, because the acceptance ratio of the error adjustment is larger initially, no negative effect is observed, and a global optimal value is more likely to be obtained after multiple rounds of double iterations.
Optionally, based on a genetic algorithm, an optimal path between the message platform and the upper layer application may be searched, and the optimal path is reported as a target to the processing chain.
Alternatively, genetic algorithms may simulate natural evolution to search for optimal solutions.
Alternatively, a genetic algorithm may be used to obtain the optimal path.
Alternatively, when the optimal path of the device node is obtained, the intersection may indicate that different paths are subjected to segment interchange.
Alternatively, the genetic algorithm may be applied to an undirected graph that enables direct interconnection and interworking between all vertices.
Alternatively, the genetic algorithm may first perform several random traversals, generating different solutions (i.e., different paths), and completing the initialization.
Alternatively, several paths that perform best may be taken out to form a queue, and a weight may be given according to the total length of each path.
Optionally, the weight may determine the probability of crossover in subsequent iterations, the better the performance the higher the crossover probability.
Optionally, in each iteration, random intersection and mutation can be performed from the existing path queue to obtain a new path which is supplemented into the original queue, and a path at the end of the performance can be eliminated by measuring the total length.
Alternatively, after a number of iterations, the optimal path may be determined from the remaining paths.
Alternatively, in a device attribute acquisition scenario that remains clueless for a long time to iterate, the genetic algorithm may jump out of the local optimal solution to the global optimal solution.
The method for determining the reporting path of the initial equipment attribute information sequentially performs recursive depth traversal and repeated node retrieval on the nodes of the initial multi-branch tree based on a tree depth-first traversal algorithm, combines repeated nodes under the condition that the repeated nodes are retrieved until a target multi-branch tree without the repeated nodes is obtained, and takes the target multi-branch tree as a target reporting processing chain, so that the computing time is saved, the equipment attribute information reporting efficiency is improved, and the equipment attribute information reporting cost is reduced.
Optionally, the method further comprises:
determining an initial reporting processing chain corresponding to a newly added upper layer application based on a subscription request of the newly added upper layer application, wherein the subscription request is used for subscribing target device attribute information corresponding to the newly added upper layer application;
and updating the target reporting processing chain based on the initial reporting processing chain corresponding to the newly added upper-layer application.
Optionally, based on the subscription request of the newly added upper layer application, an initial reporting processing chain corresponding to the newly added upper layer application may be determined.
For example, in the case where there is no newly added upper layer application, the initial reporting processing chain may include: an initial reporting processing chain 1 and an initial reporting processing chain 2; in the case that there is a newly added upper layer application, based on the subscription request of the newly added upper layer application, it may be determined that the initial reporting processing chain corresponding to the newly added upper layer application is the initial reporting processing chain 3, and in the case that there is a newly added upper layer application, the initial reporting processing chain may include: an initial reporting processing chain 1, an initial reporting processing chain 2 and an initial reporting processing chain 3.
Optionally, the subscription request may be used to subscribe to the attribute information of the target device corresponding to the newly added upper-layer application.
Optionally, based on the initial reporting processing chain corresponding to the newly added upper-layer application, the repeated path is searched and combined, and the target reporting processing chain may be updated.
The method for determining the reporting path of the initial equipment attribute information obtains the target equipment attribute information based on the subscription request of the newly added upper-layer application, determines the initial reporting processing chain, searches the repeated path based on the initial reporting processing chain, combines the repeated path, updates the target reporting processing chain, avoids repeated calculation of information processing nodes by combining the repeated path, saves the calculation time and improves the reporting efficiency of the equipment attribute information.
The device for determining a reporting path of initial device attribute information provided in the present invention is described below, and the device for determining a reporting path of initial device attribute information described below and the method for determining a reporting path of initial device attribute information described above may be referred to in a corresponding manner.
Fig. 13 is a schematic structural diagram of a device for determining a reporting path of initial device attribute information provided in the present invention, and as shown in fig. 13, the device includes: a first determining module 1310 and a second determining module 1320; wherein:
a first determining module 1310, configured to determine initial reporting processing chains corresponding to at least one upper-layer application, where a starting node of each initial reporting processing chain is a message platform where initial device attribute information is located, a destination node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in the initial reporting processing chain is configured to process the initial device attribute information to obtain target device attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
a second determining module 1320, configured to determine a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper-layer application, where a starting node of the target reporting processing chain is the message platform, a destination node of the target reporting processing chain includes the at least one upper-layer application, and the target reporting processing chain does not include a duplicate path.
Specifically, the device for determining a reporting path of the initial device attribute information is configured to determine, by the first determining module 1310, initial reporting processing chains respectively corresponding to at least one upper layer application, and then determine, by the second determining module 1320, a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper layer application.
The device for determining the reporting path of the initial equipment attribute information processes the initial equipment attribute information through the information processing node to obtain the target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain, determines the target reporting processing chain without the repeated path by combining the repeated paths in the initial reporting processing chain, realizes the purpose of quickly and effectively extracting the initial equipment attribute information from mass equipment attributes and reporting the initial equipment attribute information to the upper-layer application, provides information for the upper-layer application in time, avoids the loss and waste of computing resources and improves the production efficiency.
Fig. 14 is a schematic structural diagram of an electronic device provided in the present invention, and as shown in fig. 14, the electronic device may include: a processor (processor) 1410, a communication Interface (Communications Interface) 1420, a memory (memory) 1430, and a communication bus 1440, wherein the processor 1410, the communication Interface 1420, and the memory 1430 communicate with each other via the communication bus 1440. The processor 1410 may call logic instructions in the memory 1430 to execute a method for determining a reporting path of initial device attribute information, the method including:
determining initial reporting processing chains respectively corresponding to at least one upper-layer application, wherein a starting node of each initial reporting processing chain is a message platform where initial equipment attribute information is located, an end node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in each initial reporting processing chain is used for processing the initial equipment attribute information to obtain target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
and determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper-layer application, wherein a starting node of the target reporting processing chain is the message platform, an end node of the target reporting processing chain comprises the at least one upper-layer application, and the target reporting processing chain does not comprise a repeat path.
In addition, the logic instructions in the memory 1430 may be implemented in software functional units and stored in a computer readable storage medium when sold or used as a stand-alone product. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
In another aspect, the present invention further provides a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements a method for determining a reporting path of initial device attribute information provided by the foregoing methods, where the method includes:
determining initial reporting processing chains respectively corresponding to at least one upper-layer application, wherein a starting node of each initial reporting processing chain is a message platform where initial equipment attribute information is located, an end node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in each initial reporting processing chain is used for processing the initial equipment attribute information to obtain target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
and determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper-layer application, wherein a starting node of the target reporting processing chain is the message platform, an end node of the target reporting processing chain comprises the at least one upper-layer application, and the target reporting processing chain does not comprise a repeat path.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment may be implemented by software plus a necessary general hardware platform, and may also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in the embodiments or some parts of the embodiments.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A method for determining a reporting path of initial equipment attribute information is characterized by comprising the following steps:
determining initial reporting processing chains respectively corresponding to at least one upper-layer application, wherein a starting node of each initial reporting processing chain is a message platform where initial equipment attribute information is located, an end node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in each initial reporting processing chain is used for processing the initial equipment attribute information to obtain target equipment attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
and determining a target reporting processing chain based on the initial reporting processing chain corresponding to each of the at least one upper-layer application, wherein a starting node of the target reporting processing chain is the message platform, an end node of the target reporting processing chain includes the at least one upper-layer application, and the target reporting processing chain does not include a duplicate path.
2. The method of claim 1, wherein the determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper layer application comprises:
and sequentially searching repeated paths for paths included in the initial reporting processing chain respectively corresponding to at least one upper-layer application, and combining the repeated paths under the condition that the repeated paths are searched until a target reporting processing chain not including the repeated paths is obtained.
3. The method of claim 1, wherein the determining a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper layer application comprises:
and acquiring a target reporting processing chain without the repeated path based on the nodes included in the initial reporting processing chain respectively corresponding to the depth-first search algorithm and the at least one upper-layer application.
4. The method of claim 3, wherein before the obtaining, by the node included in the initial reporting processing chain corresponding to the at least one upper-layer application based on the depth-first search algorithm, a target reporting processing chain that does not include the duplicate path, the method further comprises:
and constructing an initial multi-branch tree, wherein the initial multi-branch tree is used for representing the initial reporting processing chain.
5. The method for determining a reporting path of initial device attribute information according to claim 4, wherein the constructing an initial multi-way tree comprises:
and taking nodes included in the initial reporting processing chain respectively corresponding to the at least one upper-layer application as nodes of an initial multi-branch tree, and constructing the initial multi-branch tree by directionally connecting the nodes of the initial multi-branch tree based on the time sequence relation among the nodes of the initial multi-branch tree.
6. The method of claim 4, wherein obtaining a target reporting processing chain that does not include a duplicate path based on the depth-first search algorithm and the nodes included in the initial reporting processing chain corresponding to the at least one upper-layer application respectively comprises:
and sequentially performing recursive depth traversal and repeated node retrieval on the nodes of the initial multi-branch tree based on a tree depth-first traversal algorithm, and combining the repeated nodes under the condition that the repeated nodes are retrieved until a target multi-branch tree which does not comprise the repeated nodes is obtained, wherein the target multi-branch tree is used for representing the target reporting processing chain.
7. The method for determining a reporting path of initial device attribute information according to claim 1, further comprising:
determining an initial reporting processing chain corresponding to a newly added upper layer application based on a subscription request of the newly added upper layer application, wherein the subscription request is used for subscribing target device attribute information corresponding to the newly added upper layer application;
and updating the target reporting processing chain based on the initial reporting processing chain corresponding to the newly added upper-layer application.
8. An apparatus for determining a reporting path of initial device attribute information, the apparatus comprising:
a first determining module, configured to determine initial reporting processing chains corresponding to at least one upper-layer application, where a starting node of each initial reporting processing chain is a message platform where initial device attribute information is located, a destination node of each initial reporting processing chain is an upper-layer application corresponding to the initial reporting processing chain, and at least one information processing node included in the initial reporting processing chain is configured to process the initial device attribute information to obtain target device attribute information subscribed by the upper-layer application corresponding to the initial reporting processing chain;
a second determining module, configured to determine a target reporting processing chain based on the initial reporting processing chains respectively corresponding to the at least one upper-layer application, where a starting node of the target reporting processing chain is the message platform, a destination node of the target reporting processing chain includes the at least one upper-layer application, and the target reporting processing chain does not include a duplicate path.
9. An electronic device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the method for determining a reporting path of initial device attribute information according to any one of claims 1 to 7 when executing the program.
10. A non-transitory computer readable storage medium, having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method for determining a reporting path of initial device attribute information according to any one of claims 1 to 7.
CN202310174893.0A 2023-02-28 2023-02-28 Method and device for determining reporting path of initial equipment attribute information Pending CN115866071A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310174893.0A CN115866071A (en) 2023-02-28 2023-02-28 Method and device for determining reporting path of initial equipment attribute information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310174893.0A CN115866071A (en) 2023-02-28 2023-02-28 Method and device for determining reporting path of initial equipment attribute information

Publications (1)

Publication Number Publication Date
CN115866071A true CN115866071A (en) 2023-03-28

Family

ID=85659320

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310174893.0A Pending CN115866071A (en) 2023-02-28 2023-02-28 Method and device for determining reporting path of initial equipment attribute information

Country Status (1)

Country Link
CN (1) CN115866071A (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140348028A1 (en) * 2012-01-17 2014-11-27 Huawei Technologies Co., Ltd. Method for creating ring network label switched path, related device, and communications system
CN107153877A (en) * 2017-05-24 2017-09-12 艾凯克斯(嘉兴)信息科技有限公司 A kind of machine learning method of rule-based matrix multiway tree
CN110677341A (en) * 2019-09-09 2020-01-10 锐捷网络股份有限公司 Data forwarding method and device, electronic equipment and storage medium
CN110929323A (en) * 2019-11-20 2020-03-27 上海建工四建集团有限公司 Equipment route connection relation rendering path duplicate removal method and electronic equipment
CN111193779A (en) * 2019-12-17 2020-05-22 北京首钢自动化信息技术有限公司 Internet of things control method and system
CN111352417A (en) * 2020-02-10 2020-06-30 合肥工业大学 Rapid generation method of heterogeneous multi-unmanned aerial vehicle cooperative path
CN112039574A (en) * 2020-06-10 2020-12-04 合肥工业大学 Method and system for quickly reconstructing unmanned aerial vehicle cooperative relay network under communication interference
CN112183710A (en) * 2020-10-22 2021-01-05 中国联合网络通信集团有限公司 Method and device for determining path
CN114285786A (en) * 2021-12-24 2022-04-05 中国农业银行股份有限公司 Method and device for constructing network link library
CN115688341A (en) * 2022-11-15 2023-02-03 厦门亿力吉奥信息科技有限公司 Distribution network thematic map layout method based on multi-branch tree collision detection and storage medium

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140348028A1 (en) * 2012-01-17 2014-11-27 Huawei Technologies Co., Ltd. Method for creating ring network label switched path, related device, and communications system
CN107153877A (en) * 2017-05-24 2017-09-12 艾凯克斯(嘉兴)信息科技有限公司 A kind of machine learning method of rule-based matrix multiway tree
CN110677341A (en) * 2019-09-09 2020-01-10 锐捷网络股份有限公司 Data forwarding method and device, electronic equipment and storage medium
CN110929323A (en) * 2019-11-20 2020-03-27 上海建工四建集团有限公司 Equipment route connection relation rendering path duplicate removal method and electronic equipment
CN111193779A (en) * 2019-12-17 2020-05-22 北京首钢自动化信息技术有限公司 Internet of things control method and system
CN111352417A (en) * 2020-02-10 2020-06-30 合肥工业大学 Rapid generation method of heterogeneous multi-unmanned aerial vehicle cooperative path
CN112039574A (en) * 2020-06-10 2020-12-04 合肥工业大学 Method and system for quickly reconstructing unmanned aerial vehicle cooperative relay network under communication interference
CN112183710A (en) * 2020-10-22 2021-01-05 中国联合网络通信集团有限公司 Method and device for determining path
CN114285786A (en) * 2021-12-24 2022-04-05 中国农业银行股份有限公司 Method and device for constructing network link library
CN115688341A (en) * 2022-11-15 2023-02-03 厦门亿力吉奥信息科技有限公司 Distribution network thematic map layout method based on multi-branch tree collision detection and storage medium

Similar Documents

Publication Publication Date Title
CN110677284A (en) Heterogeneous network link prediction method based on meta path
CN109902274A (en) A kind of method and system converting json character string to thrift binary stream
CN109995580B (en) VN mapping method based on GA _ PSO hybrid algorithm in 5G network slice
CN107911300B (en) Multicast routing optimization method based on whale algorithm and application of multicast routing optimization method on Spark platform
CN112100450A (en) Graph calculation data segmentation method, terminal device and storage medium
CN110659284A (en) Block sequencing method and system based on tree graph structure and data processing terminal
CN113190939B (en) Large sparse complex network topology analysis and simplification method based on polygon coefficient
CN109189393A (en) Method for processing business and device
CN113516501A (en) User communication behavior prediction method and device based on graph neural network
CN114244774B (en) LEO satellite network congestion multicast routing avoiding method based on swarm intelligence
CN108614932B (en) Edge graph-based linear flow overlapping community discovery method, system and storage medium
CN113228059A (en) Cross-network-oriented representation learning algorithm
CN111460277B (en) Personalized recommendation method based on mobile social network tree-shaped transmission path
CN111709102B (en) Water supply network partitioning method based on hierarchical clustering
CN117408587A (en) Method for mining maximum propagation point set of large-scale express logistics network
CN111597139A (en) Communication method, system, equipment and medium of GPU
CN111683010A (en) Method and device for generating double routes based on optical cable network optical path
CN115866071A (en) Method and device for determining reporting path of initial equipment attribute information
CN106991195B (en) Distributed subgraph enumeration method
Wang et al. On searching multiple disjoint shortest paths in scale-free networks with hyperbolic geometry
CN115001978A (en) Cloud tenant virtual network intelligent mapping method based on reinforcement learning model
CN116260730B (en) Geographic information service evolution particle swarm optimization method in multi-edge computing node
CN115827996B (en) Community query method and system with sharing constraint
CN111935006B (en) Data transmission method, device, processing equipment and medium
CN111291232B (en) Graph kernel decomposition method based on h-jump distance

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20230328