A method, device, and storage medium for verifying a flow chart generation algorithm

By calculating the dependency matrix and generating event logs, the reliability of the flowchart generation algorithm is verified, and the problem of lack of effective verification of flowchart path consistency in the prior art is solved, and verification efficiency and accuracy are improved.

CN115658353BActive Publication Date: 2025-06-10SHANGHAI YISAIQI SOFTWARE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211295936.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-21
Publication Date
2025-06-10
Estimated Expiration
2042-10-21

AI Technical Summary

Technical Problem

There is a lack of effective methods in the prior art to verify path consistency in flowcharts, especially when handling large amounts of event logs.

Method used

By obtaining the original flowchart, calculating the dependency matrix, generating event logs, and using the flowchart generation algorithm to be verified to generate the calculation flowchart. Finally, the calculation flowchart is compared with the original flowchart to verify the reliability of the flowchart generation algorithm.

Benefits of technology

Effective verification of the flowchart generation algorithm is achieved, and the efficiency and accuracy of path consistency checks are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115658353B_ABST
    Figure CN115658353B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, apparatus and storage medium for verifying a flowchart generation algorithm. The method for verifying the flowchart generation algorithm includes: obtaining an original flowchart; obtaining information on all paths from the original flowchart; calculating a dependency matrix based on the information on all paths; generating an event log according to the dependency matrix; generating a calculated flowchart by using the flowchart generation algorithm to be verified according to the event log; comparing the calculated flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified. By calculating a dependency matrix based on the information on all paths and generating an event log according to the dependency matrix, the present invention has a simple operation process and high efficiency, realizes the comparison between the flowchart generated by the flowchart generation algorithm and the standard flowchart, and the generated event log can be adjusted according to requirements, thereby improving the reliability of verifying the flowchart generation algorithm.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of process mining, and in particular to a method, device and storage medium for verifying a flowchart generation algorithm. Background Art

[0002] Process Mining is a new interdisciplinary application across fields such as data mining, machine learning, process modeling and analysis. Its core principle is based on the collection of business operation logs across platforms and systems, and a complete view of the business process operation process is generated according to the business logs, so as to discover, monitor and improve the business process. For example, find the workflow model and organizational model from the workflow logs of the ERP (Enterprise Resource Planning) system, and after analysis, finally find the problems existing in the process and give optimization suggestions. Organizations using process mining can understand the business process more comprehensively, find the root causes of inefficiencies and identify improvement opportunities including automation, and then gain the ability to make accurate strategy-based decisions for long-term business growth.

[0003] In the prior art, process mining algorithms can restore a logical flowchart from event logs and use four indicators, namely accuracy, fitting degree, generalization degree and simplicity, to measure the effectiveness of the logical flowchart. However, there is no general measurement index for the process of converting the logical flowchart into a visual flowchart. Since what actual users usually see is the visual flowchart rather than the logical flowchart, an effective way is needed to judge the effectiveness of the visual flowchart. In addition, in actual projects, the event log files analyzed often have tens of millions of records, and both the nodes and lines of the visual flowchart restored from the event logs are very numerous. It is also very difficult to judge the consistency between the visual flowchart and the event logs. Currently, there is no good method in the prior art to verify the paths in the flowchart. Summary of the Invention

[0004] The purpose of the present invention is to provide a method, device and storage medium for verifying a flowchart generation algorithm to solve the problem that there is no good method in the prior art to verify the paths in the flowchart.

[0005] To achieve the above object, the present invention provides the following technical solutions:

[0006] In the first aspect, the present invention provides a method for verifying a flowchart generation algorithm, and the method includes the following steps:

[0007] Obtain an original flowchart;

[0008] Obtain the information of all paths from the original flowchart;

[0009] Calculate the dependency matrix based on the information of all paths;

[0010] Generate an event log according to the dependency matrix;

[0011] Generate a calculation flowchart according to the event log using the flowchart generation algorithm to be verified;

