Data processing device, computer program, and recording medium

JP7680710B2Active Publication Date: 2025-05-21BROTHER KOGYO KK
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
JP2021090564
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2021-05-28
Publication Date
2025-05-21
Estimated Expiration
2041-05-28

Smart Images

  • Figure 0007680710000001
    Figure 0007680710000001
  • Figure 0007680710000002
    Figure 0007680710000002
  • Figure 0007680710000003
    Figure 0007680710000003
Patent Text Reader

Abstract

To appropriately detect positions of streaks.SOLUTION: A data processing apparatus acquires first outside area read image data generated on the basis of, a signal that is output from an image sensor during one conveyance of a document to read the document, the signal output from the image sensor with the document being located at a position separate from a reading position. The data processing apparatus determines first color value evaluation values of J (J is an integer of 2 or more) pixel positions in a second direction perpendicular to a first direction that is a direction of conveyance in a first outside area read image represented by the first outside area read image data by using a reference parameter including color values of K (K is an integer of 2 or more) pixels having the same pixel position in the second direction in the first outside area read image. The data processing apparatus detects the positions in the second direction of streaks that are parallel in the first direction on the first outside area read image by using the first color value evaluation values of the J pixel positions.SELECTED DRAWING: Figure 5
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present specification relates to a technique for processing read image data generated by a reading execution unit. [Background technology]

[0002] Conventionally, a reading execution unit is used that optically reads an original and generates read image data representing a read image of the original. Also, a technology has been proposed to reduce streaks on a read image caused by foreign matter such as dust. For example, Patent Document 1 discloses a technology that creates a histogram showing the number of pixels for each density value, calculates a density value that is a predetermined value darker than the density value with the largest number of pixels as a threshold value, and determines pixels darker than the threshold value as abnormal pixels. [Prior art documents] [Patent documents]

[0003] [Patent Document 1] Patent No. 6344062 Summary of the Invention [Problem to be solved by the invention]

[0004] By the way, there was room for improvement when it came to detecting the position of muscles.

[0005] This specification discloses a technique for appropriately detecting the position of a muscle. [Means for solving the problem]

[0006] The technology disclosed in this specification can be realized in the following application examples.

[0007] [Application example 1] A data processing device that processes read image data representing a read image having a plurality of pixels, the read image data being generated by a reading execution unit having a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path, the data processing device processing the read image data representing a read image having a plurality of pixels, the data processing device generating first outer area read image data based on a signal output from the image sensor during one conveyance of the document to read the document, the signal being output from the image sensor when the document is located at a position away from the reading position. a determination unit that determines a first color value evaluation value for each of J (J is an integer equal to or greater than 2) pixel positions in a second direction perpendicular to a first direction, which is the direction of conveyance, in a first external area read image represented by the first external area read image data, using reference parameters including color values ​​of K (K is an integer equal to or greater than 2) pixels having the same pixel position in the second direction in the first external area read image, and a detection unit that detects a position in the second direction of a streak parallel to the first direction on the first external area read image, using the first color value evaluation value for each of the J pixel positions.

[0008] According to this configuration, first outer area read image data is acquired based on a signal output from the image sensor during one transport of the document to read it, and first color value evaluation values ​​of J (J is an integer of 2 or more) pixel positions in a second direction perpendicular to the first direction, which is the direction of transport, are determined using reference parameters including color values ​​of K (K is an integer of 2 or more) pixels, and the position of a streak in the second direction parallel to the first direction is detected using the first color value evaluation values ​​of J pixel positions, thereby reducing the time required to detect the position of the streak and enabling the position of the streak to be detected appropriately. [Application example 2] 2. A data processing device according to claim 1, the first outer region read image data is generated based on a signal output from the image sensor in a state where the entire document is located upstream of the reading position, the reference parameters consist of the color values ​​of each of the K pixels; the acquiring unit is further configured to acquire second outer region read image data generated based on a signal output from the image sensor in a state where the entire document is located downstream of the reading position, The determination unit further a second color value evaluation value of each of L pixel positions (L is an integer equal to or greater than 2) in the second direction in the second outer area read image represented by the second outer area read image data is determined using color values ​​of M pixels (M is an integer equal to or greater than 2) having the same pixel position in the second direction in the second outer area read image, The detection unit further includes: a position in the second direction of a streak parallel to the first direction on the second outer region read image is detected by using the second color value evaluation value of each of the L pixel positions; Data processing device. [Application example 3] 2. A data processing device according to claim 1, the first outer region read image data is generated based on the signal output from the image sensor in one of a state in which the entire document is located upstream of the reading position and a state in which the entire document is located downstream of the reading position; the reference parameters consist of the color values ​​of each of the K pixels. Data processing device. [Application example 4] 2. A data processing device according to claim 1, the first outer area read image data is generated based on the signal output from the image sensor in a first state, which is one of an upstream state in which the entire document is located upstream of the reading position and a downstream state in which the entire document is located downstream of the reading position; The acquisition unit is further configured to acquire second outer area read image data generated based on a signal output from the image sensor in a second state that is a state different from the first state of the upstream state and the downstream state, the reference parameters include the color values ​​of each of the K pixels and color values ​​of each of N pixels (N is an integer equal to or greater than 2) having the same pixel position in the second direction in a second outer area read image represented by the second outer area read image data. Data processing device. [Application example 5] A data processing device according to any one of claims 1 to 4, The acquisition unit is further configured to acquire document read image data representing a read image of the document, The data processing device further comprises: a correction unit that corrects a color value of a target pixel included in a plurality of pixels at the position in the second direction of a detected line among a plurality of pixels of the scanned image of the document, using a color value of a pixel in the vicinity of the target pixel and having a position different from the position in the second direction of the detected line. [Application Example 6] A data processing device according to any one of claims 1 to 5, the first color value evaluation value is a total value of color values ​​of a plurality of pixels included in the reference parameters; the detection unit is configured to detect a pixel position in the second direction associated with an out-of-range evaluation value, which is a first color value evaluation value outside a predetermined allowable range, as the position in the second direction of the streak. Data processing device. [Application Example 7] A computer program for a computer that processes read image data representing a read image having a plurality of pixels, the read image data being generated by a reading execution unit including a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path based on a signal output from the image sensor, the computer program comprising: an acquisition function for acquiring first outer region read image data generated based on a signal output from the image sensor during one transport of the document for reading the document, the signal being output from the image sensor when the document is located at a position away from the reading position; a determination function that determines a first color value evaluation value of each of J (J is an integer of 2 or more) pixel positions in a second direction perpendicular to a first direction, which is a conveying direction, in a first outer area read image represented by the first outer area read image data, using reference parameters including color values ​​of K (K is an integer of 2 or more) pixels having the same pixel position in the second direction in the first outer area read image; a detection function for detecting a position in the second direction of a streak parallel to the first direction on the first outer region read image by using the first color value evaluation value of each of the J pixel positions; A computer program that enables a computer to realize the above. [Application Example 8] A computer-readable recording medium having recorded thereon a computer program for a computer that processes read image data representing a read image having a plurality of pixels, the read image data being generated by a reading execution unit that includes a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path, based on a signal output from the image sensor, the computer-readable recording medium comprising: The computer program comprises: an acquisition function for acquiring first outer region read image data generated based on a signal output from the image sensor during one transport of the document for reading the document, the signal being output from the image sensor when the document is located at a position away from the reading position; a determination function that determines a first color value evaluation value of each of J (J is an integer of 2 or more) pixel positions in a second direction perpendicular to a first direction, which is a conveying direction, in a first outer area read image represented by the first outer area read image data, using reference parameters including color values ​​of K (K is an integer of 2 or more) pixels having the same pixel position in the second direction in the first outer area read image; a detection function for detecting a position in the second direction of a streak parallel to the first direction on the first outer region read image by using the first color value evaluation value of each of the J pixel positions; A recording medium that enables a computer to realize the above.

