Data comparison method, data comparison program, and information processing device

The data comparison method and program address the inability of existing devices to detect table changes by comparing character strings and identifying differences, allowing for accurate revision detection and difference identification.

JP7786420B2Active Publication Date: 2025-12-16TOYOTA JIDOSHA KK
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
JP2023060183
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2023-04-03
Publication Date
2025-12-16
Estimated Expiration
2043-04-03

AI Technical Summary

Technical Problem

Existing character reading devices can only identify characters but cannot determine changes in tables before and after revisions, or identify differences between similar tables.

Method used

A data comparison method and program that acquires character strings from each cell in two tables, determines table correspondence based on similarity, and identifies differences between corresponding cells.

Benefits of technology

Enables determination of table revisions and identification of differences in character strings between corresponding cells, even if tables have been revised.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007786420000001
    Figure 0007786420000001
  • Figure 0007786420000002
    Figure 0007786420000002
  • Figure 0007786420000003
    Figure 0007786420000003
Patent Text Reader

Abstract

To provide an information processing device for specifying which item of a table is changed before and after table revision, a data comparison method and a program.SOLUTION: In a data comparison system, a data comparison control method by an information processing device acquires a character string of each cell included in a first table and a second table in document data (S12). The information processing device may identify a character included in the character string by using a learned model which performs learning in advance by machine learning in acquiring the character string. Also, the method determines whether the second table corresponds to the first table on the basis of similarity between a character string of a cell included in the first table and a character string of a cell included in the second table (S31), and specifies difference between the character string of the cell included in the first table and a character string of a cell included in the second table and corresponding to the cell included in the first table in the case of determining that the second table corresponds to the first table (S32).SELECTED DRAWING: Figure 2
Need to check novelty before this filing date? Find Prior Art

Description

[Technical Field]

[0001] The present invention relates to a data comparison method, a data comparison program, and an information processing device. [Background technology]

[0002] The character reading device in Patent Document 1 separates a character string from an original image and a frame line located near the character string.The character reading device then extracts an image of each character included in the character string.The character reading device then identifies the character based on the extracted image of each character. [Prior art documents] [Patent documents]

[0003] [Patent Document 1] Japanese Patent Application Publication No. 11-328309 Summary of the Invention [Problem to be solved by the invention]

[0004] For example, suppose a document containing a table is revised. In this case, it may be necessary to determine whether there were any changes to the items in the table before and after the revision, and if there were any changes, which items in the table were changed. However, the character reading device of Patent Document 1 can only identify characters. Therefore, the character reading device of Patent Document 1 cannot determine whether there were any changes before and after the revision. Note that although the example given here is a case where a document has been revised, the same problem arises when identifying differences between items in two similar tables. [Means for solving the problem]

[0005] A data comparison method for solving the above problem involves an information processing device acquiring character strings for each cell included in a first table in document data, acquiring character strings for each cell included in a second table in the document data that is a different table from the first table, determining whether the second table corresponds to the first table based on the similarity between the character strings in the cells included in the first table and the character strings in the cells included in the second table, and, if it is determined that the second table corresponds to the first table, identifying differences between the character strings in the cells included in the first table and the character strings in cells included in the second table that correspond to cells included in the first table.

[0006] A data comparison program for solving the above problem causes an information processing device to perform the following operations: acquire character strings for each cell contained in a first table in document data; acquire character strings for each cell contained in a second table in the document data that is a table different from the first table; determine whether the second table corresponds to the first table based on the similarity between the character strings in the cells contained in the first table and the character strings in the cells contained in the second table; and, if it is determined that the second table corresponds to the first table, identify differences between the character strings in the cells contained in the first table and the character strings in cells contained in the second table that correspond to cells contained in the first table.

[0007] An information processing device for solving the above problem performs the following steps: acquires character strings for each cell contained in a first table in document data; acquires character strings for each cell contained in a second table in the document data that is a different table from the first table; determines whether the second table corresponds to the first table based on the similarity between the character strings in the cells contained in the first table and the character strings in the cells contained in the second table; and, if it is determined that the second table corresponds to the first table, identifies the difference between the character strings in the cells contained in the first table and the character strings in the cells contained in the second table that correspond to the cells contained in the first table. [Effects of the Invention]

