WO2019019250A1 - 倾斜图像的倾斜值获取方法、装置、终端及存储介质 - Google Patents

倾斜图像的倾斜值获取方法、装置、终端及存储介质 Download PDF

Info

Publication number
WO2019019250A1
WO2019019250A1 PCT/CN2017/099644 CN2017099644W WO2019019250A1 WO 2019019250 A1 WO2019019250 A1 WO 2019019250A1 CN 2017099644 W CN2017099644 W CN 2017099644W WO 2019019250 A1 WO2019019250 A1 WO 2019019250A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
tilt
value
character
regions
Prior art date
Application number
PCT/CN2017/099644
Other languages
English (en)
French (fr)
Inventor
王健宗
王晨羽
马进
肖京
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Priority to US16/090,198 priority Critical patent/US11074443B2/en
Priority to SG11201808503WA priority patent/SG11201808503WA/en
Publication of WO2019019250A1 publication Critical patent/WO2019019250A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • G06T7/73Determining position or orientation of objects or cameras using feature-based methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/12Edge-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/14Image acquisition
    • G06V30/146Aligning or centring of the image pick-up or image-field
    • G06V30/1475Inclination or skew detection or correction of characters or of image to be recognised
    • G06V30/1478Inclination or skew detection or correction of characters or of image to be recognised of characters or characters lines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/18Extraction of features or characteristics of the image
    • G06V30/1801Detecting partial patterns, e.g. edges or contours, or configurations, e.g. loops, corners, strokes or intersections
    • G06V30/18019Detecting partial patterns, e.g. edges or contours, or configurations, e.g. loops, corners, strokes or intersections by matching or filtering
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/40Document-oriented image-based pattern recognition
    • G06V30/41Analysis of document content
    • G06V30/414Extracting the geometrical structure, e.g. layout tree; Block segmentation, e.g. bounding boxes for graphics or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20048Transform domain processing
    • G06T2207/20061Hough transform
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30176Document
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition

Definitions

  • the present invention relates to the field of image processing, and in particular, to a method, an apparatus, a terminal, and a storage medium for acquiring a tilt value of a tilt image.
  • the boundary line of the image can be detected by the Hough line segment detection algorithm, but since the rectangular image includes the boundary line along the length direction and the width direction of the image, The borders of some rectangular images are not clear enough, so that multiple line segments will be extracted on the same boundary, and the background of some rectangular images is not pure enough to carry the impurity line segments, which will cause the detection of the Hough line segment detection algorithm. A lot of border lines.
  • the boundary values are different. Normally, the slope values will be different from each other. Even the slope values of multiple line segments extracted from the same boundary of the rectangular image will have some differences, so that the tilt value of the image cannot be uniquely determined.
  • the present invention provides a method, an apparatus, a terminal, and a storage medium for acquiring the tilt value of the tilt image.
  • an embodiment of the present invention provides a method for acquiring a tilt value of a tilt image, where the tilt image is a rectangle, and the method for obtaining the tilt value includes:
  • Parsing the oblique image acquiring coordinate information of a plurality of boundary lines of the oblique image
  • the first tilt value corresponding to the minimum difference is determined as the tilt value of the tilt image.
  • the embodiment of the present invention provides a tilt value acquiring device for a tilt image, wherein the tilt image is a rectangle, and the tilt value obtaining device includes:
  • a parsing module configured to parse the oblique image, and acquire coordinate information of a plurality of boundary lines of the oblique image
  • a first tilt value obtaining module configured to separately perform analysis and calculation on each coordinate information, to obtain a first tilt value of each of the boundary lines
  • a calibration value acquisition module for obtaining a calibration value
  • a difference calculation module configured to separately calculate a difference between each of the first tilt value and the calibration value to obtain a minimum difference
  • a determining module configured to determine a first tilt value corresponding to the minimum difference value as a tilt value of the tilt image.
  • an embodiment of the present invention provides a terminal, including a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the computer program
  • the tilt value acquisition method of the oblique image described in the above first aspect is a third aspect.
  • an embodiment of the present invention provides a computer readable storage medium, where the computer readable storage medium stores a computer program, and when the computer program is executed by a processor, implements the tilt image according to the first aspect. Tilt value acquisition method.
  • the invention provides a method, a device, a terminal and a storage medium for acquiring a tilt value of a tilt image, and obtains a calibration value, and compares the first tilt value of each extracted boundary line with a calibration value, The first tilt value corresponding to the minimum difference is then determined as the tilt value of the tilt image, so that the tilt value of the tilt image is uniquely determined.
  • FIG. 1 is a schematic flow chart of a first embodiment of a method for acquiring a tilt value of a tilt image according to the present invention
  • FIG. 2 is a schematic flow chart of a second embodiment of a method for acquiring a tilt value of a tilt image according to the present invention
  • FIG. 3 is a schematic flow chart of an embodiment of a calibration value acquisition method of the present invention.
  • FIG. 4 is a schematic flow chart of an embodiment of a calibration value acquisition method of the present invention.
  • Fig. 5 is a view showing the configuration of an embodiment of a tilt value acquiring device for a tilt image of the present invention.
  • FIG. 1 is a schematic flow chart of a first embodiment of a method for acquiring a tilt value of a tilt image according to the present invention.
  • the method includes:
  • Step 101 Analyze the oblique image, and acquire coordinate information of a plurality of boundary lines of the oblique image.
  • This step may specifically perform binarization processing on the oblique image to obtain a binarized image, that is, a black and white image; and detecting the binarized image based on the Hough line segment detection algorithm to obtain coordinate information of a plurality of boundary lines.
  • the coordinate information may be a slope and an intercept of the boundary line in the plane rectangular coordinate system (x, y), or may be a coordinate of a boundary line corresponding to the point corresponding to the parameter plane (k, b).
  • the binarization processing of the oblique image is to set the gray value of the pixel point in the oblique image to the first value or the second value, that is, to display the entire oblique image with a distinct black and white visual effect.
  • the binarization processing method for the oblique image has a bimodal method, an iterative method, a P-parameter method, etc., and several types of binarization processing methods are listed, and there are many other methods of binarization processing, and embodiments of the present disclosure This is no longer listed one by one. For detailed steps of the binarization processing method, reference may be made to related technologies, which is not specifically described in this embodiment.
  • the first value and the second value may be set in advance, and the first value is greater than the second value, for example, the first value may be 255, 254, 253, etc., and the second value may be 0, 1, 2 Etc., in order to more accurately obtain the contour of the straight line to be detected (ie, the boundary line) in the oblique image, thereby improving the accuracy of the line detection, the first value may be 255, and the second value may be 0, the implementation This example does not specifically limit this.
  • the coordinates of the point, the number of intersecting lines corresponding to the intersection point, and the number of intersecting lines exceeds the preset number.
  • the intersection point is determined as a point at which each boundary line corresponds to the parameter plane, and the coordinate information of the intersection point is determined as the coordinate information of the boundary point.
  • the coordinates (k, b) of the intersection point are the slope and intercept of the boundary line.
  • Step 102 Acquire a first tilt value of each boundary line according to each coordinate information.
  • the first tilt value can be an oblique angle or a slope. Specifically, when the first tilt value is a slope, the slope of each boundary line may be extracted from the coordinate information of each boundary line; when the first tilt value is the tilt angle, the coordinate information of each boundary line may be extracted. The slope k of each boundary line, and the slope is calculated to obtain an inclination angle of arctank.
  • a calibration value is obtained.
  • the calibration value is used to filter or filter the first tilt value of each extracted boundary line, from which the tilt value of the unique tilt image is obtained. There are many ways to obtain calibration values.
  • the obtained plurality of first tilt values may be clustered to obtain two clusters, each of which has a variance smaller than a preset variance value; and then respectively calculated in each cluster
  • Each first tilt value corresponds to a length sum of the line segments; a maximum value or a minimum value of the two length sums obtained above is determined, and a mean value of the cluster corresponding to the maximum value or the minimum value is used as a calibration value.
  • boundary lines are extracted: one is a boundary line substantially parallel to the longitudinal direction of the oblique image, and the other is a boundary line substantially parallel to the width direction; and all boundary lines substantially parallel to the longitudinal direction.
  • the sum of the lengths is greater than the sum of the widths of all the boundary lines substantially parallel to the width direction. Therefore, by using the mean value of the cluster corresponding to the maximum value or the minimum value as a calibration value, the linear direction corresponding to the calibration value can be determined.
  • the linear direction is substantially parallel to the longitudinal direction or the width direction of the oblique image.
  • the tilt direction corresponding to the tilt value obtained in step 105 is the length direction of the oblique image; if the average value of the cluster corresponding to the minimum value is used as the calibration value, then step 105
  • the tilt direction corresponding to the tilt value obtained in the middle is the width of the oblique image to.
  • the oblique image may be parsed, and a plurality of element regions are extracted, wherein
  • the element area is an area containing a single element in the oblique image; determining two adjacent element areas; acquiring all the second tilt values, and the second tilt value is a tilt value of a line connecting the adjacent two element areas; All the second tilt values are analyzed and calculated to obtain a calibration value.
  • the oblique image may be parsed to extract a plurality of character regions, wherein the character region is an affine invariant region containing the characters; Two adjacent character regions, wherein a distance between two adjacent character regions is less than a preset distance value, and a preset distance value is less than or equal to a minimum line spacing of characters; obtaining all second tilt values, second The tilt value is the slope value of the line connecting the adjacent two character regions; the average value is obtained for all the second tilt values to obtain a calibration value.
  • the straight line connecting any two adjacent character regions and the length direction of the oblique image is substantially parallel such that the oblique direction corresponding to the calibration value is the length direction of the oblique image.
  • the method of extracting a plurality of character regions and extracting the oblique image and extracting the plurality of element regions is the same as the method of extracting the oblique image, and is specifically shown in the embodiment shown in FIG. 3, and details are not described herein.
  • the tilt image is a captured image of the ID card
  • the ID image is parsed, and all single-character regions are extracted, and the single-character region is an affine invariant region containing a single character; all single-character regions are grouped , get multiple single-character area groups; among them, single-character area group
  • the distance between two adjacent single-character regions is smaller than the first preset threshold; the single-character region group with the largest length is obtained; and the inclination value of the connecting segment of the first and second single-character regions of the single-character region group with the largest length is obtained.
  • step 104 the difference between each first tilt value and the calibration value is calculated separately to obtain a minimum difference.
  • Step 105 Determine a first tilt value corresponding to the minimum difference value as a tilt value of the tilt image.
  • the calibration value is obtained, and the first tilt value of each extracted boundary line is compared with the calibration value, and finally the first tilt value corresponding to the minimum difference value is determined as the tilt value of the tilt image, thereby making the tilt
  • the tilt value of the image is uniquely determined.
  • FIG. 2 is a schematic flow chart of a second embodiment of a method for acquiring a tilt value of a tilt image according to the present invention.
  • the oblique image comes from the captured image of the tilted document.
  • the method includes:
  • Step 201 Acquire a captured image of the tilted document, wherein the captured image includes a background image and a tilted image.
  • the tilted document can be specifically an ID card, a social security card or a bank card.
  • Step 202 parsing the captured image, removing the background image, and obtaining a tilted image.
  • the feature information of the preset tilt image may be acquired, and the feature information may specifically be a shape feature or a color brightness feature; and an image region matching the feature information is searched in the captured image; The area (ie, the background image) is removed, resulting in a tilted image.
  • step 203 it is determined whether the size of the oblique image is larger than the size of the tilted document.
  • Step 204 If the size of the tilt image is larger than the size of the tilt document, set the size of the tilt image to the size of the tilt document. If the size of the oblique image is less than or equal to the size of the tilted document, the size of the oblique image is not set.
  • Step 205 parsing the oblique image, and acquiring coordinate information of a plurality of boundary lines of the oblique image.
  • the step may specifically perform binarization processing on the oblique image to obtain a binarized image; and detecting the binarized image based on the Hough line segment detection algorithm to obtain coordinate information of the plurality of boundary lines.
  • the information can be the coordinate information of the two endpoints of the boundary line.
  • Step 206 Perform analysis and calculation on each coordinate information to obtain a first tilt value of each boundary line.
  • the first tilt value can be an oblique angle or a slope.
  • Step 207 obtaining a calibration value.
  • the method of obtaining the calibration value is also described in detail above, and therefore will not be described again.
  • Step 208 respectively calculating a difference between each of the first tilt values and the calibration values.
  • Step 209 determining a first tilt value corresponding to the minimum difference value as a tilt value of the tilt image.
  • the size of the oblique image may deviate from the size of the tilted document, and in the process of extracting the boundary line, the larger the size of the oblique image, the less easily the boundary line is extracted. Therefore, in the embodiment of the present invention, when the size of the oblique image is larger than the size of the tilted document, the size of the oblique image is set to the size of the tilted document, thereby ensuring that the oblique image is not excessively large, thereby not affecting the boundary line. extract.
  • FIG. 3 is a schematic flowchart of an embodiment of a calibration value acquisition method according to the present invention.
  • This embodiment describes the second method of obtaining the calibration value in detail.
  • the oblique image includes a plurality of elements arranged in order, and the sorting direction of the plurality of elements is the same as the length direction or the width direction of the oblique image of the rectangle.
  • the calibration value acquisition method specifically includes:
  • Step 301 parsing the oblique image, and extracting a plurality of element regions, wherein the element region is an affine invariant region containing the element.
  • Step 301 includes:
  • the step includes: acquiring a preset number of gray thresholds, performing binarization processing on the oblique images by using each gray threshold, respectively, obtaining a binarized image corresponding to each gray threshold; acquiring the preset grayscale A region with a stable shape is maintained in each binarized image corresponding to the threshold range, and Maximum stable extreme value area.
  • the step includes: determining a contour of the maximum stable extremum region; and obtaining a minimum circumscribed rectangle of the contour according to the determined contour, thereby obtaining a rectangular boundary of the maximum stable extremum region.
  • the minimum circumscribed rectangle refers to the maximum range of the two-dimensional shape represented by two-dimensional coordinates, that is, the maximum abscissa, the minimum abscissa, the maximum ordinate, and the minimum ordinate of each vertice of a given two-dimensional shape are defined The rectangle.
  • 301c is specifically: detecting whether there is a first rectangular boundary.
  • the first rectangular boundary is a rectangular boundary located inside the other rectangular boundary, a rectangular boundary having an area larger than a second preset threshold, or a rectangular boundary having an aspect ratio greater than a third preset threshold; if the first rectangular boundary is detected, the The maximum stable extreme value region corresponding to the first rectangular boundary is filtered out in all the maximum stable extreme value regions.
  • the second preset threshold may be one quarter of the area of the tilt image, and if the element is a character, the third preset threshold may be 1.5.
  • Step 302 determining two adjacent element regions. Specifically, the distance between the two element regions may be acquired; determining whether the distance is less than a third preset threshold; if the distance is less than the third preset threshold, determining two element regions as two adjacent element regions .
  • two The distance between the element regions may be the distance between the center points of the two element regions.
  • the distance between the two element regions is the lateral distance and/or the longitudinal distance of the two element regions in the preset coordinate system.
  • the third preset threshold is less than twice the element row spacing or twice the column spacing; or the third preset threshold is less than twice the element row spacing, and Less than twice the spacing of the element columns.
  • the determined adjacent two element regions include two element regions adjacent in the element sorting direction, and/or two element regions adjacent in the vertical direction.
  • the vertical direction is a direction perpendicular to the order in which the elements are sorted.
  • the number of linear directions connecting the adjacent two element regions depends on the line spacing of the elements, the column spacing, and the third predetermined threshold.
  • Step 303 Acquire all the second tilt values, and the second tilt value is a tilt value of a line connecting the adjacent two element regions.
  • the distance between two adjacent element regions is less than a preset distance value.
  • the preset distance value may be customized according to actual requirements. In this embodiment, the preset distance value should be less than twice the row spacing or column spacing of the element.
  • step 304 all the second tilt values are analyzed and calculated to obtain a calibration value.
  • the step includes: 304a, clustering all the second tilt values to obtain a plurality of tilt value clusters; 304b, obtaining the tilt value cluster with the largest weight (ie, the tilt value cluster having the largest number of tilt values); 304c Calculate the mean of the cluster of slope values with the largest weight and obtain the calibration value. Since the adjacent two element regions determined in step 302 include element regions adjacent in the longitudinal direction of the oblique image and element regions adjacent in the width direction of the oblique image, clustering and clustering of the tilt values having the largest weight are performed The mean value is used as a calibration value to uniquely determine the calibration value.
  • the step 304a is specifically: acquiring a preset number; clustering all the third tilt values to obtain a preset number of tilt value clusters; calculating a variance of each tilt value cluster to obtain a minimum variance value; determining the minimum Whether the variance value is smaller than the first preset threshold; if the minimum variance value is greater than or equal to the first pre-predetermined value If the threshold is set, the preset number is updated, and the step of performing clustering on all the third tilt values to obtain a preset number of tilt value clusters is performed until the minimum variance value is less than the first preset threshold.
  • the preset number is usually 2, and the more preset number is: adding 1 to the current preset number value, obtaining a new value, and assigning the new value to the preset number. If the tilt image is an image of an ID card, the first preset value is 200.
  • the step of clustering all the tilt values to obtain a preset number of tilt value clusters includes: arbitrarily selecting a preset number of tilt values from all the tilt values as the initial cluster center; and for remaining others
  • the tilt values are assigned to the cluster clusters represented by the initial cluster centers, based on their similarity with the initial cluster centers (ie, the distance from the initial cluster center). The number of clusters.
  • FIG. 4 it is a schematic flowchart of an embodiment of a calibration value acquisition method according to the present invention. This embodiment describes in detail the fourth mode of obtaining the calibration value.
  • Step 401 Parse the ID card image and extract a plurality of single character regions.
  • the ID card image includes a plurality of characters in a sequence of characters, and the characters can be characters or numbers.
  • the single character area is an affine invariant area containing a single character. Specifically, all the affine invariant regions in the ID image can be extracted based on the region feature extraction algorithm, and the single character region (ie, the affine invariant region that does not have all the features of the single character) is removed therefrom, thereby obtaining Single character area.
  • Step 402 Acquire a first single character area.
  • the first single-character region may be randomly selected from all the extracted single-character regions for the first-characterized single-character region group; for the first-character region group that is not first acquired, the first single-character region needs to be Random selection in the remaining single-character areas.
  • the remaining single-character area refers to a plurality of single-character areas obtained by culling the acquired single-character area group from all single-character areas.
  • Step 403 Acquire all the seconds that are smaller than the first preset threshold by the first single-character area.
  • Single character area The distance between any two adjacent single-character regions in the single-character region group is smaller than the first preset threshold. Further, in order to divide all single-character regions located on the same line of the ID image into the same group as possible, any one of the single-character regions and any other single-character region group in any one-character region group The distance between the single character regions is greater than or equal to the first predetermined threshold.
  • the first preset threshold has been described above in detail, and therefore will not be described herein.
  • the single-character region in the middle usually has at least two single-character regions with a distance less than the first predetermined threshold, so in order to obtain all the single-character regions in the same row Need to get all the second single character areas.
  • Step 404 until all the nth character single character regions whose distance from the n-1th single character region is smaller than the first preset threshold are obtained.
  • This step can be understood as to sequentially obtain all the single-character regions whose reference distance is less than the first preset threshold from the newly acquired single-character region to the n-th single-character region.
  • n is greater than or equal to 2.
  • the first single character area, the second single character area, and the nth single character area are different.
  • n can be a preset value, for example, n can be 10.
  • n may also be an indefinite value.
  • step 404 includes: obtaining a distance from the n-1th single-character area is smaller than All n-th character single-character regions of the first preset threshold until the n+1th single-character region acquisition fails.
  • the n+1th single character area is different from the first single character area, the second single character area, and the nth single character area.
  • the step 404 includes: acquiring all the third single-character regions whose distance from the second single-character region is less than the first preset threshold; acquiring all the first distances from the third single-character region that are smaller than the first preset threshold. Four single-character regions... until all n-th single-character regions whose distance from the n-1th single-character region is less than the first predetermined threshold are obtained. During the implementation of the step, since the distance between the third single-character region and the first character region and the second-character region is less than the first preset threshold, The obtained third single-character area and the previously acquired first single-character area are repeated. Therefore, the process in step 304 is performed to ensure that the currently obtained single-character area is different from all previously acquired single-character areas. ,specifically,
  • the newly acquired m-th single-character region and all previously acquired single-character regions may be determined. (including all the first single-character area, the second single-character area, and the m-th single-character area) whether there is a coincidence. If there is a coincidence, the process ends. If there is no coincidence, the next step is performed: the latest acquired order
  • the character area is a reference (ie, the mth single-character area), and all the m+1th single-character areas that are smaller than the first preset threshold from the reference distance (m single-character area) are acquired. Where m is less than or equal to n-1.
  • Step 405 Determine the first single character area, the second single character area, and the nth single character area as a single character area group.
  • Step 406 Acquire a single-character region group with the largest length.
  • the step specifically includes: calculating the length of each single-character region group separately, and filtering out the single-character region group having the largest length.
  • the length calculation of the single-character region group includes: obtaining the length of the connection line segment of the first and second single-character regions of the single-character region group; determining the length of the connection segment as the length of the single-character region group.
  • the step of obtaining the length of the connecting line segment of the first two character regions of the single-character region group includes: obtaining a distance between any two single-character regions in the current single-character region group, and filtering out the maximum distance; The maximum distance is determined as the length of the connecting line segment of the first two character regions of the current single-character region group.
  • the step of filtering out the single-character region group with the largest length includes: selecting the maximum length from the lengths of all the connected segment segments, and determining the single-character region group corresponding to the maximum length as the single-character region having the largest length. group.
  • Step 407 Obtain a connection line between the first and last two single-character regions of the single-character region group with the largest length
  • the slope value of the segment and the slope value of the connected segment is determined as the calibration value.
  • the connecting line segment is a line segment that uses the reference point of each of the two single-character regions in the first and last ends as an end point.
  • the reference point is specifically a geometric center point of a single character area.
  • FIG. 5 it is a schematic structural view of an embodiment of a tilt value acquiring apparatus for a tilt image according to the present invention.
  • the tilt value obtaining means includes a parsing module 501, a first tilt value acquiring module 502, a calibration value acquiring module 503, a difference calculating module 504, and a determining module 505.
  • the parsing module 501 is configured to parse the oblique image, and acquire coordinate information of a plurality of boundary lines of the oblique image.
  • the step may specifically perform binarization processing on the oblique image to obtain a binarized image; and detecting the binarized image based on the Hough line segment detection algorithm to obtain coordinate information of the plurality of boundary lines.
  • the first tilt value obtaining module 502 is configured to separately perform analysis and calculation on each coordinate information to obtain a first tilt value of each boundary line.
  • the first tilt value can be an oblique angle or a slope.
  • the calibration value acquisition module 503 is configured to acquire a calibration value.
  • the way the calibration value is obtained has been made above. A detailed introduction, so I will not repeat them here.
  • the calibration value acquiring module 503 includes an element extracting unit, an adjacent element determining unit, and the Two tilt value acquisition unit and calibration value calculation unit.
  • the element extracting unit is configured to parse the oblique image and extract a plurality of element regions, wherein the element region is an affine invariant region including the element.
  • the adjacent element determining unit is for determining two adjacent element regions.
  • the second tilt value acquisition unit is configured to acquire all the second tilt values, and the second tilt value is a tilt value of a line connecting the adjacent two element regions.
  • the calibration value calculation unit is configured to perform analysis calculation on all the second tilt values to obtain a calibration value.
  • the difference calculation module 504 is configured to separately calculate a difference between each of the first tilt values and the calibration values.
  • the determining module 505 is configured to determine the first tilt value corresponding to the minimum difference value as the tilt value of the tilt image.
  • the calibration value is obtained, and the first tilt value of each extracted boundary line is compared with the calibration value, and finally the first tilt value corresponding to the minimum difference value is determined as the tilt value of the tilt image, thereby making the tilt
  • the tilt value of the image is uniquely determined.
  • the tilt value acquisition device of the oblique image further includes a captured image acquisition module, a background removal module, a determination module, and a setting module.
  • the captured image acquisition module is configured to acquire a captured image of the tilted document, wherein the captured image includes a background image and a tilted image.
  • the tilted document can be specifically an ID card, a social security card or a bank card.
  • a background removal module is configured to parse the captured image, remove the background image, and obtain a tilted image.
  • the judging module is configured to judge whether the size of the tilt image is larger than the size of the tilt document.
  • the setting module is configured to set the size of the oblique image to the size of the tilted document if the size of the tilted image is larger than the size of the tilted document.
  • the parsing module 501 is configured to parse the oblique image set by the setting module, and acquire coordinate information of a plurality of boundary lines of the oblique image.
  • the size of the oblique image may deviate from the size of the tilted document, and in the process of extracting the boundary line, the larger the size of the oblique image, the less easily the boundary line is extracted. Therefore, in the embodiment of the present invention, when the size of the oblique image is larger than the size of the tilted document, the size of the oblique image is set to the size of the tilted document, thereby ensuring that the oblique image is not excessively large, thereby not affecting the boundary line. extract.
  • An embodiment of the present invention further provides a terminal, including a memory, a processor, and a computer program stored in the memory and operable on the processor, where the processor implements the tilt image described above when executing the computer program The method of obtaining the tilt value.
  • the embodiment of the present invention further provides a computer readable storage medium storing a computer program, and when the computer program is executed by a processor, implementing the tilt value acquisition method of the oblique image.
  • the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Geometry (AREA)
  • Computer Graphics (AREA)
  • Artificial Intelligence (AREA)
  • Image Analysis (AREA)
  • Apparatus For Radiation Diagnosis (AREA)
  • Character Input (AREA)