[0012] Compare the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified.

[0013] Furthermore, the method for calculating the dependency matrix based on the information of all paths includes:

[0014] Merge the same paths among all paths. Each path includes multiple path nodes such as a start node, an end node, and multiple intermediate nodes. The start node is assigned the number START, the end node is assigned the number END, and each intermediate node is assigned a unique number;

[0015] Construct a dependency matrix. The content of the first row and the first column of this matrix is the node number of the path node. The value in the matrix except the first row and the first column represents the total number of times the path from the path node represented by the node number in the column where the value is located to the path node represented by the node number in the row where the value is located appears in all paths. The default initial number of times is 0 times.

[0016] Furthermore, the method for generating an event log according to the dependency matrix includes: extracting the complete path from the start node to the end node in the dependency matrix by sampling to generate an event log; among them, the sampling method should ensure that the probability of each path node reaching all reachable path nodes is consistent with the probability in the dependency matrix and no path node is missed.

[0017] Furthermore, the method for comparing the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified includes: comparing the number of path nodes with the same name, the distance between the same two path nodes, and the number of times the same edge passes in the calculation flowchart and the original flowchart. If the error is within the preset range, the flowchart generation algorithm to be verified is reliable; otherwise, the flowchart generation algorithm to be verified is unreliable.

[0018] Furthermore, the method for verifying the flowchart generation algorithm also includes obtaining multiple flowcharts and the calculation flowchart and comparing them. The method includes:

[0019] Add paths to the initial flowchart one by one. Each time a path is added, a flowchart is obtained. After adding K paths, K flowcharts are obtained, denoted as Flowchart Figure 1 、Flowchart Figure 2, …, Flowchart K;

[0020] Use the flowchart generation algorithm to be verified to generate calculation processes respectively Figure 1 , calculation process Figure 2 , …, calculation flowchart K;

[0021] Compare the calculation process Figure 1 , calculation process Figure 2 , …, calculation flowchart K with the processes Figure 1 , process Figure 2 , …, flowchart K respectively. If the comparison results are consistent each time, record it as 1. If not, record it as 0. Sum up the comparison results and divide by the total number of comparisons to obtain the comparison result.

[0022] In a second aspect, the present invention provides a device for verifying a flowchart generation algorithm, including:

[0023] Original flowchart acquisition module: used to acquire the original flowchart;

[0024] All-path information acquisition module: used to acquire the information of all paths from the original flowchart;

[0025] Dependency matrix calculation module: used to calculate the dependency matrix according to the information of all paths;

[0026] Event log generation module: used to generate an event log according to the dependency matrix;

[0027] Calculation flowchart generation module: used to generate a calculation flowchart according to the event log by using the flowchart generation algorithm to be verified;

[0028] Reliability identification module: used to compare the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified.

[0029] In a third aspect, the present invention provides a device for verifying a flowchart generation algorithm, including a processor and a storage medium;

[0030] The storage medium is used to store instructions;

[0031] The processor is used to operate according to the instructions to execute the steps of the above method.

[0032] In a fourth aspect, the present invention provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the above method are implemented.

[0033] Compared with the prior art, the beneficial effects of the present invention are:

[0034] A method for generating a verification flowchart generation algorithm calculates a dependency matrix based on the information of all paths, generates an event log according to the dependency matrix, has a simple operation process and high efficiency, realizes the comparison between the flowchart generated by the flowchart generation algorithm and the standard flowchart, and the generated event log can be adjusted according to requirements, thereby improving the reliability of the verification flowchart generation algorithm. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 is a flowchart of the method for generating a verification flowchart generation algorithm provided by an embodiment of the present invention;

[0036] Figure 2 is the original flowchart provided by an embodiment of the present invention;

[0037] Figure 3 is the calculation flowchart provided by an embodiment of the present invention;

[0038] Figure 4 is the calculation process provided by an embodiment of the present invention Figure 1 ;