[0009] The technology disclosed in this specification can be realized in various forms, for example, in the form of a data processing method and a data processing device, a computer program for realizing the functions of the method or device, a recording medium (e.g., a non-transitory recording medium) on which the computer program is recorded, and the like. [Brief description of the drawings]

[0010] [Figure 1] FIG. 1 is an explanatory diagram illustrating a multifunction peripheral according to an embodiment; [Diagram 2] 1A shows a schematic configuration of a multifunction device 200. 1B shows an enlarged view of an area AR. [Diagram 3] 13 is a flowchart illustrating an example of a reading process. [Figure 4] 2 shows an example of a read image represented by the read image data. [Diagram 5] 13 is a flowchart illustrating an example of a muscle position detection process. [Figure 6] 13A to 13E are diagrams illustrating the first color evaluation value. [Figure 7] 13 is a flowchart illustrating an example of an image correction process. [Figure 8] FIG. 4 is an explanatory diagram of an image correction process. [Figure 9] 13 is a flowchart showing a second embodiment of the muscle position detection process. [Figure 10] 13A shows another example of a scanned image, and FIG. 13B is an explanatory diagram showing a line position LP. [Figure 11] 13 is a flowchart showing a third embodiment of the muscle position detection process. [Figure 12] 10A shows another example of a scanned image, and FIG. 10B is an explanatory diagram showing a line position LP. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0011] A. First Example: A1. Equipment configuration 1 is an explanatory diagram showing a multifunction device as an embodiment. The multifunction device 200 includes a control unit 299, a display unit 240, an operation unit 250, a communication interface 270, a reading execution unit 400, and a printing execution unit 290. The control unit 299 includes a processor 210 and a storage device 215. These elements are connected to each other via a bus. The storage device 215 includes a volatile storage device 220 and a non-volatile storage device 230.

[0012] The display unit 240 is a device configured to display images, such as a liquid crystal display or an organic EL display. The operation unit 250 is a device configured to receive operations by a user, such as a touch panel, a button, a lever, etc., which are arranged overlaid on the display unit 240. The user can input various instructions to the multifunction device 200 by operating the operation unit 250. The communication interface 270 is an interface for communicating with other devices (for example, a USB interface, a wired LAN interface, or an IEEE802.11 wireless interface).

[0013] The reading execution unit 400 is a reading device configured to optically read an object such as a document using a photoelectric conversion element such as a CCD or a CMOS. The reading execution unit 400 generates read image data representing a read image (called a "read image"). In this embodiment, the read image data is color bitmap data indicating the gradation values ​​of R (red), G (green), and B (blue). The gradation values ​​are expressed in 256 gradations, for example, from 0 to 255.

[0014] The print execution unit 290 is a device that prints an image on paper (an example of a print medium) using a printing material in a predetermined manner (for example, a laser method or an inkjet method). The print execution unit 290 executes printing according to the control of the processor 210.

[0015] The processor 210 is a device configured to perform data processing, and may be, for example, a CPU. The volatile storage device 220 may be, for example, a DRAM, and the non-volatile storage device 230 may be, for example, a flash memory.

[0016] The non-volatile storage device 230 stores a program 232. The processor 210 executes the program 232 to realize various functions for controlling the multifunction device 200. The processor 210 temporarily stores various intermediate data used in the execution of the program 232 in a storage device (e.g., either the volatile storage device 220 or the non-volatile storage device 230). In this embodiment, the program 232 is stored in advance in the non-volatile storage device 230 as firmware by the manufacturer of the multifunction device 200.

[0017] A2. Configuration of the reading execution unit 400: FIG. 2A shows a schematic configuration of the multifunction device 200 (particularly, the reading execution unit 400). The multifunction device 200 includes a housing 70. The reading execution unit 400 includes an image sensor 60 disposed inside the housing 70, a signal processing unit 90 that generates read image data using a signal from the image sensor 60, a transparent glass document table 80 disposed on the upper part of the housing 70, and a conveying device 50 disposed above the housing 70. The conveying device 50 is a so-called ADF (short for Auto Document Feeder), and is supported by a hinge (not shown) provided at the end of the upper surface of the housing 70 so as to be openable and closable. The conveying device 50 includes a paper feed tray 56 and a paper discharge tray 57.

[0018] In this embodiment, the reading execution unit 400 can use the flatbed (fixed original scanning) method and the ADF (moving original scanning) method as the original reading method. In the flatbed method, the image sensor 60 moves in the scanning direction (the direction of the arrow A in FIG. 2(A)) with the original placed on the original table 80. During the movement, the image sensor 60 reads the image of the original line by line parallel to the sensor direction (depth direction in FIG. 2(A)) perpendicular to the scanning direction. The image sensor 60 has a plurality of reading elements aligned in the sensor direction.

[0019] In the ADF method, an original is placed on a paper feed tray 56 of a transport device 50. The transport device 50 transports the original along a transport path TR (described later) that leads from the paper feed tray 56 to a paper discharge tray 57. The transport path TR is a path that passes through a predetermined reading position RP (described later) on the upper surface of a document table 80. The image sensor 60 is fixed below the reading position RP on the document table 80, and reads the image of the original line by line as it passes the reading position RP.

[0020] Fig. 2(B) shows an enlarged view of an area AR surrounded by a dashed line in Fig. 2(A). Fig. 2(B) shows the internal configuration of the conveying device 50. Fig. 2(B) shows a conveying path TR from the paper feed tray 56 to the paper discharge tray 57. The conveying device 50 includes a plurality of rollers 54a-54g that are driven to rotate by a conveying motor (not shown), and a plurality of guide members 55a-55e. Hereinafter, among the directions along the conveying path TR, the direction toward the paper discharge tray 57 is referred to as the downstream direction, and the direction toward the paper feed tray 56 is referred to as the upstream direction.

[0021] The two feed rollers 54a, 54b are disposed near the downstream end of the upper surface of the feed tray 56. The feed rollers 54a, 54b transport one or more documents placed on the feed tray 56 in the downstream direction of the feed tray 56 one by one.

[0022] The three transport rollers 54c-54e and guide members 55a, 55b, and 55c provided near the transport rollers 54c-54e invert the document transported from the paper feed tray 56 and transport it to the reading position RP. The reading position RP is located at a portion on the transport path TR that is sandwiched between the guide member 55c and the document table 80. The guide member 55c has a tape 55cp attached to a portion corresponding to the reading position RP.

[0023] The document that has passed through the reading position RP is guided by guide members 55d and 55e and conveyed to a pair of discharge rollers 54g and 54f. The discharge rollers 54g and 54f discharge the document onto a discharge tray 57.

[0024] A3. Reading process: FIG. 3 is a flowchart showing an example of the reading process. In this reading process, a document is read by the ADF method described above to generate read image data. The user places a document on the paper feed tray 56 (FIG. 2(A)). Then, the user operates the operation unit 250 (FIG. 1) to input an instruction to start the reading process. In response to the start instruction, the processor 210 of the multifunction device 200 starts the process of FIG. 3. The processor 210 performs the process of FIG. 3 by executing the program 232.