Abstract

一种倾斜图像的倾斜值获取方法、装置、终端及存储介质,该倾斜图像的倾斜值获取方法包括解析倾斜图像,获取倾斜图像的多个边界线的坐标信息;分别对各个坐标信息进行分析计算,得到各个边界线的第一倾斜值;获取校准值;分别计算各个第一倾斜值与校准值的差值;将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值,本发明技术方案可以使倾斜图像的倾斜值唯一确定。

Description

倾斜图像的倾斜值获取方法、装置、终端及存储介质 技术领域
本发明涉及图像处理领域,尤其涉及一种倾斜图像的倾斜值获取方法、装置、终端及存储介质。
背景技术
目前,当矩形图像发生倾斜时,如要获取其倾斜值,可以通过霍夫线段检测算法检测提取该图像的边界线,但是由于矩形图像包括沿图像的长度方向和宽度方向的边界线,再加上一些矩形图像的边界不够分明,使得同一边界上会提取出多个线段,以及还有一些矩形图像的背景不够纯净,携带有杂质线段,这样,就会导致采用霍夫线段检测算法会检测出很多条边界线。边界线不同,通常情况下斜率值也会互不相同,即使是从矩形图像的同一边界上提取的多个线段的斜率值也会有一些差异,从而使得图像的倾斜值不能唯一确定。
发明内容
为克服现有技术中图像的倾斜值不能唯一确定的问题,本发明提供一种倾斜图像的倾斜值获取方法、装置、终端及存储介质。
第一方面,本发明实施例提供了一种倾斜图像的倾斜值获取方法,所述倾斜图像为矩形,所述倾斜值获取方法包括:
解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息;
根据各个坐标信息,获取各个所述边界线的第一倾斜值;
获取校准值;
分别计算各个所述第一倾斜值与所述校准值的差值;
将最小差值对应的第一倾斜值确定为所述倾斜图像的倾斜值。
第二方面,本发明实施例提供一种倾斜图像的倾斜值获取装置,所述倾斜图像为矩形,所述倾斜值获取装置包括:
解析模块,用于解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息;
第一倾斜值获取模块,用于分别对各个坐标信息进行分析计算,得到各个所述边界线的第一倾斜值;
校准值获取模块,用于获取校准值;
差值计算模块,用于分别计算各个所述第一倾斜值与所述校准值的差值,以获得最小差值;
确定模块,用于将所述最小差值对应的第一倾斜值确定为所述倾斜图像的倾斜值。
第三方面,本发明实施例提供了一种终端,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现上述第一方面所述的倾斜图像的倾斜值获取方法。
第四方面,本发明实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现上述第一方面所述的倾斜图像的倾斜值获取方法。
本发明提供一种倾斜图像的倾斜值获取方法、装置、终端及存储介质,通过获取校准值,并将提取的各边界线的第一倾斜值与校准值一一比较,最 后将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值,从而使得倾斜图像的倾斜值唯一确定。
附图说明
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本发明的倾斜图像的倾斜值获取方法的第一实施例的流程示意图;
图2是本发明的倾斜图像的倾斜值获取方法的第二实施例的流程示意图;
图3是本发明的校准值获取方式的实施例的流程示意图;
图4是本发明的校准值获取方式的实施例的流程示意图;
图5是本发明的倾斜图像的倾斜值获取装置的实施例的结构示意图。
具体实施方式
为了使本发明所解决的技术问题、技术方案及有益效果更加清楚明白,以下结合附图及实施例,对本发明进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本发明,并不用于限定本发明。
请参照图1,是本发明的倾斜图像的倾斜值获取方法的第一实施例的流程示意图。该方法包括:
步骤101,解析倾斜图像,获取倾斜图像的多个边界线的坐标信息。本步骤具体可以为对倾斜图像进行二值化处理,得到二值化图像,即黑白图像;基于霍夫线段检测算法对二值化图像进行检测,得到多个边界线的坐标信息。 其中,坐标信息可以为边界线在平面直角坐标系(x,y)中的斜率和截距,也可以为边界线在其参数平面(k,b)所对应的点的坐标。
倾斜图像的二值化处理是将倾斜图像中像素点的灰度值设置为第一数值或第二数值,也就是将整个倾斜图像呈现出明显的只有黑和白的视觉效果。而对倾斜图像的二值化处理方式有双峰法、迭代法、P参数法等,除去列出来的几种二值化处理方式,还有很多其他二值化处理的方式,本公开实施例对此不再一一列举。而关于二值化处理方式的详细步骤可以参考相关技术,本实施例对此不作具体阐述。需要说明的是,第一数值和第二数值可以事先设置,且第一数值大于第二数值,比如,第一数值可以为255、254、253等等,第二数值可以为0、1、2等等,而为了能够更精确地获取到倾斜图像中待检测直线(即边界线)的轮廓,进而提高直线检测的准确度,第一数值可以为255,以及第二数值可以为0,本实施例对此不作具体限定。
在基于霍夫线段检测算法对二值化图像进行检测之前,需要获取二值化图像中各个像素点的灰度值,基于获取的各个像素点的灰度值,从该二值化图像区域中选择灰度值为第一数值的像素点,进而确定选择的像素点的像素点坐标。
在平面直角坐标系(x,y)中,一条直线可以用方程y=kx+b来表示。对于直线上一个确定的点(x0,y0),有y0=k x0+b,这表示参数平面(k,b)中的一条直线。因此,二值化图像中的一个像素点对应其参数平面中的一条直线,二值化图像中的一条直线对应参数平面中的一个点。因此,本步骤可以对二值化图像上所有的灰度值为第一数值的像素点作霍夫变换,得到各个像素点在参数平面所对应的直线;并且确定参数平面中多条直线的相交点的坐标,统计相交点对应的相交直线的数目,将相交直线的数目超过预设数目的 相交点确定为各个边界线在参数平面对应的点,以及将相交点的坐标信息确定为边界点的坐标信息。具体地,相交点的坐标(k,b)即为边界线的斜率和截距。
步骤102,根据各个坐标信息,获取各个边界线的第一倾斜值。第一倾斜值可以为倾斜角度或斜率。具体地,当第一倾斜值为斜率时,可以从各个边界线的坐标信息中提取出各个边界线的斜率;当第一倾斜值为倾斜角度时,可以从各个边界线的坐标信息中提取出各个边界线的斜率k,并对斜率进行计算得到倾斜角度为arctank。
步骤103,获取校准值。校准值用于对提取的各个边界线的第一倾斜值进行过滤或筛选,从中得到唯一的倾斜图像的倾斜值。校准值的获取方式包括多种。
第一种方式,当倾斜图像为长方形时,可以对获取的多个第一倾斜值进行聚类,得到两个簇,每个簇的方差都小于预设方差值;然后分别计算各个簇中各第一倾斜值对应线段的长度和;确定上述获取的两个长度和中的最大值或最小值,并将最大值或最小值对应的簇的均值作为校准值。通常情况下会提取出两类边界线:一类是与倾斜图像的长度方向大致平行的边界线,另一类是与宽度方向大致平行的边界线;并且与长度方向大致平行的所有边界线的长度之和是大于与宽度方向上大致平行的所有边界线的宽度之和,因此,通过将最大值或最小值对应的簇的均值作为校准值,便可以确定校准值所对应的直线方向,该直线方向大致平行于倾斜图像的长度方向或宽度方向。若将最大值对应的簇的均值作为校准值,那么步骤105中获取的倾斜值所对应的倾斜方向即为倾斜图像的长度方向;若将最小值对应的簇的均值作为校准值,那么步骤105中获取的倾斜值所对应的倾斜方向即为倾斜图像的宽度方 向。
第二种方式,若倾斜图像包括按序排列的多个元素,且多个元素的排序方向与矩形的倾斜图像的长度方向或宽度方向相同,则可以解析倾斜图像,提取多个元素区域,其中,元素区域为倾斜图像中包含单个元素的区域;确定相邻的两个元素区域;获取所有的第二倾斜值,第二倾斜值为连接相邻的两个元素区域的直线的倾斜值;对所有的第二倾斜值进行分析计算,得到校准值。
采用第二种方式获取校准值的方法会在下文中作详细介绍,故在此不作赘述。
第三种方式,若倾斜图像为身份证的拍摄图像,倾斜图像包含多个字符,则可以解析倾斜图像,提取多个字符区域,其中,字符区域为包含字符的仿射不变区域;确定所有相邻的两个字符区域,其中,相邻的两个字符区域之间的距离小于预设距离值,预设距离值小于或等于字符的最小行间距;获取所有的第二倾斜值,第二倾斜值为连接相邻的两个字符区域的直线的倾斜值;对所有的第二倾斜值求均值,得到校准值。由于身份证上住址信息和号码信息分别对应的字符串之间的列间距均小于身份证上字符的最小行间距,因此,连接任意相邻的两个字符区域的直线均与倾斜图像的长度方向大致平行,从而使得校准值对应的倾斜方向即为倾斜图像的长度方向。其中,解析倾斜图像,提取多个字符区域与解析倾斜图像,提取多个元素区域的方法相同,具体见图3所示的实施例,在此不作赘述。
第四种方式,若倾斜图像为身份证的拍摄图像,则解析身份证图像,提取所有的单字符区域,单字符区域为包含单个字符的仿射不变区域;对所有的单字符区域进行分组,得到多个单字符区域组;其中,单字符区域组中任 意相邻的两个单字符区域之间的距离小于第一预设阈值;获取长度最大的单字符区域组;获取长度最大的单字符区域组的首尾两个单字符区域的连接线段的倾斜值,并将连接线段的倾斜值确定校准值。
步骤104,分别计算各个第一倾斜值与校准值的差值,以得到最小差值。
步骤105,将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值。
本发明实施例通过获取校准值,并将提取的各边界线的第一倾斜值与校准值一一比较,最后将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值,从而使得倾斜图像的倾斜值唯一确定。
请参照图2,是本发明的倾斜图像的倾斜值获取方法的第二实施例的流程示意图。本实施例中,倾斜图像来自于倾斜证件的拍摄图像。该方法包括:
步骤201,获取倾斜证件的拍摄图像,其中,拍摄图像包括背景图像和倾斜图像。倾斜证件具体可以为身份证、社保卡或银行卡等。
步骤202,解析拍摄图像,去除所述背景图像,得到倾斜图像。具体地,可以获取预设倾斜图像的特征信息,该特征信息具体可以为形状特征或颜色亮度特征;在拍摄图像中查找与该特征信息相匹配的图像区域;将拍摄图像中该图像区域之外的区域(即背景图像)去除,从而得到倾斜图像。
步骤203,判断倾斜图像的尺寸是否大于倾斜证件的尺寸。
步骤204,若倾斜图像的尺寸大于倾斜证件的尺寸,则将倾斜图像的尺寸设置为倾斜证件的尺寸。若倾斜图像的尺寸小于或等于倾斜证件的尺寸,则不对倾斜图像的尺寸进行设置。
步骤205,解析倾斜图像,获取倾斜图像的多个边界线的坐标信息。本步骤具体可以为对倾斜图像进行二值化处理,得到二值化图像;基于霍夫线段检测算法对二值化图像进行检测,得到多个边界线的坐标信息。其中,坐标 信息可以为边界线两个端点的坐标信息。
步骤206,分别对各个坐标信息进行分析计算,得到各个边界线的第一倾斜值。第一倾斜值可以为倾斜角度或斜率。
步骤207,获取校准值。校准值的获取方法也在上文中做了详细介绍,故在不作赘述。
步骤208,分别计算各个第一倾斜值与校准值的差值。
步骤209,将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值。
由于倾斜图像是基于倾斜证件的拍摄图像得到的,因此,倾斜图像的尺寸会与倾斜证件的尺寸有偏差,而在边界线提取的过程中,倾斜图像的尺寸越大,边界线越不容易提取,因此,本发明实施例通过在倾斜图像的尺寸大于倾斜证件的尺寸时,将倾斜图像的尺寸设置为倾斜证件的尺寸,从而保证了倾斜图像不会过大,进而不会影响到边界线的提取。
请参照图3,是本发明的校准值获取方式的实施例的流程示意图。本实施例对校准值获取的第二种方式进行详细的介绍。其中,倾斜图像包括按序排列的多个元素,且多个元素的排序方向与矩形的倾斜图像的长度方向或宽度方向相同。校准值获取方式具体包括:
步骤301,解析倾斜图像,提取多个元素区域,其中,元素区域为包含元素的仿射不变区域。步骤301包括:
301a,解析倾斜图像,提取所有的最大稳定极值区域。最大稳定极值区域是当使用不同的灰度阈值对倾斜图像进行二值化处理时得到的最稳定的区域。具体地,本步骤包括:获取预设数目的灰度阈值,分别采用每个灰度阈值对倾斜图像进行二值化处理,得到各个灰度阈值对应的二值化图像;获取在预设灰度阈值范围对应的各个二值化图像中均保持形状稳定的区域,得到 最大稳定极值区域。
301b,确定各个最大稳定极值区域的矩形边界。具体地,本步骤包括:确定最大稳定极值区域的轮廓;根据确定的轮廓,得到该轮廓的最小外接矩形,从而得到该最大稳定极值区域的矩形边界。其中,最小外接矩形是指以二维坐标表示的二维形状的最大范围,即以给定的二维形状各顶点中的最大横坐标、最小横坐标、最大纵坐标、最小纵坐标定下边界的矩形。
301c,从所有的最大稳定极值区域中滤除非元素区域,得到多个元素区域,其中,非元素区域具体为第一矩形边界对应的最大稳定极值区域,元素区域为包含单个元素的区域。由于提取出来的所有最大稳定极值区域中会包括多个非元素区域,因此,需要将其滤除,以免对后续步骤的实施造成干扰,最终使得获取到校准值误差过大。由于各个最大稳定极值区域是不规则的区域,不便于计算其中心点,也不便于对非元素区域的去除,因此需要为各最大稳定极值区域确定一个外接的矩形边界,以便于对元素区域的中心点的计算。
其中,301c具体为:检测是否存在第一矩形边界。第一矩形边界为位于其它矩形边界的内部的矩形边界、面积大于第二预设阈值的矩形边界、或长宽比大于第三预设阈值的矩形边界;若检测存在第一矩形边界,则从所有的最大稳定极值区域中将第一矩形边界对应的最大稳定极值区域滤除。若倾斜图像为身份证图像,第二预设阈值可以为倾斜图像的面积的四分之一,若元素为字符,那么第三预设阈值可以为1.5。
步骤302,确定相邻的两个元素区域。具体地,可以获取两个元素区域之间的距离;判断该距离是否小于第三预设阈值;若该距离小于第三预设阈值,则将两个元素区域确定为相邻的两个元素区域。作为第一种实施方式,两个 元素区域之间的距离可以是两个元素区域中心点之间的距离。作为第二种实施方式,两个元素区域之间的距离是两个元素区域在预设坐标系中的横向距离和/或纵向距离。当图像中的多个元素排成多行和多列时,第三预设阈值小于元素行间距的两倍或列间距的两倍;或者第三预设阈值小于元素行间距的两倍,且小于元素列间距的两倍。确定的相邻的两个元素区域包括在元素排序方向上相邻的两个元素区域、和/或在垂直方向上相邻的两个元素区域。其中,垂直方向是与元素排序方向相垂直的方向。连接相邻的两个元素区域的直线方向(以下简称相邻方向)的数目取决于元素的行间距、列间距以及第三预设阈值。
步骤303,获取所有的第二倾斜值,第二倾斜值为连接相邻的两个元素区域的直线的倾斜值。相邻的两个元素区域之间的距离小于预设距离值。其中,预设距离值的大小可以根据实际需求自定义,本实施例中,预设距离值应小于元素的行间距或列间距的两倍。
步骤304,对所有的第二倾斜值进行分析计算,得到校准值。该步骤包括:304a,对所有的所述第二倾斜值进行聚类,得到多个倾斜值簇;304b,获取权重最大的倾斜值簇(即具有倾斜值的数目最多的倾斜值簇);304c,计算权重最大的倾斜值簇的均值,得到校准值。由于步骤302确定的相邻的两个元素区域包括沿倾斜图像长度方向相邻的元素区域和沿倾斜图像宽度方向相邻的元素区域,因此,通过聚类,并将权重最大的倾斜值簇的均值作为校准值,可以对校准值进行唯一确定。
其中,304a步骤具体为:获取预设数目;对所有的第三倾斜值进行聚类,得到预设数目的倾斜值簇;计算各个倾斜值簇的方差,得到最小方差值;判断所述最小方差值是否小于第一预设阈值;若最小方差值大于或等于第一预 设阈值,则更新预设数目,返回执行对所有的第三倾斜值进行聚类,得到预设数目的倾斜值簇的步骤,直至最小方差值小于第一预设阈值。预设数目通常为2,其中更预设数目的方式为:对当前的预设数目的值加1,得到新值,并将新值赋值给预设数目。若倾斜图像为身份证的图像,那么第一预设值为200。
具体地,对所有的倾斜值进行聚类,得到预设数目的倾斜值簇的步骤包括:从所有的倾斜值任意选择预设数目的倾斜值分别作为初始聚类中心;而对于所剩下其它倾斜值,则根据它们与这些初始聚类中心的相似度(即与初始聚类中心的距离),分别将它们分配给与其最相似的由初始聚类中心所代表的聚类簇,得到预设数目的聚类簇。
请参照图4,是本发明的校准值获取方式的实施例的流程示意图。本实施例对校准值获取的第四种方式进行详细的介绍。
步骤401,解析身份证图像,提取多个单字符区域。身份证图像包括多个按序排列的字符多行字符,字符可以为文字或数字。其中,单字符区域为包含单个字符的仿射不变区域。具体地,可以基于区域特征提取算法,对身份证图像中所有的仿射不变区域进行提取,并从中剔除非单字符区域(即不具有单个字符全部特征的仿射不变区域),从而得到单字符区域。
步骤402,获取第一单字符区域。其中,对于首次获取的单字符区域组而言,第一单字符区域可从提取的所有的单字符区域中随机选择;对于非首次获取的单字符区域组而言,第一单字符区域需要从剩余的单字符区域中随机选择。其中,剩余的单字符区域是指从所有的单字符区域中,剔除掉已经获取的单字符区域组后得到的多个单字符区域。
步骤403,获取与第一单字符区域的距离小于第一预设阈值的所有的第二 单字符区域。其中,单字符区域组中任意相邻的两个单字符区域之间的距离小于第一预设阈值。进一步地,为了尽可能将身份证图像上位于同一行的所有单字符区域均分为同一组中,任一单字符区域组中的任一单字符区域与另一单字符区域组中的任一单字符区域之间的距离大于或等于第一预设阈值。第一预设阈值已经在上文中,作了详细介绍,故在此不作赘述。
针对于同一行的单字符区域而言,位于中间的单字符区域通常会具有至少两个与之距离小于第一预设阈值的单字符区域,因此,为了得到所有的位于同一行的单字符区域,需要获取所有的第二单字符区域。
步骤404,直至获取与第n-1单字符区域的距离小于第一预设阈值的所有的第n字单字符区域。本步骤可以理解为依次以新获取到的单字符区域为基准,获取与该基准距离小于第一预设阈值的所有的单字符区域,直至第n单字符区域。其中,n大于等于2。为了保证不重复获取单字符区域,第一单字符区域、第二单字符区域直至第n单字符区域各不相同。其中,n可以为预设定值,例如n可以为10。此外,n也可以为一个不定值,为了尽可能将身份证图像上位于同一行的所有单字符区域均分为同一组中,步骤404包括:获取与第n-1单字符区域的距离小于第一预设阈值的所有的第n字单字符区域,直至第n+1单字符区域获取失败。其中,第n+1单字符区域与第一单字符区域、第二单字符区域直至第n单字符区域各不相同。
具体地,步骤404包括:获取与第二单字符区域的距离小于第一预设阈值的所有的第三单字符区域;获取与第三单字符区域的距离小于第一预设阈值的所有的第四单字符区域……直至获取与第n-1单字符区域的距离小于第一预设阈值的所有的第n单字符区域。在实施本步骤的过程中,由于第三单字符区域和第一字符区域与均第二字符区域的距离小于第一预设阈值,这样, 就会导致获取的第三单字符区域和之前获取的第一单字符区域重复,因此,在实施步骤304中的过程,为了保证当前获取的单字符区域与之前获取的所有的单字符区域均不同,具体地,
具体地,在获取与第m-1单字符区域小于第一预设阈值的所有的第m单字符区域的步骤之后,可以判断新获取的第m单字符区域与之前获取的所有的单字符区域(包括所有的第一单字符区域、第二单字符区域直至第m单字符区域)是否有重合,若有重合,则结束进程,若没有重合,则执行下一步骤:以最新获取到的单字符区域为基准(即第m单字符区域),获取与该基准距离(m单字符区域)小于第一预设阈值的所有的第m+1单字符区域。其中,m小于或等于n-1。
步骤405,将第一单字符区域、第二单字符区域直至第n单字符区域确定为单字符区域组。
步骤406,获取长度最大的单字符区域组。该步骤具体包括:分别计算各单字符区域组的长度,并筛选出长度最大的单字符区域组。
单字符区域组的长度计算包括:获取单字符区域组的首尾两个单字符区域的连接线段的长度;将连接线段的长度确定为该单字符区域组的长度。其中,获取单字符区域组的首尾两个单字符区域的连接线段的长度的步骤,包括:获取当前单字符区域组中任两个单字符区域之间的距离,并筛选出最大距离;将该最大距离确定为当前单字符区域组的首尾两个单字符区域的连接线段的长度。进一步地,筛选出长度最大的单字符区域组的步骤,包括:从获取的所有连接线段的长度中,筛选出最大长度,并将最大长度对应的单字符区域组确定为长度最大的单字符区域组。
步骤407,获取长度最大的单字符区域组的首尾两个单字符区域的连接线 段的倾斜值,并将连接线段的倾斜值确定为校准值。其中,连接线段是将首尾两个单字符区域各自的参照点作为端点的线段。其中,参照点具体为单字符区域的几何中心点。通过获取连接线段的两端点的坐标,即可以得到连接线段的倾斜值。倾斜值可以为倾斜角度,也可以为斜率。由于各个字符的形状不一,这就会导致提取的各单字符区域的几何中心点不能同时位于同一直线上,因此,通过获取长度最大的单字符区域组的首尾两个单字符区域的连接线段的倾斜值,可以尽量减少误差,使其接近于真实的身份证图像的倾斜值。
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本发明实施例的实施过程构成任何限定。
上文针对本发明的倾斜图像的倾斜值获取方法做了详细介绍,下面将相对于上述方法的装置做进一步阐述。
请参照图5,是本发明的倾斜图像的倾斜值获取装置的实施例的结构示意图。
倾斜值获取装置包括:解析模块501、第一倾斜值获取模块502、校准值获取模块503、差值计算模块504和确定模块505。
解析模块501,用于解析倾斜图像,获取倾斜图像的多个边界线的坐标信息。本步骤具体可以为对倾斜图像进行二值化处理,得到二值化图像;基于霍夫线段检测算法对二值化图像进行检测,得到多个边界线的坐标信息。
第一倾斜值获取模块502,用于分别对各个坐标信息进行分析计算,得到各个边界线的第一倾斜值。第一倾斜值可以为倾斜角度或斜率。
校准值获取模块503,用于获取校准值。校准值的获取方式已在上文中作 了详细介绍,故在此不作赘述。若倾斜图像包括按序排列的多个元素,且多个元素的排序方向与矩形的倾斜图像的长度方向或宽度方向相同,则校准值获取模块503包括元素提取单元、相邻元素确定单元、第二倾斜值获取单元和校准值计算单元。
其中,元素提取单元用于可以解析倾斜图像,提取多个元素区域,其中,元素区域为包含元素的仿射不变区域。相邻元素确定单元用于确定相邻的两个元素区域。第二倾斜值获取单元用于获取所有的第二倾斜值,第二倾斜值为连接相邻的两个元素区域的直线的倾斜值。校准值计算单元用于对所有的第二倾斜值进行分析计算,得到校准值。
差值计算模块504,用于分别计算各个第一倾斜值与校准值的差值。
确定模块505,用于将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值。
本发明实施例通过获取校准值,并将提取的各边界线的第一倾斜值与校准值一一比较,最后将最小差值对应的第一倾斜值确定为倾斜图像的倾斜值,从而使得倾斜图像的倾斜值唯一确定。
此外,倾斜图像的倾斜值获取装置还包括拍摄图像获取模块、背景去除模块、判断模块和设置模块。拍摄图像获取模块,用于获取倾斜证件的拍摄图像,其中,拍摄图像包括背景图像和倾斜图像。倾斜证件具体可以为身份证、社保卡或银行卡等。背景去除模块,用于解析拍摄图像,去除所述背景图像,得到倾斜图像。判断模块,用于判断倾斜图像的尺寸是否大于倾斜证件的尺寸。设置模块,用于若倾斜图像的尺寸大于倾斜证件的尺寸,则将倾斜图像的尺寸设置为倾斜证件的尺寸。具体地,解析模块501用于解析设置模块设置的倾斜图像,获取倾斜图像的多个边界线的坐标信息。
由于倾斜图像是基于倾斜证件的拍摄图像得到的,因此,倾斜图像的尺寸会与倾斜证件的尺寸有偏差,而在边界线提取的过程中,倾斜图像的尺寸越大,边界线越不容易提取,因此,本发明实施例通过在倾斜图像的尺寸大于倾斜证件的尺寸时,将倾斜图像的尺寸设置为倾斜证件的尺寸,从而保证了倾斜图像不会过大,进而不会影响到边界线的提取。
本发明实施例还提供一种终端,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现上述的倾斜图像的倾斜值获取方法。
本发明实施例还提供一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现上述的倾斜图像的倾斜值获取方法。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)或随机存储记忆体(Random Access Memory,RAM)等。
如上所述是结合具体内容提供的一种或多种实施方式,并不认定本发明的具体实施只局限于这些说明。凡与本发明的方法、结构等近似、雷同,或是对于本发明构思前提下做出若干技术推演或替换,都应当视为本发明的保护范围。