[0008] With the above configuration, even if Table 1 is revised to Table 2, for example, it is possible to determine that Table 2 is a revision of Table 1 based on the similarity of the character strings in the cells contained in each table. It is then possible to identify the difference between the character strings in the cells of Table 1 and the character strings in the cells contained in Table 2 that correspond to the cells of Table 1. [Brief explanation of the drawings]

[0009] [Figure 1] FIG. 1 is a schematic diagram of a data comparison system. [Figure 2] FIG. 2 is a flowchart showing the data comparison control. [Figure 3] FIG. 3 is an explanatory diagram showing a document. [Figure 4] FIG. 4 is an explanatory diagram showing a document. [Figure 5] FIG. 5 is an explanatory diagram showing a plurality of cell similarities. [Figure 6] FIG. 6 is an explanatory diagram showing a plurality of line similarities. [Figure 7] FIG. 7 is an explanatory diagram showing a plurality of table similarities. DETAILED DESCRIPTION OF THE INVENTION

[0010] <Outline of the data comparison system> An embodiment of the present invention will now be described with reference to Figures 1 to 7. First, a schematic configuration of a data comparison system 10 will be described.

[0011] As shown in FIG. 1, the data comparison system 10 includes an information processing device 20, an input device 30, a camera 40, and a display 50. The information processing device 20 includes an execution device 21 and a storage device 22. An example of the execution device 21 is a CPU. The storage device 22 includes a read-only ROM, a readable / writable volatile RAM, and a readable / writable non-volatile storage. The storage device 22 stores various programs and various data in advance. The storage device 22 also stores a data comparison program 22A in advance as one of the various programs. The execution device 21 realizes various processes by executing the programs stored in the storage device 22. The execution device 21 also realizes various processes in the data comparison method by executing the data comparison program 22A stored in the storage device 22. An example of the information processing device 20 is a so-called personal computer.

[0012] The input device 30 includes, for example, a keyboard and a pointing device. The camera 40 is capable of capturing an image of a subject. Therefore, the camera 40 is capable of capturing images of a document 100 and a document 200, which will be described later. The display 50 is capable of displaying various types of information.

[0013] <Data comparison control> Next, the data comparison control executed by the information processing device 20 will be described with reference to Fig. 2. The information processing device 20 executes the data comparison control by executing the data comparison program 22A. In this embodiment, the information processing device 20 executes the data comparison control when, for example, an operator performs an operation to start the data comparison control via the input device 30.

[0014] In the following, as an example of data comparison control, a process for comparing a table included in document 100 with a table included in document 200 will be described. As shown in FIG. 3, document 100 includes Table A, Table B, and Table C. As shown in FIG. 4, document 200 includes Table X, Table Y, and Table Z. In this embodiment, Table A, Table B, and Table C included in document 100 each correspond to Table 1. Furthermore, Table X, Table Y, and Table Z included in document 200 each correspond to Table 2, which is a table different from Table 1. In this embodiment, an example of document 100 and document 200 is an instruction manual that comes with a car when purchased, a so-called owner's manual. Furthermore, document 200 is a revised version of document 100.

[0015] As shown in FIG. 2, when the information processing device 20 starts data comparison control, it executes the process of step S11. In step S11, the information processing device 20 acquires image data of document 100 and image data of document 200 using camera 40. Note that each image data acquired in step S11 is an example of document data. Furthermore, the information processing device 20 extracts Table A, Table B, and Table C contained in document 100 from the image data of document 100. Similarly, the information processing device 20 extracts Table X, Table Y, and Table Z contained in document 200 from the image data of document 200. After step S11, the information processing device 20 proceeds to the process of step S12.

[0016] In step S12, the information processing device 20 acquires character strings for each cell included in Table A. Specifically, the information processing device 20 acquires character strings from image data of the document 100 using optical character recognition, or OCR. At this time, the information processing device 20 identifies characters included in the character strings by using a trained model that has been trained in advance by machine learning. Note that a well-known configuration such as that described in Japanese Patent Application Laid-Open No. 11-328309 can be used as a configuration for identifying characters in this manner. Similarly, the information processing device 20 acquires character strings for all cells included in Table A. Furthermore, in the same manner as above, the information processing device 20 acquires character strings for each cell included in Table B, Table C, Table X, Table Y, and Table Z. After step S12, the information processing device 20 proceeds to step S21.