[0025] In S110, the processor 210 causes the reading execution unit 400 (FIG. 2(A)) to generate read image data. The reading execution unit 400 executes the following processes in response to an instruction from the processor 210. The conveying device 50 conveys the document once, the image sensor 60 reads the document, and the signal processing unit 90 generates read image data using a signal from the image sensor 60.

[0026] FIG. 4 shows an example of a read image represented by the read image data. In the figure, a downstream direction D1 and an upstream direction D1r along the transport path TR (FIG. 2(B)) and a sensor direction D2 perpendicular to these directions D1 and D1r are shown. The downstream direction D1 indicates the direction of transport of the document. Hereinafter, the downstream direction D1 is also called the first direction D1, and the sensor direction D2 is also called the second direction D2. The read image RI is a rectangular image having two sides parallel to the downstream direction D1 and two sides parallel to the sensor direction D2.

[0027] The image of the reading position RP read by the image sensor 60 (FIG. 2(A)) is an image of one pixel line parallel to the sensor direction D2 in the read image RI (also called the read line image 60L). The signal processing unit 90 moves the position of the read line image 60L in the downstream direction D1 in the read image RI by one pixel during the rotation of the rollers 54a to 54g (for example, the position of the read line image 60L moves by one pixel toward the upstream direction D1r). The signal processing unit 90 generates image data of the read line image 60L at each position in the downstream direction D1 in the read image RI by repeating the process of generating image data of the read line image 60L using the signal from the image sensor 60 during the rotation of the rollers 54a to 54g. In this way, the signal processing unit 90 generates read image data representing the entire read image RI.

[0028] The read image RI includes three partial images RIo1, RId, and RIo2 arranged from the downstream direction D1 side toward the upstream direction D1r. The first outer region read image RIo1 on the downstream direction D1 side (also called the first outer image RIo1) is an image read before the document reaches the reading position RP (FIG. 2B). Before the document reaches the reading position RP, the image sensor 60 continues to read the tape 55cp, which is a part of the guide member 55c at the reading position RP. The first outer image RIo1 is an image obtained by arranging a plurality of read line images 60L showing the tape 55cp in the upstream direction D1r. Usually, a plurality of pixels of the first outer image RIo1 show approximately the same color (in this embodiment, the color of the tape 55cp). Hereinafter, the color of the tape 55cp is assumed to be gray (for example, R, G, and B are approximately 128).

[0029] The central partial image RId is a read image of the document (also called the read document image RId, or simply the document image RId).

[0030] The second external area read image RIo2 on the upstream direction D1r side (also called the second external image RIo2) is an image read after the entire document has passed the reading position RP (FIG. 2(B)). After the entire document has passed the reading position RP, the image sensor 60 continues to read the tape 55cp, which is the portion of the guide member 55c at the reading position RP. The second external image RIo2 is an image obtained by arranging a plurality of reading line images 60L showing the tape 55cp in the upstream direction D1r. The plurality of pixels of the second external image RIo2 show approximately the same color (the color of the tape 55cp in this embodiment) as the plurality of pixels of the first external image RIo1.

[0031] In this embodiment, the reading execution unit 400 generates read image data representing the read image RI by conveying the document once. For example, the signal processing unit 90 generates read image data by repeating a process of generating image data of the read line image 60L while the time elapsed since the start of rotation of the rollers 54a to 54g is within a predetermined time range. The reading execution unit 400 may also include a sensor that detects the position of the document on the conveying path TR. The signal processing unit 90 may determine the start and end timings of the process of generating image data of the read line image 60L according to the position of the document detected by the sensor.

[0032] Foreign matter such as pieces of paper or hair may adhere to the reading position RP of the conveying device 50 (for example, the reading position RP of the platen 80 or the reading position RP of the guide member 55c). The foreign matter may form streaks parallel to the downstream direction D1 in the read image RI (also called vertical streaks). Four streaks La-Ld caused by foreign matter are formed in the read image RI in FIG. 4. As will be described later, the reading process of this embodiment includes an image correction process that makes such streaks La-Ld less noticeable.

[0033] In S120 (FIG. 3), the processor 210 acquires the read image data from the reading execution unit 400 and stores the acquired read image data in the storage device 215 (in this embodiment, the non-volatile storage device 230). The processor 210 also analyzes the read image data to divide the read image data into three pieces of image data corresponding to the three partial images RIo1, RId, and RIo2. For example, the processor 210 adopts, as the outer images RIo1 and RIo2, a portion of the read image RI in which a plurality of pixels showing a predetermined color of the tape 55cp of the guide member 55c are continuous. In addition, when the reading execution unit 400 includes a sensor for detecting the position of the document on the transport path TR, the processor 210 can use the detected position of the document to determine the range of the downstream direction D1 of each of the partial images RIo1, RId, and RIo2 in the read image RI. Note that instead of the processor 210, the reading execution unit 400 (for example, the signal processing unit 90) may generate three pieces of image data corresponding to the three partial images RIo1, RId, and RIo2.

[0034] Hereinafter, the data of the first external image RIo1 is also referred to as the first external area read image data or simply as the first external image data. The data of the original image RId is also referred to as the original read image data or simply as the original image data. The data of the second external image RIo2 is also referred to as the second external area read image data or simply as the second external image data.

[0035] In S130, the processor 210 executes a muscle position detection process. FIG 5 is a flowchart showing an example of the muscle position detection process. In S210, the processor 210 acquires the first image data from the non-volatile storage device 230.

[0036] In S220, the processor 210 determines a first color value evaluation value. Figures 6(A)-6(E) are explanatory diagrams of the first color value evaluation value. Figure 6(A) shows a first external image RIo1. As shown in the figure, the first external image RIo1 shows four stripes La-Ld.

[0037] 6(B)-6(D) show histograms Hr, Hg, and Hb of red, green, and blue, respectively. The horizontal axis of each histogram Hr, Hg, and Hb indicates the pixel position PD2 in the sensor direction D2. The vertical axis of each histogram Hr, Hg, and Hb is the sum of the gradation values ​​of the corresponding color. For example, the red total value Rx in FIG. 6(B) is the sum of the red R gradation values ​​of multiple pixels at the same pixel position PD2 in the first external image RIo1. Similarly, the green total value Gx (FIG. 6(C)) is the sum of the green G gradation values ​​of multiple pixels at the same pixel position PD2, and the blue total value Bx (FIG. 6(D)) is the sum of the blue B gradation values ​​of multiple pixels at the same pixel position PD2. The sum values ​​Rx, Gx, and Bx are examples of the first color value evaluation values ​​of the plurality of pixel positions PD2 (hereinafter, the sum values ​​Rx, Gx, and Bx are also referred to as the first color value evaluation values ​​Rx, Gx, and Bx). The processor 210 determines the first color value evaluation values ​​of RGB by generating histograms Hr, Hg, and Hb for each of the RGB color components. Hereinafter, the number of pixels in the sensor direction D2 of the first external image RIo1 (FIG. 6(A)) (and thus the number of pixels in the sensor direction D2 of the read image RI) is assumed to be J (J is an integer of 2 or more). In addition, the number of pixels in the downstream direction D1 of the first external image RIo1 (i.e., the total number of the plurality of pixels at the same pixel position PD2) is assumed to be K (K is an integer of 2 or more). The histograms Hr, Hg, and Hb show the sum values ​​Rx, Gx, and Bx of the color values ​​of the K pixels at the J pixel positions PD2.

