CN115527024A - Detection positioning method and system based on image information - Google Patents

Detection positioning method and system based on image information Download PDF

Info

Publication number
CN115527024A
CN115527024A CN202211242799.6A CN202211242799A CN115527024A CN 115527024 A CN115527024 A CN 115527024A CN 202211242799 A CN202211242799 A CN 202211242799A CN 115527024 A CN115527024 A CN 115527024A
Authority
CN
China
Prior art keywords
image
resistance
board card
information
image information
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202211242799.6A
Other languages
Chinese (zh)
Inventor
张涛
林单
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Putian Xile Network Technology Co ltd
Original Assignee
Putian Xile Network Technology Co ltd
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 Putian Xile Network Technology Co ltd filed Critical Putian Xile Network Technology Co ltd
Priority to CN202211242799.6A priority Critical patent/CN115527024A/en
Publication of CN115527024A publication Critical patent/CN115527024A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/25Determination of region of interest [ROI] or a volume of interest [VOI]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/24Aligning, centring, orientation detection or correction of the image
    • G06V10/247Aligning, centring, orientation detection or correction of the image by affine transforms, e.g. correction due to perspective effects; Quadrilaterals, e.g. trapezoids
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/26Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion
    • G06V10/267Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion by performing operations on regions, e.g. growing, shrinking or watersheds
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/764Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects
    • G06V10/765Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects using rules for classification or partitioning the feature space
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/82Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computing Systems (AREA)
  • Databases & Information Systems (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Software Systems (AREA)
  • Image Analysis (AREA)

Abstract

The invention provides a detection positioning method and a system based on image information, which relate to the technical field of image processing and comprise the steps of obtaining a test set of an image of a board card to be detected; segmenting the image information according to a preset resistance segmentation model of the convolutional neural network to obtain segmented resistance image information of the board card to be detected; acquiring a standard image of a board card, extracting a resistance profile in the resistance image information based on the standard image of the board card, and positioning the resistance profile by adopting a minimum circumscribed rectangle algorithm to obtain resistance profile information of the board card; and correcting the resistance contour information by using an affine transformation method, and detecting and positioning the resistance by using a filtering method of a Gaussian template. The method has the advantages that the resistors are determined by adopting a minimum circumscribed rectangle algorithm according to the resistor segmentation image obtained by the convolutional neural network, and the color rings of the color ring resistors are positioned by the Gao Simo plate, so that the detection and the positioning of the resistors on the board card are realized.

Description

Detection positioning method and system based on image information
Technical Field
The invention relates to the technical field of image processing, in particular to a detection positioning method and a detection positioning system based on image information.
Background
The traditional detection method based on the image information is effective for detecting a single component in a board card image under a simple background, but has high requirements on image quality.
When the types of components in the image are multiple, the arrangement is compact, and the condition of uneven illumination exists, the accuracy and the robustness of the algorithm are not high. Especially, for the color ring resistor which is dependent on the color ring color to distinguish the resistance value, the illumination intensity and the lighting mode bring great difficulty to the image segmentation; and the images will also exhibit a wide variety of differences. Therefore, it is necessary to research a new image processing method to solve the problems of detecting and positioning the resistance of the multi-component board cards with different layouts under different illumination conditions.
Disclosure of Invention
The present invention provides a method and a system for detecting and positioning based on image information, so as to improve the above problems. In order to achieve the purpose, the technical scheme adopted by the invention is as follows:
in a first aspect, the present application provides a detection and positioning method based on image information, including:
acquiring a test set of a board image to be detected, wherein the test set of the board image to be detected comprises image information in the test set of the board image to be detected acquired by a shooting device under the conditions of different shooting angles, different illumination conditions and different object distances;
segmenting the image information according to a preset resistance segmentation model of the convolutional neural network and the test set to obtain the segmented resistance image information of the board card to be detected, wherein the resistance segmentation model consists of a four-layer encoder, a decoder and a classifier; the resistance image information of each segmented board card to be detected at least comprises a group of resistors which are arranged at equal intervals, and the resistors are arranged transversely or longitudinally;
acquiring a standard image of a board card, extracting a resistance contour in resistance image information of the board card to be detected based on the standard image of the board card, and positioning the resistance contour by adopting a minimum circumscribed rectangle algorithm to obtain resistance positioning information of the board card;
and based on the resistance contour information, correcting the resistance positioning information by using an affine transformation method, and detecting and positioning the resistance by using a filtering method of a Gaussian template.
In a second aspect, the present application further provides a detection and positioning apparatus based on image information, including an obtaining module, a segmentation module, a positioning module, and a correction module, wherein:
an acquisition module: the test set is used for acquiring a board card image to be detected, and comprises image information in the test set of the board card image to be detected, which is acquired by a shooting device under the conditions of different shooting angles, different illumination conditions and different object distances;
a segmentation module: the test set is used for carrying out test set segmentation on the image information according to a preset resistance segmentation model of the convolutional neural network, and obtaining the segmented resistance image information of the board card to be detected, wherein the resistance segmentation model consists of a four-layer encoder, a decoder and a classifier; the resistance image information of each segmented board card to be detected at least comprises a group of resistors which are arranged at equal intervals, and the resistors are transversely or longitudinally arranged;
a positioning module: the system comprises a detection module, a detection module and a control module, wherein the detection module is used for acquiring a standard image of a board card, extracting a resistance contour in resistance image information of the board card to be detected based on the standard image of the board card, and positioning the resistance contour by adopting a minimum external rectangle algorithm to obtain resistance positioning information of the board card;
a correction module: the system is used for correcting the resistance positioning information by using an affine transformation method based on the resistance contour information and detecting and positioning the resistance by using a filtering method of a Gaussian template.
The invention has the beneficial effects that: aiming at the difficult problems of detection and positioning of resistance images in board cards with different shooting conditions and different layouts, a lightweight full-convolution accumulating network model is constructed according to an encoder-decoder structure so as to realize rapid segmentation and detection of the resistance in the board cards; according to a resistance segmentation image obtained by the convolutional neural network, determining the resistance by adopting a minimum circumscribed rectangle algorithm, and performing vertical correction by using affine transformation; the color ring of the color ring resistor is positioned through the Gao Simo plate, and the detection and the positioning of the resistor on the board card are realized. The invention adopts a twice positioning mode to monitor and position the image information with higher precision, and has practical value and wide application prospect in the field of image detection.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by the practice of the embodiments of the invention. The objectives and other advantages of the invention will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and those skilled in the art can also obtain other related drawings based on the drawings without inventive efforts.
Fig. 1 is a schematic flow chart of a detection and positioning method based on image information according to an embodiment of the present invention;
FIG. 2 is a schematic structural diagram of an apparatus for detecting and locating positions based on image information according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a detection and positioning device based on image information according to an embodiment of the present invention.
In the figure, 701, an acquisition module; 702. a segmentation module; 7021. a conversion unit; 7022. a first processing unit; 70221. a third processing unit; 70222. a statistical unit; 70223. an acquisition unit; 70224. an adjustment unit; 7023. a transformation unit; 7024. a second processing unit; 703. a positioning module; 7031. a clustering unit; 7032. a calculation unit; 7033. a transmitting unit; 70331. a parameter calculating unit; 70332. a mapping unit; 70333. a merging unit; 70334. a corresponding unit; 704. a correction module; 7041. a building unit; 7042. a rotation unit; 800. detecting and positioning equipment based on image information; 801. a processor; 802. a memory; 803. a multimedia component; 804. an I/O interface; 805. a communication component.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. The components of embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present invention, presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures. Meanwhile, in the description of the present invention, the terms "first", "second", and the like are used only for distinguishing the description, and are not to be construed as indicating or implying relative importance.
Example 1:
the embodiment provides a detection positioning method based on image information.
Referring to fig. 1, it is shown that the method includes step S100, step S200, step S300 and step S400.
S100, a test set of the board image to be detected is obtained, wherein the test set of the board image to be detected comprises image information in the test set of the board image to be detected, which is obtained by a shooting device under the conditions of different shooting angles, different illumination conditions and different object distances.
It can be understood that the resistors in the board image to be detected in this step are distributed in a substantially horizontal-vertical or horizontal-vertical staggered manner, but the specific positions and the inclination degrees are still greatly different. This creates certain difficulties in locating the resistors. In addition, in the shooting process of the board card, the adopted angles, the illumination conditions and the object distances are different greatly, and the types and the layout forms of the components are various, so that the step includes but is not limited to the situation that in the case of different shooting angles, different illumination conditions and different object distances, the collection test set can be carried out according to the conditions of the types, the sizes, the quantities and the like of the resistors, and the data set is complete. A training set and a verification set can also be acquired, 200 images are acquired as a test set, and 1058 resistors are used for testing.
S200, segmenting the image information according to a preset resistance segmentation model of the convolutional neural network and the test set to obtain segmented resistance image information of the board card to be detected, wherein the resistance segmentation model consists of a four-layer encoder, a decoder and a classifier; the resistance image information of each segmented board card to be detected at least comprises a group of resistors which are arranged at equal intervals, and the resistors are arranged transversely or longitudinally.
In order to enable the image to be positioned better and more clearly, the shot image is segmented to obtain a small segmented image, and then the small segmented image is processed, so that the image is more precise, and the result is more standard. The resistors in the resistor image information of the board card to be detected are transversely or longitudinally arranged, but each segmented resistor image information at least has one group of resistors.
Specifically, each encoder is composed of a convolutional layer, an active layer, and a downsampled layer, and each decoder is composed of an upsampled layer, a convolutional layer, a normalization layer, and an active layer.
It is understood that step S200 is followed by steps S201, S202, S203 and S204, wherein:
s201, converting the segmented image information into a first gray image;
s202, processing the first gray level image by adopting an otsu threshold segmentation algorithm to obtain a binary image, wherein the processing process of the binary image comprises the step of converting an analog image signal in a board card into a digital image signal;
specifically, the otsu threshold segmentation algorithm is adopted to process the first gray level image to obtain a binary image, and image information, namely an analog signal, in the image is converted into a digital image signal during processing, so that subsequent processing and observation are facilitated.
S203, performing morphological transformation on the binary image, and processing the image after the morphological transformation by using an expansion operator and a corrosion operator to obtain the segmented resistance image information of the board card to be detected;
and S204, multiplying the segmented resistance image information of the board card to be detected and the standard image for masking to obtain a masked image.
Specifically, the binary image is subjected to morphological transformation, a matrix of 256 × 256 is used as a template to perform closed operation, and the template is expanded first; traversing the image after the form transformation to obtain a plurality of elements, searching the largest element, corroding the image, eliminating cracks and irregular places, removing noise after elimination, and performing expansion operation to obtain the segmented resistance image information of the board card to be detected.
Setting the size of a mask plate to be 256 × 256, setting the RGB value of the image to be white when the RGB value is higher, setting the RGB value to be zero when the RGB value is lower, and setting the RGB value to be black, performing fixed threshold binarization by using a least square method, extracting the outline of the image to obtain a mark, and obtaining the image after the mask according to the mark.
It should be noted that, after step S202, steps S2021, S2022, S2023, and S2024 are further included, where:
s2021, performing Gaussian filtering processing on the binary image, and converting the binary image into a second gray image after the Gaussian filtering processing;
s2022, carrying out statistics on gray information of the second gray image to obtain a gray histogram, and normalizing the gray histogram;
s2023, acquiring first information, wherein the first information comprises gradient information of each slope in the normalized gray level histogram, the gradient information of each slope comprises a slope peak value, a total slope value, a slope mean value, a slope starting point and a slope ending point of a resistor, and one slope in the gray level histogram is an area between two adjacent lowest slopes;
specifically, one range in the gray histogram is selected for comparison, in this embodiment, the gray range may be selected as {50, 150}, and the kurtosis values of all slopes in this range are compared to select the largest and the smallest.
S2024, adjusting the highest slope point and the lowest slope point, determining an adaptive threshold value to obtain a segmentation result image, and recording the segmentation result image as resistance image information of the board card to be detected.
Specifically, according to the highest slope point and the lowest slope point, the average threshold value of the image area is obtained through judgment and calculation to conduct iteration, the sum of the total values of all slopes on the left side of the threshold value on one side is compared with the sum of the total values of all slopes on the right side of the threshold value on the other side, if one side is larger than the other side, the adaptive threshold value is set on the one side, and otherwise, the adaptive threshold value is set on the other side.
S300, acquiring a standard image of the board card, extracting a resistance contour in resistance image information of the board card to be detected based on the standard image of the board card, and positioning the resistance contour by adopting a minimum external rectangle algorithm to obtain resistance positioning information of the board card.
In this step, the contour of the resistor is located, but only the approximate resistor location.
Specifically, the standard image of the board card is an image of the board card which is qualified in all aspects; the resistance positioning method adopting the minimum area circumscribed rectangle algorithm comprises the following steps: by the calculation formula:
Figure BDA0003885346070000071
it is understood that step S300 is followed by steps S301, S302 and S303, wherein:
s301, clustering resistance contours in the standard image of the board card according to contour types to obtain resistance contour category distribution results, wherein the contour types comprise metal film resistors, carbon film resistors, fusing resistors, winding resistors and packaging resistors;
s302, clustering is carried out based on the resistance profile category distribution result to obtain at least one characteristic cluster, a parameter range corresponding to the at least one characteristic cluster is called, and a first parameter average number in each characteristic cluster is calculated;
specifically, the resistance profiles in the standard image of the board card are clustered according to profile types, wherein different Fan Weiju clusters are different clusters, the average pixel value of the parameter range of each characteristic cluster is determined based on each cluster, the characteristic color is further determined based on the pixel value, and the characteristic types are preliminarily judged, for example, the profile types comprise metal film resistors, carbon film resistors, fusing resistors, winding resistors and packaging resistors.
And S303, sending each first parameter average to a preset classification model for processing to obtain a resistor classification result.
Specifically, it can be understood that the invention judges the type of the board resistor by comparing the average number of different characteristic pixel points with the data in the database, and determines the resistor distribution information through the pixel point range, so as to obtain the resistor identification result, and classifies the resistor type, for example, into the types of winding resistors or packaging resistors, so that the board resistor can be classified, and the board resistor can be effectively and rapidly positioned and detected.
It should be noted that the method for constructing the classification model in step S303 includes S3031, S3032, S3033, and S3034, where:
s3031, calculating to obtain at least one second parameter average based on a clustering algorithm and the standard image of the board card, wherein the second parameter average is a characteristic parameter range obtained by clustering the standard board card image, and further calculating to obtain a parameter average in a characteristic clustering cluster;
it can be understood that the above steps are based on historical data to train the classification model, so as to improve the recognition accuracy of the classification model, ensure that the classification model can be classified accurately, and reduce errors.
S3032, mapping at least one second parameter average number and the standard image to obtain a corresponding relation between each standard image and each second parameter average number;
the method and the device have the advantages that the standard image and the second parameter average number are mapped through the classification model, so that the one-to-one correspondence between each resistor type and the board card image is guaranteed, and the resistors in each board card image can be accurately classified.
S3033, processing each second parameter average based on a Hash algorithm to obtain a Hash value corresponding to each second parameter average; combining all the hash values based on a non-maximum value suppression algorithm to obtain combined hash values, and constructing a classification database based on each combined hash value;
s3034, based on a K-Means clustering method, sending the corresponding relation between each standard image and each second parameter average to the classification database for processing to obtain a constructed classification model, wherein the corresponding relation corresponds to each spliced hash value.
It can be understood that in the above steps, the average number of the second parameter is converted by using a hash algorithm, all image data are encrypted, and the calculated amount of data is reduced by hash value conversion, so that the calculation speed is greatly optimized, and the calculation efficiency is improved.
S400, based on the resistance contour information, correcting the resistance positioning information by using an affine transformation method, and detecting and positioning the resistance by using a filtering method of a Gaussian template.
In the step, an affine transformation method and a filtering method of a Gaussian template are adopted to accurately position the resistor.
It is understood that step S400 includes steps S401 and S402, where:
s401, establishing a minimum circumscribed rectangle surrounding the resistance outline, and calculating to obtain a central point of the minimum circumscribed rectangle;
s402, using an affine transformation method, taking the central point as a rotation center, and rotating the minimum circumscribed rectangle counterclockwise to be vertical.
It should be noted that, by using an affine transformation method, the center point p = (x) of the rectangle circumscribed by the minimum resistance is p ,y p ) As a center of rotation, rotate counterclockwise (90 ° -a) to vertical, where affine transformation matrix M is:
Figure BDA0003885346070000101
wherein α = cos (90 ° - α) and β = sin (90 ° - α).
It should be noted that, the positioning based on gaussian matching is to position the color circle by using a gaussian template matching method for the vertically corrected resistance image. The normalized Gaussian template converts the gray value of the image to [0,1] according to the characteristic that the symmetric axis of the Gaussian function G (z) is an extreme point and gradually decreases towards the periphery. And respectively matching the Gaussian template with the gray values of RGB three channels of the resistor by adopting a normalized correlation coefficient matching method, and superposing the Gaussian template and the gray values of the RGB three channels of the resistor for positioning.
Example 2:
as shown in fig. 2, the present embodiment provides a detection positioning apparatus based on image information, and the apparatus includes an obtaining module, a segmentation module, a positioning module, and a correction module with reference to fig. 2, wherein:
an acquisition module: the test set is used for acquiring a board card image to be detected, and comprises image information in the test set of the board card image to be detected, which is acquired by a shooting device under the conditions of different shooting angles, different illumination conditions and different object distances;
a segmentation module: the test set is used for carrying out test set segmentation on the image information according to a preset resistance segmentation model of the convolutional neural network, and obtaining the segmented resistance image information of the board card to be detected, wherein the resistance segmentation model consists of a four-layer encoder, a decoder and a classifier; the resistance image information of each segmented board card to be detected at least comprises a group of resistors which are arranged at equal intervals, and the resistors are arranged transversely or longitudinally;
a positioning module: the device comprises a detection module, a detection module and a processing module, wherein the detection module is used for acquiring a standard image of a board card, extracting a resistance outline in resistance image information of the board card to be detected based on the standard image of the board card, and positioning the resistance outline by adopting a minimum circumscribed rectangle algorithm to obtain resistance positioning information of the board card;
a correction module: the system is used for correcting the resistance positioning information by using an affine transformation method based on the resistance contour information, and detecting and positioning the resistance by using a filtering method of a Gaussian template.
Specifically, the segmentation module, thereafter, includes a conversion unit, a first processing unit, a transformation unit, and a second processing unit, wherein:
a conversion unit: the image processing device is used for converting the segmented image information into a first gray image;
a first processing unit: the processing method comprises the steps of processing the first gray level image by adopting an otsu threshold segmentation algorithm to obtain a binary image, wherein the processing process of the binary image comprises the step of converting an analog image signal in a board card into a digital image signal;
a transformation unit: the system is used for carrying out morphological transformation on the binary image, and processing the morphologically transformed image by using an expansion operator and a corrosion operator to obtain resistance image information of the segmented board card to be detected;
a second processing unit: and the standard image processing module is used for multiplying the segmented resistance image information of the board card to be detected with the standard image to perform mask processing to obtain a masked image.
Specifically, the first processing unit, then, includes a third processing unit, a statistical unit, an obtaining unit, and an adjusting unit, wherein:
a third processing unit: the image processing device is used for carrying out Gaussian filtering processing on the binary image and converting the binary image into a second gray level image after the Gaussian filtering processing;
a statistic unit: the gray level histogram is used for counting the gray level information of the second gray level image to obtain a gray level histogram and normalizing the gray level histogram;
an acquisition unit: the first information comprises gradient information of each slope in the normalized gray level histogram, wherein the gradient information of each slope comprises a slope peak value, a slope total value, a slope mean value, a slope starting point and a slope ending point of a resistor, and one slope in the gray level histogram is an area between two adjacent lowest slopes;
an adjusting unit: and the self-adaptive threshold is determined to obtain a segmentation result image, and the segmentation result image is recorded as the resistance image information of the board card to be detected.
Specifically, the correction module includes a building unit and a rotating unit, wherein:
the establishing unit: the minimum circumscribed rectangle is used for establishing a minimum circumscribed rectangle surrounding the resistance outline, and the central point of the minimum circumscribed rectangle is calculated;
a rotation unit: and the minimum bounding rectangle is rotated anticlockwise to be vertical by using the affine transformation method and taking the central point as a rotation center.
Specifically, the positioning module comprises a clustering unit, a calculating unit and a sending unit, wherein:
a clustering unit: the device comprises a board card, a standard image acquisition module, a resistance profile classification module and a processing module, wherein the board card is used for clustering resistance profiles in the standard image of the board card according to profile types to obtain resistance profile classification distribution results, and the profile types comprise metal film resistors, carbon film resistors, fusing resistors, winding resistors and packaging resistors;
a calculation unit: the resistance profile classification distribution result is used for clustering to obtain at least one characteristic clustering cluster, a parameter range corresponding to the at least one characteristic clustering cluster is called, and a first parameter average number in each characteristic clustering cluster is calculated;
a transmission unit: and the resistance classification module is used for sending each first parameter average to a preset classification model for processing to obtain a resistance classification result.
It should be noted that, regarding the apparatus in the above embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated herein.
Example 3:
corresponding to the above method embodiment, the present embodiment further provides an image information-based detection positioning apparatus, and a detection positioning apparatus based on image information described below and a detection positioning method based on image information described above may be referred to correspondingly.
FIG. 3 is a block diagram illustrating an apparatus 800 for image information based detection localization, according to an exemplary embodiment. As shown in fig. 3, the image information-based detection positioning apparatus 800 may include: a processor 801, a memory 802. The image information based detection pointing device 800 may also include one or more of a multimedia component 803, an i/O interface 804, and a communications component 805.
The processor 801 is configured to control the overall operation of the image information based detection and positioning apparatus 800, so as to complete all or part of the steps in the image information based detection and positioning method. Memory 802 is used to store various types of data to support operation of the image information-based detection and location device 800, such data can include, for example, instructions for any application or method operating on the image information-based detection and location device 800, as well as application-related data such as contact data, messaging, pictures, audio, video, and the like. The Memory 802 may be implemented by any type of volatile or non-volatile Memory device or combination thereof, such as Static Random Access Memory (SRAM), electrically Erasable Programmable Read-Only Memory (EEPROM), erasable Programmable Read-Only Memory (EPROM), programmable Read-Only Memory (PROM), read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic disk, or optical disk. The multimedia components 803 may include screen and audio components. Wherein the screen may be, for example, a touch screen and the audio component is used for outputting and/or inputting audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may further be stored in the memory 802 or transmitted through the communication component 805. The audio assembly also includes at least one speaker for outputting audio signals. The I/O interface 804 provides an interface between the processor 801 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 805 is used for wired or wireless communication between the image information based detection positioning device 800 and other devices. Wireless communication, such as Wi-Fi, bluetooth, near Field Communication (NFC), 2G, 3G, or 4G, or a combination of one or more of them, so that the corresponding communication component 805 may include: wi-Fi module, bluetooth module, NFC module.
In an exemplary embodiment, the image information-based detection and location Device 800 may be implemented by one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components for executing the above image information-based detection and location method.
In another exemplary embodiment, a computer readable storage medium including program instructions for implementing the steps of the above-mentioned image information based detection and positioning method when being executed by a processor is also provided. For example, the computer readable storage medium may be the memory 802 comprising program instructions executable by the processor 801 of the image information based detection and localization apparatus 800 to perform the image information based detection and localization method described above.
Example 4:
corresponding to the above method embodiment, a readable storage medium is also provided in this embodiment, and a readable storage medium described below and a detection and positioning method based on image information described above may be referred to in correspondence.
A readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of the detection and positioning method based on image information of the foregoing method embodiment.
The readable storage medium may be a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and various other readable storage media capable of storing program codes.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and all the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (10)