[0017] In step S21, the information processing device 20 calculates cell similarity SC, which is the degree of similarity between the character string of a cell included in the first table and the character string of a cell included in the second table. As a specific example, the information processing device 20 calculates cell similarity SC between the character string of a cell included in Table A and the character string of a cell included in Table X. At this time, the information processing device 20 calculates cell similarity SC for all combinations of cells included in Table A and cells included in Table X. For example, as shown in FIG. 3, it is assumed that Table A has three rows and two columns. Therefore, Table A includes a total of six cells, cells A11 to A32. Furthermore, it is assumed that Table X has two rows and two columns, as shown in FIG. 4. Therefore, Table X includes a total of four cells, cells X11 to X22. In this case, the information processing device 20 calculates cell similarity SC between the character string of cell A11 and the character string of cell X11, for example. Specifically, the information processing device 20 calculates cell similarity SC using the following formula (1).

[0018] Equation (1): Cell similarity SC = (2 × NW3) / (NW1 + NW2) Here, "NW1" is the number of characters in the string in cell A11. Furthermore, "NW2" is the number of characters in the string in cell X11. Furthermore, "NW3" is the number of characters that match between the string in cell A11 and the string in cell X11. For example, suppose the string in cell A11 is "Engine1234". Furthermore, suppose the string in cell X11 is "Engine1239". In this case, "NW1" is "10". Furthermore, "NW2" is "10". Furthermore, "NW3" is "9". Therefore, the cell similarity SC is "0.9".

[0019] As described above, the information processing device 20 calculates cell similarities SC for all combinations of cells included in Table A and cells included in Table X. That is, the information processing device 20 calculates cell similarities SC for cell A11 and cells X11 to X22. The information processing device 20 also calculates cell similarities SC for cell A12 and cells X11 to X22. Similarly, the information processing device 20 calculates cell similarities SC for cells A21 to A32 and cells X11 to X22. Therefore, in the above example, the information processing device 20 calculates a total of 24 cell similarities SC for all combinations of cells included in Table A and cells included in Table X.

[0020] Similarly, the information processing device 20 calculates the cell similarity SC between the character string of a cell included in Table A and the character string of a cell included in Table Y. The information processing device 20 also calculates the cell similarity SC between the character string of a cell included in Table A and the character string of a cell included in Table Z. In the same manner as above, the information processing device 20 calculates the cell similarity SC between the character string of a cell included in Table B and the character string of a cell included in Tables X to Z. The information processing device 20 also calculates the cell similarity SC between the character string of a cell included in Table C and the character string of a cell included in Tables X to Z. Therefore, in the above example, the information processing device 20 calculates the cell similarity SC for all combinations of Tables A to C and Tables X to Z, a total of nine table combinations. As shown in FIG. 2, after step S21, the information processing device 20 proceeds to the process at step S22.

[0021] In step S22, the information processing device 20 organizes the calculated cell similarities SC by row of Table A and by row of Table X. Then, the information processing device 20 extracts multiple cell similarities SC including the highest value from the cell similarities SC for each row. In this embodiment, the information processing device 20 extracts the top two cell similarities SC from the multiple cell similarities SC. For example, focus is placed on the first row of Table A and the first row of Table X. In this case, the first row of Table A includes cells A11 and A12. Furthermore, the first row of Table X includes cells X11 and X12. Therefore, in the above-mentioned step S21, the information processing device 20 calculates a total of four cell similarities SC as shown in FIG. 5 by comparing the first row of Table A with the first row of Table X. In this case, in step S22, the information processing device 20 extracts, from a total of four cell similarities SC, the cell similarity SC between cell A11 and cell X11 of "0.9" and the cell similarity SC between cell A12 and cell X12 of "0.7". Similarly, the information processing device 20 extracts cell similarities SC for all combinations of rows included in Table A and rows included in Table X in Table A and Table X.

[0022] Similarly to the above, the information processing device 20 extracts a plurality of cell similarities SC including the highest value from among the cell similarities SC for each row for Table A and Table Y. The information processing device 20 also extracts a plurality of cell similarities SC including the highest value from among the cell similarities SC for each row for Table A and Table Z. Furthermore, in the same manner as above, the information processing device 20 extracts a plurality of cell similarities SC including the highest value from among the cell similarities SC for each row for Table B and Tables X to Z. The information processing device 20 also extracts a plurality of cell similarities SC including the highest value from among the cell similarities SC for each row for Table C and Tables X to Z. As shown in FIG. 2, after step S22, the information processing device 20 proceeds to step S23.