[0038] As described above, in the portion without streaks in the first external image RIo1, the pixels show approximately the same color. Therefore, in the pixel position PD2 without streaks, the total value is approximately the same regardless of the pixel position PD2 (hereinafter, this same value is also called the standard value). For example, the red total value Rx (FIG. 6(B)) is approximately the same as the red standard value Rxs, the green total value Gx (FIG. 6(C)) is approximately the same as the green standard value Gxs, and the blue total value Bx (FIG. 6(D)) is approximately the same as the blue standard value Bxs.

[0039] At pixel position PD2 showing a streak, multiple pixels show colors caused by foreign matter. Therefore, the total value may deviate from the standard value. For example, four ranges Rr1-Rr4 at pixel position PD2 in FIG. 6B show ranges where the red total value Rx is significantly different from the red standard value Rxs, and correspond to four streaks La-Ld, respectively.

[0040] At the pixel position PD2 showing the streak, the pixel color may be various colors caused by foreign matter. The deviation from the standard value may differ for each color component. At the pixel position PD2 showing the streak, the total value may be close to the standard value. For example, the three ranges Rg1, Rg2, and Rg3 at the pixel position PD2 in FIG. 6C indicate ranges in which the green total value Gx is significantly different from the green standard value Gxs, and correspond to the three streaks La, Lc, and Ld, respectively. At the pixel position PD2 showing the second streak Lb, the green total value Gx is close to the green standard value Gxs. At the pixel position PD2 showing the second streak Lb, the three ranges Rb1, Rb2, and Rb3 at the pixel position PD2 in FIG. 6D indicate ranges in which the blue total value Bx is significantly different from the blue standard value Bxs, and correspond to the three streaks La, Lc, and Ld, respectively. At the pixel position PD2 showing the second streak Lb, the blue total value Bx is close to the blue standard value Bxs.

[0041] In S230 (FIG. 5), the processor 210 detects the pixel position PD2 of the streak using the first color value evaluation value. In this embodiment, the tape 55cp of the guide member 55c (FIG. 2(B)) is an opaque, plain tape, and its color is a single color that is predetermined (as described above, in this embodiment, the color of the tape 55cp is gray). In this embodiment, the color change of the tape 55cp due to the passage of time is small. Therefore, in the part without a streak in the first external image RIo1, the total values ​​Rx, Gx, Bx (FIGS. 6(B)-6(D)) are stable. Therefore, in this embodiment, the first threshold values ​​Rxa, Gxa, Bxa and the second threshold values ​​Rxb, Gxb, Bxb that determine the allowable ranges RR, RG, RB of the total values ​​Rx, Gx, Bx are predetermined. The red tolerance range RR is a range including the red standard value Rxs, and is a range equal to or greater than a first red threshold Rxa and equal to or less than a second red threshold Rxb. The first red threshold Rxa is smaller than the red standard value Rxs, and the second red threshold Rxb is larger than the red standard value Rxs. The same is true for the green tolerance range RG and the blue tolerance range RB. The tolerance range may be experimentally determined, for example, such that the sum of pixel positions PD2 without streaks is within the tolerance range, and the sum of pixel positions PD2 showing streaks may deviate from the tolerance range.

[0042] The processor 210 refers to the histogram and detects pixel positions PD2 that indicate total values ​​outside the allowable range as pixel positions PD2 of the streaks. From the red histogram Hr (FIG. 6(B)), a plurality of pixel positions PD2 in four ranges Rr1, Rr2, Rr3, and Rr4 that indicate red total values ​​Rx that are outside the red allowable range RR are detected. From the green histogram Hg (FIG. 6(C)), a plurality of pixel positions PD2 in three ranges Rg1, Rg2, and Rg3 that indicate green total values ​​Gx that are outside the green allowable range RG are detected. From the blue histogram Hb (FIG. 6(D)), a plurality of pixel positions PD2 in three ranges Rb1, Rb2, and Rb3 that indicate blue total values ​​Bx that are outside the blue allowable range RB are detected.

[0043] In this embodiment, the processor 210 adopts all pixel positions PD2 detected from each of the three histograms Hr, Hg, and Hb as muscle pixel positions PD2 (also called muscle positions LP). FIG. 6(E) is an explanatory diagram showing muscle positions LP detected from the first external image RIo1 of FIG. 6(A) (i.e., the histograms Hr, Hg, and Hb of FIG. 6(B)-FIG. 6(D)). The horizontal axis indicates pixel positions PD2. As shown in the figure, a plurality of muscle positions LP in four ranges LP1-LP4 corresponding to four muscles La-Ld are detected. The four ranges LP1-LP4 are the sum of the range Rr1-Rr4 of FIG. 6(B), the range Rg1-Rg3 of FIG. 6(C), and the range Rb1-Rb3 of FIG. 6(D). The total number of muscle positions LP indicating one muscle can be various numbers equal to or greater than 1.

[0044] In S240 (FIG. 5), the processor 210 stores muscle position data indicating the detected muscle position LP in the storage device 215 (in this embodiment, the non-volatile storage device 230). Then, the processor 210 ends the process in FIG. 5, that is, the process in S130 in FIG. 3.

[0045] In S140, the processor 210 executes image correction processing to make streaks in the document image less noticeable.

[0046] 7 is a flowchart showing an example of the image correction process. In S310, the processor 210 obtains, from the non-volatile storage device 230, document image data representing the document image RId.

[0047] In S320, the processor 210 acquires the line position LP by referring to the line position data, and then corrects the color value of the pixel at the line position LP in the document image RId (i.e., the pixel indicating the vertical line).

[0048] 8 is an explanatory diagram of the image correction process. In the figure, a part of the original image RId before correction and a part of the original image RIdx after correction are shown. The illustrated images RId and RIdx show the same part including the streak La.

[0049] The processor 210 corrects the color value of the pixel of interest PXi included in the streak La using the color value of a pixel in the vicinity of the pixel of interest PXi and having a pixel position PD2 different from the detected streak position LP. For example, the processor 210 selects a plurality of candidate pixels PXc whose distance from the pixel of interest PXi is equal to or less than a distance threshold as candidates of reference pixels to be referred to for correcting the pixel of interest PXi. The distance threshold may be a distance for selecting so-called 8-neighborhood as the candidate pixels PXc. The processor 210 selects a pixel not included in the streak from among the plurality of candidate pixels PXc as the reference pixel PXr. The processor 210 determines the corrected color value of the pixel of interest PXi to be the median value of the color values ​​of the reference pixels PXr. The correction of the color value is performed for each of the RGB color components. By such a correction, the color value of the pixel of interest PXi is corrected to a value close to the color value of the reference pixel PXr that is in the vicinity of the pixel of interest PXi and different from the streak. Such a correction can make the streak La less noticeable. The process of determining the color value of the pixel of interest PXi using the color values ​​of the reference pixels PXr surrounding the pixel of interest PXi is also called an interpolation process. The selection range of the candidate pixels PXc may be experimentally determined in advance so as to be larger than the thickness of the line. The selection range of the candidate pixels PXc is not limited to the 8 neighborhoods, but may be, for example, 24 pixels included in 5 rows and 5 columns centered on the pixel of interest PXi. The corrected color value is not limited to the median value of the color values ​​of one or more reference pixels PXr, but may be various values ​​calculated using the color values ​​of one or more reference pixels PXr, such as an average value.