[0039] Figure 5 is the calculation process provided by an embodiment of the present invention Figure 2 . DETAILED DESCRIPTION OF THE EMBODIMENTS

[0040] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

[0041] An embodiment of the present invention provides a method for generating a verification flowchart generation algorithm, and its flowchart is as Figure 1 shown, and it specifically includes the following steps:

[0042] S1: Obtain the original flowchart; the original flowchart can be any form of business flowchart, including: a hand-drawn business flowchart, a BPMN (Business Process Modeling Notation) flowchart designed using software, or a flowchart restored using a process mining tool. Each flowchart includes multiple paths, each path includes one or more path nodes, each path node represents a business step, and the connection line between two path nodes indicates that the corresponding two business steps are executed consecutively. If there is a number on the connection line, it indicates the number of executions. Each path starts from the default start node and ends at the default end node. In this embodiment, each flowchart includes only one default start node and one default end node.

[0043] Such as Figure 2 The original flowchart shown, where: the thin-line circle represents the default start node (START), the thick-line circle represents the default end node (END), the rectangle represents the path node, the connection line represents the sequential execution order of the nodes, each path includes multiple path nodes including the default start node, the default end node, and multiple intermediate nodes. The start node is assigned the number START, the end node is assigned the number END, and each intermediate node is assigned a unique number, which is represented by letters starting from a in this embodiment.

[0044] S2: Obtain the information of all paths from the original flowchart; as shown in Table 1, it is the information of all paths obtained from the original flowchart, where the occurrence times represent the number of executions of the corresponding business process.

[0045] Table 1 Information of all paths in the original flowchart

[0046] Path Occurrence count START,a,b,c,d,e,END 500 START,a,f,g,d,e,END 200 START,a,f,g,f,g,d,e,END 60 START,a,b,c,c,d,e,END 70 START,a,h,i,j,e,END 250 START,a,h,i,j,k,h,i,j,e,END 30 START,a,h,i,d,e,END 80

[0047] S3: Calculate the dependency matrix based on the information of all paths; the method for calculating the dependency matrix based on Table 1 specifically includes: merging the same paths in all paths; constructing a dependency matrix, where the content of the first row and the first column of the matrix is the node number of the path node, and the value in the matrix except the first row and the first column represents the total number of times the path from the path node represented by the node number in the column where the value is located to the path node represented by the node number in the row where the value is located appears in all paths, and the default initial number of times is 0 times.

[0048] According to Table 1, count the reachable path nodes of each path node and the total number of occurrences of each path node to each reachable path node. For example: The reachable path node of the default start node START is only node a, and the total number of occurrences of the default start node START to node a is 500 + 200 + 60 + 70 + 250 + 30 + 80 = 1190; The reachable path nodes of node a are node b, node f, and node h. The total number of occurrences of node a to node b is 500 + 70 = 570, the total number of occurrences of node a to node f is 200 + 60 = 260, and the total number of occurrences of node a to node h is 250 + 30 + 80 = 360.

[0049] According to the calculation in Table 1, the dependency matrix is finally obtained, as shown in Table 2.

[0050] Table 2 Dependency Matrix

[0051]

[0052] The numbers in the rows and columns of the dependency matrix are the same. The values in the dependency matrix represent the total number of occurrences of the path node in the column where the value is located to the path node in the row where the value is located in all paths. If two nodes appear multiple times in the same path, they need to be counted repeatedly. For example, if the node pair (f, g) appears twice in the third path, the corresponding count in the current path should be 60 × 2, for a total of 120 times.

[0053] S4: Generate an event log according to the dependency matrix; the generated event log is not unique, that is, the content of the event log generated each time is different; The method of generating an event log according to the dependency matrix specifically includes: extracting a complete path from the default start node to the default end node in the dependency matrix by sampling to generate an event log; among them, the sampling method should ensure that the probability of each path node reaching all reachable path nodes is consistent with the probability in the dependency matrix and no path nodes are missed.