[0023] In step S23, the information processing device 20 calculates a row similarity SL based on the extracted cell similarity SC for each row. Specifically, the information processing device 20 calculates the average value of the extracted cell similarities SC for each row as the row similarity SL. The row similarity SL is the similarity between the character strings in a row included in the first table and the character strings in a row included in the second table. For example, when focusing on the first row of Table A and the first row of Table X, the cell similarities SC for each row extracted by the information processing device 20 in step S22 described above are "0.9" and "0.7." In this case, as shown in FIG. 6, the information processing device 20 calculates "0.8," which is the average of "0.9" and "0.7," as the row similarity SL between the first row of Table A and the first row of Table X. Similarly, the information processing device 20 calculates the row similarity SL for all combinations of a row included in Table A and a row included in Table X in Tables A and X.

[0024] Similarly to the above, the information processing device 20 calculates row similarity SL for Table A and Table Y based on the extracted cell similarity SC for each row. Also, the information processing device 20 calculates row similarity SL for Table A and Table Z based on the extracted cell similarity SC for each row. Furthermore, in the same manner as above, the information processing device 20 calculates row similarity SL for Table B and each of Tables X to Z based on the extracted cell similarity SC for each row. Also, the information processing device 20 calculates row similarity SL for Table C and each of Tables X to Z based on the extracted cell similarity SC for each row. As shown in FIG. 2, after step S23, the information processing device 20 proceeds to the process at step S24.

[0025] In step S24, the information processing device 20 extracts, for each combination of tables, a plurality of row similarities SL including the highest value from among the calculated row similarities SL. In this embodiment, the information processing device 20 extracts the top two row similarities SL from among the plurality of row similarities SL. For example, when focusing on the combination of Table A and Table X, in step S23 described above, the information processing device 20 calculates a total of six row similarities SL as shown in FIG. 6. In this case, in step S24, the information processing device 20 extracts "0.8" and "1.0" as the top two row similarities SL from among the total of six calculated row similarities SL.

[0026] Similarly, the information processing device 20 extracts a plurality of row similarities SL including the highest value from among the calculated row similarities SL for the combination of Table A and Table Y. Furthermore, the information processing device 20 extracts a plurality of row similarities SL including the highest value from among the calculated row similarities SL for the combination of Table A and Table Z. Furthermore, in the same manner as above, the information processing device 20 extracts a plurality of row similarities SL including the highest value from among the calculated row similarities SL for each combination of Table B and Tables X to Z. Furthermore, the information processing device 20 extracts a plurality of row similarities SL including the highest value from among the calculated row similarities SL for each combination of Table C and Tables X to Z. As shown in FIG. 2, after step S24, the information processing device 20 proceeds to step S25.

[0027] In step S25, the information processing device 20 calculates a table similarity ST for each combination of tables based on the extracted row similarities SL. Specifically, the information processing device 20 sets the average value of the extracted row similarities SL as the table similarity ST. For example, when focusing on the combination of Table A and Table X, the row similarities SL extracted by the information processing device 20 in the above-mentioned step S24 are "0.8" and "1.0". In this case, as shown in FIG. 7, the information processing device 20 calculates "0.9", which is the average value of "0.8" and "1.0", as the table similarity ST for Table A and Table X.

[0028] Similarly, the information processing device 20 calculates a table similarity ST for the combination of Table A and Table Y based on the extracted row similarity SL. Furthermore, the information processing device 20 calculates a table similarity ST for the combination of Table A and Table Z based on the extracted row similarity SL. Furthermore, in the same manner as above, the information processing device 20 calculates a table similarity ST for each combination of Table B and Tables X to Z based on the extracted row similarity SL. Furthermore, the information processing device 20 calculates a table similarity ST for each combination of Table C and Tables X to Z based on the extracted row similarity SL. As shown in FIG. 2, after step S25, the information processing device 20 advances the process to step S31.