[0050] In S320 (FIG. 7), the processor 210 generates corrected original image data representing a corrected original image by correcting all color values ​​of the multiple pixels of the detected streak position LP. In S330, the processor 210 stores the corrected original image data in the storage device 215 (in this embodiment, the non-volatile storage device 230). Then, the processor 210 ends the process in FIG. 7, i.e., the process of S140 in FIG. 3.

[0051] In S150, the processor 210 outputs the corrected document image data. For example, the processor 210 may output the corrected document image data to the display unit 240, thereby causing the display unit 240 to display the corrected document image. Alternatively, the processor 210 may output (specifically, store) the corrected document image data to a storage device designated by the user (for example, the non-volatile storage device 230 or an external storage device connected to the communication interface 270). In response to the end of S150, the processor 210 ends the reading process of FIG. 3.

[0052] As described above, in this embodiment, the reading execution unit 400 (FIGS. 2(A) and 2(B)) includes the transport device 50 that transports the document along the transport path TR, and the image sensor 60 that optically reads the document at a reading position RP on the transport path TR. The control unit 299 (FIG. 1) is an example of a data processing device that processes read image data generated by the reading execution unit 400 based on a signal output from the image sensor 60, which represents a read image RI having a plurality of pixels.

[0053] The processor 210 of the multifunction device 200 executes the following process. In S210 of Fig. 5, the processor 210 acquires the first outside area read image data of the first outside area read image RIo1. As described in Fig. 4, the image data of the first outside area read image RIo1 is a signal output from the image sensor 60 during one transport of the document to read the document, and is image data generated based on a signal output from the image sensor 60 in a state where the document is located at a position away from the reading position RP.

[0054] In S220 of Fig. 5, as described in Fig. 6(A)-Fig. 6(D), the processor 210 determines the first color value evaluation values ​​Rx, Gx, Bx of each of J (J is an integer equal to or greater than 2) pixel positions PD2 in the sensor direction D2. For this determination, the processor 210 uses reference parameters including the color values ​​of K (K is an integer equal to or greater than 2) pixels having the same pixel position PD2 in the sensor direction D2 in the first outside area read image RIo1 (Fig. 6(A)). The sensor direction D2 is a direction perpendicular to the downstream direction D1, which is the conveying direction in the first outside area read image RIo1.

[0055] In S230 of FIG. 5, the processor 210 detects the line position LP (FIG. 6(E)) in the sensor direction D2 of the line La-Ld parallel to the downstream direction D1 on the first outer area reading image RIo1 (FIG. 6(A)) using the first color value evaluation values ​​Rx, Gx, Bx (FIGS. 6(A)-FIG. 6(B)) of each of the J pixel positions PD2.

[0056] In this way, the image data of the first outside area read image RIo1 used to detect the streak position LP is generated based on the signal output from the image sensor 60 during one transport of the document to read the document. Therefore, the time required to detect the streak position can be shortened compared to the case where the document is transported separately to detect the streak position. Also, the first color value evaluation values ​​Rx, Gx, Bx used to detect the streak position LP are determined using multiple color values ​​of multiple pixels at the same pixel position PD2 in the sensor direction D2. Therefore, the streak position LP can be detected more appropriately compared to the case where the first color value evaluation value is determined using the color value of one pixel.

[0057] As described in FIG. 4, the image data of the first outside area read image RIo1 (FIG. 6A) is generated based on a signal output from the image sensor 60 when the entire document is located upstream of the read position RP. As described in S220 of FIG. 5, the reference parameters used to determine the first color value evaluation values ​​Rx, Gx, and Bx are composed of the color values ​​of K pixels having the same pixel position PD2 in the sensor direction D2 in the first outside area read image RIo1 (FIG. 6A). In this embodiment, the data of the second outside area read image RIo2 is not used to determine the first color value evaluation values ​​Rx, Gx, and Bx. Therefore, the processor 210 can reduce the time required to determine the streak position LP compared to the case where both the first outside area read image RIo1 and the second outside area read image RIo2 are used to determine the first color value evaluation values ​​Rx, Gx, and Bx. The reference parameters may consist of only the color values ​​of each of the K pixels.

[0058] 7, the processor 210 acquires document read image data representing the document read image RId. In S320, the processor 210 corrects the color value of a target pixel PXi (FIG. 8) included in the multiple pixels at the detected streak position LP among the multiple pixels of the document read image RId. For this correction, the processor 210 uses the color value of a reference pixel PXr that is a pixel near the target pixel PXi and has a position different from the detected streak position LP. Thus, the processor 210 can make the streak on the document read image RId less noticeable.

[0059] As described in S220 of FIG. 5, the first color value evaluation values ​​Rx, Gx, Bx are the sum of the color values ​​of a plurality of pixels (in this embodiment, K pixels having the same pixel position PD2 in the sensor direction D2 in the first outside area read image RIo1 (FIG. 6(A))) included in the reference parameters. As described in S230 of FIG. 5, the processor 210 detects the pixel position PD2 associated with the out-of-range evaluation values, which are the first color value evaluation values ​​Rx, Gx, Bx outside the predetermined allowable ranges RR, RG, RB, as the streak position LP. Such detection of the pixel position PD2 is a simple process. Compared to the case of performing a complex process such as pattern recognition of the shape of the streak in the document read image RId, the processor 210 can reduce the time required to determine the streak position LP. The processor 210 can also appropriately detect the streak position LP.

[0060] B. Second Example: Fig. 9 is a flow chart showing a second embodiment of the line position detection process. The difference from the first embodiment of Fig. 5 is that the processor 210 detects the line position LP from the second outside area read image in addition to the first outside area read image. The process of Fig. 9 is executed instead of the process of Fig. 5 (for example, the processor 210 executes the process of Fig. 9 in S130 of Fig. 3).

[0061] Fig. 10(A) shows another example of a scanned image. The only difference between scanned image RI2 and scanned image RI2 in Fig. 4 is that the third streak Lc is divided into a first partial streak Lc1 on the downstream direction D1 side and a second partial streak Lc2 on the upstream direction D1r side. The positions of the sensor direction D2 are different between these partial streaks Lc1 and Lc2. Such a change in the streak position can occur when the position of a foreign object changes during the transport of the document.

[0062] The read image RI2 includes partial images RI2o1, RI2d, and RI2o2 corresponding to partial images RIo1, RId, and RIo2 of the read image RI (FIG. 4). The first external region read image RI2o1 (also called the first external image RI2o1) shows four stripes La, Lb, Lc1, and Ld. The original read image RI2d (also called the original image RI2d) shows both the first partial stripe Lc1 and the second partial stripe Lc2 in addition to the stripes La, Lb, and Ld. The second external region read image RI2o2 (also called the second external image RI2o2) shows four stripes La, Lb, Lc2, and Ld.

[0063] In S210a (FIG. 9), the processor 210 acquires, from the non-volatile storage device 230, first external image data representing the first external image RI2o1 and second external image data representing the second external image RI2o2.

[0064] In S220a, the processor 210 uses the first external image RI2o1 to generate histograms for each of RGB and determine first color value evaluation values ​​for each of RGB according to the same algorithm as in the process of S220 in FIG.

[0065] In S220b, the processor 210 uses the second external image RI2o2 to generate histograms for each of RGB according to the same algorithm as in the process of S220 in Fig. 5. The sum of the color values ​​of each pixel position PD2 of each histogram generated in S220b is referred to as a second color value evaluation value. In this embodiment, the histogram generated in S220b indicates the sum of the color values ​​of K pixels at each of J pixel positions PD2, similar to the histogram generated in S220a (in this embodiment, the sizes in each direction D1, D2 of the second external image RI2o2 are the same as the sizes in each direction D1, D2 of the first external image RI2o1, respectively).

