File scanning processing method, intelligent terminal and storage medium
By detecting the gap information in the file, the document blocks are segmented and sorted, which solves the problem of low efficiency of document block sorting in the existing OCR technology and realizes efficient document block processing on the mobile terminal.
Patent Information
- Application Number
- CN201910375483.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-05-07
- Publication Date
- 2024-09-13
- Estimated Expiration
- 2039-05-07
AI Technical Summary
Existing OCR technology is inefficient in sorting document blocks and is not suitable for mobile deployment. It is time-consuming and difficult to achieve complex segmentation and sorting of document blocks.
By detecting horizontal and vertical gaps in the file, the document blocks are divided into multiple sets and sorted according to the preset order. The gap information is used to improve the efficiency of document block segmentation and sorting.
The efficiency of document block segmentation and sorting has been improved, which is suitable for mobile application scenarios, takes less time and is easy to implement.
Smart Images

Figure CN112001390B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a file scanning and processing method, an intelligent terminal and a storage medium. Background Art
[0002] Optical Character Recognition (OCR) refers to the process in which an electronic device (such as a scanner or digital camera) examines characters printed on paper, determines the character shape by detecting dark and light patterns, and then uses character recognition methods to translate the character shape into computer text; that is, for printed characters, an optical method is used to convert the text in a paper document into a black and white dot matrix image file, and recognition software is used to convert the text in the image into text format for further editing and processing by word processing software.
[0003] In the existing OCR technical solutions, the document blocks in the file are usually sorted based on a predefined set of rules, or based on computer vision and machine learning algorithms. However, the above two technical solutions are very complex to implement, have high requirements on the operating environment, are not suitable for deployment and application on mobile terminals, and the document block sorting takes a long time and is inefficient. Summary of the invention
[0004] The embodiments of the present invention provide a file scanning and processing method, an intelligent terminal and a storage medium, which can effectively improve the efficiency of document block segmentation and sorting and increase the application scenarios of document block segmentation and sorting.
[0005] On the one hand, an embodiment of the present invention provides a file scanning processing method, the method comprising:
[0006] Scan the file to be processed to obtain target document scan data, wherein the target document scan data includes multiple document content blocks and position information of the document content blocks in the file to be processed;
[0007] Determine, according to the position information of the document content blocks, a first type of gap in the horizontal direction of the to-be-processed file, and divide the plurality of document content blocks into N document block sets according to the first type of gap, where N is a positive integer greater than 1;
[0008] In the vertical direction of the to-be-processed file, gap detection is performed on a first set of two or more document blocks in the N document block sets to determine a second type of gap;
[0009] dividing the first collection into a plurality of document blocks according to the second type of gaps;
[0010] The document blocks in the second set including only one document block in the N document block sets and the multiple document blocks obtained by dividing the first set are sorted in a preset order to obtain a sorting result.
[0011] On the other hand, an embodiment of the present invention provides a file scanning and processing device, the device comprising:
[0012] A scanning unit, used for scanning the file to be processed to obtain target document scanning data, wherein the target document scanning data includes a plurality of document content blocks and position information of the document content blocks in the file to be processed;
[0013] a processing unit, configured to determine, according to the position information of the document content blocks, a first type of gap in the horizontal direction of the to-be-processed file, and divide the plurality of document content blocks into N document block sets according to the first type of gap, where N is a positive integer greater than 1;
[0014] The processing unit is further configured to perform gap detection on a first set of two or more document blocks in the N document block sets in the vertical direction of the to-be-processed file to determine a second type of gap;
[0015] The processing unit is further configured to divide the first set into a plurality of document blocks according to the second type of gaps;
[0016] The sorting unit is used to sort the document blocks in the second set including only one document block in the N document block sets and the multiple document blocks obtained by dividing the first set in a preset order to obtain a sorting result.
[0017] On the other hand, an embodiment of the present invention provides an intelligent terminal, including: a processor and a memory, wherein the memory stores executable program codes, and the processor is used to call the executable program codes to execute the above-mentioned file scanning processing method.
[0018] Correspondingly, an embodiment of the present invention further provides a storage medium, in which instructions are stored, and when the storage medium is run on a computer, the computer executes the above-mentioned file scanning and processing method.
[0019] The embodiment of the present invention divides multiple document content blocks into N document block sets according to a first type of gap in the horizontal direction, performs gap detection on a first set of the N document block sets in the vertical direction, determines a second type of gap, and divides the first set into multiple document blocks according to the second type of gap, and then sorts the document blocks in the second set of the N document block sets and the multiple document blocks obtained by dividing the first set in a preset order to obtain a sorting result, so that the document blocks in the file can be divided and sorted based on the gaps. The technical solution is time-saving and easy to implement, and can effectively improve the efficiency of document block segmentation and sorting, and increase the application scenarios of document block segmentation and sorting. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0021] Figure 1 It is a flowchart of a file scanning processing method provided by an embodiment of the present invention;
[0022] Figure 2a is a schematic diagram of a page of a file to be processed provided by the first embodiment of the present invention;
[0023] Figure 2b is based on Figure 2a Schematic diagram of the tree constructed from the segmentation results shown in;
[0024] Figure 3a is a schematic diagram of a page of a file to be processed provided by a second embodiment of the present invention;
[0025] Figure 3b yes Figure 3a Schematic diagram of the document content block after shrinkage processing shown in ;
[0026] Figure 3c is a schematic diagram of a page of a file to be processed provided by a third embodiment of the present invention;
[0027] Figure 3d yes Figure 3c A schematic diagram of the document content blocks after merging shown in ;
[0028] Figure 3e is a schematic diagram of a page of a file to be processed provided by a fourth embodiment of the present invention;
[0029] Figure 4It is a structural schematic diagram of a file scanning and processing device provided by an embodiment of the present invention;
[0030] Figure 5 It is a structural schematic diagram of an intelligent terminal provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0031] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings in the embodiments of the present invention.
[0032] In the embodiment of the present invention, the intelligent terminal may be a terminal such as a smart phone (such as an Android phone, an iOS phone, a Windows Phone phone, etc.), a tablet computer, a mobile Internet device (Mobile Internet Devices, MID), a computer, etc. The intelligent terminal scans and processes the image file corresponding to the to-be-processed file to obtain the target document scan data, wherein the target document scan data includes multiple document content blocks and the position information of the document content blocks in the to-be-processed file; then, according to the position information of the document content blocks, the first type of gap in the horizontal direction of the to-be-processed file is determined, and the first type of gap refers to the gap (Gap) that divides the multiple document content blocks into at least two parts in the vertical direction of the to-be-processed file; after determining the first type of gap, the multiple document content blocks are divided into multiple document block sets according to the first type of gap. Further, the intelligent terminal performs gap detection on the first set of the multiple document block sets in the vertical direction of the to-be-processed file to determine the second type of gap. The first set is a document block set including two or more document blocks in the multiple document block sets, and the second type of gap refers to the gap that divides the first set into at least two parts in the horizontal direction of the to-be-processed file. After determining the second type of gaps, the intelligent terminal divides the first set into multiple document blocks according to the second type of gaps. Furthermore, the intelligent terminal sorts the document blocks in the second set that only includes one document block in the multiple document block sets and the multiple document blocks obtained by dividing the first set in a preset order to obtain a sorting result. In the above manner, the document blocks in the file can be divided and sorted based on the gaps in the horizontal and vertical directions. This technical solution is time-saving and easy to implement, which can effectively improve the efficiency of document block segmentation and sorting and increase the application scenarios of document block segmentation and sorting.
[0033] See also Figure 1 , Figure 1 A flowchart of a file scanning processing method provided by an embodiment of the present invention. The file scanning processing method described in the embodiment of the present invention includes:
[0034] S101. The intelligent terminal scans a file to be processed to obtain target document scan data, wherein the target document scan data includes multiple document content blocks and position information of the document content blocks in the file to be processed.
[0035] In an embodiment of the present invention, the target document scan data includes multiple document content blocks and position information of the document content blocks in the file to be processed. The multiple document content blocks are obtained by preliminary segmentation of the content in the file to be processed during the scanning process of the file to be processed by the intelligent terminal; the file to be processed may include text, pictures and other contents; the document content block may include one or more sub-document content blocks. The position information of the document content block is used to indicate the relative coordinates of the document content block in the page of the file to be processed, and can be specifically used to indicate the margin coordinate value of the document content block in the page of the file to be processed, and the margin coordinate value includes one or more of the upper margin coordinate value, the lower margin coordinate value, the left margin coordinate value and the right margin coordinate value.
[0036] The file to be processed may refer to an image file converted from a paper file, or may refer to a paper file. In the case where the file to be processed refers to an image file converted from a paper file, the intelligent terminal directly scans and processes the file to be processed to obtain the target document scan data. In one embodiment, the intelligent terminal may use its configured OCR module to scan the file to be processed to obtain the target document scan data. In the case where the file to be processed refers to a paper file, the intelligent terminal first controls its configured image acquisition device to acquire the image file corresponding to the file to be processed; then obtains the image file corresponding to the file to be processed output by the image acquisition device, and scans and processes the image file corresponding to the file to be processed to obtain the target document scan data. In one embodiment, the image acquisition device may be a scanner or a shooting device. The image acquisition device may be set in the intelligent terminal or may be independent of the intelligent terminal. When the image acquisition device is independent of the intelligent terminal, the intelligent device communicates with the image acquisition device via a wired or wireless method to control the image acquisition device to perform the task operation.
[0037] In one embodiment, before the intelligent terminal scans and processes the image file corresponding to the file to be processed, it first performs image preprocessing on the image file corresponding to the file to be processed to obtain the preprocessed image file. Further, the intelligent terminal scans and processes the preprocessed image file to obtain the target document scan data. The image preprocessing includes image binarization, tilt correction, etc. Image binarization refers to converting a color or grayscale image into a binary image, and tilt correction is used to compensate for image tilt to correct the tilted image. Performing image preprocessing on the image file corresponding to the file to be processed can speed up the subsequent scanning process to a certain extent, and improve the accuracy of the scanning process results.
[0038] In one embodiment, the intelligent terminal scans and processes the image file corresponding to the file to be processed to obtain initial document scan data, which includes multiple initial document content blocks and position information of the initial document content blocks in the page of the file to be processed; then, it is determined whether the multiple initial document content blocks meet the preset merging conditions. If the intelligent terminal determines that the multiple initial document content blocks do not meet the preset merging conditions, the initial document scan data is used as the target document scan data. If the intelligent terminal determines that the multiple initial document content blocks meet the preset merging conditions, the mergeable document content blocks in the multiple initial document content blocks are merged to obtain multiple document content block sets; then, the document scan data corresponding to each document content block set in the multiple document content block sets is obtained, and the document scan data corresponding to each document content block set is used as the target document scan data.
[0039] The fact that the multiple initial document content blocks meet the preset merging condition means that: the number of the multiple initial document content blocks is greater than a preset number threshold, and / or the distribution mode of the multiple initial document content blocks in the to-be-processed file is a target distribution mode. The target distribution mode may mean that: there are target-type gaps in the to-be-processed file, and the target-type gaps refer to gaps that divide the multiple initial document content blocks into at least two parts in the horizontal direction of the to-be-processed file and run through the pages of the to-be-processed file in the vertical direction of the to-be-processed file.
[0040] The mergeable document content blocks refer to: document content blocks whose position offset from adjacent document content blocks in the to-be-processed file is within a preset offset range, and the adjacent document content blocks. Specifically, assuming that the first document content block is any one of the multiple initial document content blocks, and the second document content block is a document content block adjacent to the first document content block in the upper or lower direction among the multiple initial document content blocks; if the smart terminal detects that the difference between the coordinate value of the left limit position of the first document content block and the coordinate value of the left limit position of the second document content block is less than or equal to the first preset offset threshold, and detects that the difference between the coordinate value of the right limit position of the first document content block and the coordinate value of the right limit position of the second document content block is less than or equal to the second preset offset threshold; then the first document content block and the second document content block are determined to be document content blocks that can be merged among the multiple initial document content blocks. Assuming that the third document content block is any one of the multiple initial document content blocks, and the fourth document content block is a document content block adjacent to the third document content block in the left or right direction among the multiple initial document content blocks; if the smart terminal detects that the difference between the coordinate value of the upper limit position of the third document content block and the coordinate value of the upper limit position of the fourth document content block is less than or equal to the third preset offset threshold, and detects that the difference between the coordinate value of the right limit position of the third document content block and the coordinate value of the right limit position of the fourth document content block is less than or equal to the fourth preset offset threshold; then it is determined that the third document content block and the fourth document content block are document content blocks that can be merged among the multiple initial document content blocks.
[0041] S102: The intelligent terminal determines a first type of gap in the horizontal direction of the to-be-processed file according to position information of the document content blocks, and divides the plurality of document content blocks into N document block sets according to the first type of gap.
[0042] In the embodiment of the present invention, the direction corresponding to the first type of gap is parallel to the horizontal direction of the to-be-processed file, and the first type of gap refers to a gap that divides the multiple document content blocks included in the target document scan data into at least two parts in the vertical direction of the to-be-processed file, and runs through the page of the to-be-processed file in the horizontal direction of the to-be-processed file. The gap value corresponding to the first type of gap is greater than or equal to the first gap reference value, and the gap value corresponding to the first type of gap refers to: the size of the interval between two adjacent parts into which the multiple document content blocks are divided by the first type of gap.
[0043] In one embodiment, the first gap reference value is determined based on the gap value of all or part of the gaps that runs through the page of the to-be-processed file in the horizontal direction of the to-be-processed file. The intelligent terminal obtains the gap value of all or part of the gaps that runs through the page of the to-be-processed file in the horizontal direction of the to-be-processed file; then the obtained gap values are counted to determine the number of gaps corresponding to each gap value; the gap value with the largest number of corresponding gaps is used as the first gap reference value. For example, the intelligent terminal uses a histogram to count the obtained gap values to determine the number of gaps corresponding to each gap value; assuming that the obtained gap values include 10mm and 20mm, according to the statistical results of the histogram, the number of gaps corresponding to the gap value 10mm is 1, and the number of gaps corresponding to the gap value 20mm is 4; the intelligent terminal uses the gap value 20mm as the first gap reference value. In another embodiment, the first gap reference value is determined based on the gap value of the gap that runs through the page of the to-be-processed file in the horizontal direction of the to-be-processed file and the gap value is greater than or equal to the first preset value. Since there may be gaps between text lines, but the gap values between text lines are usually small, when determining the first gap reference value, the gaps between text lines can be filtered out first, thereby ensuring that the first gap reference value is greater than the gap value between text lines, avoiding the segmentation of text lines, and to a certain extent ensuring that the segmented document blocks are text paragraphs.
[0044] In one embodiment, the intelligent terminal sorts the multiple document content blocks included in the target document data in the order of the upper limit coordinate value indicated by the position information of the document content block from small to large; in the sorting process, a current maximum lower limit coordinate value is recorded, and then the multiple document content blocks are traversed for comparison; if the comparison result indicates that the upper limit coordinate value of a certain document content block is greater than the current maximum lower limit coordinate value, and the difference between the two is greater than or equal to a preset threshold, or greater than or equal to the above-mentioned first preset interval threshold; the intelligent terminal determines that there is a gap between the certain document content block and the document content block corresponding to the current maximum lower limit coordinate value. Further, the intelligent terminal detects whether the gap can penetrate the page of the to-be-processed file in the horizontal direction of the to-be-processed file. If it is detected that the gap can penetrate the page of the to-be-processed file in the horizontal direction of the to-be-processed file, the gap is determined to be a first-class gap. In the above manner, all first-class gaps between the multiple document content blocks can be determined. In another embodiment, if the intelligent terminal detects that there is a gap in a certain document content block according to the position information of the sub-document content block in the to-be-processed file, it further detects whether the gap can penetrate the page of the to-be-processed file in the horizontal direction of the to-be-processed file, and if so, it determines that the gap is a first-class gap. In the above manner, the first-class gap in each document content block can be determined.
[0045] Furthermore, after the intelligent terminal determines the first type of gaps in the horizontal direction of the to-be-processed file, the plurality of document content blocks are divided into N document block sets according to the first type of gaps. N is a positive integer greater than 1, and each of the N document block sets includes one, two or more document blocks; the one, two or more document blocks included in each document block set may belong to the same document content block or may belong to different document content blocks; the document block may be a document content block or a sub-document content block in a document content block.
[0046] In one embodiment, the intelligent terminal first determines whether there is a first type of gap in the horizontal direction of the to-be-processed file according to the position information of the document content block; if it is determined that there is a first type of gap in the horizontal direction of the to-be-processed file, the plurality of document content blocks are divided into N document block sets according to the determined first type of gap. If it is determined that there is no first type of gap in the horizontal direction of the to-be-processed file, the intelligent terminal first performs a preset ratio shrinkage process on the plurality of document content blocks according to the position information of the document content block. Specifically, the intelligent terminal determines the shrinkage reference point of each document content block in the plurality of document content blocks according to the position information of the document content block, and performs a preset ratio shrinkage process on each document content block according to the shrinkage reference point of each document content block. The shrinkage reference point may be any one of the center position point, the upper left corner vertex, the lower left corner vertex, the upper right corner vertex, and the lower right corner vertex of the document content block. The preset ratio is, for example, 5%, 10%, etc.
[0047] Furthermore, the intelligent terminal obtains the position information of the document content block after the shrinkage processing in the file to be processed, and determines the first type of gap in the horizontal direction of the file to be processed according to the position information of the document content block after the shrinkage processing; then the multiple document content blocks are divided into N document block sets according to the determined first type of gap. In another embodiment, after the intelligent terminal obtains the position information of the document content block after the shrinkage processing in the file to be processed, it first determines whether there is a first type of gap in the horizontal direction of the file to be processed according to the position information of the document content block after the shrinkage processing; if it is determined that there is a first type of gap in the horizontal direction of the file to be processed, the multiple document content blocks are divided into N document block sets according to the determined first type of gap. If it is determined that there is still no first type of gap in the horizontal direction of the file to be processed, the intelligent terminal shrinks the multiple document content blocks after the shrinkage processing again according to the position information of the document content block after the shrinkage processing. Repeat the above steps until it is determined that there is a first type of gap in the horizontal direction of the file to be processed.
[0048] S103: The intelligent terminal performs gap detection on a first set of two or more document blocks in the N document block sets in the vertical direction of the to-be-processed file to determine a second type of gap.
[0049] In an embodiment of the present invention, the direction corresponding to the second type of gap is parallel to the vertical direction of the file to be processed, and the second type of gap refers to the gap that divides the first set into at least two parts in the horizontal direction of the file to be processed, and runs through the page area where the first set is located in the vertical direction of the file to be processed. Among them, the first set refers to a document block set including two or more document blocks in the N document block sets. The gap value corresponding to the second type of gap is greater than or equal to the second gap reference value, and the gap value corresponding to the second type of gap refers to: the interval between two adjacent parts divided by the second type of gap. In one embodiment, the second gap reference value is determined based on the gap value of all or part of the gaps that runs through the page area where the first set is located in the vertical direction of the file to be processed. The intelligent terminal obtains the gap value of all or part of the gaps that runs through the page area where the first set is located in the vertical direction of the file to be processed; then the obtained gap values are counted to determine the number of gaps corresponding to each gap value; and the gap value with the largest number of corresponding gaps is used as the second gap reference value. In another embodiment, the second gap reference value is determined based on the gap value of the gap that runs through the page area where the first set is located in the vertical direction of the file to be processed and whose gap value is greater than or equal to the second preset value.
[0050] S104: The intelligent terminal divides the first collection into multiple document blocks according to the second type of gaps.
[0051] In an embodiment of the present invention, after the intelligent terminal determines the second type of gap, it first divides the first set into multiple subsets according to the second type of gap; then, in the horizontal direction of the file to be processed, the first subset including two or more document blocks in the multiple subsets is detected for gaps to determine whether there is a third type of gap in the horizontal direction of the file to be processed. If it is determined that there is a third type of gap in the horizontal direction of the file to be processed, the third type of gap is determined, and the first subset is divided into multiple document blocks according to the determined third type of gap. The direction corresponding to the third type of gap is parallel to the horizontal direction of the file to be processed, and the third type of gap refers to the gap that divides the first subset into at least two parts in the vertical direction of the file to be processed and runs through the page area where the first subset is located in the horizontal direction of the file to be processed. The gap value corresponding to the third type of gap is greater than or equal to the third gap reference value, and the gap value corresponding to the third type of gap refers to: the interval between two adjacent parts divided by the third type of gap. In one embodiment, the third gap reference value is determined based on the gap values of all or part of the gaps that run through the page area where the first subset is located in the horizontal direction of the file to be processed. The intelligent terminal obtains the gap values of all or part of the gaps that run through the page area where the first subset is located in the horizontal direction of the file to be processed; then counts the obtained gap values to determine the number of gaps corresponding to each gap value; and uses the gap value with the largest number of corresponding gaps as the third gap reference value. In another embodiment, the third gap reference value is determined based on the gap values of the gaps that run through the page area where the first subset is located in the horizontal direction of the file to be processed, and whose gap values are greater than or equal to the third preset value.
[0052] S105. The intelligent terminal sorts the document blocks in the second set including only one document block in the N document block sets and the multiple document blocks obtained by dividing the first set in a preset order to obtain a sorting result.
[0053] In an embodiment of the present invention, the preset order refers to an order from top to bottom and from left to right. The intelligent terminal sorts the document blocks in the second set including only one document block in the above-mentioned N document block sets and the multiple document blocks obtained by segmenting the above-mentioned first set according to the distribution positions of the document blocks in the file to be processed and in the order from top to bottom and from left to right corresponding to the document blocks, to obtain a sorting result. Among them, the multiple document blocks obtained by segmenting the first set include the document blocks in the second subset including only one document block in the above-mentioned multiple subsets and the multiple document blocks obtained by segmenting the above-mentioned first subset. Sorting the segmented document blocks in an order from top to bottom and from left to right can make the sorting result conform to the natural reading order of the user.
[0054] In one embodiment, in the process of segmenting multiple document content blocks included in the target document scan data according to the gaps in the horizontal direction and the gaps in the vertical direction, the intelligent terminal constructs a tree for the document block set and the document blocks according to the document block set obtained by segmentation and the distribution positions of the document blocks in the to-be-processed file; the leaf nodes in the constructed tree are used to represent the document blocks, and the leaf nodes constitute the final sorting results. Therefore, the intelligent terminal can quickly obtain the sorting results of the document blocks according to the constructed tree.
[0055] In one embodiment, after the intelligent terminal sorts the segmented document blocks according to a preset order to obtain the sorting result, the document blocks in the second set including only one document block in the N document block sets and the multiple document blocks segmented from the first set are sequentially input into the document block output queue according to the sorting result, so that the intelligent terminal outputs the segmented document blocks in sequence according to the document block output queue and the sorting result for subsequent processing by the user or the intelligent terminal. The above method can not only output based on document blocks, but also effectively restore the document block order of the to-be-processed file itself. The document block can be understood as a document paragraph; thus, the problem that the output can only be based on text lines and the paragraphs and order of the document itself cannot be restored due to the limitation of OCR technology can be effectively solved, and the user reading experience can be effectively improved.
[0056] In order to better understand the file scanning and processing method in the embodiment of the present invention, the following is explained by taking an example. Figure 2a , Figure 2a A schematic diagram of a page of a file to be processed provided by the first embodiment of the present invention. After the intelligent terminal scans the file to be processed, the target document scanning data is obtained, such as Figure 2a As shown, the target document scan data includes 5 document content blocks 21, 22, 23, 24 and 25; the areas shown in 21, 22, 23, 24 and 25 represent the positions of the 5 document content blocks included in the target document scan data in the pages of the file to be processed. The document content block includes one or more document blocks, for example, document content block 21 includes document blocks 201 and 202, and document content block 23 includes document block 206.
[0057] The intelligent terminal performs gap detection in the horizontal direction to determine the first type of gap, such as Figure 2aAs shown, the intelligent terminal can determine 3 first-class gaps 11, 12 and 13, and the areas shown in 11, 12 and 13 represent the positions of the first-class gaps in the to-be-processed file. Among them, the first-class gaps 11, 12 and 13 respectively divide the 5 document content blocks into two parts in the vertical direction, and run through the pages of the to-be-processed file in the horizontal direction. For example, the first-class gap 12 divides the document content blocks 21, 22, 23, 24 and 25 into two parts in the vertical direction, one part includes the document content block 21, and the other part includes the document content blocks 22, 23, 24 and 25. Further, the intelligent terminal can divide the 5 document content blocks into 4 document block sets, namely {201}, {202}, {203, 204, 205} and {206, 207, 208, 209, 210} according to the first-class gaps 11, 12 and 13.
[0058] Furthermore, the intelligent terminal performs gap detection on the document block sets {203, 204, 205} and {206, 207, 208, 209, 210} including two or more document blocks in the four document block sets in the vertical direction to determine the second type of gaps; Figure 2a As shown, the intelligent terminal can determine 3 second-class gaps 14, 15 and 16, and the areas shown in 14, 15 and 16 represent the positions of the second-class gaps in the to-be-processed file. According to the second-class gaps 14 and 15, the document block set {203, 204, 205} can be divided into three parts of subsets {203}, {204} and {205} in the horizontal direction, and they all run through the page area where the set {203, 204, 205} is located in the vertical direction. According to the second-class gap 16, the document block set {206, 207, 208, 209, 210} can be divided into two parts in the horizontal direction, one part includes the subset {206, 207}, and the other part includes the subset {208, 209, 210}; and they all run through the page area where the set {206, 207, 208, 209, 210} is located in the vertical direction.
[0059] Furthermore, the intelligent terminal performs gap detection on the subsets {206, 207} and {208, 209, 210} including two or more document blocks in the plurality of subsets obtained by segmentation according to the second type of gaps in the horizontal direction, respectively, to determine the third type of gaps; Figure 2aAs shown, the intelligent terminal can determine 3 third-class gaps 17, 18 and 19, and the areas shown in 17, 18 and 19 represent the positions of the third-class gaps in the to-be-processed file. According to the third-class gap 17, the subset {206, 207} can be divided into two parts, document block {206} and document block {207}, in the vertical direction, and the page area where the subset {206, 207} is located is traversed in the vertical direction. According to the third-class gaps 18 and 19, the subset {208, 209, 210} can be divided into three parts, document block {208}, document block {209} and document block {210}, in the horizontal direction, and the page area where the subset {208, 209, 210} is located is traversed in the vertical direction. At this point, the intelligent terminal divides the multiple document content blocks into 10 document blocks, namely {210}, {209}, {208}, {207}, {206}, {205}, {204}, {203}, {202} and {201}. Further, the intelligent terminal sorts the 10 document blocks from top to bottom and from left to right according to their positions in the to-be-processed file, and the sorting result is: {201}-{202}-{203}-{204}-{205}-{206}-{207}-{208}-{209}-{210}.
[0060] In the above process of segmenting the document content block, document block set, and sub-set, the intelligent terminal can construct a tree for the document block set and document block according to the segmentation result. Figure 2b , Figure 2b Based on Figure 2a Schematic diagram of the tree constructed from the segmentation results shown in . Figure 2b As shown, the leaf nodes in the constructed tree are used to represent the document blocks obtained by segmentation, and the document blocks {210}, {209}, {208}, {207}, {206}, {205}, {204}, {203}, {202} and {201} obtained by segmentation correspond to a leaf node respectively. The leaf node is also the last node of each branch in the tree. The position of the leaf node in the constructed tree represents the sorting order of the corresponding document blocks. For example, the leaf node corresponding to the document block {201} is located at the leftmost of all the leaf nodes in the constructed tree, which means that the sorting order corresponding to the document block {201} is the first. The leaf node corresponding to the document block {205} is located at the fifth from the left of all the leaf nodes in the constructed tree, which means that the sorting order corresponding to the document block {205} is the fifth. According to the leaf nodes in the constructed tree, the intelligent terminal can obtain the sorting result of the 10 document blocks as follows: {201}-{202}-{203}-{204}-{205}-{206}-{207}-{208}-{209}-{210}.
[0061] In another embodiment, please refer to Figure 3a , Figure 3a A schematic diagram of a page of a file to be processed provided by the second embodiment of the present invention. After the intelligent terminal scans the file to be processed, the target document scanning data is obtained, such as Figure 3a As shown in FIG. 1 , the target document scan data includes 5 document content blocks 31, 32, 33, 34 and 35; the areas shown in FIG. 31, 32, 33, 34 and 35 represent the positions of the 5 document content blocks included in the target document scan data in the to-be-processed file. The intelligent terminal performs gap detection in the horizontal direction to determine whether there is a first type of gap in the horizontal direction. Figure 3a In the layout of the document content blocks shown, the smart terminal can determine that there are gaps between the document content blocks 31, 32, 33, 34 and 35, but the gaps between the document content blocks 31, 32, 33, 34 and 35 cannot run through the page of the file to be processed. Therefore, the first type of gap in the horizontal direction cannot be determined at this time.
[0062] When the first type of gap in the horizontal direction cannot be determined, the intelligent terminal shrinks the document content blocks 31, 32, 33, 34 and 35 by 25% according to the center positions of the document content blocks 31, 32, 33, 34 and 35. Figure 3b , Figure 3b for Figure 3a The schematic diagram of the document content block after shrinking is shown. Figure 3a As shown, the document content blocks 31, 32, 33, 34 and 35 are shrunk by 25%. At this time, the intelligent terminal performs gap detection in the horizontal direction, and can determine two first-class gaps 41 and 42. The first-class gaps 41 and 42 divide the five shrunk document content blocks into two parts in the vertical direction, and both run through the pages of the to-be-processed file in the horizontal direction. The above method can solve the problem of not being able to determine the first-class gaps in the horizontal direction of the to-be-processed file to a certain extent by shrinking the document content blocks to determine the first-class gaps, and increase the application scenarios of document block segmentation and sorting.
[0063] In another embodiment, please refer to Figure 3c , Figure 3c A schematic diagram of a page of a file to be processed provided by the third embodiment of the present invention. After the intelligent terminal scans the file to be processed, the initial document scanning data is obtained, such as Figure 3cAs shown, the initial document scan data includes 6 initial document content blocks A, B, C, D, E and F; the areas shown by A, B, C, D, E and F represent the positions of the 6 initial document content blocks included in the initial document scan data in the to-be-processed file. Assuming that the initial document content blocks A, B, C, D, E and F are directly segmented and sorted in the manner described above, a first type of gap can be determined between the initial document content block A and the document block set {B, E}, and a first type of gap can also be determined between the document block set {B, E} and {C, D, F}; further, a second type of gap can be determined between the document block set {C, D} and the initial document content block F. The initial document content blocks A, B, C, D, E and F are segmented and sorted based on the first type of gap and the second type of gap, and the sorting result obtained is ABECDF. However, assuming that the correct sorting order should be ABCDEF, it indicates that the above sorting result is wrong.
[0064] Please also see Figure 3d , Figure 3d yes Figure 3c The schematic diagram of the initial document content blocks after merging is shown in . Figure 3c or Figure 3d The page shown has a target class gap 43 that runs through the entire page in the vertical direction, so that the entire page is divided in the horizontal direction. In this case, if the segmentation is still performed in the vertical direction first as described above, it will cause sorting errors; in this case, it is necessary to segment in the horizontal direction first. The intelligent terminal first determines the target class gap 43 in the vertical direction. The target class gap 43 divides the initial document content blocks A, B, C, D, E and F into two parts in the horizontal direction, one part includes the initial document content blocks B, C, D, and the other part includes the initial document content blocks A, E, F; and runs through the entire page in the vertical direction. Furthermore, the intelligent terminal merges the mergeable document blocks in the initial document content blocks B, C, D, such as Figure 3d As shown in FIG. 1 , the left margin position offset between the initial document content block C and the adjacent document content blocks B and D is within the preset range, and the right margin position offset between the initial document content block C and the adjacent document content blocks B and D is also within the preset range; the initial document content blocks B, C and D can be merged to obtain the document content block set {B, C, D}. The intelligent terminal merges the mergeable document blocks in the initial document content blocks A, E, and F, as shown in FIG. Figure 3dAs shown, the left limit position offset between the initial document content block E and the adjacent document content block F is within the preset range, and the right limit position offset between the two is also within the preset range; the initial document content blocks E and F can be merged to obtain a document content block set {E, F}. Since the left limit position offset between the initial document content block A and the adjacent initial document content block E is large and not within the preset range, the initial document content blocks A and F cannot be merged; the initial document content block A can only be regarded as a document content block set {A} alone. Furthermore, the intelligent terminal adopts the method described in this solution to segment the document content block sets {A}, {B, C, D}, {E, F} respectively, and sorts the segmented document blocks to obtain the correct sorting order ABCDEF.
[0065] In another embodiment, please refer to Figure 3e , Figure 3e A schematic diagram of a page of a file to be processed provided by the fourth embodiment of the present invention. After the intelligent terminal scans the file to be processed, the target document scan data is obtained, such as Figure 3e As shown, the target document scan data includes five document content blocks, namely G, H, I, J and K; the areas indicated by G, H, I, J and K indicate the positions of the five document content blocks included in the target document scan data in the to-be-processed file. It can be seen that there are overlapping parts between document content block G and document content blocks I and K, and there are overlapping parts between document content block H and document content blocks J and K; but if document content blocks G and H are removed, there is no overlapping part between document content blocks I, J and K. At this time, the intelligent terminal adopts the method in this embodiment to preferentially segment document blocks I and K respectively; then, the method in this embodiment is adopted to segment the document content block set {I, J, K}. Finally, the segmented document blocks are sorted. Among them, in view of the overlap between multiple document content blocks included in the target document scan data, the intelligent terminal determines the target document content block from multiple document content blocks that overlap with other document content blocks, and then preferentially segments the target document content block using the method in this embodiment. If the target document content block is filtered out from the multiple document content blocks included in the target document scan data, there will be no overlap between the remaining document content blocks.
[0066] It should be noted that if the document blocks obtained by the previous segmentation can be further segmented, the segmentable document blocks can be further segmented in the above manner or in a manner similar to the above manner; the specific implementation method can be referred to the above description and will not be repeated here.
[0067] The embodiment of the present invention divides multiple document content blocks into N document block sets according to a first type of gap in the horizontal direction, performs gap detection on a first set of the N document block sets in the vertical direction, determines a second type of gap, and divides the first set into multiple document blocks according to the second type of gap, and then sorts the document blocks in the second set of the N document block sets and the multiple document blocks obtained by dividing the first set in a preset order to obtain a sorting result, so that the document blocks in the file can be divided and sorted based on the gaps. The technical solution is time-saving and easy to implement, and can effectively improve the efficiency of document block segmentation and sorting, and increase the application scenarios of document block segmentation and sorting.
[0068] See also Figure 4 , Figure 4 A schematic diagram of the structure of a file scanning and processing device provided in an embodiment of the present invention. The file scanning and processing device described in the embodiment of the present invention corresponds to the intelligent terminal described above, and the file scanning and processing device includes:
[0069] A scanning unit 401 is used to scan the file to be processed to obtain target document scan data, wherein the target document scan data includes multiple document content blocks and position information of the document content blocks in the file to be processed;
[0070] The processing unit 402 is configured to determine a first type of gap in the horizontal direction of the to-be-processed file according to the position information of the document content blocks, and divide the plurality of document content blocks into N document block sets according to the first type of gap, where N is a positive integer greater than 1;
[0071] The processing unit 402 is further configured to perform gap detection on a first set of two or more document blocks in the N document block sets in the vertical direction of the to-be-processed file to determine a second type of gap;
[0072] The processing unit 402 is further configured to divide the first set into a plurality of document blocks according to the second type of gaps;
[0073] The sorting unit 403 is used to sort the document blocks in the second set including only one document block in the N document block sets and the multiple document blocks obtained by dividing the first set in a preset order to obtain a sorting result.
[0074] In one embodiment, the first type of gap refers to a gap that divides the multiple document content blocks into at least two parts in the vertical direction of the file to be processed and runs through the pages of the file to be processed in the horizontal direction of the file to be processed; the gap value corresponding to the first type of gap is greater than or equal to the first gap reference value.
[0075] In one embodiment, the second type of gap refers to a gap that divides the first set into at least two parts in the horizontal direction of the file to be processed and runs through the page area where the first set is located in the vertical direction of the file to be processed; the gap value corresponding to the second type of gap is greater than or equal to the second gap reference value.
[0076] In one embodiment, when the processing unit 402 divides the first set into multiple document blocks according to the second type of gaps, it is specifically used to: divide the first set into multiple subsets according to the second type of gaps; perform gap detection on a first subset of the multiple subsets including two or more document blocks to determine a third type of gap in the horizontal direction of the file to be processed; divide the first subset into multiple document blocks according to the third type of gaps; wherein the multiple document blocks obtained by dividing the first set include document blocks in a second subset of the multiple subsets including only one document block and the multiple document blocks obtained by dividing the first subset.
[0077] In one embodiment, the third type of gap refers to a gap that divides the first subset into at least two parts in the vertical direction of the file to be processed and runs through the page area where the first subset is located in the horizontal direction of the file to be processed; the gap value corresponding to the third type of gap is greater than or equal to the third gap reference value.
[0078] In one embodiment, when the processing unit 402 determines the first type of gaps in the horizontal direction of the file to be processed according to the position information of the document content blocks, and divides the multiple document content blocks into N document block sets according to the first type of gaps, it is specifically used to: determine whether there are first type of gaps in the horizontal direction of the file to be processed according to the position information of the document content blocks; if not, shrink the multiple document content blocks by a preset ratio according to the position information of the document content blocks; obtain the position information of the document content blocks after the shrinkage processing in the file to be processed; determine the first type of gaps in the horizontal direction of the file to be processed according to the position information of the document content blocks after the shrinkage processing; and divide the multiple document content blocks into N document block sets according to the first type of gaps.
[0079] In one embodiment, when the processing unit 402 scans the file to be processed and obtains target document scan data, it is specifically used to: scan the file to be processed to obtain initial document scan data, wherein the initial document scan data includes multiple initial document content blocks and position information of the initial document content blocks in the file to be processed; when the multiple initial document content blocks meet preset merging conditions, merge the mergeable document content blocks in the multiple initial document content blocks to obtain multiple document content block sets; obtain document scan data corresponding to each document content block set in the multiple document content block sets, and use the document scan data corresponding to each document content block set as target document scan data.
[0080] In one embodiment, the multiple initial document content blocks meet the preset merging conditions when: the number of the multiple initial document content blocks is greater than a preset number threshold, and / or the distribution of the multiple initial document content blocks in the to-be-processed file is a target distribution method; the mergeable document content block refers to: a document content block whose position offset from an adjacent document content block in the to-be-processed file is within a preset offset range.
[0081] It can be understood that the functions of each functional unit of the file scanning and processing device of the embodiment of the present invention can be specifically implemented according to the method in the above method embodiment, and its specific implementation process can refer to the relevant description of the above method embodiment, which will not be repeated here.
[0082] See also Figure 5 , Figure 5 A schematic diagram of the structure of an intelligent terminal provided in an embodiment of the present invention. The intelligent terminal described in the embodiment of the present invention includes: a processor 501, a communication interface 502, and a memory 503. The processor 501, the communication interface 502, and the memory 503 can be connected via a bus or other means, and the embodiment of the present invention takes the connection via a bus as an example.
[0083] Among them, the processor 501 (or CPU (Central Processing Unit)) is the computing core and control core of the terminal, which can parse various instructions in the terminal and process various data of the terminal. For example, the CPU can be used to parse the power on and off instructions sent by the user to the terminal, and control the terminal to perform power on and off operations; for another example, the CPU can transmit various interactive data between the internal structures of the terminal, and so on. The communication interface 502 can optionally include a standard wired interface, a wireless interface (such as Wi-Fi, a mobile communication interface, etc.), which is controlled by the processor 501 to send and receive data. The memory 503 (Memory) is a memory device in the terminal for storing programs and data. It can be understood that the memory 503 here can include both the built-in memory of the terminal and the extended memory supported by the terminal. The memory 503 provides a storage space, which stores the operating system of the terminal, which may include but is not limited to: Android system, iOS system, Windows Phone system, etc., and the present invention is not limited to this.
[0084] In the embodiment of the present invention, the processor 501 performs the following operations by running the executable program code in the memory 503:
[0085] Scan the file to be processed to obtain target document scan data, wherein the target document scan data includes multiple document content blocks and position information of the document content blocks in the file to be processed;
[0086] Determine, according to the position information of the document content blocks, a first type of gap in the horizontal direction of the to-be-processed file, and divide the plurality of document content blocks into N document block sets according to the first type of gap, where N is a positive integer greater than 1;
[0087] In the vertical direction of the to-be-processed file, gap detection is performed on a first set of two or more document blocks in the N document block sets to determine a second type of gap;
[0088] dividing the first collection into a plurality of document blocks according to the second type of gaps;
[0089] The document blocks in the second set including only one document block in the N document block sets and the multiple document blocks obtained by dividing the first set are sorted in a preset order to obtain a sorting result.
[0090] In one embodiment, the first type of gap refers to a gap that divides the multiple document content blocks into at least two parts in the vertical direction of the file to be processed and runs through the pages of the file to be processed in the horizontal direction of the file to be processed; the gap value corresponding to the first type of gap is greater than or equal to the first gap reference value.
[0091] In one embodiment, the second type of gap refers to a gap that divides the first set into at least two parts in the horizontal direction of the file to be processed and runs through the page area where the first set is located in the vertical direction of the file to be processed; the gap value corresponding to the second type of gap is greater than or equal to the second gap reference value.
[0092] In one embodiment, when the processor 501 divides the first set into multiple document blocks according to the second type of gaps, it is specifically used to: divide the first set into multiple subsets according to the second type of gaps; perform gap detection on a first subset of the multiple subsets including two or more document blocks to determine a third type of gap in the horizontal direction of the file to be processed; divide the first subset into multiple document blocks according to the third type of gaps; wherein the multiple document blocks obtained by dividing the first set include document blocks in a second subset of the multiple subsets including only one document block and the multiple document blocks obtained by dividing the first subset.
[0093] In one embodiment, the third type of gap refers to a gap that divides the first subset into at least two parts in the vertical direction of the file to be processed and runs through the page area where the first subset is located in the horizontal direction of the file to be processed; the gap value corresponding to the third type of gap is greater than or equal to the third gap reference value.
[0094] In one embodiment, when the processor 501 determines the first type of gaps in the horizontal direction of the file to be processed based on the position information of the document content blocks, and divides the multiple document content blocks into N document block sets based on the first type of gaps, it is specifically used to: determine whether there are first type of gaps in the horizontal direction of the file to be processed based on the position information of the document content blocks; if not, shrink the multiple document content blocks by a preset ratio based on the position information of the document content blocks; obtain the position information of the document content blocks after the shrinkage processing in the file to be processed; determine the first type of gaps in the horizontal direction of the file to be processed based on the position information of the document content blocks after the shrinkage processing; and divide the multiple document content blocks into N document block sets based on the first type of gaps.
[0095] In one embodiment, when the processor 501 scans the file to be processed and obtains target document scan data, it is specifically used to: scan the file to be processed to obtain initial document scan data, wherein the initial document scan data includes multiple initial document content blocks and position information of the initial document content blocks in the file to be processed; when the multiple initial document content blocks meet preset merging conditions, merge the mergeable document content blocks in the multiple initial document content blocks to obtain multiple document content block sets; obtain document scan data corresponding to each document content block set in the multiple document content block sets, and use the document scan data corresponding to each document content block set as target document scan data.
[0096] In one embodiment, the multiple initial document content blocks meet the preset merging conditions when: the number of the multiple initial document content blocks is greater than a preset number threshold, and / or the distribution of the multiple initial document content blocks in the to-be-processed file is a target distribution method; the mergeable document content block refers to: a document content block whose position offset from an adjacent document content block in the to-be-processed file is within a preset offset range.
[0097] In a specific implementation, the processor 501, communication interface 502 and memory 503 described in the embodiment of the present invention can execute the implementation method of the intelligent terminal described in a file scanning and processing method provided in an embodiment of the present invention, and can also execute the implementation method described in a file scanning and processing device provided in an embodiment of the present invention, which will not be repeated here.
[0098] The embodiment of the present invention further provides a computer-readable storage medium, in which instructions are stored. When the computer-readable storage medium is run on a computer, the computer is enabled to execute the file scanning and processing method as described in the embodiment of the present invention.
[0099] The embodiment of the present invention further provides a computer program product including instructions, which, when executed on a computer, enables the computer to execute the file scanning and processing method as described in the embodiment of the present invention.
[0100] It should be noted that, for the above-mentioned various method embodiments, for the sake of simplicity of description, they are all expressed as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described order of actions, because according to the present invention, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0101] A person skilled in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0102] The above disclosure is only part of the embodiments of the present invention, which certainly cannot be used to limit the scope of the present invention. Therefore, equivalent changes made according to the claims of the present invention are still within the scope of the present invention.
Claims
1. A file scanning and processing method, characterized in that: The method comprises: Scan the file to be processed to obtain target document scan data, wherein the target document scan data includes multiple document content blocks and position information of the document content blocks in the file to be processed; According to the position information of the document content block, determining whether there is a first type of gap in the horizontal direction of the to-be-processed file; If so, the plurality of document content blocks are divided into N document block sets according to the determined first type of gaps; if not, the plurality of document content blocks are shrunk by a preset ratio according to the position information of the document content blocks, the position information of the document content blocks after the shrunk processing in the to-be-processed file is obtained, the first type of gaps in the horizontal direction of the to-be-processed file is determined according to the position information of the document content blocks after the shrunk processing, and the plurality of document content blocks are divided into N document block sets according to the first type of gaps; N is a positive integer greater than 1; In the vertical direction of the to-be-processed file, gap detection is performed on a first set of the N document block sets including a plurality of document blocks to determine a second type of gap; dividing the first collection into a plurality of document blocks according to the second type of gaps; The document blocks in the second set including only one document block in the N document block sets and the multiple document blocks obtained by dividing the first set are sorted in a preset order to obtain a sorting result.
2. The method according to claim 1, characterized in that The first type of gap refers to a gap that divides the plurality of document content blocks into at least two parts in the vertical direction of the to-be-processed file and runs through the pages of the to-be-processed file in the horizontal direction of the to-be-processed file; The gap value corresponding to the first type of gap is greater than or equal to a first gap reference value.
3. The method according to claim 1 or 2, characterized in that The second type of gap refers to a gap that divides the first set into at least two parts in the horizontal direction of the file to be processed and runs through the page area where the first set is located in the vertical direction of the file to be processed; the gap value corresponding to the second type of gap is greater than or equal to the second gap reference value.
4. The method according to claim 1, characterized in that The step of dividing the first set into a plurality of document blocks according to the second type of gaps comprises: dividing the first set into a plurality of subsets according to the second type of gaps; In the horizontal direction of the to-be-processed file, gap detection is performed on a first subset of the plurality of subsets including a plurality of document blocks to determine a third type of gap; dividing the first subset into a plurality of document blocks according to the third type of gaps; The multiple document blocks obtained by dividing the first set include document blocks in a second subset of the multiple subsets that only include one document block and the multiple document blocks obtained by dividing the first subset.
5. The method according to claim 4, characterized in that The third type of gap refers to a gap that divides the first subset into at least two parts in the vertical direction of the file to be processed and runs through the page area where the first subset is located in the horizontal direction of the file to be processed; the gap value corresponding to the third type of gap is greater than or equal to the third gap reference value.
6. The method according to claim 1, characterized in that The step of scanning the file to be processed to obtain target document scan data includes: Scan the file to be processed to obtain initial document scan data, wherein the initial document scan data includes a plurality of initial document content blocks and position information of the initial document content blocks in the file to be processed; When the multiple initial document content blocks meet a preset merging condition, merging mergeable document content blocks among the multiple initial document content blocks to obtain multiple document content block sets; The document scan data corresponding to each document content block set in the plurality of document content block sets is acquired, and the document scan data corresponding to each document content block set is used as the target document scan data.
7. The method according to claim 6, characterized in that The multiple initial document content blocks meet the preset merging conditions when: the number of the multiple initial document content blocks is greater than a preset number threshold, and / or the distribution method of the multiple initial document content blocks in the file to be processed is a target distribution method; the mergeable document content block refers to: a document content block whose position offset with an adjacent document content block in the file to be processed is within a preset offset range.
8. An intelligent terminal, characterized in that: include: A processor and a memory, wherein the memory stores an executable program code, and the processor is used to call the executable program code to execute the file scanning processing method according to any one of claims 1 to 7.
9. A storage medium, characterized in that: The storage medium stores instructions, which, when executed on a computer, enable the computer to execute the file scanning and processing method according to any one of claims 1 to 7.
10. A computer program product comprising instructions, characterized in that When the method is run on a computer, the computer is enabled to execute the file scanning and processing method as claimed in any one of claims 1 to 7.
Citation Information
Patent Citations
Open fixed-layout document paragraph identification method
CN106326854A
Vision-based document segmentation
CN1577328A
Document processing apparatus
JP2011070529A
Method and apparatus for determining logical document structure
US20060271847A1