[0029] In step S31, the information processing device 20 identifies corresponding tables based on the calculated table similarity ST. Specifically, the information processing device 20 determines whether the table similarity ST for each combination of tables is equal to or greater than a predetermined value. If the table similarity ST is equal to or greater than the predetermined value, the information processing device 20 determines that the second table corresponds to the first table. An example of the predetermined value is "0.9." For example, when comparing a table included in document 100 with a table included in document 200, in step S25 described above, the information processing device 20 calculates a total of nine table similarities ST as shown in FIG. 7. In this example, the table similarity ST between table A and table X is "0.9." As a result, the information processing device 20 determines that table A and table X correspond to each other. Furthermore, the table similarity ST between table B and table Z is "0.9." As a result, the information processing device 20 determines that table B and table Z correspond to each other. As shown in FIG. 2, after step S31, the information processing device 20 advances the process to step S32.

[0030] In step S32, for the first and second tables determined to correspond to each other in step S31, the information processing device 20 identifies a difference between the character string of a cell included in the first table and the character string of a cell included in the second table that corresponds to the cell included in the first table. In other words, if the information processing device 20 determines in step S31 that the second table corresponds to the first table, the information processing device 20 identifies a difference between the character string of a cell included in the first table and the character string of a cell included in the second table that corresponds to the cell included in the first table. The information processing device 20 identifies the difference in character strings, for example, as follows. As a specific example, when Table A and Table X correspond to each other, the information processing device 20 determines that, of all the cell similarities SC in Table A and Table X, cells having a cell similarity SC equal to or greater than a specified value correspond to the cells in Table 1 and Table 2. Here, it is assumed that cell A11 included in Table A corresponds to cell X11 included in Table X. It is also assumed that the character string in cell A11 is "Engine1234." Furthermore, suppose the character string in cell X11 is "Engine1239." In this case, the information processing device 20 identifies the "4" in the character string "Engine1234" in cell A11 as a difference in the character string. Furthermore, the information processing device 20 identifies the "9" in the character string "Engine1239" in cell X11 as a difference in the character string. After step S32, the information processing device 20 proceeds to the process at step S33.

[0031] In step S33, information processing device 20 determines whether or not there is a corresponding table between the table included in document 100 and the table included in document 200. If information processing device 20 determines in step S33 that there is a corresponding table (S33: YES), information processing device 20 proceeds to step S41.

[0032] In step S41, the information processing device 20 displays the corresponding tables on the display 50. Specifically, the information processing device 20 displays the corresponding tables on the display 50 by outputting a control signal to the display 50. At this time, the information processing device 20 displays the corresponding tables, for example, side by side on the display 50. The information processing device 20 also displays the differences in the character strings identified in step S32 on the display 50. In this embodiment, the information processing device 20 displays the identified differences in the character strings on the display 50, for example, by highlighting them. For example, if Table A and Table X correspond to each other, the information processing device 20 displays Table A and Table X side by side on the display 50. Also, for example, it is assumed that cell A11 included in Table A corresponds to cell X11 included in Table X, and that there is a difference between the character strings in cell A11 and cell X11. Furthermore, it is assumed that the character string in cell A11 is "Engine1234." It is also assumed that the character string in cell X11 is "Engine1239." In this case, the information processing device 20 highlights the "4" in the character string "Engine1234" in cell A11 and displays it on the display 50. The information processing device 20 also highlights the "9" in the character string "Engine1239" in cell X11 and displays it on the display 50. After step S41, the information processing device 20 ends the current data comparison control.

[0033] On the other hand, if the information processing device 20 determines in step S33 that there is no corresponding table (S33: NO), the information processing device 20 advances the process to step S42. In step S42, the information processing device 20 displays on the display 50 that there is no corresponding table. Specifically, the information processing device 20 displays on the display 50 that there is no corresponding table by outputting a control signal to the display 50. After step S42, the information processing device 20 ends the current data comparison control.

[0034] <Operation of this embodiment> The information processing device 20 executes data comparison control targeting, for example, document 100 and document 200. At this time, in step S21, the information processing device 20 calculates cell similarity SC, which is the similarity between the character strings in the cells of a first table included in document 100 and the character strings in the cells of a second table included in document 200. In step S23, the information processing device 20 calculates row similarity SL based on the cell similarity SC for each row of the first and second tables. In step S25, the information processing device 20 calculates table similarity ST based on the row similarity SL for the first and second tables. In step S31, the information processing device 20 determines whether the table similarity ST is equal to or greater than a predetermined value. If the table similarity ST is equal to or greater than the predetermined value, the information processing device 20 determines that the second table corresponds to the first table. Then, in step S32, if the information processing device 20 determines in step S31 that the second table corresponds to the first table, it identifies the difference between the character string of the cell contained in the first table and the character string of the cell contained in the second table that corresponds to the cell contained in the first table.