[0066] In S230a, the processor 210 detects the line positions LP according to the same algorithm as the process of S230 in Fig. 5, using the first color value evaluation value determined in S220a. Fig. 10(B) is an explanatory diagram showing the detected line positions LP. The horizontal axis indicates the pixel position PD2. As shown in the figure, a plurality of line positions LP in four ranges LP11-LP14 corresponding to the four lines La, Lb, Lc1, and Ld are detected from the first external image RI2o1.

[0067] In S230b, the processor 210 uses the second color value evaluation value determined in S220b to detect muscle positions LP according to the same algorithm as the process of S230 in Fig. 5. As shown in Fig. 10(B) , a plurality of muscle positions LP in four ranges LP21-LP24 corresponding to the four muscles La, Lb, Lc2, and Ld are detected from the second external image RI2o2.

[0068] In this embodiment, the processor 210 employs both the muscle position LP detected from the first external image RI2o1 and the muscle position LP detected from the second external image RI2o2.

[0069] In S240a, the processor 210 stores muscle position data indicating the detected muscle position LP in the non-volatile storage device 230. Then, the processor 210 ends the processing of FIG.

[0070] As described above, in this embodiment, the processor 210 detects the line position LP from both the first external image RI2o1 and the second external image RI2o2. Therefore, when the original image RI2d includes the second partial line Lc2 that is not included in the first external image RI2o1 but is included in the second external image RI2o2, the processor 210 can appropriately detect the line position LP of the second partial line Lc2. Also, when the original image RI2d includes the first partial line Lc1 that is not included in the second external image RI2o2 but is included in the first external image RI2o1, the processor 210 can appropriately detect the line position LP of the first partial line Lc1.

[0071] In addition, when the processor 210 corrects the original image RI2d of FIG. 10(A) using the streak position LP of FIG. 10(B) in S140 of FIG. 3, the processor 210 corrects the color values ​​of the pixels indicating the streaks in the original image RI2d as well as the color values ​​of the pixels indicating the portions other than the streaks. For example, the color value of the pixel at the same pixel position PD2 as the second partial streak Lc2 in the portion of the original image RI2d on the downstream direction D1 side is corrected. However, the correction of the color value of the target pixel PXi (FIG. 8) is performed using the color value of the reference pixel PXr, which is a pixel in the vicinity of the target pixel PXi and has a pixel position PD2 different from the streak position LP. Therefore, the difference between the corrected color value and the color value before correction is suppressed for the pixel indicating the portion other than the streak.

[0072] In this embodiment, the image data of the first outer area read image RI2o1 is generated based on a signal output from the image sensor 60 when the entire document is located upstream of the reading position RP (FIG. 2(B)). The reference parameters used in determining the first color value evaluation value (S220a) are composed of the color values ​​of K pixels having the same pixel position PD2 in the sensor direction D2 in the first outer area read image RI2o1. In this embodiment, the data of the second outer area read image RI2o2 is not used in determining the first color value evaluation value (S220a). The reference parameters may be composed of only the color values ​​of the K pixels.

[0073] 9, the processor 210 acquires image data of the second outer region read image RI2o2 in addition to the image data of the first outer region read image RI2o1. The image data of the second outer region read image RI2o2 is image data generated based on a signal output from the image sensor 60 in a state where the entire document is located downstream of the reading position RP.

[0074] In S220b, the processor 210 determines the second color value evaluation value of each of L (L is an integer equal to or greater than 2) pixel positions PD2 in the sensor direction D2 in the second outside area read image RI2o2 by using the color values ​​of M (M is an integer equal to or greater than 2) pixels having the same pixel position PD2 in the sensor direction D2 in the second outside area read image RI2o2. In this embodiment, the number L of pixel positions PD2 at which the second color value evaluation value is determined is the same as the number J of pixel positions PD2 at which the first color value evaluation value is determined in S220a. In addition, the number M of pixels used to determine the second color value evaluation value is the same as the number K of pixels used to determine the first color value evaluation value in S220a. However, M may be different from K. In addition, the allowable range used in S230b may be different from the allowable range of the same color component used in S230a.

[0075] In S230b, the processor 210 detects streak positions LP in the sensor direction D2 of streaks parallel to the downstream direction D1 on the second outer region read image RI2o2 using the second color value evaluation values ​​of each of the L pixel positions PD2.

[0076] As described above, the processor 210 can appropriately detect the line position LP of the line included in the document read image RI2d by using the first outside area read image RI2o1 and the second outside area read image RI2o2.

[0077] C. Third Example: Fig. 11 is a flow chart showing a third embodiment of the line position detection process. The difference from the second embodiment of Fig. 9 is that the processor 210 determines the first color value evaluation value using both the first outside area read image and the second outside area read image. The process of Fig. 11 is executed instead of the process of Fig. 5 (for example, in S130 of Fig. 3, the processor 210 executes the process of Fig. 9).

[0078] FIG. 12A shows another example of a read image. The difference between the read image RI in FIG. 4 and the read image RI3 is that the third streak Lcx has partially disappeared in the read image RI3. Such a streak may be caused by a foreign object moving during the transport of the document.

[0079] The scanned image RI3 includes partial images RI3o1, RI3d, and RI3o2 corresponding to the partial images RIo1, RId, and RIo2 of the scanned image RI (FIG. 4). Each of the partial images RI3o1, RI3d, and RI3o2 shows four lines La, Lb, Lcx, and Ld.

[0080] S210a (FIG. 11) is the same as S210a in FIG. 9. The processor 210 acquires, from the non-volatile storage device 230, first external image data representing the first external image RI3o1 and second external image data representing the second external image RI3o2.

[0081] In S220c, the processor 210 uses both the first external image RI3o1 and the second external image RI3o2 to generate histograms for each of RGB and determine a first color value evaluation value for each of RGB according to the same algorithm as the process of S220 in Fig. 5. The histogram generated in S220c indicates the sum of color values ​​of a plurality of pixels at each of J pixel positions PD2. The sum (i.e., the first color value evaluation value) at one pixel position PD2 is the sum of K color values ​​of K pixels in the first external image RI3o1 and K color values ​​of K pixels in the second external image RI3o2.

[0082] In S230c, the processor 210 detects the muscle positions LP according to the same algorithm as the process of S230 in Fig. 5, using the first color value evaluation value determined in S220c. Fig. 12(B) is an explanatory diagram showing the detected muscle positions LP. The horizontal axis indicates the pixel position PD2. As shown in the figure, a plurality of muscle positions LP in four ranges LP31-LP34 corresponding to the four muscles La, Lb, Lcx, and Ld are detected by combining the first external image RI3o1 and the second external image RI3o2.

[0083] In S240c, the processor 210 stores muscle position data indicating the detected muscle position LP in the non-volatile storage device 230. Then, the processor 210 ends the processing of FIG.

[0084] As described above, in this embodiment, the processor 210 uses both the first external image RI3o1 and the second external image RI3o2 to determine the first color value evaluation value. Therefore, even if the line is partially disappeared as in the third line Lcx (FIG. 12(A)), the processor 210 can appropriately detect the line. For example, in the first external image RI3o1, a large portion of the third line Lcx is missing. If only the first external image RI3o1 is used to determine the first color value evaluation value, the line position LP of the third line Lcx may not be detected. Also, in the second external image RI3o2, a large portion of the third line Lcx is missing. If only the second external image RI3o2 is used to determine the first color value evaluation value, the line position LP of the third line Lcx may not be detected. In this embodiment, since both the first external image RI3o1 and the second external image RI3o2 are used, the line position LP of the third line Lcx may be appropriately detected.