[0054] According to the dependency matrix, continuously simulate all paths that can start from the default start node START to the default end node END to generate an event log. The start of all event logs starts from the default start node START and ends at the default end node END.

[0055] Starting from the default start node START, one can only choose to reach node a. After reaching node a, one can choose to reach node b, node f, and node h. Probabilistic selection is made according to the initial ratio of the values, that is, the probability of choosing to reach node b is 570 / (570 + 260 + 360) = 0.479, the probability of choosing to reach node f is 260 / (570 + 260 + 360) = 0.218, and the probability of choosing to reach node h is 360 / (570 + 260 + 360) = 0.303. These probabilities will generate a probability table in advance according to the initial ratio before simulating the generation of the event log, as shown in Table 3.

[0056] Table 3 Probability Table

[0057]

[0058] Every time from the default start node START to the default end node END, add this path to the event log once, and subtract 1 from the number of times the nodes passed by this path in the dependency matrix. If the number of times the node selected according to the probability is already 0, and there are other nodes with the number of selectable nodes not being 0, then give priority to selecting other nodes until the number of selectable nodes is all 0, and then make a random selection according to the probability.

[0059] An example of the generated event log is shown in Table 4. Among them, the first column timestamp represents the time when the event occurs. When sampling, according to the time of the previous event, add a random interval automatically to obtain the time of the current event. The second column activity represents the event content represented by the node name. The third column case ID represents the path ID number (used to distinguish each path, also called the case number / case ID), and each sampled complete path corresponds to a unique value.

[0060] Table 4 Generated Event Log

[0061] Timestamp Activity Case ID 2011-01-02 05:05:47 a 1 2011-01-03 18:17:39 b 1 2011-01-05 13:27:58 C 1 2011-01-06 05:18:02 d 1 2011-01-07 14:40:51 e 1 2011-01-08 22:16:32 a 2 2011-01-09 03:33:12 h 2 2011-01-09 10:06:35 1 2 2011-01-10 02:28:19 j 2 2011-01-11 07:07:13 e 2 2011-01-12 20:50:37 a 3 2011-01-14 03:18:46 b 3 2011-01-14 23:47:28 C 3 2011-01-15 22:49:22 d 3 2011-01-15 23:18:11 e 3 2011-01-17 03:58:39 a 4 2011-01-18 21:08:04 h 4 2011-01-1823:54:57 i 4 2011-01-20 09:45:33 j 4 2011-01-22 08:42:57 e 4 2011-01-23 03:12:46 a 5 2011-01-23 20:30:51 h 5 2011-01-25 04:41:33 i 5 2011-01-26 11:57:12 j 5 2011-01-28 04:51:54 e 5 2011-01-30 02:26:58 a 6 2011-01-31 19:38:44 f 6 2011-02-02 14:20:17 g 6 2011-02-03 06:21:42 d 6 2011-02-05 02:16:26 e 6 2011-02-05 04:04:43 a 7 2011-02-05 12:04:31 h 7 2011-02-07 11:50:49 i 7 2011-02-08 02:44:04 j 7 2011-02-09 01:00:50 e 7 2011-02-09 07:05:25 a 8 2011-02-10 21:08:04 b 8 2011-02-12 13:53:15 C 8 2011-02-13 11:24:24 d 8 2011-02-14 20:01:31 e 8

[0062] S5: According to the event log, use the flowchart generation algorithm to be verified to generate a calculation flowchart, as Figure 3 shown.

[0063] S6: Compare the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified; the method of comparing the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified specifically includes: comparing the number of path nodes with the same name in the calculation flowchart and the original flowchart, the distance between the same two path nodes, and the number of times the same edge passes through. If the error is within the preset range, the flowchart generation algorithm to be verified is reliable; otherwise, the flowchart generation algorithm to be verified is unreliable.

[0064] First, verify the intermediate nodes in the calculation flowchart (as shown in Figure 3 ):