[0035] <Effects of this embodiment> (1) For example, when document 100 is revised to become document 200, table A included in document 100 is revised to become table X included in document 200. In this case, cell similarity SC, which is the similarity between the character strings in the cells included in table A and table X, tends to be high. Therefore, row similarity SL and table similarity ST between table A and table X also become high. If table similarity ST is equal to or greater than a specified value, information processing device 20 determines that table A and table X correspond to each other. Therefore, even if table A is revised to table X, for example, it is possible to determine whether table A and table X correspond to each other, i.e., whether table X is a revision of table A, based on cell similarity SC. For example, if cell A11 included in table A corresponds to cell X11 included in table X and there is a difference between the character strings in cell A11 and cell X11, the difference between the character strings in cell A11 and cell X11 can be identified.

[0036] (2) For example, suppose that Table X is a revised version of Table A, while Table Y is a completely different type of table from Table A. In this case, there is a strong need to identify the differences in the character strings in the cells of Table A and Table X, but there is little need to identify the differences in the character strings in the cells of Table A and Table Y.

[0037] In this regard, the information processing device 20 identifies differences in the character strings of cells contained in Tables A and X when Table A and Table X correspond to each other, in other words, when, for example, Table A has been revised to Table X or the contents of Tables A and X are similar. This makes it possible to identify differences in the character strings of cells contained in Tables A and X in situations where there is a high need to identify differences in the character strings of cells contained in Tables A and X.

[0038] (3) For example, if Table A is revised to Table X, the cell similarity SC for cells whose cell text remains unchanged due to the revision will be high. On the other hand, the cell similarity SC for cells whose cell text has been changed due to the revision will be low. Therefore, if we were to determine whether Table A and Table X correspond based on the average value of the cell similarity SC for all combinations of cells included in Table A and cells included in Table X, the relatively low average value would likely lead to a determination that Table A and Table X do not correspond.

[0039] In this regard, in step S22, the information processing device 20 extracts a plurality of cell similarities SC including the highest value from among the calculated cell similarities SC for each row. Then, in step S23, the information processing device 20 calculates row similarities SL based on the extracted cell similarities SC for each row. In other words, the information processing device 20 determines whether or not Table A and Table X correspond to each other based on the cell similarities SC of cells that have not been changed or have been changed only slightly due to revision. This makes it possible to more reliably determine that Table A and Table X correspond to each other, for example, when Table A is revised to Table X, even if the cell similarities SC of cells whose character strings have been changed due to revision become lower.

[0040] (4) For example, even if Table A is not revised to Table X, it is possible that some of the multiple cell similarities SC between Table A and Table X may become high simply because Table A and Table X are similar. On the other hand, for example, if Table A is revised to Table X, it is highly likely that some rows will be deleted from the multiple rows contained in Table A, or new rows will be added to Table A. As a result, not only will some of the multiple cell similarities SC between Table A and Table X become high, but some of the multiple row similarities SL between Table A and Table X tend to become significantly high.

[0041] In this regard, in step S24, the information processing device 20 extracts a plurality of line similarities SL including the highest value from among the calculated line similarities SL. Then, in step S25, the information processing device 20 calculates table similarities ST based on the extracted line similarities SL. This makes it possible to determine that, for example, Table A and Table X correspond to each other in a situation where there is a high possibility that Table A has been revised to Table X.

[0042] <Example of change> This embodiment can be modified as follows: This embodiment and the following modifications can be combined and implemented within the scope of technical compatibility.

[0043] In the above embodiment, the data comparison control may be changed. For example, the configuration for extracting a table in step S11 may be changed. As a specific example, if the storage device 22 stores document data of the document 100 and the document 200 in advance, the information processing device 20 may extract Table A, Table B, Table C, Table X, Table Y, and Table Z from the document data stored in the storage device 22. Note that the document data may be in a format different from that of the image data. In other words, the format of the document data may be changed. Furthermore, the document data from which the table is extracted in step S11 may be the document data of one of the document 100 and the document 200. In other words, the information processing device 20 may extract the first and second tables from the same document data.