Claims (20)

  1. 一种倾斜图像的倾斜值获取方法,其特征在于,所述倾斜图像为矩形,所述倾斜值获取方法包括:
    解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息;
    根据各个所述坐标信息,获取各个所述边界线的第一倾斜值;
    获取校准值;
    分别计算各个所述第一倾斜值与所述校准值的差值,以获得最小差值;
    将所述最小差值对应的第一倾斜值确定为所述倾斜图像的倾斜值。
  2. 如权利要求1所述的倾斜图像的倾斜值获取方法,其特征在于,所述解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息,包括:
    对所述倾斜图像进行二值化处理,得到二值化图像;
    基于霍夫线段检测算法对所述二值化图像进行检测,得到多个所述边界线的坐标信息。
  3. 如权利要求1所述的倾斜图像的倾斜值获取方法,其特征在于,所述倾斜图像为身份证图像;
    所述获取校准值,包括:
    解析身份证图像,提取所有的单字符区域,所述单字符区域为包含单个字符的仿射不变区域;
    对所有的单字符区域进行分组,得到多个单字符区域组;其中,所述单字符区域组中任意相邻的两个单字符区域之间的距离小于第一预设阈值;
    获取长度最大的单字符区域组;
    获取长度最大的单字符区域组的首尾两个单字符区域的连接线段的倾斜值,并将所述连接线段的倾斜值确定为校准值。
  4. 如权利要求3所述的倾斜图像的倾斜值获取方法,其特征在于,所述对所有的单字符区域进行分组,得到多个单字符区域组,包括:
    获取第一单字符区域;
    获取与所述第一单字符区域的距离小于所述第一预设阈值的所有第二字单字符区域;
    直至获取与第n-1单字符区域的距离小于所述第一预设阈值的所有的第n字单字符区域;其中,n大于2,且所述第一单字符区域、所述第二单字符区域直至所述第n单字符区域不相同;
    将所述第一单字符区域、所有的所述第二单字符区域直至所有的所述第n单字符区域确定为单字符区域组。
  5. 如权利要求1所述的倾斜图像的倾斜值获取方法,其特征在于,所述倾斜图像包括按序排列的多个元素,多个元素的排序方向与所述倾斜图像的长度方向或宽度方向相同;
    所述获取校准值,包括:
    解析所述倾斜图像,提取多个元素区域,所述元素区域为包含单个元素的区域;
    确定相邻的两个元素区域;
    获取所有的第二倾斜值,所述第二倾斜值为连接相邻的两个元素区域的直线的倾斜值;
    对所有的所述第二倾斜值进行分析计算,得到所述校准值。
  6. 如权利要求5所述的倾斜图像的倾斜值获取方法,其特征在于,所述对所有的所述第二倾斜值进行分析计算,得到所述校准值,包括:
    对所有的所述第二倾斜值进行聚类,得到多个倾斜值簇;
    获取权重最大的倾斜值簇;
    计算权重最大的倾斜值簇的均值,得到所述校准值。
  7. 如权利要求5所述的倾斜图像的倾斜值获取方法,其特征在于,所述解析倾斜图像,提取多个元素区域,包括:
    解析倾斜图像,提取所有的最大稳定极值区域;
    从所有的最大稳定极值区域中滤除非元素区域,得到多个所述元素区域。
  8. 如权利要求1所述的倾斜图像的倾斜值获取方法,其特征在于,当倾斜图像为长方形时,所述获取校准值,包括:
    对获取的多个第一倾斜值进行聚类,得到两个簇,每个簇的方差都小于预设方差值;
    分别计算每个簇中各第一倾斜值对应线段的长度和;
    确定获取的两个长度和中的最大值或最小值,并将最大值或最小值对应的簇的均值作为校准值。
  9. 如权利要求1所述的倾斜图像的倾斜值获取方法,其特征在于,解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息,之前还包括:
    获取倾斜证件的拍摄图像,其中,拍摄图像包括背景图像和倾斜图像;
    解析拍摄图像,去除所述背景图像,得到倾斜图像;
    判断倾斜图像的尺寸是否大于倾斜证件的尺寸;
    若倾斜图像的尺寸大于倾斜证件的尺寸,则将倾斜图像的尺寸设置为倾斜证件的尺寸;
    若倾斜图像的尺寸小于或等于倾斜证件的尺寸,则不对倾斜图像的尺寸进行设置。
  10. 一种倾斜图像的倾斜值获取装置,其特征在于,所述倾斜图像为矩 形,所述倾斜值获取装置包括:
    解析模块,用于解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息;
    第一倾斜值获取模块,用于分别对各个坐标信息进行分析计算,得到各个所述边界线的第一倾斜值;
    校准值获取模块,用于获取校准值;
    差值计算模块,用于分别计算各个所述第一倾斜值与所述校准值的差值,以获得最小差值;
    确定模块,用于将所述最小差值对应的第一倾斜值确定为所述倾斜图像的倾斜值。
  11. 如权利要求10所述的倾斜图像的倾斜值获取装置,其特征在于,所述倾斜图像的倾斜值获取装置还包括:
    拍摄图像获取模块,用于获取倾斜证件的拍摄图像,其中,拍摄图像包括背景图像和倾斜图像;
    背景去除模块,用于解析拍摄图像,去除所述背景图像,得到倾斜图像;
    判断模块,用于判断倾斜图像的尺寸是否大于倾斜证件的尺寸;
    设置模块,用于若倾斜图像的尺寸大于倾斜证件的尺寸,则将倾斜图像的尺寸设置为倾斜证件的尺寸。
  12. 一种终端,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如下步骤:
    解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息;
    根据各个所述坐标信息,获取各个所述边界线的第一倾斜值;
    获取校准值;
    分别计算各个所述第一倾斜值与所述校准值的差值,以获得最小差值;
    将所述最小差值对应的第一倾斜值确定为所述倾斜图像的倾斜值。
  13. 根据权利要求12所述的终端,其特征在于,所述解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息,包括:
    对所述倾斜图像进行二值化处理,得到二值化图像;
    基于霍夫线段检测算法对所述二值化图像进行检测,得到多个所述边界线的坐标信息。
  14. 根据权利要求12所述的终端,其特征在于,所述倾斜图像为身份证图像;
    所述获取校准值,包括:
    解析身份证图像,提取所有的单字符区域,所述单字符区域为包含单个字符的仿射不变区域;
    对所有的单字符区域进行分组,得到多个单字符区域组;其中,所述单字符区域组中任意相邻的两个单字符区域之间的距离小于第一预设阈值;
    获取长度最大的单字符区域组;
    获取长度最大的单字符区域组的首尾两个单字符区域的连接线段的倾斜值,并将所述连接线段的倾斜值确定为校准值。
  15. 根据权利要求14所述的终端,其特征在于,所述对所有的单字符区域进行分组,得到多个单字符区域组,包括:
    获取第一单字符区域;
    获取与所述第一单字符区域的距离小于所述第一预设阈值的所有第二字单字符区域;
    直至获取与第n-1单字符区域的距离小于所述第一预设阈值的所有的第n字单字符区域;其中,n大于2,且所述第一单字符区域、所述第二单字符区域直至所述第n单字符区域不相同;
    将所述第一单字符区域、所有的所述第二单字符区域直至所有的所述第n单字符区域确定为单字符区域组。
  16. 根据权利要求12所述的终端,其特征在于,所述倾斜图像包括按序排列的多个元素,多个元素的排序方向与所述倾斜图像的长度方向或宽度方向相同;
    所述获取校准值,包括:
    解析所述倾斜图像,提取多个元素区域,所述元素区域为包含单个元素的区域;
    确定相邻的两个元素区域;
    获取所有的第二倾斜值,所述第二倾斜值为连接相邻的两个元素区域的直线的倾斜值;
    对所有的所述第二倾斜值进行分析计算,得到所述校准值。
  17. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如下步骤:
    解析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息;
    根据各个所述坐标信息,获取各个所述边界线的第一倾斜值;
    获取校准值;
    分别计算各个所述第一倾斜值与所述校准值的差值,以获得最小差值;
    将所述最小差值对应的第一倾斜值确定为所述倾斜图像的倾斜值。
  18. 根据权利要求17所述的计算机可读存储介质,其特征在于,所述解 析所述倾斜图像,获取所述倾斜图像的多个边界线的坐标信息,包括:
    对所述倾斜图像进行二值化处理,得到二值化图像;
    基于霍夫线段检测算法对所述二值化图像进行检测,得到多个所述边界线的坐标信息。
  19. 根据权利要求17所述的计算机可读存储介质,其特征在于,所述倾斜图像为身份证图像;所述获取校准值,包括:
    解析身份证图像,提取所有的单字符区域,所述单字符区域为包含单个字符的仿射不变区域;
    对所有的单字符区域进行分组,得到多个单字符区域组;其中,所述单字符区域组中任意相邻的两个单字符区域之间的距离小于第一预设阈值;
    获取长度最大的单字符区域组;
    获取长度最大的单字符区域组的首尾两个单字符区域的连接线段的倾斜值,并将所述连接线段的倾斜值确定为校准值。
  20. 根据权利要求19所述的计算机可读存储介质,其特征在于,所述对所有的单字符区域进行分组,得到多个单字符区域组,包括:
    获取第一单字符区域;
    获取与所述第一单字符区域的距离小于所述第一预设阈值的所有第二字单字符区域;
    直至获取与第n-1单字符区域的距离小于所述第一预设阈值的所有的第n字单字符区域;其中,n大于2,且所述第一单字符区域、所述第二单字符区域直至所述第n单字符区域不相同;
    将所述第一单字符区域、所有的所述第二单字符区域直至所有的所述第n单字符区域确定为单字符区域组。