1. A detection positioning method based on image information is characterized by comprising the following steps:
acquiring a test set of a board image to be detected, wherein the test set of the board image to be detected comprises image information in the test set of the board image to be detected, which is acquired by a shooting device under the conditions of different shooting angles, different illumination conditions and different object distances;
segmenting the image information according to a preset resistance segmentation model of the convolutional neural network and the test set to obtain the segmented resistance image information of the board card to be detected, wherein the resistance segmentation model consists of a four-layer encoder, a decoder and a classifier; the resistance image information of each segmented board card to be detected at least comprises a group of resistors which are arranged at equal intervals, and the resistors are arranged transversely or longitudinally;
acquiring a standard image of a board card, extracting a resistance contour in resistance image information of the board card to be detected based on the standard image of the board card, and positioning the resistance contour by adopting a minimum external rectangle algorithm to obtain resistance positioning information of the board card;
and based on the resistance contour information, correcting the resistance positioning information by using an affine transformation method, and detecting and positioning the resistance by using a filtering method of a Gaussian template.
2. The method for detecting and positioning based on image information according to claim 1, wherein the segmenting the image information according to the preset resistance segmentation model of the convolutional neural network and the test set, and then comprises:
converting the segmented image information into a first gray image;
processing the first gray level image by adopting an otsu threshold segmentation algorithm to obtain a binary image, wherein the processing process of the binary image comprises the step of converting an analog image signal in a board card into a digital image signal;
performing morphological transformation on the binary image, and processing the morphologically transformed image by using an expansion operator and a corrosion operator to obtain resistance image information of the segmented board card to be detected;
and multiplying the segmented resistance image information of the board card to be detected with the standard image to perform masking processing to obtain a masked image.
3. The method as claimed in claim 2, wherein the step of processing the first gray image by otsu threshold segmentation algorithm to obtain a binary image comprises:
performing Gaussian filtering processing on the binary image, and converting the binary image into a second gray level image after the Gaussian filtering processing;
counting the gray information of the second gray image to obtain a gray histogram, and normalizing the gray histogram;
acquiring first information, wherein the first information comprises gradient information of each slope in the normalized gray level histogram, the gradient information of each slope comprises a slope peak value, a slope total value, a slope mean value, a slope starting point and a slope ending point of a resistor, and one slope in the gray level histogram is an area between two adjacent lowest slopes;
and adjusting the highest slope point and the lowest slope point, determining a self-adaptive threshold value to obtain a segmentation result image, and recording the segmentation result image as the resistance image information of the board card to be detected.
4. The image information-based detection positioning method according to claim 1, wherein the correction of the resistance positioning information by an affine transformation method based on the resistance contour information comprises:
establishing a minimum circumscribed rectangle surrounding the resistance outline, and calculating to obtain a central point of the minimum circumscribed rectangle;
and using an affine transformation method to take the central point as a rotation center, and rotating the minimum bounding rectangle anticlockwise to be vertical.
5. The image information-based detection and positioning method according to claim 1, wherein the acquiring of the standard image of the board, the extracting of the resistance profile in the resistance image information of the board to be detected based on the standard image of the board, then comprises:
clustering resistance profiles in the standard images of the board cards according to profile types to obtain resistance profile type distribution results, wherein the profile types comprise metal film resistors, carbon film resistors, fusing resistors, winding resistors and packaging resistors;
clustering based on the resistance profile category distribution result to obtain at least one characteristic cluster, calling a parameter range corresponding to the at least one characteristic cluster, and calculating a first parameter average in each characteristic cluster;
and sending each first parameter average to a preset classification model for processing to obtain a resistor classification result.
6. An apparatus for detecting and locating a position based on image information, comprising:
an acquisition module: the test set is used for acquiring a board card image to be detected, and comprises image information in the test set of the board card image to be detected, which is acquired by a shooting device under the conditions of different shooting angles, different illumination conditions and different object distances;
a segmentation module: the test set is used for carrying out test set segmentation on the image information according to a preset resistance segmentation model of the convolutional neural network, and obtaining the segmented resistance image information of the board card to be detected, wherein the resistance segmentation model consists of a four-layer encoder, a decoder and a classifier; the resistance image information of each segmented board card to be detected at least comprises a group of resistors which are arranged at equal intervals, and the resistors are arranged transversely or longitudinally;
a positioning module: the device comprises a detection module, a detection module and a processing module, wherein the detection module is used for acquiring a standard image of a board card, extracting a resistance outline in resistance image information of the board card to be detected based on the standard image of the board card, and positioning the resistance outline by adopting a minimum circumscribed rectangle algorithm to obtain resistance positioning information of the board card;
a correction module: the system is used for correcting the resistance positioning information by using an affine transformation method based on the resistance contour information and detecting and positioning the resistance by using a filtering method of a Gaussian template.
7. The apparatus according to claim 6, wherein the segmentation module is followed by:
a transformation unit: the image processing device is used for converting the segmented image information into a first gray image;
a first processing unit: the processing method comprises the steps of processing the first gray level image by adopting an otsu threshold segmentation algorithm to obtain a binary image, wherein the processing process of the binary image comprises the step of converting an analog image signal in a board card into a digital image signal;
a transformation unit: the system is used for carrying out morphological transformation on the binary image, and processing the morphologically transformed image by using an expansion operator and a corrosion operator to obtain resistance image information of the segmented board card to be detected;
a second processing unit: and the standard image processing module is used for multiplying the segmented resistance image information of the board card to be detected with the standard image to perform mask processing to obtain a masked image.
8. The apparatus according to claim 7, wherein the first processing unit then comprises:
a third processing unit: the image processing device is used for carrying out Gaussian filtering processing on the binary image and converting the binary image into a second gray level image after the Gaussian filtering processing;
a statistic unit: the gray level histogram is used for counting the gray level information of the second gray level image to obtain a gray level histogram and normalizing the gray level histogram;
an acquisition unit: the first information comprises gradient information of each slope in the normalized gray level histogram, wherein the gradient information of each slope comprises a slope peak value, a slope total value, a slope mean value, a slope starting point and a slope ending point of a resistor, and one slope in the gray level histogram is an area between two adjacent lowest slopes;
an adjusting unit: and the self-adaptive threshold is determined to obtain a segmentation result image, and the segmentation result image is recorded as the resistance image information of the board card to be detected.
9. The apparatus according to claim 6, wherein the correction module comprises:
the establishing unit: the minimum circumscribed rectangle is used for establishing the minimum circumscribed rectangle surrounding the resistor outline, and the central point of the minimum circumscribed rectangle is calculated;
a rotation unit: and the minimum bounding rectangle is rotated anticlockwise to be vertical by using the affine transformation method and taking the central point as a rotation center.
10. The apparatus for detecting and locating image information according to claim 6, wherein said locating module then comprises:
a clustering unit: the device comprises a board card, a standard image acquisition module, a resistance profile classification module and a processing module, wherein the board card is used for clustering resistance profiles in the standard image of the board card according to profile types to obtain resistance profile classification distribution results, and the profile types comprise metal film resistors, carbon film resistors, fusing resistors, winding resistors and packaging resistors;
a calculation unit: the resistance profile classification distribution result is used for clustering to obtain at least one characteristic clustering cluster, a parameter range corresponding to the at least one characteristic clustering cluster is called, and a first parameter average number in each characteristic clustering cluster is calculated;
a transmission unit: and the resistance classification module is used for sending each first parameter average to a preset classification model for processing to obtain a resistance classification result.
CN202211242799.6A 2022-10-11 2022-10-11 Detection positioning method and system based on image information Pending CN115527024A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211242799.6A CN115527024A (en) 2022-10-11 2022-10-11 Detection positioning method and system based on image information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211242799.6A CN115527024A (en) 2022-10-11 2022-10-11 Detection positioning method and system based on image information