[0044] For example, the configuration for acquiring the character string for each cell in step S12 may be changed. As a specific example, if the storage device 22 stores document data for the document 100 and the document 200 in advance, the information processing device 20 may acquire the character string for each cell from the document data stored in the storage device 22.

[0045] For example, the calculation configuration of the row similarity SL in step S23 may be changed. As a specific example, the information processing device 20 may calculate the row similarity SL of a row based on all the cell similarities SC included in that row calculated in step S21. Note that with this configuration, the processing of step S22 can be omitted.

[0046] For example, in step S23, column similarity may be calculated instead of row similarity SL. As a specific example, the information processing device 20 may calculate the column similarity of a column based on the multiple cell similarities SC included in each column calculated in step S21. Here, the column similarity is the similarity between the character strings in the column included in the first table and the character strings in the column included in the second table. In this case, in step S22, the information processing device 20 preferably extracts the multiple cell similarities SC including the highest value from the calculated cell similarities SC for each column. Note that the processing of step S22 may be omitted.

[0047] For example, the calculation configuration of the table similarity ST in step S25 may be changed. As a specific example, the information processing device 20 may calculate the table similarity ST based on all the row similarities SL calculated in step S23. Note that with this configuration, the processing of step S24 can be omitted.

[0048] In the above embodiment, the configuration of the data comparison system 10 may be changed. For example, the data comparison system 10 may use, instead of the camera 40, an input device that converts documents and the like into image data, that is, a so-called scanner. [Explanation of symbols]

[0049] SC...cell similarity SL...row similarity ST...table similarity 10...data comparison system 20...information processing device 21...execution device 22...storage device 22A...data comparison program 30...input device 40...camera 50...display 100...document 200...document

Claims

1. The information processing device Obtaining a character string for each cell included in the first table in the document data; acquiring character strings for each cell included in a second table in the document data, the second table being a table different from the first table; determining whether the second table corresponds to the first table based on the similarity between a character string in a cell included in the first table and a character string in a cell included in the second table; When it is determined that the second table corresponds to the first table, identifying a difference between a character string in a cell included in the first table and a character string in a cell included in the second table that corresponds to a cell included in the first table; Run Data comparison methods.

2. When the similarity between the character string of a cell included in the first table and the character string of a cell included in the second table is defined as cell similarity, The information processing device, calculating the cell similarity for all combinations of cells included in the first table and cells included in the second table; extracting a plurality of the cell similarities having the highest value from among the calculated cell similarities; determining whether the second table corresponds to the first table based on an average value of the extracted plurality of cell similarities; Run The data comparison method according to claim 1 .

3. When the similarity between a character string in a row included in the first table and a character string in a row included in the second table is defined as a row similarity, The information processing device, calculating the row similarity based on an average value of the cell similarity for all combinations of rows included in the first table and rows included in the second table; extracting a plurality of the line similarities having the highest value from among the calculated line similarities; determining that the second table corresponds to the first table on the condition that an average value of the extracted plurality of row similarities is equal to or greater than a predetermined value; Run 3. The data comparison method according to claim 2.

4. In the information processing device, Obtaining a character string for each cell included in the first table in the document data; acquiring character strings for each cell included in a second table in the document data, the second table being a table different from the first table; determining whether the second table corresponds to the first table based on the similarity between a character string in a cell included in the first table and a character string in a cell included in the second table; When it is determined that the second table corresponds to the first table, identifying a difference between a character string in a cell included in the first table and a character string in a cell included in the second table that corresponds to a cell included in the first table; Run Data comparison program.

5. Obtaining a character string for each cell included in the first table in the document data; acquiring character strings for each cell included in a second table in the document data, the second table being a table different from the first table; determining whether the second table corresponds to the first table based on the similarity between a character string in a cell included in the first table and a character string in a cell included in the second table; When it is determined that the second table corresponds to the first table, identifying a difference between a character string in a cell included in the first table and a character string in a cell included in the second table that corresponds to a cell included in the first table; Run Information processing device.

Citation Information

Patent Citations

  • Method and device for optical character read

    JP1999328309A

  • Document data comparison method, document data comparison apparatus, and document data comparison program

    JP2015069393A

  • Information processing device and information processing program

    JP2016105214A

  • Information processing apparatus, image reading device, image forming apparatus, and program

    JP2017102587A

  • Classifier learning device, table type classifier, method, and program

    JP2017201482A