[0085] In this embodiment, the image data of the first outer area read image RI3o1 is generated based on a signal output from the image sensor in an upstream state where the entire document is located upstream of the reading position RP (FIG. 2(B)). In S210a of FIG. 11, the processor 210 acquires image data of the second outer area read image RI3o2 in addition to the image data of the first outer area read image RI3o1. The image data of the second outer area read image RI3o2 is image data generated based on a signal output from the image sensor 60 in a state where the entire document is located downstream of the reading position RP.

[0086] The reference parameters used in determining the first color value evaluation value (S220c) include color values ​​of K pixels (K is an integer of 2 or more) having the same pixel position PD2 in the sensor direction D2 in the first external area read image RI3o1, and color values ​​of N pixels (N is an integer of 2 or more) having the same pixel position PD2 in the sensor direction D2 in the second external area read image RI3o2. In this embodiment, the number of pixels N of the second external area read image RI3o2 is the same as the number of pixels K of the first external area read image RI3o1. However, N may be different from K.

[0087] As described above, the processor 210 can appropriately detect the line position LP of the line included in the document read image RI2d by using the first outside area read image RI2o1 and the second outside area read image RI2o2.

[0088] D. Variations: (1) The first color value evaluation value (S220 (FIG. 5), S220a (FIG. 9), S220c (FIG. 11)) is not limited to the total value of the color values ​​of multiple pixels such as the total values ​​Rx, Gx, and Bx in FIGS. 6(B) to 6(D), but may be an overall evaluation value of the color values ​​of multiple pixels (e.g., average value, median, etc.). The first color value evaluation value may be various values ​​calculated using the color values ​​of multiple pixels. The first color value evaluation value may be various values ​​that may differ between a pixel position PD2 without a streak and a pixel position PD2 with a streak. The same applies to the second color value evaluation value (S220b (FIG. 9)). The second color value evaluation value (S220b (FIG. 9)) may be calculated according to the same algorithm as the algorithm for calculating the first color value evaluation value.

[0089] (2) In S220 (FIG. 5), S220a (FIG. 9), and S220c (FIG. 11), the number of pixels K used to calculate one first color value evaluation value at one pixel position PD2 may be less than the total number of pixels at the same pixel position PD2 in the outer area read image (e.g., the first outer area read image RIo1). In other words, the first color value evaluation value may be calculated using a part of the outer area read image.

[0090] In S220b (FIG. 9), the number of pixels M used to calculate one second color value evaluation value at one pixel position PD2 may be less than the total number of pixels at the same pixel position PD2 in the outer area read image (e.g., the second outer area read image RI2o2). That is, the second color value evaluation value may be calculated using a part of the outer area read image.

[0091] (3) In S220 (FIG. 5), S220a (FIG. 9), and S220c (FIG. 11), the total number J of pixel positions PD2 in the sensor direction D2 for which the first color value evaluation value is calculated may be smaller than the number of pixels in the sensor direction D2 of the outer area read image (e.g., the first outer area read image RIo1). That is, the processor 210 may calculate the first color value evaluation value at some of the pixel positions PD2 of the outer area read image in the sensor direction D2. For example, the processor 210 may calculate the first color value evaluation value at even-numbered pixel positions PD2 in the sensor direction D2 and omit the calculation of the first color value evaluation value at odd-numbered pixel positions PD2 in the sensor direction D2. In this case, in S230 (FIG. 5), S230a (FIG. 9), and S230c (FIG. 11), the processor 210 may detect, as a pixel position PD2 indicating a streak (i.e., a streak position LP), a pixel position PD2 in the vicinity of the streak position LP detected using the first color value evaluation value, among the multiple pixel positions PD2 for which the calculation of the first color value evaluation value has been omitted. The pixel position PD2 in the vicinity of the streak position LP may be, for example, a pixel position PD2 whose shortest distance from the streak position LP is equal to or smaller than a predetermined threshold value. The same applies to the calculation of the second color value evaluation value (S220b (FIG. 9)) and the detection of the streak position LP using the second color value evaluation value (S230b (FIG. 9)). Note that the total number L of pixel positions PD2 in the sensor direction D2 for which the second color value evaluation value is calculated may be different from the total number J of pixel positions PD2 in the sensor direction D2 for which the first color value evaluation value is calculated.

[0092] 5, the processor 210 may use the second outer region read image RIo2 instead of the first outer region read image RIo1. In this case, the data of the first outer region read image RIo1 is not used to determine the color value evaluation value in S220.

[0093] (5) The image correction process may be various processes for making the streak less noticeable, instead of the processes described in Fig. 7 and Fig. 8. For example, the processor 210 may execute various interpolation processes (for example, nearest neighbor interpolation using reference pixels PXr having a position different from the streak position LP, etc.). The processor 210 may also change the selection range of the candidate pixels PXc used for selecting the reference pixels PXr according to the image data to be processed. For example, when selecting a plurality of pixels within a range whose distance (for example, Euclidean distance) from the pixel of interest PXi is equal to or less than a distance threshold as the candidate pixels PXc, the processor 210 may adjust the distance threshold so that the total number of the reference pixels PXr is equal to or greater than a predetermined threshold (for example, 10).

[0094] (6) The corrected document image data generated by the reading process (FIG. 3) may be grayscale image data instead of color image data. For example, the processor 210 may convert the color corrected document image data into grayscale corrected document image data after the image correction process (S140). Also, the reading execution unit 400 may generate grayscale read image data instead of color read image data.

[0095] (7) The use of the streak position LP detected by the streak position detection process is not limited to image correction process for making the streak less noticeable, and may be any use. For example, the processor 210 may cause the display unit 240 to display information indicating a portion of the conveying device 50 (FIGS. 2(A) and 2(B)) corresponding to the streak position LP as a portion to be cleaned. In this embodiment, the portion corresponding to the streak position LP is the portion of the guide member 55c and the platen 80 corresponding to the streak position LP. The displayed information may be any information related to the portion corresponding to the streak position LP, and may include, for example, an image of the portion corresponding to the streak position LP.

[0096] (8) The configuration of the reading execution unit 400 is not limited to the configuration described in FIG. 2(A) and FIG. 2(B), and may be any configuration including a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path. For example, the color of the portion of the guide member 55c corresponding to the reading position RP (the tape 55cp in the above embodiment) is not limited to gray, and may be any color. The conveying device 50 may be configured to convey the document without inverting it. The reading device including the reading execution unit may be a single-function reading device instead of the multifunction device 200. A control device provided inside the reading device, such as the control unit 299, may process the read image data (for example, the control device may execute the line position detection process (and further image correction process)). Alternatively, an external data processing device connected to the reading device may process the read image data (for example, the data processing device may execute the line position detection process (and further image correction process)). The data processing device may be various devices such as a personal computer, a smartphone, a tablet computer, etc. In addition, a plurality of devices (e.g., computers) that can communicate with each other via a network may share a part of the data processing function of the data processing device, and as a whole, provide the data processing function (a system including these devices corresponds to a data processing device).

[0097] In each of the above embodiments, a part of the configuration realized by hardware may be replaced by software, and conversely, a part or all of the configuration realized by software may be replaced by hardware. For example, the function of determining the color evaluation value in S220 in Fig. 5 may be realized by a dedicated hardware circuit.