[0065] There are intermediate nodes in the original flowchart ( Figure 2 ): a, b, c, d, e, f, g, h, i, j, k, and the total number of intermediate nodes is: 11; verify each intermediate node in the calculation flowchart. If there is an intermediate node that is the same as in the original flowchart, output 1; otherwise, output 0.

[0066] Let the threshold be 100%. The verification value is obtained as (1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1) / 11 * 100% = 100%. The verification result is that the intermediate nodes in the calculation flowchart meet the threshold requirements, and each intermediate node exists.

[0067] Secondly, verify the edges in the calculation flowchart:

[0068] The edges in the original flowchart are:

[0069] S - a, a - b, b - c, c - c, c - d, d - e, a - h, h - i, i - d, i - j, j - k, k - h, j - e, a - f, f - g, g - f, g - d, e - E. The total number of edges is 18; verify each edge in the calculation flowchart. If there is an edge that is the same as in the original flowchart, output 1; otherwise, output 0. Among them, m - n represents the edge from intermediate node m to intermediate node n, where m and n are any intermediate node names, S represents the START default start node, and E represents the END default end node.

[0070] Let the threshold be 90%. The verification value is obtained as:

[0071] (1 + 1 + 1 + 1 + 1 + 1 + 1 + 0.9231 + 1 + 0.9194 + 0.93 + 0.93 + 1 + 1 + 0.8125 + 0.75 + 1 + 1) / 18 * 100% = 95.36%. The verification result is that the edges in the calculation flowchart meet the threshold requirements.

[0072] The result shows that the flowchart generation algorithm to be verified is reliable.

[0073] A method for verifying a flowchart generation algorithm provided by an embodiment of the present invention further includes the following specific steps: obtaining multiple flowcharts and the calculation flowchart and making a comparison. The method specifically includes the following steps:

[0074] Add paths to the initial flowchart one by one. Each time a path is added, a flowchart is obtained. After adding K paths, K flowcharts are obtained, denoted as Flowchart Figure 1 , Flowchart Figure 2 , …, Flowchart K;

[0075] Use the flowchart generation algorithm to be verified to generate calculation processes respectively Figure 1 , calculation processes Figure 2 ,..., calculation flowchart K;

[0076] Compare the calculation processes Figure 1 , calculation processes Figure 2 ,..., calculation flowchart K with the processes Figure 1 , processes Figure 2 ,..., flowchart K respectively. If the comparison results are consistent each time, record it as 1. If not, record it as 0. Sum up the comparison results and divide by the total number of comparisons to obtain the comparison result.

[0077] As Figure 4 shown, it is the calculation process obtained by adding a path to the initial flowchart Figure 1 , and Table 5 is the dependency matrix 1 calculated based on all path information obtained from the process Figure 1 .

[0078] Table 5 Dependency matrix 1

[0079]

[0080] First, verify the intermediate nodes in the calculation process Figure 1 :

[0081] The intermediate nodes in the calculation process Figure 1 should be: a, b, c, d, e, f, g, h, i, and the total number of intermediate nodes that should be there is: 9. Verify each intermediate node that should be there. If the intermediate node exists, output 1. Otherwise, output 0.

[0082] Set the threshold to 100%, and the verification value is obtained as (1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1) / 9 * 100% = 100%. The verification result is that the intermediate node verification meets the threshold requirement, and each intermediate node that should be there exists.

[0083] Secondly, verify the edges in the calculation process Figure 1 :

[0084] The edges that should be in the calculation process Figure 1 are:

[0085] There should be a total of 12 edges for S-a, a-b, b-c, c-d, d-e, a-h, h-i, i-d, a-f, f-g, g-e, e-E. For each supposed edge, verify it. When the supposed edge exists, output the ratio of the existing edge to the supposed edge. When the supposed edge does not exist, output 0. Here, m-n represents the edge from intermediate node m to intermediate node n, where m and n are any intermediate node names, S represents the START default start node, and E represents the END default end node.