Publications (1)

Publication Number Publication Date
CN115527024A true CN115527024A (en) 2022-12-27

Family

ID=84701805

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211242799.6A Pending CN115527024A (en) 2022-10-11 2022-10-11 Detection positioning method and system based on image information

Country Status (1)

Country Link
CN (1) CN115527024A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117351100A (en) * 2023-12-04 2024-01-05 成都数之联科技股份有限公司 Color ring resistor color extraction method, device, equipment and medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117351100A (en) * 2023-12-04 2024-01-05 成都数之联科技股份有限公司 Color ring resistor color extraction method, device, equipment and medium
CN117351100B (en) * 2023-12-04 2024-03-22 成都数之联科技股份有限公司 Color ring resistor color extraction method, device, equipment and medium

Similar Documents

Publication Publication Date Title
CN108985137B (en) License plate recognition method, device and system
CN107301385B (en) Method and device for identifying shielded license plate
CN115294140B (en) Hardware part defect detection method and system
CN110781901B (en) Instrument ghost character recognition method based on BP neural network prediction threshold
CN110378324B (en) Quality dimension-based face recognition algorithm evaluation method
CN109523529B (en) Power transmission line defect identification method based on SURF algorithm
CN108491498B (en) Bayonet image target searching method based on multi-feature detection
Zhang et al. License plate localization in unconstrained scenes using a two-stage CNN-RNN
CN110781882A (en) License plate positioning and identifying method based on YOLO model
CN111626295B (en) Training method and device for license plate detection model
CN111553310B (en) Security inspection image acquisition method and system based on millimeter wave radar and security inspection equipment
CN111507957B (en) Identity card picture conversion method and device, computer equipment and storage medium
CN116596875B (en) Wafer defect detection method and device, electronic equipment and storage medium
CN114612469A (en) Product defect detection method, device and equipment and readable storage medium
CN112560858B (en) Character and picture detection and rapid matching method combining lightweight network and personalized feature extraction
CN107578011A (en) The decision method and device of key frame of video
CN114038004A (en) Certificate information extraction method, device, equipment and storage medium
CN115527024A (en) Detection positioning method and system based on image information
CN114820625A (en) Automobile top block defect detection method
CN111539330A (en) Transformer substation digital display instrument identification method based on double-SVM multi-classifier
CN113936280A (en) Embedded instrument code disc character automatic identification system and method
CN117115197B (en) Intelligent processing method and system for design data of LED lamp bead circuit board
CN112784494A (en) Training method of false positive recognition model, target recognition method and device
CN110728276B (en) License plate recognition method and device
CN110674689A (en) Vehicle re-identification method and system based on feature embedding space geometric constraint

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination