Supercharge Your Innovation With Domain-Expert AI Agents!

Loop detection method and device in directed graph, equipment and storage medium

A loop detection and directed graph technology, applied in the field of graph theory, can solve the problems of low efficiency, inability to guarantee loop detection, long time consumption, etc., to achieve the effect of improving execution efficiency, improving detection rate, and improving detection efficiency.

Active Publication Date: 2020-04-07
BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF12 Cites 8 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

This method is inefficient, and a traversal takes too long; and it cannot guarantee the detection of all loops

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Loop detection method and device in directed graph, equipment and storage medium
  • Loop detection method and device in directed graph, equipment and storage medium
  • Loop detection method and device in directed graph, equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0079] figure 2 It is a flowchart of a loop detection method in a directed graph in Embodiment 1 of the present application. The embodiment of the present application is suitable for detecting loops in a directed graph, but not for loops with repeated vertices checkout. The method is executed by the loop detection device in the directed graph, the device is realized by software and / or hardware, and is specifically configured in an electronic device with a certain data computing capability.

[0080] Such as figure 2 The shown loop detection method in a directed graph is applied to a distributed cluster, and the distributed cluster includes a service center and multiple computing nodes communicatively connected to the service center. The service center is used to distribute tasks to the computing nodes, and reprocess the information returned by the computing nodes to obtain all the cycles in the directed graph. In this embodiment, the electronic device may be a service cent...

Embodiment 2

[0099] image 3 It is a flow chart of a loop detection method in a directed graph in Embodiment 2 of the present application. This embodiment of the present application is optimized and improved on the basis of the technical solutions of the foregoing embodiments.

[0100] Further, the operation "the service center splices the obtained loops and / or links according to the cut edge information between the subgraphs to obtain the loops in the directed graph" is refined into "the service center acquires In the loop sequence and chain sequence, find the adjacent sequence of the first trimming sequence; the service center will splice the adjacent sequence and the first trimming sequence to obtain a new first trimming sequence; if the new first trimming sequence does not exist Repeat the vertex, the service center judges whether there is a directed edge at the beginning and end of the new first tangent edge sequence; if it exists, the service center detects the new first tangent edge...

Embodiment 3

[0133] Figure 4 It is a flowchart of a loop detection method in a directed graph in Embodiment 3 of the present application. The embodiment of the present application is suitable for detecting loops in a directed graph, but not for loops with repeated vertices checkout. The method is executed by the loop detection device in the directed graph, the device is realized by software and / or hardware, and is specifically configured in an electronic device with a certain data computing capability.

[0134] Such as Figure 4 The shown loop detection method in a directed graph is applied to a distributed cluster, and the distributed cluster includes a service center and multiple computing nodes communicatively connected to the service center. The service center is used to distribute tasks to the computing nodes, and reprocess the information returned by the computing nodes to obtain all the cycles in the directed graph. In this embodiment, the electronic device can be any computing ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a loop detection method and device in a directed graph, equipment and a storage medium, and relates to the technical field of graph theory. According to the specific implementation scheme, the loop detection method comprises the steps that a service center in a distributed cluster obtains a to-be-detected directed graph; the service center cuts at least one edge of the directed graph to obtain a plurality of sub-graphs; the service center distributes the plurality of sub-graphs to a plurality of computing nodes in a distributed cluster, so that each computing node detects a loop and a link in the received sub-graph; and the service center acquires the loops and the links in the plurality of sub-graphs from the plurality of computing nodes, and splices the acquired loops and / or the links according to the trimmed information among the sub-graphs to obtain the loops in the directed graph. According to the embodiment of the invention, computing resources of the distributed cluster are fully utilized to improve the detection efficiency; and the loop and the link in the subgraph are detected in parallel, and then the loop and the link are spliced, so that the detection efficiency is improved, and the detection rate of the loop is effectively improved.

Description

technical field [0001] This application relates to computer technology, in particular to the technical field of graph theory. Background technique [0002] In the data processing scenario based on a directed graph, it is often necessary to detect the loops in it, so as to perform targeted processing on the data in the loops. [0003] At present, the following methods are commonly used for loop detection of directed graphs: depth-first traversal, breadth-first traversal, and topological sorting. However, these three detection methods all adopt the serial traversal method of vertices. This method is inefficient and takes too long for one traversal; moreover, detection of all loops cannot be guaranteed. Contents of the invention [0004] Embodiments of the present application provide a loop detection method, device, device, and storage medium in a directed graph, so as to improve the detection rate of loops in the directed graph and improve detection efficiency. [0005] I...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F9/50G06F16/901
CPCG06F9/5027G06F16/9024
Inventor 卢文祥李玉明王云龙周力蔡歌汪洋袁鹏程李刚
Owner BEIJING BAIDU NETCOM SCI & TECH CO LTD
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More