[0086] Let the threshold be 90%. The verification value is obtained as (1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1) / 12 * 100% = 100%. The verification result is that the edge verification meets the threshold requirement, and each supposed edge exists.

[0087] As Figure 5 shown, it is the calculation process obtained by adding one more path to the initial flowchart. Figure 2 , Table 6 is the dependency matrix 2 calculated based on the information of all paths obtained from the Figure 2 process.

[0088] Table 6 Dependency Matrix 2

[0089]

[0090] First, verify the intermediate nodes in the calculation process Figure 2 :

[0091] The supposed intermediate nodes in the calculation process Figure 2 are: a, b, c, d, e, f, g, h, i, j. The total number of supposed intermediate nodes is: 10. Verify each supposed intermediate node. When the supposed intermediate node exists, output 1; otherwise, output 0.

[0092] Let the threshold be 100%. The verification value is obtained as (1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1) / 10 * 100% = 100%. The verification result is that the intermediate node verification meets the threshold requirement, and each supposed intermediate node exists.

[0093] Secondly, verify the edges in the calculation process Figure 2 :

[0094] The supposed edges in the calculation process Figure 2 are:

[0095] For S-a, a-b, b-c, c-d, d-e, a-h, h-i, i-d, a-f, f-g, g-e, i-j, j-e, e-E, the total number of expected edges should be 14; verify each expected edge. When the expected edge exists, output the ratio of the existing edge to the expected edge; when the expected edge does not exist, output 0. Here, m-n represents the edge from intermediate node m to intermediate node n, where m and n are any intermediate node names, S represents the START default start node, and E represents the END default end node.

[0096] Let the threshold be 90%, and the verification value obtained is:

[0097] (1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1) / 14 * 100% = 100%, and the verification result is that the edge verification meets the threshold requirement, and each expected edge exists.

[0098] The embodiment of the present invention also provides a device for verifying a flowchart generation algorithm, including:

[0099] An original flowchart acquisition module: used to acquire the original flowchart;

[0100] An information acquisition module for all paths: used to acquire the information of all paths from the original flowchart;

[0101] A dependency matrix calculation module: used to calculate the dependency matrix based on the information of all paths;

[0102] An event log generation module: used to generate an event log based on the dependency matrix;

[0103] A calculation flowchart generation module: used to generate a calculation flowchart based on the event log by using the flowchart generation algorithm to be verified;

[0104] A reliability identification module: used to compare the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified.

[0105] The embodiment of the present invention also provides a device for verifying a flowchart generation algorithm, including a processor and a storage medium;

[0106] The storage medium is used to store instructions;

[0107] The processor is used to operate according to the instructions to execute the steps of the foregoing method.

[0108] The embodiment of the present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the foregoing method are implemented.

[0109] For those skilled in the art, it is obvious that the present invention is not limited to the details of the above-described exemplary embodiments, and the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention. Therefore, from any point of view, the embodiments should be regarded as exemplary and non-restrictive. The scope of the present invention is defined by the appended claims rather than the above description. Therefore, all changes falling within the meaning and scope of the equivalent elements of the claims are intended to be embraced within the present invention. Any reference signs in the claims should not be construed as limiting the claims involved.

Claims