[0098] Furthermore, when some or all of the functions of the present invention are realized by a computer program, the program can be provided in a form stored in a computer-readable recording medium (e.g., a non-transitory recording medium). The program can be used in a state stored in the same or a different recording medium (computer-readable recording medium) from when it was provided. "Computer-readable recording medium" is not limited to portable recording media such as memory cards and CD-ROMs, but can also include internal storage devices within a computer, such as various ROMs, and external storage devices connected to a computer, such as a hard disk drive.

[0099] Although the present invention has been described above based on examples and modifications, the above-described embodiments of the invention are intended to facilitate understanding of the present invention and are not intended to limit the present invention. The present invention may be modified or improved without departing from the spirit of the invention, and equivalents thereof are included in the present invention. [Explanation of symbols]

[0100] 50...conveying device, 54a-54g...rollers, 55a-55e...guide members, 55cp...tape, 56...paper feed tray, 57...paper output tray, 60...image sensor, 60L...reading line image, 70...housing, 80...original table, 90...signal processing unit, 200...multifunction device, 210...processor, 215...storage device, 220...volatile storage device, 230...non-volatile storage device, 232...program, 240...display unit, 250...operation unit, 270...communication interface, 290...printing execution unit, 299...control unit, 400...reading execution unit, RP...reading position, TR...conveying path

Claims

1. A data processing device that processes read image data representing a read image having a plurality of pixels, the read image data being generated by a reading execution unit including a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path, based on a signal output from the image sensor, the read image data comprising: an acquisition unit that acquires outside-document area read image data generated based on a signal output from the image sensor during one transport of the document for reading the document, the signal being output from the image sensor when the document is located at a position away from the reading position; a determination unit that determines a first color value evaluation value of each of J pixel positions (J is an integer of 2 or more) in a second direction perpendicular to a first direction, which is a transport direction, in the outside-document area read image represented by the outside-document area read image data, using reference parameters including color values ​​of each of K pixels (K is an integer of 2 or more) having the same pixel position in the second direction in the outside-document area read image; a detection unit that detects a position in the second direction of a streak parallel to the first direction on the document outside region read image by using the first color value evaluation value of each of the J pixel positions; A data processing device comprising:

2. 2. A data processing apparatus according to claim 1, the outside-document-area read image data includes first outside-document-area read image data, the first outside-document region read image data is generated based on a signal output from the image sensor in a state where the entire document is located upstream of the reading position; the first color value evaluation value at each of the J pixel positions is an evaluation value in a first outside-document-area read image represented by the first outside-document-area read image data, the reference parameters are configured with the color values ​​of the K pixels in the first outside-document-area read image, the position of the streak in the second direction detected using the first color value evaluation value is a position of the streak parallel to the first direction on the first outside-document region read image; the document outside region read image data includes second document outside region read image data, the acquiring unit is further configured to acquire the second outside-document region read image data generated based on a signal output from the image sensor in a state in which the entire document is located downstream of the reading position, The determination unit further a second color value evaluation value of each of L pixel positions (L is an integer equal to or greater than 2) in the second direction in the second outside-document area read image represented by the second outside-document area read image data is determined using color values ​​of M pixels (M is an integer equal to or greater than 2) having the same pixel position in the second direction in the second outside-document area read image, The detection unit further includes: a position in the second direction of a streak parallel to the first direction on the second outside document region read image is detected by using the second color value evaluation value of each of the L pixel positions; Data processing device.

3. 2. A data processing apparatus according to claim 1, the document outside region read image data is generated based on the signal output from the image sensor in one of a state in which the entire document is located upstream of the reading position and a state in which the entire document is located downstream of the reading position; the reference parameters consist of the color values ​​of each of the K pixels; Data processing device.

4. 2. A data processing apparatus according to claim 1, the outside-document-area read image data includes first outside-document-area read image data, the first outside-document region read image data is generated based on the signal output from the image sensor in a first state, which is one of an upstream state in which the entire document is located upstream of the reading position and a downstream state in which the entire document is located downstream of the reading position; the document outside region read image data includes second document outside region read image data, the acquiring unit is further configured to acquire the second outside-document-area read image data generated based on a signal output from the image sensor in a second state that is a state different from the first state of the upstream state and the downstream state, the reference parameters include the color values ​​of the K pixels in a first outside-document area read image represented by the first outside-document area read image data, and color values ​​of N pixels (N is an integer equal to or greater than 2) having the same pixel position in the second direction in a second outside-document area read image represented by the second outside-document area read image data. Data processing device.

5. 5. A data processing device according to claim 1, The acquisition unit is further configured to acquire document read image data representing a read image of the document, The data processing device further comprises: A data processing device comprising: a correction unit that corrects a color value of a target pixel included in a plurality of pixels at the position in the second direction of a detected line among a plurality of pixels of the scanned image of the document, using a color value of a pixel whose distance from the target pixel is equal to or less than a distance threshold and which has a position different from the position in the second direction of the detected line.

6. 6. A data processing device according to claim 1, the first color value evaluation value is a total value of color values ​​of a plurality of pixels included in the reference parameters; the detection unit is configured to detect a pixel position in the second direction associated with an out-of-range evaluation value, which is a first color value evaluation value outside a predetermined allowable range, as the position in the second direction of the streak. Data processing device.

7. A computer program for a computer that processes read image data representing a read image having a plurality of pixels, the read image data being generated by a reading execution unit including a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path based on a signal output from the image sensor, the computer program comprising: an acquisition function for acquiring image data of an area outside the document, the image data being generated based on a signal output from the image sensor during one transport of the document for reading the document, the image data being output from the image sensor when the document is located at a position away from the reading position; a determination function for determining a first color value evaluation value of each of J pixel positions (J is an integer of 2 or more) in a second direction perpendicular to a first direction, which is a conveying direction, in the outside-document area read image represented by the outside-document area read image data, using reference parameters including color values ​​of each of K pixels (K is an integer of 2 or more) having the same pixel position in the second direction in the outside-document area read image; a detection function for detecting a position in the second direction of a streak parallel to the first direction on the document outside region read image by using the first color value evaluation value of each of the J pixel positions; A computer program that enables a computer to realize the above.

8. A computer-readable recording medium having recorded thereon a computer program for a computer that processes read image data representing a read image having a plurality of pixels, the read image data being generated by a reading execution unit that includes a conveying device that conveys a document along a conveying path and an image sensor that optically reads the document at a reading position on the conveying path, based on a signal output from the image sensor, the computer-readable recording medium comprising: The computer program comprises: an acquisition function for acquiring image data of an area outside the document, the image data being generated based on a signal output from the image sensor during one transport of the document for reading the document, the image data being output from the image sensor when the document is located at a position away from the reading position; a determination function for determining a first color value evaluation value of each of J pixel positions (J is an integer of 2 or more) in a second direction perpendicular to a first direction, which is a conveying direction, in the outside-document area read image represented by the outside-document area read image data, using reference parameters including color values ​​of each of K pixels (K is an integer of 2 or more) having the same pixel position in the second direction in the outside-document area read image; a detection function for detecting a position in the second direction of a streak parallel to the first direction on the document outside region read image by using the first color value evaluation value of each of the J pixel positions; A recording medium that enables a computer to realize the above.

Citation Information

Patent Citations

  • pillar

    JP1988044062A

  • Original reader

    JP2004120425A

  • Image processing device and image reader

    JP2017103699A