PCT/CN2017/099644 2017-07-28 2017-08-30 倾斜图像的倾斜值获取方法、装置、终端及存储介质 WO2019019250A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
US16/090,198 US11074443B2 (en) 2017-07-28 2017-08-30 Method and device for acquiring slant value of slant image, terminal and storage medium
SG11201808503WA SG11201808503WA (en) 2017-07-28 2017-08-30 Method and device for acquiring slant value of slant image, terminal and storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710630855.6A CN107680108B (zh) 2017-07-28 2017-07-28 倾斜图像的倾斜值获取方法、装置、终端及存储介质
CN201710630855.6 2017-07-28

Publications (1)

Publication Number Publication Date
WO2019019250A1 true WO2019019250A1 (zh) 2019-01-31

Family

ID=61133913

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/099644 WO2019019250A1 (zh) 2017-07-28 2017-08-30 倾斜图像的倾斜值获取方法、装置、终端及存储介质

Country Status (4)

Country Link
US (1) US11074443B2 (zh)
CN (1) CN107680108B (zh)
SG (1) SG11201808503WA (zh)
WO (1) WO2019019250A1 (zh)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112840308A (zh) * 2018-12-19 2021-05-25 深圳市欢太科技有限公司 一种优化字体的方法及相关设备
CN110788858B (zh) * 2019-10-23 2023-06-13 武汉库柏特科技有限公司 一种基于图像的物体校位方法、智能机器人及校位系统
CN111553344B (zh) * 2020-04-17 2023-05-12 携程旅游信息技术(上海)有限公司 文本图像的倾斜校正方法、系统、设备和存储介质
CN114322849A (zh) * 2020-09-29 2022-04-12 昆山午力电子有限公司 基于图像识别的物品特征定位系统
CN113379681B (zh) * 2021-05-20 2022-11-04 深圳技术大学 Led芯片倾斜角度的获取方法、系统、电子装置及存储介质
CN115229357B (zh) * 2022-09-23 2022-12-13 江苏美乐嘉科技新材料有限公司 一种用于木塑材料的激光切割方法

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4136819B2 (ja) * 2003-07-18 2008-08-20 株式会社リコー 画像処理装置及びプログラム
CN105608455A (zh) * 2015-12-18 2016-05-25 浙江宇视科技有限公司 一种车牌倾斜校正方法及装置
CN106131362A (zh) * 2016-07-12 2016-11-16 珠海赛纳打印科技股份有限公司 一种图像处理方法、装置及图像形成设备