1. A method for verifying a flowchart generation algorithm, characterized in that, the method comprises the following steps: Obtain the original flowchart; Obtain the information of all paths from the original flowchart; Calculate the dependency matrix according to the information of all paths; Generate an event log according to the dependency matrix; According to the event log, use the flowchart generation algorithm to be verified to generate a calculation flowchart; Compare the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified, including: comparing the number of path nodes with the same name in the calculation flowchart and the original flowchart, the distance between the same two path nodes, and the number of times the same edge passes through. If the error is within the preset range, the flowchart generation algorithm to be verified is reliable; otherwise, the flowchart generation algorithm to be verified is unreliable; Or It also includes obtaining multiple flowcharts and the calculation flowchart and comparing them: Add paths to the initial flowchart one by one. Each time a path is added, a flowchart is obtained. After adding K paths, K flowcharts are obtained, denoted as flowchart 1, flowchart 2,..., flowchart K; Use the flowchart generation algorithm to be verified to generate calculation flowchart 1, calculation flowchart 2,..., calculation flowchart K respectively; Compare calculation flowchart 1, calculation flowchart 2,..., calculation flowchart K with flowchart 1, flowchart 2,..., flowchart K respectively. If the comparison results are the same each time, it is recorded as 1. If they are different, it is recorded as 0. Sum up the comparison results and divide by the total number of comparisons to obtain the comparison result.

2. The method for verifying a flowchart generation algorithm according to claim 1, characterized in that, The method for calculating the dependency matrix according to the information of all paths includes: Merge the same paths among all paths. Each path includes multiple path nodes including a start node, an end node, and multiple intermediate nodes. The start node is assigned the number START, the end node is assigned the number END, and each intermediate node is assigned a unique number; Construct a dependency matrix. The content of the first row and the first column of this matrix is the node numbers of the path nodes. The values in the matrix except the first row and the first column represent the total number of times the path from the path node represented by the node number in the column where the value is located to the path node represented by the node number in the row where the value is located appears in all paths. The default initial number of times is 0 times.

3. The method for verifying a flowchart generation algorithm according to claim 1, characterized in that, The method for generating an event log according to the dependency matrix includes: extracting the complete path from the start node to the end node in the dependency matrix by sampling to generate an event log; among them, the sampling method should ensure that the probability of each path node reaching all reachable path nodes is consistent with the probability in the dependency matrix and no path node is missed.

4. A device for verifying a flowchart generation algorithm, characterized in that, comprises: Original flowchart acquisition module: used to obtain the original flowchart; All-path information acquisition module: used to obtain the information of all paths from the original flowchart; Dependency relationship matrix calculation module: used to calculate the dependency relationship matrix based on the information of all paths; Event log generation module: used to generate an event log based on the dependency relationship matrix; Calculation flowchart generation module: used to generate a calculation flowchart according to the event log by using the flowchart generation algorithm to be verified; Reliability identification module: used to compare the calculation flowchart with the original flowchart to identify the reliability of the flowchart generation algorithm to be verified, including: comparing the number of path nodes with the same name, the distance between the same two path nodes, and the passing times of the same edges in the calculation flowchart and the original flowchart. If the error is within the preset range, the flowchart generation algorithm to be verified is reliable; otherwise, the flowchart generation algorithm to be verified is unreliable; Or It also includes obtaining multiple flowcharts and the calculation flowchart and making comparisons: Add paths to the initial flowchart one by one. Each time a path is added, a flowchart is obtained. After adding K paths, K flowcharts are obtained, denoted as flowchart 1, flowchart 2,..., flowchart K; Use the flowchart generation algorithm to be verified to generate calculation flowchart 1, calculation flowchart 2,..., calculation flowchart K respectively; Compare calculation flowchart 1, calculation flowchart 2,..., calculation flowchart K with flowchart 1, flowchart 2,..., flowchart K respectively. If the comparison results are consistent each time, record it as 1; if not, record it as 0. Sum up the comparison results and divide by the total number of comparisons to obtain the comparison result.

5. An apparatus for verifying a flowchart generation algorithm, Characterized in that, It includes a processor and a storage medium; The storage medium is used to store instructions; The processor is used to operate according to the instructions to execute the steps of the method according to any one of claims 1 to 3.

6. A computer-readable storage medium, on which a computer program is stored, Characterized in that, When the program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 3.

Citation Information

Patent Citations

  • Process arrangement-based service combination path derivation method

    CN106126416A

  • A process model modification method based on step matrix and process tree

    CN109102150A