Image processing device, image processing method, and program
The image processing device and method enhance object recognition accuracy by calculating feature amounts and performing projective transformation to align images, addressing the challenge of inadequate feature range specification in existing technologies.
Patent Information
- Application Number
- JP2020053665
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2020-03-25
- Publication Date
- 2024-09-18
- Estimated Expiration
- 2040-03-25
AI Technical Summary
Existing technologies struggle to accurately recognize the state of objects in images due to inadequate specification of feature ranges.
An image processing device and method that calculates feature amounts within a specified range in an image, identifies multiple feature ranges that can form the vertices of a polygon, and performs projective transformation to align the image for accurate recognition.
Enables high-accuracy recognition of objects by appropriately specifying feature ranges and aligning images for improved recognition processing.
Smart Images

Figure 0007552048000008 
Figure 0007552048000003 
Figure 0007552048000007
Abstract
Description
[Technical field]
[0001] The present invention relates to an image processing device, an image processing method, and a program. [Background technology]
[0002] There is a demand for a technology that can recognize the state of a recognition target object shown in an image with higher accuracy. Patent Document 1 discloses a related technology that can reliably read the indicated value of a meter. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] JP 2009-75848 A Summary of the Invention [Problem to be solved by the invention]
[0004] In order to accurately recognize an object, it is necessary to properly identify the characteristic range in an image.
[0005] SUMMARY OF THE PRESENT DISCLOSURE An object of the present invention is to provide an image processing device, an image processing method, and a program that solve the above-mentioned problems. [Means for solving the problem]
[0006] According to a first aspect of the present invention, an image processing device comprises a feature amount calculation means for calculating a feature amount of a feature range included in a processing target range excluding an exclusion range in an image of an object to be recognized, and a feature range identification means for identifying a plurality of feature ranges that may constitute vertices of a polygon included in the feature range in the image based on the feature amounts.
[0007] According to a second aspect of the present invention, an image processing method calculates feature values of a feature range included in a processing target range excluding an exclusion range in an image of an object to be recognized, and identifies a plurality of feature ranges that may constitute vertices of a polygon included in the feature range in the image based on the feature values.
[0008] In addition, the present invention provides a program that causes a computer of an image processing device to function as a feature amount calculation means that calculates feature amounts of a feature amount of a feature amount included in a processing target range excluding an exclusion range in an image of an object to be recognized, and a feature amount identification means that identifies a plurality of feature amount of feature amounts that can constitute vertices of a polygon included in the feature amount in the image based on the feature amount. Effect of the Invention
[0009] According to the present invention, it is possible to appropriately specify a characteristic range in an image in order to recognize an object to be recognized with high accuracy. [Brief description of the drawings]
[0010] [Figure 1] 1 is a diagram showing an overview of an image processing apparatus according to an embodiment of the present invention; [Diagram 2] 1 is a diagram illustrating a hardware configuration of an image processing apparatus according to an embodiment of the present invention. [Diagram 3] 1 is a functional block diagram of an image processing apparatus according to an embodiment of the present invention. [Figure 4] 4 is a flowchart of an image processing apparatus according to an embodiment of the present invention. [Diagram 5] FIG. 1 is a first diagram illustrating an overview of processing performed by an image processing device according to an embodiment of the present invention. [Figure 6] FIG. 2 is a second diagram showing the outline of processing by the image processing device according to the embodiment of the present invention. [Figure 7] FIG. 1 is a diagram showing a minimum configuration of an image processing device according to the present invention. [Figure 8] FIG. 2 is a diagram showing a processing flow of an image processing device with a minimum configuration according to the present invention. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0011] An image processing apparatus according to an embodiment of the present invention will now be described with reference to the drawings. FIG. 1 is a diagram showing an overview of an image processing apparatus according to this embodiment. As shown in this figure, the image processing device 1 may be, for example, a device that functions as a mobile terminal such as a smartphone. The image processing device 1 includes a camera that captures a recognition object 2, such as an instrument, a clock, or characters printed on a device. The recognition object 2 may be of any type.
[0012] FIG. 2 is a diagram illustrating a hardware configuration of the image processing device. 2, the image processing device 1 is a computer including various hardware components such as a CPU (Central Processing Unit) 101, a ROM (Read Only Memory) 102, a RAM (Random Access Memory) 103, an SSD (Solid State Drive) 104, a communication module 105, and a camera 106. The image processing device 1 may include other hardware configurations.
[0013] FIG. 3 is a functional block diagram of the image processing device. The image processing device 1 executes the image processing program to realize the functions of a control unit 11, a processing target range specifying unit 12, a characteristic range specifying unit 13, an image conversion unit 14, and a recognition processing unit 15. The control unit 11 controls the other functional units. The processing target range specification unit 12 specifies a processing target range relating to the recognition target object in an image obtained by photographing the recognition target object. The characteristic area specifying unit 13 specifies a plurality of characteristic areas that can form vertices of a polygon when the characteristic areas are regarded as points, based on the feature amounts of the characteristic areas included in the processing target area. The image transformation unit 14 performs a projective transformation to bring the image of the object to be recognized closer to a normal image obtained by photographing the object from the front. The recognition processing unit 15 performs a recognition process for the state of the recognition object by using the result of projective transformation of an image of the recognition object.
[0014] In this embodiment, the image processing device 1 is described as a mobile terminal, but it may be a PC, a computer server, or the like. In this case, an image of the recognition target object 2 described below may be generated by an image capture device, and the PC or computer server may acquire the image from the image capture device and perform the following processing. Details of the processing of the image processing device will be described below.
[0015] FIG. 4 is a flow chart of the image processing device. FIG. 5 is a first diagram illustrating an overview of processing performed by the image processing device. FIG. 6 is a second diagram showing the outline of processing performed by the image processing device. First, the user operates the image processing device 1 to capture an image of the recognition target 2. The camera 106 of the image processing device 1 generates a captured image of an area including the recognition target 2 based on the user's shooting operation, and records the captured image in a storage unit such as the SSD 104 (step S101). The user instructs the image processing device 1 to start image processing of the recognition target 2. The control unit 11 then reads the captured image of the recognition target 2, and outputs the captured image to the processing target area specification unit 12.
[0016] The processing target range identifying unit 12 acquires a captured image (step S102). Here, the processing target range identifying unit 12 may acquire a captured image in which the image converting unit 14 has once performed projective transformation (first projective transformation) on the captured image to convert it into an image in which the recognition target 2 is viewed from the front. For example, if a square mark is printed or embodied on the recognition target 2, a projective transformation matrix may be generated so that the shape of the mark in the captured image becomes a square shape, and the captured image may be projectively transformed using the projective transformation matrix to use the new captured image. As an example, this projective transformation matrix is calculated by a known method of calculating a homography transformation matrix using the deviations or correlation values between the four coordinates of the rectangular corners of the mark in the captured image and the four coordinates of the corresponding positions of the mark that are determined in advance.
[0017] The normal image is an image taken from the front of the recognition target 2. The taken image and the normal image are images of the recognition target 2 taken from positions at approximately the same distance from the recognition target 2. In this case, the size of the recognition target 2 shown in the taken image is approximately the same as the size of the recognition target 2 shown in the normal image.
[0018] The processing target range identifying unit 12 identifies a processing target range of the recognition target object 2 appearing in the captured image (step S103). As an example, the processing target range is a range obtained by excluding an excluded range other than the recognition target object 2 appearing in the captured image from the captured image. When the recognition target object 2 is, for example, an instrument such as a clock, an analog meter, or a digital meter, the processing target range identifying unit 12 may identify only the inside of the face of the clock or the instrument (such as a dial face or a liquid crystal face) as the processing target range. The processing target range identifying unit 12 may also identify the pointer of the clock or the instrument as the excluded range. The processing target range identifying unit 12 may identify a range that matches the normal image by pattern matching or the like, and identify the range as the processing target range. The processing target range identifying unit 12 may identify the processing target range by a method other than the above. For example, the processing target range identifying unit 12 may identify the processing target range by using a machine learning method. The processing target range identifying unit 12 may identify an image in which foreign objects (such as the above-mentioned marks) in the recognition target object 2 are masked.
[0019] As shown in FIG. 5, the feature amount calculation range r of a small section is set within the processing target range, and the feature amount calculation range r is set while shifting the feature amount calculation range r by a predetermined number of pixels in the horizontal direction or the vertical direction, and the feature amount of each of the set feature amount calculation ranges r is calculated sequentially (step S104). More specifically, the feature amount calculation range r is defined as a range smaller than the processing target range. Each of the feature amount calculation ranges r set within the captured image may overlap with other feature amount calculation ranges r. The feature amount calculation range 13 calculates the feature amount of each pixel within the feature amount calculation range r based on color information and edge information of each pixel included in the feature amount calculation range r. The feature amount calculation range 13 calculates the feature amount of each pixel using a known feature amount calculation method (AgastFeasture, AKAZE, BRISK, FAST, KAZE, MSER, ORB, SIFT, SURF, etc.). The feature amount calculation range r is calculated by summing or integrating the feature amounts of each pixel included in the feature amount calculation range r.
[0020] The characteristic range identifying unit 13 sets a threshold to the value of the largest feature amount among the feature amounts calculated for each feature amount calculation range r, and gradually lowers the threshold to identify the feature amount calculation range r corresponding to the multiple feature amounts exceeding the threshold as a characteristic range (step S105). The characteristic range identifying unit 13 may identify the characteristic range in the above-mentioned captured image showing the recognition target 2 based on a learning model obtained by machine learning an input-output relationship in which an image is input and the feature range in the image is output.
[0021] As an example, the feature range identification unit 13 identifies four feature ranges. The feature range identification unit 13 may identify three feature ranges in descending order of the feature amount. Alternatively, the feature range identification unit 13 may identify three feature ranges in descending order of the feature amount. In the features of the above-mentioned feature ranges, the feature range identification unit 13 identifies a plurality of feature amount calculation ranges r that may constitute the vertices of a polygon as feature ranges. When identifying such feature ranges, the feature range identification unit 13 identifies three or more feature amount calculation ranges r that are as far outside the processing target range as possible.
[0022] For example, when identifying four feature amount calculation ranges r as feature ranges, the feature amount calculation range identifying unit 13 may identify one feature amount range from each of the areas A, B, C, and D (see FIG. 5) divided into four by lines drawn vertically and horizontally with respect to the center of the processing target area. Alternatively, multiple feature amount calculation ranges r may be identified for each of the areas A, B, C, and D in descending order of feature amount, and the central coordinates indicated by the feature amount calculation ranges r may be compared to identify the one feature amount calculation range r whose x coordinate or y coordinate is closest to the coordinate indicating the outer frame of the feature amount calculation range r as the feature amount range. The feature amount calculation range identifying unit 13 outputs the identified feature amount ranges to the image conversion unit 14.
[0023] The feature range identification unit 13 may output the feature amount calculation range r having a predetermined number of feature amounts equal to or greater than the threshold value to a display device or the like based on the relationship between the feature amount of each feature amount calculation range r and the threshold value, and may accept a designation (selection information) of the feature amount calculation range r to be identified as the feature range from the user, thereby identifying the feature range. This process is one aspect of a process in which the feature amount calculation range identification unit 13 outputs the feature amount calculation range to the display device, inputs selection information indicating the feature amount calculation range selected by the user from the output feature amount calculation range, and identifies multiple feature amount calculation ranges that may form the vertices of a polygon as the feature range based on the selection information. The feature range identification unit 13 may output multiple feature amount calculation ranges close to the outside of the processing target range to the display device, inputs selection information indicating the feature amount calculation range selected by the user from the output feature amount calculation range, and identifies multiple feature amount calculation ranges that may form the vertices of a polygon as the feature range based on the selection information. In the following, the description will be given on the assumption that the feature amount calculation range identification unit 13 identifies four feature amount calculation ranges (a, b, c, and d in FIG. 6) in this embodiment.
[0024] The image conversion unit 14 acquires coordinate information of the four characteristic ranges. The image conversion unit 14 acquires the normal image of the recognition target object 2 from the storage unit. The image conversion unit 14 specifies the amount of deviation between the image pattern included in the characteristic range specified in the processing target range in the captured image and the image pattern included in the corresponding position range in the normal image for each of the four characteristic ranges (step S106). For example, it is assumed that the processing target range of the recognition target object 2 is a board surface on which characters are printed, and the characters are printed in the characteristic range. In this case, the image conversion unit 14 assumes that a part of the character (image pattern) appears in the characteristic range. The image conversion unit 14 calculates the amount of deviation between a part of the character appearing in the characteristic range specified in the processing target of the captured image and a part of the character appearing in the corresponding range in the normal image. This amount of deviation may be expressed by a vertical deviation (amount of deviation in the x-coordinate direction), a horizontal deviation (amount of deviation in the y-coordinate), a rotation angle, or the like.
[0025] The image conversion unit 14 calculates a homography transformation matrix by a known method for calculating a homography transformation matrix using the shift amounts calculated for each of the four feature ranges (step S107). The image conversion unit 14 may calculate a homography transformation matrix by a known method for calculating an affine transformation matrix using the shift amounts related to the features (numbers) of any three of the four feature ranges distributed in the recognition target object 2.
[0026] The image transformation unit 14 generates a projection-transformed image by projectively transforming the captured image containing the recognition target 2 using a projection transformation matrix (step S109). When the first projection transformation using the above-mentioned mark is performed, this transformation becomes a second projection transformation. The image transformation unit 14 outputs the projection-transformed image to the recognition processing unit 15. It is assumed that the recognition target 2 shown in the captured image is an analog meter including a pointer. Based on the position of the scale indicated by the pointer in the projection-transformed image, the recognition processing unit 15 calculates a numerical value to be stored corresponding to that position by interpolation calculation or the like. The image transformation unit 14 outputs a numerical value corresponding to the position of the scale indicated by the pointer. For example, the output destination is a liquid crystal display, and the recognition processing unit 15 outputs the numerical value of the scale indicated by the pointer to the liquid crystal display.
[0027] According to the above process, the image processing device 1 performs projective transformation on the captured image so that the object to be recognized shown in the captured image appears as if it were photographed from the front, similar to the object to be recognized shown in the normal image. The image processing device 1 can specify a feature range based on the feature amount of the object to be recognized shown in the captured image, which is suitable for calculating a projective transformation matrix for this projective transformation. This feature range specifies a plurality of feature amount calculation ranges that can form the vertices of a polygon. Therefore, it is possible to specify three or more feature ranges that can form the vertices of a polygon for calculating a projective transformation matrix used in projective transformation.
[0028] FIG. 7 is a diagram showing the minimum configuration of an image processing device. FIG. 8 is a diagram showing a processing flow of an image processing device with a minimum configuration. As shown in this figure, the image processing device 1 may be a device that exerts the functions of at least a feature amount calculation means 71 and a feature range identification means 72. The feature amount calculation means 71 calculates the feature amount of each of the feature amount calculation ranges of a plurality of small sections set within a processing target range in a captured image of an object to be recognized (step S701). The characteristic range specifying means 72 specifies, based on the characteristic amounts, a plurality of characteristic amount calculation ranges that can form vertices of a polygon within the characteristic amount calculation range as characteristic ranges (step S702).
[0029] The image processing device described above has a computer system therein. Each of the above-mentioned steps is stored in a computer-readable recording medium in the form of a program, and the computer reads and executes this program to perform the above-mentioned processing. Here, the computer-readable recording medium refers to a magnetic disk, a magneto-optical disk, a CD-ROM, a DVD-ROM, a semiconductor memory, etc. Also, the computer program may be distributed to a computer via a communication line, and the computer that receives the program may execute the program.
[0030] The program may be for realizing part of the functions described above. Furthermore, the above-mentioned functions may be realized in combination with a program already recorded in the computer system, that is, a so-called differential file (differential program). [Explanation of symbols]
[0031] 1. Image processing device 2. Recognition object 11. Control section 12 Processing target range specification section 13: Feature range specification unit (feature amount calculation means 71, feature range specification means 72) 14. Image conversion section 15 Recognition processing section
Claims
1. a feature amount calculation means for calculating a feature amount for each of a plurality of small partition feature amount calculation ranges set within a processing target range in a photographed image of an object to be recognized; a feature range specifying means for specifying, as feature ranges, a plurality of feature amount calculation ranges that can form vertices of a polygon among the feature amount calculation ranges in descending order of the feature amount; An image processing device comprising:
2. The feature range specification means specifies, as feature ranges, a plurality of feature amount calculation ranges that are close to the outside of the processing target range and that can form vertices of a polygon, out of the plurality of specified feature amount calculation ranges. The image processing device according to claim 1 .
3. The feature range specification means outputs the specified plurality of feature amount calculation ranges to a display device, inputs selection information indicating a feature amount calculation range selected by a user from the output feature amount calculation ranges, and specifies the plurality of feature amount calculation ranges that can constitute vertices of the polygon as feature ranges based on the selection information.
3. The image processing device according to claim 1 or 2.
4. The object to be recognized is a face of an analog meter, an image transformation means for performing a projective transformation to approximate the recognition target object to a normal image obtained by photographing the recognition target object from the front, using information on a plurality of characteristic ranges that can constitute the vertices of the polygon; The image processing device according to claim 1 , further comprising:
5. Calculating feature amounts for each of a plurality of feature amount calculation ranges for small sections set within a processing target range in a photographed image of the object to be recognized; A plurality of feature amount calculation ranges that can form vertices of a polygon are identified as feature ranges in descending order of the feature amount. Image processing methods.
6. The computer of the image processing device a feature amount calculation means for calculating a feature amount for each of a plurality of small partition feature amount calculation ranges set within a processing target range in a photographed image of an object to be recognized; a feature range specifying means for specifying, as feature ranges, a plurality of feature amount calculation ranges that can form vertices of a polygon among the feature amount calculation ranges in descending order of the feature amount; A program that functions as a
Citation Information
Patent Citations
Image transfer using drawing command hooking
JP2006058668A
Device and method for evaluating paint film
JP2006234613A
Analog meter reading method, reader and reading system
JP2009075848A
Display device and television receiver
JP2013138399A
Reading system, reading method, program and storage medium
JP2019169116A
