CN116630339A - Marker point positioning method, device, image recognition equipment and storage medium - Google Patents
Marker point positioning method, device, image recognition equipment and storage medium Download PDFInfo
- Publication number
- CN116630339A CN116630339A CN202211042195.7A CN202211042195A CN116630339A CN 116630339 A CN116630339 A CN 116630339A CN 202211042195 A CN202211042195 A CN 202211042195A CN 116630339 A CN116630339 A CN 116630339A
- Authority
- CN
- China
- Prior art keywords
- initial
- target
- images
- marker
- image
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 55
- 239000003550 marker Substances 0.000 title claims description 88
- 238000012549 training Methods 0.000 claims abstract description 30
- 238000012545 processing Methods 0.000 claims description 19
- 230000002159 abnormal effect Effects 0.000 claims description 9
- 230000007704 transition Effects 0.000 claims description 9
- 238000010606 normalization Methods 0.000 claims description 4
- 238000010586 diagram Methods 0.000 description 8
- 230000008569 process Effects 0.000 description 5
- 230000008859 change Effects 0.000 description 4
- 238000012795 verification Methods 0.000 description 4
- 238000000605 extraction Methods 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 238000004590 computer program Methods 0.000 description 2
- 230000007613 environmental effect Effects 0.000 description 2
- 238000002372 labelling Methods 0.000 description 2
- 239000004973 liquid crystal related substance Substances 0.000 description 2
- 230000004075 alteration Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000013135 deep learning Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000004880 explosion Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000007781 pre-processing Methods 0.000 description 1
- 238000003672 processing method Methods 0.000 description 1
- 238000012163 sequencing technique Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/11—Region-based segmentation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/70—Determining position or orientation of objects or cameras
- G06T7/73—Determining position or orientation of objects or cameras using feature-based methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/77—Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
- G06V10/774—Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20081—Training; Learning
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Artificial Intelligence (AREA)
- Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- Databases & Information Systems (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Software Systems (AREA)
- Multimedia (AREA)
- Image Analysis (AREA)
Abstract
The application provides a marking point positioning method, a marking point positioning device, image recognition equipment and a storage medium, wherein the marking point positioning method comprises the following steps: acquiring a plurality of initial images, and determining an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located; extracting initial mark points, randomly embedding the initial mark points into an initial blank area according to preset times, and obtaining a plurality of enhanced images, wherein the enhanced images comprise a target mark point area and a target blank area where at least one target mark point is located; constructing an initial mark point positioning model, and training the initial mark point positioning model based on a plurality of enhanced images and a plurality of initial images to obtain a target mark point positioning model; and positioning the mark points in the image to be positioned according to the target mark point positioning model. The method and the device can improve the quantity and the richness of the images by carrying out image enhancement on the initial images, thereby improving the positioning accuracy and the robustness of the target mark point positioning model on the mark points.
Description
Technical Field
The application relates to the technical field of machine vision, in particular to a marking point positioning method, a marking point positioning device, image recognition equipment and a storage medium.
Background
With the continuous development of society, machine vision plays an increasingly important role in the industrial field, and can play a role in replacing manpower. Deep learning, which is an image processing method, has been gradually developed in the machine vision industry based on its strong feature extraction capability, and is superior in some aspects to the conventional vision method.
In the practical application of mark point positioning, the number of training sample images is often too small and different scenes cannot be covered due to the influence of factors such as large change of the training image sample acquisition environment and limited time for acquiring the sample images. The insufficient image of the training sample can cause insufficient image characteristics in the training stage to effectively represent the image characteristic change, so that the trained mark point positioning model has poor robustness.
Therefore, it is necessary to provide a marker positioning method, a device, an image recognition apparatus and a storage medium, so as to generate more enhanced images, so that a target marker positioning model trained by the enhanced images has better robustness.
Disclosure of Invention
In view of the foregoing, it is necessary to provide a marker positioning method, a device, an image recognition apparatus and a storage medium, so as to solve the technical problem that the robustness of the trained target marker positioning model is poor due to the insufficient number of images in the prior art.
In one aspect, the present application provides a marker positioning method, including:
acquiring a plurality of initial images, and determining an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
extracting the initial mark points, randomly embedding the initial mark points into the initial blank area according to preset times, and obtaining a plurality of enhanced images, wherein the enhanced images comprise a target mark point area where at least one target mark point is located and a target blank area;
constructing an initial marker point positioning model, and training the initial marker point positioning model based on the plurality of enhanced images and the plurality of initial images to obtain a target marker point positioning model;
and positioning the mark points in the image to be positioned according to the target mark point positioning model.
In some possible implementations, the at least one target mark point includes a first target mark point and a second target mark point; the step of randomly embedding the initial mark points into the initial blank area for a plurality of times to obtain an enhanced image comprises the following steps:
randomly embedding the initial mark points into the initial blank area to obtain the first target mark points, a transition mark point area where the first target mark points are located and a transition blank area;
randomly embedding the initial mark points into the transition blank area to obtain the second target mark points, the first target mark points, the target mark point area where the second target mark points are located and the target blank area.
In some possible implementations, the initial marker region is a minimum bounding rectangle of the initial marker.
In some possible implementations, the marker point positioning method further includes:
and performing secondary enhancement processing on the initial image and/or the enhanced image, wherein the secondary enhancement processing is at least one of horizontal mirroring, vertical mirroring, sharpening, brightness adjustment, contrast adjustment and Gaussian noise addition.
In some possible implementations, the positioning the marker point in the image to be positioned according to the target marker point positioning model includes:
determining a plurality of candidate prediction frames in the image to be positioned and scores of the candidate prediction frames in the plurality of candidate prediction frames according to the target mark point positioning model;
and taking the candidate prediction frame with the highest score as the target position of the marking point.
In some possible implementations, the plurality of initial images includes a plurality of normal initial images and a plurality of abnormal initial images.
In some possible implementations, before the training of the initial marker point positioning model based on the plurality of enhanced images and the plurality of initial images, the training method includes:
scaling the plurality of enhanced images and the plurality of initial images to obtain a plurality of scaled images with preset sizes;
and carrying out normalization processing on each scaled image in the plurality of scaled images to obtain a plurality of normalized images.
On the other hand, the application also provides a marking point positioning device, which comprises:
an initial image acquisition unit, configured to acquire a plurality of initial images, and determine an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
the image enhancement unit is used for extracting the initial mark points, randomly embedding the initial mark points into the initial blank area according to preset times to obtain a plurality of enhanced images, wherein the enhanced images comprise a target mark point area where at least one target mark point is located and a target blank area;
the positioning model training unit is used for constructing an initial marking point positioning model, training the initial marking point positioning model based on the plurality of enhanced images and the plurality of initial images, and obtaining a target marking point positioning model;
and the marking point positioning unit is used for positioning the marking point in the image to be positioned according to the target marking point positioning model.
In another aspect, the present application also provides an image recognition apparatus, including a memory and a processor, wherein,
the memory is used for storing programs;
the processor is coupled to the memory and is configured to execute the program stored in the memory to implement the steps in the marker point positioning method described in any one of the possible implementations.
In another aspect, the present application also provides a computer readable storage medium storing a computer readable program or instructions, which when executed by a processor, enable the implementation of the steps in the marker point positioning method described in any one of the possible implementations.
The beneficial effects of adopting the embodiment are as follows: according to the marking point positioning method provided by the application, the initial marking points are extracted, and the initial marking points are randomly embedded into the initial blank area according to the preset times, so that the enhanced image comprising the target marking point area where at least one target marking point is located and the target blank area is obtained, the enhancement of the initial image can be realized, the quantity and the richness of the enhanced image can be expanded, and the positioning accuracy and the robustness of the marking points by the target marking point positioning model trained by the enhanced image and the initial image can be further improved.
Furthermore, the method and the device for positioning the marker point in the image to be positioned can automatically extract the characteristics of the image to be positioned by positioning the marker point in the image to be positioned through the target marker point positioning model obtained by training the initial marker point positioning model, and can accurately position the marker point of the image to be positioned through the strong characteristic extraction capability of the target marker point positioning model even if the image to be positioned is acquired under the scene with great change of environmental factors, so that the success rate and the accuracy rate of positioning the marker point are further improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flowchart of a method for locating a marker point according to an embodiment of the present application;
FIG. 2 is a flowchart illustrating the step S102 of FIG. 1 according to an embodiment of the present application;
FIG. 3 is a flowchart illustrating the step S104 of FIG. 1 according to an embodiment of the present application;
FIG. 4 is a schematic structural diagram of an embodiment of a normal initial image provided by the present application;
FIG. 5 is a schematic structural diagram of an embodiment of an abnormal initial image according to the present application;
FIG. 6 is a schematic flow chart diagram of an embodiment of preprocessing a sample image according to the present application;
FIG. 7 is a schematic structural diagram of an embodiment of a marker point positioning device according to the present application;
fig. 8 is a schematic structural diagram of an embodiment of an image recognition device provided by the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. It will be apparent that the described embodiments are only some, but not all, embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
It should be understood that the schematic drawings are not drawn to scale. A flowchart, as used in this disclosure, illustrates operations implemented according to some embodiments of the present application. It should be appreciated that the operations of the flow diagrams may be implemented out of order and that steps without logical context may be performed in reverse order or concurrently. Moreover, one or more other operations may be added to or removed from the flow diagrams by those skilled in the art under the direction of the present disclosure.
Some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities. These functional entities may be implemented in software or in one or more hardware modules or integrated circuits or in different networks and/or processor systems and/or microcontroller systems.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments.
The application provides a marker point positioning method, a marker point positioning device, an image recognition device and a storage medium, which are respectively described below.
Fig. 1 is a schematic flow chart of an embodiment of a method for locating a marker, as shown in fig. 1, where the method for locating a marker includes:
s101, acquiring a plurality of initial images, and determining an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
s102, extracting initial mark points, randomly embedding the initial mark points into an initial blank area according to preset times, and obtaining a plurality of enhanced images, wherein the enhanced images comprise a target mark point area where at least one target mark point is located and a target blank area;
s103, constructing an initial marker point positioning model, and training the initial marker point positioning model based on a plurality of enhanced images and a plurality of initial images to obtain a target marker point positioning model;
s104, positioning the mark points in the image to be positioned according to the target mark point positioning model.
The initial mark point area, the initial blank area, the target mark point area and the target blank area comprise an area size and an area position.
Compared with the prior art, the marking point positioning method provided by the embodiment of the application has the advantages that the initial marking points are extracted, the initial marking points are randomly embedded into the initial blank area according to the preset times, the enhanced image comprising the target marking point area where at least one target marking point is located and the target blank area is obtained, the enhancement of the initial image can be realized, the quantity and the richness of the enhanced image can be expanded, and the positioning accuracy and the robustness of the marking points by the target marking point positioning model trained by the enhanced image and a plurality of initial images can be further improved.
Furthermore, the embodiment of the application can automatically extract the characteristics of the image to be positioned by positioning the mark points in the image to be positioned by the target mark point positioning model obtained by training the initial mark point positioning model, and can accurately position the mark points of the image to be positioned by the strong characteristic extraction capability of the target mark point positioning model even if the image to be positioned is acquired in a scene with large environmental factor change, thereby further improving the success rate and the accuracy of positioning the mark points.
The model structure of the target mark point positioning model can be any one of structures such as R-CNN, R-FCN, SPPNet, fast R-CNN, fast R-CNN, YOLO, denseBox, SSD, RFBnet and the like.
In order to avoid that the number of target mark points in the enhanced image is too large, which results in more redundant training on the enhanced image, in some embodiments of the present application, the preset number of times in step S102 should be less than or equal to 5.
It should be noted that: the initial image may include at least one initial marker point therein, and in particular embodiments of the present application, the initial image includes one initial marker point.
In order to avoid that the preset number of times is greater than 1, for example: when the at least one target mark point includes the first target mark point and the second target mark point, a technical problem that the first target mark point and the second target mark point are partially or completely overlapped, resulting in failure of the embedded target mark point occurs, in some embodiments of the present application, as shown in fig. 2, step S102 includes:
s201, randomly embedding initial mark points into an initial blank area to obtain a first target mark point, a transition mark point area where the first target mark point is located and a transition blank area;
s202, randomly embedding the initial mark points into the transition blank area to obtain a second target mark point, a first target mark point, a target mark point area where the second target mark point is located and a target blank area.
According to the embodiment of the application, the target mark points embedded each time are embedded into the blank area after the last embedding, so that partial or complete overlapping among the target mark points embedded multiple times is avoided, the technical problem that the embedded target mark points fail is avoided, and the success rate and the utilization rate of the enhanced image are improved.
Since the subsequent marker positioning model positions the marker through the marker region, in order to improve the accuracy of positioning the marker, in some embodiments of the present application, the initial marker region should be kept closely surrounding the initial marker, so as to improve the accuracy of positioning the marker.
In a preferred embodiment of the present application, the initial mark point region is the smallest circumscribed rectangle of the initial mark point.
It should be noted that: the initial marking point region can be obtained by Labeling the initial image by using an open source tool Labeling. The position coordinates of the initial mark points are stored in the format of an extensible markup language (eXtensibleMarkupLanguage, XML), and each initial image corresponds to an XML file.
To further increase the number and richness of images training the initial marker positioning model, in some embodiments of the present application, the marker positioning method further includes:
and performing secondary enhancement processing on the initial image and/or the enhanced image, wherein the secondary enhancement processing is at least one of horizontal mirroring, vertical mirroring, sharpening, brightness adjustment, contrast adjustment and Gaussian noise addition.
According to the embodiment of the application, the initial image and/or the enhanced image can be enhanced from a plurality of enhancement dimensions by carrying out secondary enhancement processing on the initial image and/or the enhanced image, so that the quantity and the richness of the images for training the initial marker point model are further improved, and the positioning accuracy and the robustness of the obtained target marker point positioning model for positioning the positioning point can be further improved.
Since the initial image includes only one marker point in the embodiment of the present application, in order to eliminate the redundant marker point, in some embodiments of the present application, as shown in fig. 3, step S104 includes:
s301, determining a plurality of candidate prediction frames in an image to be positioned and scores of all candidate prediction frames in the plurality of candidate prediction frames according to a target mark point positioning model;
s302, taking the candidate prediction frame with the highest score as the target position of the marking point.
According to the embodiment of the application, the candidate prediction frame with the highest score is used as the target position of the marking point, so that other redundant candidate prediction frames can be eliminated, and the accuracy of the determined target position of the marking point is further improved.
The candidate prediction frames refer to a plurality of prediction frames which are automatically generated when the image to be positioned is positioned through the target mark point positioning model.
The step S302 specifically includes: firstly, deleting candidate prediction frames with scores smaller than a preset score threshold, and then determining the candidate prediction frame with the highest score from the rest candidate prediction frames.
By deleting the candidate prediction frames with the scores smaller than the preset score threshold value, the workload of sequencing the candidate prediction frames can be reduced, and the speed of determining the target positions of the mark points can be improved.
It should be understood that: the preset score threshold may be set or adjusted according to an actual application scenario or an empirical value, and in an embodiment of the present application, the preset score threshold is 0.5.
To ensure robustness and generalization of the target marker point location model at the training site, in some embodiments of the present application, the plurality of initial images includes a plurality of normal initial images and a plurality of abnormal initial images, wherein a normal image refers to an image that can be normally recognized by the prior art or human eye, an abnormal image refers to an image that cannot be normally recognized by the prior art or human eye, for example, without limitation, a normal initial image is an image that can be recognized by a template matching algorithm, and an abnormal initial image is an image that cannot be recognized by a template matching algorithm.
In an embodiment of the present application, fig. 4 is a normal initial image, and fig. 5 is an abnormal initial image. It can be seen that: the marked points in fig. 4 are greatly different from other areas, so the marked points can be successfully matched through a template matching algorithm; while fig. 5 includes a plurality of regions similar to the mark points, the mark points cannot be successfully matched by the template matching algorithm.
In some embodiments of the present application, the image sample set includes a plurality of sample images, and in order to improve the training speed and stability of the initial marker positioning model, as shown in fig. 6, in some embodiments of the present application, before step S103, the method further includes:
s601, scaling each image in a plurality of enhanced images and a plurality of initial images to obtain a plurality of scaled images with preset sizes;
s602, carrying out normalization processing on each zoom image in the plurality of zoom images to obtain a plurality of normalized images.
According to the embodiment of the application, the training amount of the initial mark point positioning model can be reduced by scaling each enhanced image to the preset size, so that the training speed of the initial mark point positioning model can be improved. And by carrying out normalization processing on each scaled image, gradient explosion can be prevented from occurring in the model training process, so that the stability of the initial marker point positioning model training process can be improved.
It should be noted that: to ensure visibility of the marker points in the scaled image, the length of the marker points in any direction in the scaled image should be greater than 8 pixels.
In the embodiment of the present application, the size of the sample image is 512×512, the preset size is 448×448, and the size of the mark point in the sample image is about 50×50, and the sample image becomes 43×43 after scaling.
In a specific embodiment of the application, the normalized image is a single-channel gray scale image, and the specific process is as follows: and dividing the pixel value of each pixel in the scaled image by 255 to obtain a single-channel gray scale image.
In order to verify the superiority of the marker point positioning method provided by the embodiment of the application, 587/Zhang Chushi images are acquired, wherein 2/5 is a normal initial image, 3/5 is an abnormal initial image, and training is performed by using an initial marker point positioning model with a model structure of YOLO v5 to acquire a target marker point positioning model. And 147 images are additionally obtained as a verification set, wherein 2/5 of the verification set is a normal initial image, 3/5 is an abnormal initial image, the target mark point positioning model is verified through the verification set, and the verification result is that: the positioning point in 145 images can be accurately positioned, namely: the positioning accuracy of the mark points is up to 98.6%. And the 147 images are positioned by using a template matching method, and the accuracy rate is only 42.1 percent. It can be seen that: the positioning accuracy of the target mark point positioning model provided by the embodiment of the application is far better than that of a template matching method.
The marking point positioning method provided by the embodiment of the application is particularly suitable for the technical field of photovoltaic cell processing, generally, in order to keep the processing precision of a cell, a MARK point (marking point) is usually preset on the cell as a cell positioning MARK, and in the processing, the cell may have some chromatic aberration and the like or may generate some defects, so that errors or mistakes are generated in visual identification of the preset MARK point (marking point). The method can realize enhancement of the initial image, so that the quantity and the richness of the enhanced images for training the initial mark point positioning model can be expanded, and the positioning accuracy and the robustness of the trained target mark point positioning model on the mark points can be improved.
In order to better implement the marker positioning method in the embodiment of the present application, correspondingly, as shown in fig. 7, on the basis of the marker positioning method, the embodiment of the present application further provides a marker positioning device 700, including:
an initial image acquiring unit 701, configured to acquire a plurality of initial images, and determine an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
the image enhancement unit 702 is configured to extract an initial mark point, randomly embed the initial mark point into an initial blank area according to a preset number of times, and obtain a plurality of enhanced images, where the enhanced images include a target mark point area where at least one target mark point is located and a target blank area;
the positioning model training unit 703 is configured to construct an initial marker positioning model, and train the initial marker positioning model based on the multiple enhanced images and the multiple initial images to obtain a target marker positioning model;
and the marking point positioning unit 704 is used for positioning the marking point in the image to be positioned according to the target marking point positioning model.
The marking point positioning device 700 provided in the foregoing embodiment may implement the technical solution described in the foregoing marking point positioning method embodiment, and the specific implementation principle of each module or unit may refer to the corresponding content in the foregoing marking point positioning method embodiment, which is not described herein again.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of the functional units and modules is illustrated, and in practical application, the above-described functional distribution may be performed by different functional units and modules according to needs, i.e. the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-described functions. The functional units and modules in the embodiment may be integrated in one processing unit, or each unit may exist alone, or two or more units may be integrated in one unit, where the integrated units may be implemented in a form of hardware or a form of a software functional unit. In addition, the specific names of the functional units and modules are only for distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working process of the units and modules in the above system may refer to the corresponding process in the foregoing method embodiment, which is not described herein again.
As shown in fig. 8, the present application also provides an image recognition apparatus 800 accordingly. The image recognition device 800 includes a processor 801, a memory 802, and a display 803. Fig. 8 shows only some of the components of the image recognition device 800, but it should be understood that not all of the illustrated components are required to be implemented and that more or fewer components may be implemented instead.
The memory 802 may be an internal storage unit of the image recognition device 800, such as a hard disk or memory of the image recognition device 800, in some embodiments. The memory 802 may also be an external storage device of the image recognition device 800 in other embodiments, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card) or the like, which are provided on the image recognition device 800.
Further, the memory 802 may also include both internal storage units and external storage devices of the image recognition device 800. The memory 802 is used to store application software and various types of data for installing the image recognition device 800.
The processor 801 may in some embodiments be a central processing unit (Central Processing Unit, CPU), microprocessor or other data processing chip for executing program code or processing data stored in the memory 802, such as the marker point positioning method of the present application.
The display 803 may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch, or the like in some embodiments. The display 803 is for displaying information at the image recognition device 800 and for displaying a visualized user interface. The components 801-803 of the image recognition device 800 communicate with each other via a system bus.
In some embodiments of the present application, when the processor 801 executes the marker point location program in the memory 802, the following steps may be implemented:
acquiring a plurality of initial images, and determining an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
extracting initial mark points, randomly embedding the initial mark points into an initial blank area according to preset times, and obtaining a plurality of enhanced images, wherein the enhanced images comprise a target mark point area and a target blank area where at least one target mark point is located;
constructing an initial mark point positioning model, and training the initial mark point positioning model based on a plurality of enhanced images and a plurality of initial images to obtain a target mark point positioning model;
and positioning the mark points in the image to be positioned according to the target mark point positioning model.
It should be understood that: the processor 801, when executing the marker point location program in the memory 802, may perform other functions in addition to the above, as described above with particular reference to the corresponding method embodiments.
Further, the type of the image recognition device 800 is not particularly limited in the embodiment of the present application, and the image recognition device 800 may be a portable image recognition device such as a tablet computer, a personal digital assistant (personal digitalassistant, PDA), a wearable device, a laptop computer (laptop), etc. The portable image recognition device described above may also be other portable image recognition devices, such as a laptop computer (laptop) or the like having a touch-sensitive surface, e.g. a touch panel. It should also be appreciated that in other embodiments of the application, the image recognition device 800 may not be a portable image recognition device, but rather a desktop computer having a touch-sensitive surface (e.g., a touch panel).
Accordingly, the embodiments of the present application also provide a computer readable storage medium, where the computer readable storage medium is used to store a computer readable program or instructions, and when the program or instructions are executed by a processor, the method steps or functions provided in the foregoing method embodiments can be implemented.
Those skilled in the art will appreciate that all or part of the flow of the methods of the embodiments described above may be accomplished by way of a computer program stored in a computer readable storage medium to instruct related hardware (e.g., a processor, a controller, etc.). Wherein the computer-readable storage medium may include at least: any entity or device capable of carrying computer program code to a photographing device/terminal apparatus, recording medium, computer Memory, read-Only Memory (ROM), random access Memory (RAM, randomAccess Memory), electrical carrier signal, telecommunications signal, and software distribution medium. Such as a U-disk, removable hard disk, magnetic or optical disk, etc. In some jurisdictions, computer readable media may not be electrical carrier signals and telecommunications signals in accordance with legislation and patent practice.
The marking point positioning method, the marking point positioning device, the image recognition device and the storage medium provided by the application are described in detail, and specific examples are applied to the principle and the implementation mode of the application, and the description of the examples is only used for helping to understand the method and the core idea of the application; meanwhile, as those skilled in the art will have variations in the specific embodiments and application scope in light of the ideas of the present application, the present description should not be construed as limiting the present application.
Claims (10)
1. A method of locating a marker, comprising:
acquiring a plurality of initial images, and determining an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
extracting the initial mark points, randomly embedding the initial mark points into the initial blank area according to preset times, and obtaining a plurality of enhanced images, wherein the enhanced images comprise a target mark point area where at least one target mark point is located and a target blank area;
constructing an initial marker point positioning model, and training the initial marker point positioning model based on the plurality of enhanced images and the plurality of initial images to obtain a target marker point positioning model;
and positioning the mark points in the image to be positioned according to the target mark point positioning model.
2. The marker positioning method of claim 1, wherein the at least one target marker comprises a first target marker and a second target marker; the step of randomly embedding the initial mark points into the initial blank area for a plurality of times to obtain an enhanced image comprises the following steps:
randomly embedding the initial mark points into the initial blank area to obtain the first target mark points, a transition mark point area where the first target mark points are located and a transition blank area;
randomly embedding the initial mark points into the transition blank area to obtain the second target mark points, the first target mark points, the target mark point area where the second target mark points are located and the target blank area.
3. The marker positioning method according to claim 1, wherein the initial marker region is a minimum bounding rectangle of the initial marker.
4. The marker positioning method according to claim 1, wherein the marker positioning method further comprises:
and performing secondary enhancement processing on the initial image and/or the enhanced image, wherein the secondary enhancement processing is at least one of horizontal mirroring, vertical mirroring, sharpening, brightness adjustment, contrast adjustment and Gaussian noise addition.
5. The marker positioning method according to any one of claims 1-4, wherein positioning the marker in the image to be positioned according to the target marker positioning model includes:
determining a plurality of candidate prediction frames in the image to be positioned and scores of the candidate prediction frames in the plurality of candidate prediction frames according to the target mark point positioning model;
and taking the candidate prediction frame with the highest score as the target position of the marking point.
6. The marker positioning method according to claim 1, wherein the plurality of initial images includes a plurality of normal initial images and a plurality of abnormal initial images.
7. The marker positioning method of claim 1, comprising, prior to said training said initial marker positioning model based on said plurality of enhanced images and said plurality of initial images:
scaling the plurality of enhanced images and the plurality of initial images to obtain a plurality of scaled images with preset sizes;
and carrying out normalization processing on each scaled image in the plurality of scaled images to obtain a plurality of normalized images.
8. A marker positioning device, comprising:
an initial image acquisition unit, configured to acquire a plurality of initial images, and determine an initial mark point area and an initial blank area where initial mark points of the plurality of initial images are located;
the image enhancement unit is used for extracting the initial mark points, randomly embedding the initial mark points into the initial blank area according to preset times to obtain a plurality of enhanced images, wherein the enhanced images comprise a target mark point area where at least one target mark point is located and a target blank area;
the positioning model training unit is used for constructing an initial marking point positioning model, training the initial marking point positioning model based on the plurality of enhanced images and the plurality of initial images, and obtaining a target marking point positioning model;
and the marking point positioning unit is used for positioning the marking point in the image to be positioned according to the target marking point positioning model.
9. An image recognition device comprising a memory and a processor, wherein,
the memory is used for storing programs;
the processor is coupled to the memory for executing the program stored in the memory for implementing the steps in the marker point positioning method as set forth in the preceding claims 1 to 7.
10. A computer readable storage medium storing a computer readable program or instructions which when executed by a processor is capable of carrying out the steps of the marker point positioning method as claimed in any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211042195.7A CN116630339A (en) | 2022-08-29 | 2022-08-29 | Marker point positioning method, device, image recognition equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211042195.7A CN116630339A (en) | 2022-08-29 | 2022-08-29 | Marker point positioning method, device, image recognition equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN116630339A true CN116630339A (en) | 2023-08-22 |
Family
ID=87637071
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211042195.7A Pending CN116630339A (en) | 2022-08-29 | 2022-08-29 | Marker point positioning method, device, image recognition equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116630339A (en) |
-
2022
- 2022-08-29 CN CN202211042195.7A patent/CN116630339A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112580623B (en) | Image generation method, model training method, related device and electronic equipment | |
US10303968B2 (en) | Method and apparatus for image recognition | |
CN112418216B (en) | Text detection method in complex natural scene image | |
CN112052850B (en) | License plate recognition method and device, electronic equipment and storage medium | |
CN109685870B (en) | Information labeling method and device, labeling equipment and storage medium | |
CN110008997B (en) | Image texture similarity recognition method, device and computer readable storage medium | |
CN112699775A (en) | Certificate identification method, device and equipment based on deep learning and storage medium | |
CN112560862B (en) | Text recognition method and device and electronic equipment | |
CN110503682B (en) | Rectangular control identification method and device, terminal and storage medium | |
CN112380981A (en) | Face key point detection method and device, storage medium and electronic equipment | |
CN110675940A (en) | Pathological image labeling method and device, computer equipment and storage medium | |
CN112380978B (en) | Multi-face detection method, system and storage medium based on key point positioning | |
CN113490947A (en) | Detection model training method and device, detection model using method and storage medium | |
CN111079571A (en) | Identification card information identification and edge detection model training method and device | |
CN113033543A (en) | Curved text recognition method, device, equipment and medium | |
WO2021143058A1 (en) | Image-based information comparison method, apparatus, electronic device, and computer-readable storage medium | |
CN113361643A (en) | Deep learning-based universal mark identification method, system, equipment and storage medium | |
CN112686176A (en) | Target re-recognition method, model training method, device, equipment and storage medium | |
CN109034032B (en) | Image processing method, apparatus, device and medium | |
CN114494751A (en) | License information identification method, device, equipment and medium | |
CN112906532B (en) | Image processing method and device, electronic equipment and storage medium | |
CN110008960A (en) | A kind of method and terminal detecting character fragments integrality | |
CN116630339A (en) | Marker point positioning method, device, image recognition equipment and storage medium | |
EP4207745A1 (en) | Method for embedding image in video, and method and apparatus for acquiring planar prediction model | |
CN112784737B (en) | Text detection method, system and device combining pixel segmentation and line segment anchor |
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 |