Family Cites Families (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6373997B1 (en) * 1991-07-30 2002-04-16 Xerox Corporation Coarse and fine skew measurement
US5937084A (en) * 1996-05-22 1999-08-10 Ncr Corporation Knowledge-based document analysis system
US6310984B2 (en) * 1998-04-09 2001-10-30 Hewlett-Packard Company Image processing system with image cropping and skew correction
KR100264331B1 (ko) * 1998-05-26 2000-08-16 윤종용 원고 비틀림 보정 장치 및 방법
CN101425142B (zh) * 2008-09-17 2011-05-11 北大方正集团有限公司 页面倾斜角度的确定方法和装置
CN101408937B (zh) * 2008-11-07 2011-12-21 东莞市微模式软件有限公司 一种字符行定位的方法及装置
CN101859382B (zh) * 2010-06-03 2013-07-31 复旦大学 一种基于最大稳定极值区域的车牌检测与识别的方法
CN102955941A (zh) * 2011-08-31 2013-03-06 汉王科技股份有限公司 身份信息录入方法和装置
CN103366165B (zh) 2012-03-30 2016-06-29 富士通株式会社 图像处理装置、图像处理方法以及设备
JP6384236B2 (ja) * 2014-09-29 2018-09-05 ブラザー工業株式会社 制御プログラム、および情報処理装置
CN105590112B (zh) * 2015-09-22 2018-12-04 成都数联铭品科技有限公司 一种图像识别中倾斜文字判断方法
CN106067023B (zh) * 2016-06-02 2021-08-17 北京国泰星云科技有限公司 基于图像处理的集装箱箱号及集卡车号识别系统及方法
CN106127206B (zh) * 2016-06-28 2019-04-05 北京智芯原动科技有限公司 一种车牌的竖直角度检测方法及装置
CN106529520A (zh) * 2016-10-09 2017-03-22 中国传媒大学 基于运动员号码识别的马拉松比赛照片管理方法
CN106650739B (zh) * 2016-12-09 2020-08-11 浙江浩腾电子科技股份有限公司 一种车牌字符切割新方法
CN106845475A (zh) * 2016-12-15 2017-06-13 西安电子科技大学 基于连通域的自然场景文字检测方法
CN106846339A (zh) * 2017-02-13 2017-06-13 广州视源电子科技股份有限公司 一种图像检测方法和装置

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4136819B2 (ja) * 2003-07-18 2008-08-20 株式会社リコー 画像処理装置及びプログラム
CN105608455A (zh) * 2015-12-18 2016-05-25 浙江宇视科技有限公司 一种车牌倾斜校正方法及装置
CN106131362A (zh) * 2016-07-12 2016-11-16 珠海赛纳打印科技股份有限公司 一种图像处理方法、装置及图像形成设备

Also Published As

Publication number Publication date
CN107680108B (zh) 2019-06-21
US20210124918A1 (en) 2021-04-29
CN107680108A (zh) 2018-02-09
SG11201808503WA (en) 2019-02-27
US11074443B2 (en) 2021-07-27

Similar Documents

Publication Publication Date Title
WO2019019250A1 (zh) 倾斜图像的倾斜值获取方法、装置、终端及存储介质
KR101690981B1 (ko) 형태 인식 방법 및 디바이스
WO2016065701A1 (zh) 图像文字识别方法及装置
CN113109368B (zh) 玻璃裂纹检测方法、装置、设备及介质
WO2021139197A1 (zh) 一种图像处理方法及装置
CN111739020B (zh) 周期纹理背景缺陷标签自动标注方法、装置、设备及介质
WO2017113692A1 (zh) 一种图像匹配方法及装置
CN111222507A (zh) 数字式仪表读数的自动识别方法、计算机可读存储介质
CN112541504A (zh) 一种针对文本中单个字符目标的检测方法
CN116342525A (zh) 基于Lenet-5模型的SOP芯片引脚缺陷检测方法及系统
CN109752393B (zh) 一种基于图像特征的贴片电阻型号检测方法及其装置
WO2019019681A1 (zh) 身份证图像的倾斜值获取方法及装置、终端、存储介质
Papandreou et al. Word slant estimation using non-horizontal character parts and core-region information
Aldavert et al. Manuscript text line detection and segmentation using second-order derivatives
CN109035285B (zh) 图像边界确定方法及装置、终端及存储介质
CN116434071B (zh) 一种规整化建筑掩膜的确定方法、确定装置、设备及介质
CN112036232A (zh) 一种图像表格结构识别方法、系统、终端以及存储介质
CN112950594A (zh) 产品表面缺陷的检测方法、设备及存储介质
CN109657577B (zh) 一种基于熵和运动偏移量的动物检测方法
EP2993623B1 (en) Apparatus and method for multi-object detection in a digital image
CN115797649A (zh) 一种复杂背景下的裂缝提取方法
CN111275693B (zh) 一种图像中物体的计数方法、计数装置及可读存储介质
CN116416671B (zh) 一种人脸图像旋正方法、装置、电子设备和存储介质
CN117115275B (zh) 畸变参数的确定方法、装置和计算机设备
US20220392103A1 (en) Visual positioning method, mobile machine using the same, and computer readable storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17919540

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17919540

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 05.08.2020)

122 Ep: pct application non-entry in european phase

Ref document number: 17919540

Country of ref document: EP

Kind code of ref document: A1