CN113486861A - Moire pattern picture generation method and device - Google Patents

Moire pattern picture generation method and device Download PDF

Info

Publication number
CN113486861A
CN113486861A CN202110888374.1A CN202110888374A CN113486861A CN 113486861 A CN113486861 A CN 113486861A CN 202110888374 A CN202110888374 A CN 202110888374A CN 113486861 A CN113486861 A CN 113486861A
Authority
CN
China
Prior art keywords
moire
image
template
sample
pattern
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.)
Withdrawn
Application number
CN202110888374.1A
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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202110888374.1A priority Critical patent/CN113486861A/en
Publication of CN113486861A publication Critical patent/CN113486861A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Artificial Intelligence (AREA)
  • Software Systems (AREA)
  • Evolutionary Computation (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computing Systems (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Mathematical Physics (AREA)
  • Biophysics (AREA)
  • Molecular Biology (AREA)
  • General Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Biomedical Technology (AREA)
  • Health & Medical Sciences (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Medical Informatics (AREA)
  • Image Analysis (AREA)

Abstract

The invention discloses a Moire pattern image generation method and device, relates to the technical field of artificial intelligence, in particular to the technical field of computer vision and deep learning, and can be applied to scenes such as face recognition, living body detection and the like. The specific implementation scheme is as follows: firstly, a moire template set is obtained, then a moire template is concentrated on the basis of the moire template, a moire combined template is obtained, finally, a sample moire image is generated on the basis of the moire combined template and a sample image, so that the moire combined template can comprise moire in various forms, the diversity of the moire combined template is improved, the sample image is directly converted into the sample moire image by using the moire combined template, the sample moire image can be rapidly and conveniently generated, the obtaining efficiency of the sample moire image is effectively improved, and the obtaining cost of the sample moire image is reduced.

Description

Moire pattern picture generation method and device
Technical Field
The disclosure relates to the technical field of artificial intelligence, in particular to the technical field of computer vision and deep learning, and can be applied to scenes such as face recognition, living body detection and the like.
Background
With the popularization of face recognition systems, people pay more and more attention to the safety performance of the face recognition systems. The living body detection is used as a firewall of the face recognition system, and important safety guarantee is provided for the system. The face copying is one of common attack means of a face recognition system, and an attacker generally copies a face image by using a camera, and Moire lines exist on the copied image. The Moire generated by the copying has the characteristics of complex shape, variable texture and less data volume, so that the interception capability of the living body detection on the copied data with the Moire is obviously reduced, and the safety performance of the face recognition system is seriously influenced.
Disclosure of Invention
The present disclosure provides a moire pattern picture generation method, an image detection model training method, an image detection method, an apparatus, an electronic device, a storage medium, and a computer program product.
According to an aspect of the present disclosure, there is provided a moire pattern picture generating method, including: acquiring a Moire template set; determining a Moire pattern combined template based on the Moire pattern template set Moire pattern template; and generating a sample moire image based on the moire combination template and the sample image.
According to an aspect of the present disclosure, there is provided an image detection model training method, including: acquiring a training sample set, wherein the training sample set comprises a sample moire image, a sample image, an image annotation result corresponding to the sample moire image and an image annotation result corresponding to the sample image, and the sample moire image is acquired based on the moire image generation method; and (3) using a machine learning method, taking the sample Moire pattern image and the sample image as input, taking an image labeling result corresponding to the input image as expected output, and training the initial deep neural network to obtain an image detection model.
According to another aspect of the present disclosure, there is provided an image detection method including: acquiring an image to be detected corresponding to a target object; and inputting the image to be detected into an image detection model to obtain a detection result of the image to be detected, wherein the image detection model is obtained based on the image detection model training method.
According to another aspect of the present disclosure, there is provided a moire pattern picture generating apparatus including: an acquisition module configured to acquire a Moire pattern template set; a determination module configured to determine a moir e combination template based on the moir e template set of moir e templates; a generation module configured to generate a sample moire image based on the moire combination template and the sample image.
According to an aspect of the present disclosure, there is provided an image detection model training apparatus including: the acquisition module is configured to acquire a training sample set, wherein the training sample set comprises a sample moire image, a sample image, an image annotation result corresponding to the sample moire image and an image annotation result corresponding to the sample image, and the sample moire image is acquired based on the moire image generation method; and the acquisition module is configured to utilize a machine learning method, take the sample Moire image and the sample image as input, take an image labeling result corresponding to the input image as expected output, train the initial deep neural network and obtain an image detection model.
According to another aspect of the present disclosure, there is provided an image detection apparatus including: the acquisition module is configured to acquire an image to be detected corresponding to the target object; and the generating module is configured to input the image to be detected into the image detection model to obtain the detection result of the image to be detected, wherein the image detection model is obtained based on the image detection model training method.
According to another aspect of the present disclosure, there is provided an electronic device comprising at least one processor; and a memory communicatively coupled to the at least one processor; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the moire pattern picture generation method, the image detection model training method and the image detection method.
According to another aspect of the present disclosure, a computer-readable medium is provided, on which computer instructions are stored, the computer instructions being used for enabling a computer to execute the moire pattern generation method, the image detection model training method and the image detection method.
According to another aspect of the present disclosure, a computer program product is provided, which includes a computer program, and when the computer program is executed by a processor, the computer program implements the moire pattern generation method, the image detection model training method, and the image detection method.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not to be construed as limiting the present disclosure. Wherein:
FIG. 1 is a flow diagram of one embodiment of a moire pattern picture generation method in accordance with the present disclosure;
FIG. 2 is a schematic diagram of an application scenario of a Moire pattern picture generation method according to the present disclosure;
FIG. 3 is a flow diagram for one embodiment of obtaining a Moire template set according to the present disclosure;
FIG. 4 is a flow diagram for one embodiment of determining a moir e combination template according to the present disclosure;
FIG. 5 is a flow diagram for one embodiment of an image detection model training method according to the present disclosure;
FIG. 6 is a flow diagram for one embodiment of an image detection method according to the present disclosure;
FIG. 7 is a schematic structural diagram of one embodiment of a moir e picture generation apparatus according to the present disclosure;
FIG. 8 is a schematic diagram of an embodiment of an image detection model training apparatus according to the present disclosure;
FIG. 9 is a schematic block diagram of one embodiment of an image detection apparatus according to the present disclosure;
fig. 10 is a block diagram of an electronic device for implementing the moire pattern picture generation method, the image detection model training method, and the image detection method according to the embodiment of the present disclosure.
Detailed Description
Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, in which various details of the embodiments of the disclosure are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Referring to fig. 1, fig. 1 shows a schematic flow diagram 100 of an embodiment of a moir e picture generation method that may be applied to the present disclosure. The method for generating the Moire pattern picture comprises the following steps of:
and step 110, acquiring a Moire pattern template set.
In this embodiment, an execution main body (for example, a server) of the moire image generation method may locally read or obtain a moire template set from other terminal devices, where the moire template set may include a plurality of different moire templates, each moire template has moire patterns with different shapes, and the plurality of moire templates in the moire template set may be arranged according to a preset sequence, where the preset sequence may be an arrangement sequence preset by an operator, and may be a time sequence, a similarity between the moire templates, a complexity of a moire pattern shape, and the like.
Moire is a high frequency interference fringe on a light-sensitive element of a digital camera or scanner, which is a high frequency irregular fringe that causes a picture to appear in color. Moire patterns are irregular and therefore do not have a distinct shape regularity. When a digital image is photographed, if a texture of a fine grain is present in a photographed object, streaks such as a water wave and an abnormal color, that is, moire fringes often occur. Or when a detailed pattern on the object is, for example: this may occur when the texture or image on the garment contains very close parallel lines that overlap the pattern of the photosensitive element on the image sensor.
And step 120, based on the Moire template, concentrating the Moire templates, and determining a Moire combination template.
In this embodiment, after the execution main body obtains the moire template set, the moire template set is analyzed, and a moire template meeting a preset condition may be selected from the moire template set, where the preset condition may be a selection condition preset by an operator, the preset condition may be a selection condition selected according to an arrangement sequence, or the preset condition may be a selection condition that a plurality of adjacent moire templates are selected by sampling the moire template set at intervals, and the like, and the disclosure does not specifically limit this.
After the execution main body obtains a plurality of Moire templates in the Moire template set through a plurality of selection means, corresponding Moire patterns in all the obtained Moire templates are combined to obtain a Moire combined template, wherein the Moire patterns in the Moire combined template are obtained by combining the corresponding Moire patterns in the Moire templates and are fused with Moire patterns in a plurality of forms; the execution main body can also combine the mole patterns corresponding to any number of mole pattern templates in the mole pattern templates to obtain a mole pattern combination template, so that a plurality of different mole pattern combination templates can be obtained, and each mole pattern combination template has different and fused mole patterns.
As an example, if the moire template set includes a moire template a, a moire template B, a moire template C, a moire template D, a moire template F, and a moire template E, the execution main body samples the moire template set to obtain the moire template a, the moire template C, and the moire template F, and then the execution main body combines the three moire templates, i.e., the moire template a, the moire template C, and the moire template F, to obtain a combined moire, i.e., to obtain a moire combined template; the execution main body may further combine the moire template a and the moire template C to obtain one moire combination template, or combine the moire template a and the moire template F to obtain another moire combination template, or combine the moire template C and the moire template F to obtain another moire combination template.
And step 130, generating a sample moire image based on the moire combination template and the sample image.
In this embodiment, after the execution subject acquires the moire pattern combination template, a sample image to be converted is further acquired, where the sample image may be an original image including the target object. The execution main body can adjust the size of the moire pattern combination template according to the size of the sample image, and attach the adjusted moire pattern combination template and the sample image to generate the sample moire pattern image, wherein the sample moire pattern image is an image with moire patterns. The execution subject can also execute one or more of data expansion operation, filter operation, brightness and color adjustment operation, direction adjustment operation, compression operation and distortion operation on the sample moire image to obtain more and different sample moire images.
The execution body may use a Hadamard product to complete the attaching operation between the moire pattern combining template and the sample image, and may be:
xidmoire=xid⊙xm
wherein x isidRepresenting a sample image, xmIndicates a Moire pattern combination template, which indicates a Hadamard product.
With continuing reference to fig. 2, fig. 2 is a schematic diagram of an application scenario of the moire pattern picture generation method according to the present embodiment. In the application scenario of fig. 2, the server 201 reads from the local storage to obtain a moire template set, where the moire template set includes a plurality of moire templates. Then, the execution main body may collect a plurality of different moire templates based on the moire template to obtain a moire pattern combination template, and the moire pattern combination template may be obtained by combining a plurality of different moire patterns. And finally, the execution subject can directly input the sample image into the moire pattern combination template based on the moire pattern combination template and the sample image to generate the sample moire pattern image.
The moire pattern image generation method provided by the embodiment of the disclosure obtains the moire pattern template set, then, based on the Moire template, collecting the Moire template to obtain a Moire combined template, finally, based on the Moire combined template and the sample image, generating a sample Moire image, based on the Moire template, collecting the Moire template and combining the Moire template to obtain the Moire combined template, the Moire pattern combined template can comprise Moire patterns with various forms, the diversity of the Moire pattern combined template is improved, meanwhile, the Moire pattern combination template is directly utilized to convert the sample image into the sample Moire pattern image, the sample Moire pattern image can be rapidly and conveniently generated without manual participation, the acquisition efficiency of the sample Moire pattern image is effectively improved, the acquisition cost of the sample Moire pattern image is reduced, and the diversity of the Moire pattern image of the sample is improved, so that the accuracy and the universality of the image detection model detection image can be improved.
Referring to fig. 3, fig. 3 shows a flowchart 300 of an embodiment of obtaining a moire template set, i.e. the step 110, obtaining a moire template set, which may include the following steps:
at step 310, a Moire pattern image set is obtained.
In this embodiment, the execution subject may obtain moire images with a single background color and different forms from the network by means of a crawler or the like, and may also receive moire images with a single background color and different forms from other terminal devices. The execution body may arrange the acquired moire images with a single background color and different forms according to the acquisition time sequence or the shooting time sequence, so as to form a moire image set.
And 320, carrying out image processing on the Moire image in the Moire image set to obtain a Moire template corresponding to each Moire image.
In this embodiment, after the execution subject acquires the moire image set, image processing may be performed on each moire image in the moire image set by using an image processing method, where the image processing method may include image correction, image filtering, image graying, image enhancement, and the like. The execution main body can respectively perform moire extraction on the processed moire images through various extraction modes to obtain moire corresponding to each processed moire image, and determine a corresponding moire template according to the moire corresponding to each processed moire image.
For example, the execution body may input the processed moire image into a moire template generation model, and the moire template generation model may perform moire extraction and processing on the input moire image and output a moire template corresponding to the moire image, so that the execution body may acquire a moire template corresponding to each moire image from each moire image and the moire template generation model.
The moire pattern template generation model can be obtained based on the following steps:
the method comprises the following steps of firstly, obtaining a training sample set, wherein training samples in the training sample set comprise sample moire images and sample moire templates corresponding to the sample moire images.
And secondly, training the initial deep neural network by using a machine learning algorithm and taking the sample moire image as input data and a sample moire template corresponding to the input sample moire image as expected output data to obtain a moire template generation model.
And 330, forming a Moire template set by the Moire templates corresponding to each Moire image.
In this embodiment, after the execution subject acquires the moire template corresponding to each moire image, the moire templates corresponding to each moire image may be arranged according to an arrangement order, a time order, a similarity between the moire templates, a moire shape complexity, and the like of the moire images to form a moire template set.
In this implementation, the mole pattern template set is obtained by directly grabbing mole pattern images with different shapes from the internet, so that the mole pattern template set can contain relatively diversified mole pattern templates, the problem of manually acquiring data is avoided, and the diversity and the acquisition efficiency of the mole pattern template are improved.
Referring to fig. 4, fig. 4 shows a flowchart 400 of an embodiment of determining a moire pattern combining template, i.e. the step 120, which is described above, and determines a moire pattern combining template based on a moire pattern template in a moire pattern template set, and may include the following steps:
step 410, selecting a preset number of moire templates from the moire template set.
In this embodiment, after the execution main body obtains the moire template set, each moire template in the moire template set may be analyzed, and a preset number of moire templates is selected from the moire template set, where the preset number is a number greater than one, and may be 2, 3, 4, and the like, and this disclosure does not specifically limit this.
The execution main body obtains a plurality of Moire templates in the Moire template set through a plurality of selection means, and the Moire templates can be selected according to the arrangement sequence of the Moire templates, and a preset number of Moire templates are selected each time; or, a sampling interval may be set in advance, and the moire templates in the moire template set are sampled by using the sampling interval to obtain a preset number of moire templates, and the like.
As an example, if the preset sampling interval is set to 1 and the preset number is 3, the moire template set includes moire template a, moire template B, moire template C, moire template D, moire template F, and moire template E, and the execution subject samples the moire template set based on the sampling interval to obtain moire template a, moire template C, and moire template F.
And 420, performing linear combination on a preset number of moire pattern templates to determine a moire pattern combination template.
In this embodiment, after the execution main body obtains the preset number of moire templates, the moire templates in the preset number of moire templates may be combined to obtain a moire combined template with a plurality of moire combinations. The execution body may linearly combine a preset number of moire patterns, which may be specifically represented by the following formula:
Figure BDA0003195038320000081
wherein the content of the first and second substances,
Figure BDA0003195038320000082
wherein x ismDenotes a Moire pattern template, lambdaiThe combination coefficient is represented by a combination coefficient,
Figure BDA0003195038320000083
and K represents the ith Moire template to be combined in the Moire template set, and K represents the preset number.
In the implementation mode, the moire pattern combination template is obtained by combining the moire pattern templates, so that the moire pattern combination template can comprise moire patterns in various forms, the diversity of the moire pattern combination template is improved, and the defects that the moire pattern obtained by a manual acquisition scheme is single and the textures are limited are overcome.
As an optional implementation manner, the moire image generation method may further include the following steps: in response to obtaining the moir e composite template, adding the moir e composite template to the set of moir e templates.
Specifically, after the execution main body acquires the moire pattern combination template, the acquired moire pattern combination template may be further added to the moire pattern template set again.
In this implementation, by adding the moir e composite template to the moir e template set again, the diversity of the moir e template set moir pattern templates is improved, thereby improving the diversity of the moir pattern composite template.
Referring to FIG. 5, FIG. 5 shows a flow diagram 500 of one embodiment of an image detection model training method that may include the steps of:
step 510, a training sample set is obtained.
In this embodiment, the execution subject may obtain the moire image of the sample according to the moire image generation method shown in fig. 1 to 4, that is, after obtaining a plurality of different moire images of the sample based on different moire combination templates and sample images, annotate the moire image of each sample to obtain an image annotation result of the moire image of each sample, and the execution subject may also annotate the sample image to obtain an image annotation result of the moire image of the sample.
And after the execution main body obtains the image annotation result of each sample moire pattern image and each sample moire pattern image, and the image annotation result of the sample image and the sample image, taking the sample moire pattern image, the sample image, the image annotation result corresponding to the sample moire pattern image and the image annotation result corresponding to the sample image as a training sample set used for training the initial deep neural network.
And step 520, taking the sample Moire pattern image and the sample image as input, taking an image labeling result corresponding to the input image as expected output, and training the initial deep neural network to obtain an image detection model by using a machine learning method.
In this embodiment, after the execution subject obtains the training sample set, an initial deep neural network is obtained. The execution subject can train the initial deep neural network based on the training sample set by using a machine learning method to obtain an image detection model.
Specifically, the executing entity may respectively take the sample moire image and the sample image as inputs, and obtain corresponding prediction information through processing by an initial deep neural network, where the initial deep neural network may be any existing neural network.
And if the prediction information does not meet the constraint condition, adjusting the network parameters of the initial deep neural network, and inputting the sample Moire image and the sample image again for continuous training. And if the prediction information meets the constraint condition, finishing the model training to obtain the image detection model. The constraint condition may be that a difference between the prediction information and the image labeling result satisfies a preset threshold, where the preset threshold may be preset according to experience, and this disclosure does not specifically limit this.
In this embodiment, an initial deep neural network is trained through an obtained sample moire pattern image to obtain an image detection model, so that the obtaining efficiency of the sample moire pattern image is improved, the obtaining cost of the sample moire pattern image is reduced, the diversity of the sample moire pattern image is improved, the accuracy and the universality of the image detection model for detecting the image can be improved, the interception capability of the model for moire pattern copying data is improved, and the interception capability of in-vivo detection for the moire pattern copying data is further improved.
Referring to FIG. 6, FIG. 6 shows a flow diagram 600 of one embodiment of an image detection method that may include the steps of:
step 610, acquiring an image to be detected corresponding to the target object.
In this embodiment, the execution main body may acquire an image to be detected corresponding to the target object, where the image to be detected may be a target image corresponding to the target object, and may also acquire different moire images based on different moire combination templates and the target image.
And step 620, inputting the image to be detected into the image detection model to obtain a detection result of the image to be detected.
In this embodiment, after the execution main body obtains the image to be detected, the image to be detected may be input into an image detection model, the image detection model processes the image to be detected, and outputs a detection result corresponding to the image to be detected, where the detection result can represent whether the image to be detected is a target image corresponding to a target object.
As an example, if the image to be detected is a target image, the image detection model processes the target image and outputs a detection result corresponding to the target image and representing the image to be detected as the target image. If the image to be detected is a moire image, the image detection model processes the moire image and outputs a detection result which corresponds to the moire image and represents that the image to be detected is the moire image.
The image detection model is obtained based on the image detection model training method, that is, the image detection model can be obtained based on the steps in fig. 5, and the image detection model can detect various different moire images and target images.
In this embodiment, through the image detection model detection waiting to detect the image, can improve the detection efficiency and the accuracy of waiting to detect the image, can detect multiple mole line image and target image, improve the variety and the precision that the image detected.
With further reference to fig. 7, as an implementation of the methods shown in the above-mentioned figures, the present disclosure provides an embodiment of a moire pattern image generation apparatus, which corresponds to the embodiment of the method shown in fig. 1, and which is particularly applicable to various electronic devices.
As shown in fig. 7, the moire pattern picture generation apparatus 700 of the present embodiment includes: an acquisition module 710, a determination module 720 and a generation module 730.
Wherein, the obtaining module 710 is configured to obtain a moire pattern template set;
a determining module 720 configured to determine a moire combining template based on the moire template in the moire template set;
a generating module 730 configured to generate a sample moire image based on the moire combining template and the sample image.
In some optional aspects of this embodiment, the obtaining module 710 is further configured to: acquiring a Moire image set; carrying out image processing on the Moire image in the Moire image set to obtain a Moire template corresponding to each Moire image; and (4) forming a Moire template set by the Moire template corresponding to each Moire image.
In some alternatives of this embodiment, the determining module 720 is further configured to: selecting a preset number of Moire templates from the Moire template set; and linearly combining a preset number of moire pattern templates to determine a moire pattern combined template.
In some optional manners of this embodiment, the apparatus further includes: an add module configured to: in response to obtaining the moir e composite template, adding the moir e composite template to the set of moir e templates.
The moire pattern image generation device provided by the embodiment of the disclosure obtains the moire pattern template set, then, based on the Moire template, collecting the Moire template to obtain a Moire combined template, finally, based on the Moire combined template and the sample image, generating a sample Moire image, based on the Moire template, collecting the Moire template and combining the Moire template to obtain the Moire combined template, the Moire pattern combined template can comprise Moire patterns with various forms, the diversity of the Moire pattern combined template is improved, meanwhile, the Moire pattern combination template is directly utilized to convert the sample image into the sample Moire pattern image, the sample Moire pattern image can be rapidly and conveniently generated without manual participation, the acquisition efficiency of the sample Moire pattern image is effectively improved, the acquisition cost of the sample Moire pattern image is reduced, and the diversity of the Moire pattern image of the sample is improved, so that the accuracy and the universality of the image detection model detection image can be improved.
With further reference to fig. 8, as an implementation of the methods shown in the above-mentioned figures, the present disclosure provides an embodiment of an image detection model training apparatus, which corresponds to the method embodiment shown in fig. 5, and which can be applied in various electronic devices.
As shown in fig. 8, the image detection model training apparatus 800 of the present embodiment includes: an acquisition module 810 and a training module 820.
The obtaining module 810 is configured to obtain a training sample set, where the training sample set includes a sample moire image, a sample image, an image labeling result corresponding to the sample moire image, and an image labeling result corresponding to the sample image, where the sample moire image is obtained based on the method of any one of claims 1 to 4;
and a training module 820 configured to train the initial deep neural network by using a machine learning method, taking the sample moire image and the sample image as inputs, taking an image labeling result corresponding to the input image as an expected output, and obtaining an image detection model.
The image detection model training device provided by the embodiment of the disclosure trains the initial depth neural network through the acquired sample moire pattern image to obtain an image detection model, improves the acquisition efficiency of the sample moire pattern image, reduces the acquisition cost of the sample moire pattern image, and improves the diversity of the sample moire pattern image, thereby improving the accuracy and the universality of the image detection model detection image, improving the interception capability of the model on moire pattern reproduction data, and further improving the interception capability of in vivo detection on reproduction data with moire patterns.
With further reference to fig. 9, as an implementation of the methods shown in the above figures, the present disclosure provides an embodiment of an image detection apparatus, which corresponds to the method embodiment shown in fig. 6, and which is particularly applicable in various electronic devices.
As shown in fig. 9, the image detection apparatus 900 of the present embodiment includes: an acquisition module 910 and a generation module 920.
The acquiring module 910 is configured to acquire an image to be detected corresponding to a target object;
a generating module 920 configured to input the image to be detected into an image detection model to obtain a detection result of the image to be detected, wherein the image detection model is obtained based on the method of claim 5.
The embodiment of the disclosure provides an image detection device, through image detection model detection waiting to detect the image, can improve the detection efficiency and the accuracy of waiting to detect the image, can detect multiple mole line image and target image, improve the variety and the precision that image detection detected.
In the technical scheme of the disclosure, the acquisition, storage, application and the like of the personal information of the related user all accord with the regulations of related laws and regulations, and do not violate the good customs of the public order.
The present disclosure also provides an electronic device, a readable storage medium, and a computer program product according to embodiments of the present disclosure.
FIG. 10 illustrates a schematic block diagram of an example electronic device 1000 that can be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 10, the electronic device 1000 includes a computing unit 1001 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM)1002 or a computer program loaded from a storage unit 1008 into a Random Access Memory (RAM) 1003. In the RAM 1003, various programs and data necessary for the operation of the device 1000 can also be stored. The calculation unit 1001, the ROM 1002, and the RAM 1003 are connected to each other by a bus 1004. An input/output (I/O) interface 1005 is also connected to bus 1004.
A number of components in the electronic device 1000 are connected to the I/O interface 1005, including: an input unit 1006 such as a keyboard, a mouse, and the like; an output unit 1007 such as various types of displays, speakers, and the like; a storage unit 1008 such as a magnetic disk, an optical disk, or the like; and a communication unit 1009 such as a network card, a modem, a wireless communication transceiver, or the like. The communication unit 1009 allows the device 1000 to exchange information/data with other devices through a computer network such as the internet and/or various telecommunication networks.
Computing unit 1001 may be a variety of general and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 1001 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The calculation unit 1001 executes the respective methods and processes described above, such as the moire pattern picture generation method, the image detection model training method, or the image detection method. For example, in some embodiments, the moire pattern generation method, the image detection model training method, or the image detection method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 1008. In some embodiments, part or all of the computer program may be loaded and/or installed onto device 1000 via ROM 1002 and/or communications unit 1009. When the computer program is loaded into the RAM 1003 and executed by the computing unit 1001, one or more steps of the moire pattern picture generation method, the image detection model training method, or the image detection method described above may be performed. Alternatively, in other embodiments, the computing unit 1001 may be configured to perform the moire pattern picture generation method, the image detection model training method, or the image detection method by any other suitable means (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server may be a cloud server, a server of a distributed system, or a server with a combined blockchain.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and the present disclosure is not limited herein.
The above detailed description should not be construed as limiting the scope of the disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present disclosure should be included in the scope of protection of the present disclosure.

Claims (15)

1. A moire pattern picture generation method comprises the following steps:
acquiring a Moire template set;
determining a Moire pattern combined template based on the Moire pattern template set Moire pattern template;
and generating a sample moire image based on the moire combination template and the sample image.
2. The method of claim 1, wherein the obtaining a moire template set comprises:
acquiring a Moire image set;
carrying out image processing on the Moire image in the Moire image set to obtain a Moire template corresponding to each Moire image;
and combining the Moire templates corresponding to each Moire image into the Moire template set.
3. The method of claim 1, wherein determining a moir e combination template based on the moir e template set of moir e templates comprises:
selecting a preset number of Moire templates from the Moire template set;
and linearly combining the mole pattern templates with the preset number to determine the mole pattern combined template.
4. The method of claim 1, wherein the method further comprises:
in response to obtaining the moire pattern combination template, adding the moire pattern combination template to the moire pattern template set.
5. An image detection model training method comprises the following steps:
acquiring a training sample set, wherein the training sample set comprises a sample moire image, a sample image, an image labeling result corresponding to the sample moire image and an image labeling result corresponding to the sample image, and the sample moire image is acquired based on the method of any one of claims 1 to 4;
and using a machine learning method to input the sample Moire image and the sample image, using an image labeling result corresponding to the input image as expected output, and training the initial deep neural network to obtain an image detection model.
6. An image detection method, comprising:
acquiring an image to be detected corresponding to a target object;
inputting the image to be detected into an image detection model to obtain a detection result of the image to be detected, wherein the image detection model is obtained based on the method of claim 5.
7. A moire pattern picture generating apparatus comprising:
an acquisition module configured to acquire a Moire pattern template set;
a determination module configured to determine a moir e combination template based on the moir e template in the set of moir patterns templates;
a generation module configured to generate a sample moire image based on the moire combination template and the sample image.
8. The apparatus of claim 7, wherein the acquisition module is further configured to:
acquiring a Moire image set;
carrying out image processing on the Moire image in the Moire image set to obtain a Moire template corresponding to each Moire image;
and combining the Moire templates corresponding to each Moire image into the Moire template set.
9. The apparatus of claim 7, wherein the determination module is further configured to:
selecting a preset number of Moire templates from the Moire template set;
and linearly combining the mole pattern templates with the preset number to determine the mole pattern combined template.
10. The apparatus of claim 7, wherein the apparatus further comprises:
an add module configured to: in response to obtaining the moire pattern combination template, adding the moire pattern combination template to the moire pattern template set.
11. An image detection model training apparatus comprising:
an obtaining module, configured to obtain a training sample set, where the training sample set includes a sample moire image, a sample image, an image labeling result corresponding to the sample moire image, and an image labeling result corresponding to the sample image, where the sample moire image is obtained based on the method of any one of claims 1 to 4;
and the training module is configured to utilize a machine learning method, take the sample Moire image and the sample image as input, take an image labeling result corresponding to the input image as expected output, train the initial deep neural network and obtain an image detection model.
12. An image detection apparatus comprising:
the acquisition module is configured to acquire an image to be detected corresponding to the target object;
a generating module configured to input the image to be detected into an image detection model to obtain a detection result of the image to be detected, wherein the image detection model is obtained based on the method of claim 5.
13. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-6.
14. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of any one of claims 1-6.
15. A computer program product comprising a computer program which, when executed by a processor, implements the method according to any one of claims 1-6.
CN202110888374.1A 2021-08-03 2021-08-03 Moire pattern picture generation method and device Withdrawn CN113486861A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110888374.1A CN113486861A (en) 2021-08-03 2021-08-03 Moire pattern picture generation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110888374.1A CN113486861A (en) 2021-08-03 2021-08-03 Moire pattern picture generation method and device

Publications (1)

Publication Number Publication Date
CN113486861A true CN113486861A (en) 2021-10-08

Family

ID=77945417

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110888374.1A Withdrawn CN113486861A (en) 2021-08-03 2021-08-03 Moire pattern picture generation method and device

Country Status (1)

Country Link
CN (1) CN113486861A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117291857A (en) * 2023-11-27 2023-12-26 武汉精立电子技术有限公司 Image processing method, moire eliminating equipment and moire eliminating device
CN117333762A (en) * 2023-12-02 2024-01-02 深圳爱莫科技有限公司 Image reproduction identification method based on multi-feature fusion

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012235430A (en) * 2011-05-09 2012-11-29 Konica Minolta Business Technologies Inc Image processor, image processing method and image processing program
CN109558794A (en) * 2018-10-17 2019-04-02 平安科技(深圳)有限公司 Image-recognizing method, device, equipment and storage medium based on moire fringes
CN110059700A (en) * 2019-03-18 2019-07-26 深圳神目信息技术有限公司 The recognition methods of image moire fringes, device, computer equipment and storage medium
CN110992244A (en) * 2019-10-31 2020-04-10 上海扩博智能技术有限公司 Picture generation method, system, equipment and storage medium with Moire patterns
CN111476737A (en) * 2020-04-15 2020-07-31 腾讯科技(深圳)有限公司 Image processing method, intelligent device and computer readable storage medium
CN112562028A (en) * 2020-12-03 2021-03-26 科大讯飞股份有限公司 Method, device and equipment for constructing image with moire fringes and storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012235430A (en) * 2011-05-09 2012-11-29 Konica Minolta Business Technologies Inc Image processor, image processing method and image processing program
CN109558794A (en) * 2018-10-17 2019-04-02 平安科技(深圳)有限公司 Image-recognizing method, device, equipment and storage medium based on moire fringes
CN110059700A (en) * 2019-03-18 2019-07-26 深圳神目信息技术有限公司 The recognition methods of image moire fringes, device, computer equipment and storage medium
CN110992244A (en) * 2019-10-31 2020-04-10 上海扩博智能技术有限公司 Picture generation method, system, equipment and storage medium with Moire patterns
CN111476737A (en) * 2020-04-15 2020-07-31 腾讯科技(深圳)有限公司 Image processing method, intelligent device and computer readable storage medium
CN112562028A (en) * 2020-12-03 2021-03-26 科大讯飞股份有限公司 Method, device and equipment for constructing image with moire fringes and storage medium

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117291857A (en) * 2023-11-27 2023-12-26 武汉精立电子技术有限公司 Image processing method, moire eliminating equipment and moire eliminating device
CN117291857B (en) * 2023-11-27 2024-03-22 武汉精立电子技术有限公司 Image processing method, moire eliminating equipment and moire eliminating device
CN117333762A (en) * 2023-12-02 2024-01-02 深圳爱莫科技有限公司 Image reproduction identification method based on multi-feature fusion
CN117333762B (en) * 2023-12-02 2024-03-15 深圳爱莫科技有限公司 Image reproduction identification method based on multi-feature fusion

Similar Documents

Publication Publication Date Title
CN113486861A (en) Moire pattern picture generation method and device
CN110929564B (en) Fingerprint model generation method and related device based on countermeasure network
CN112862877A (en) Method and apparatus for training image processing network and image processing
CN113869429A (en) Model training method and image processing method
CN114360074A (en) Training method of detection model, living body detection method, apparatus, device and medium
CN104636743B (en) Method and device for correcting character image
CN113569708A (en) Living body recognition method, living body recognition device, electronic apparatus, and storage medium
CN113158773B (en) Training method and training device for living body detection model
CN114445663A (en) Method, apparatus and computer program product for detecting challenge samples
CN113569707A (en) Living body detection method, living body detection device, electronic apparatus, and storage medium
CN113705381A (en) Target detection method and device in foggy days, electronic equipment and storage medium
CN115205163B (en) Method, device and equipment for processing identification image and storage medium
US11468269B2 (en) Arithmetic device, arithmetic method, and discrimination system
CN110555799A (en) Method and apparatus for processing video
CN114415997B (en) Display parameter setting method and device, electronic equipment and storage medium
CN115660991A (en) Model training method, image exposure correction method, device, equipment and medium
CN115019057A (en) Image feature extraction model determining method and device and image identification method and device
CN116310615A (en) Image processing method, device, equipment and medium
CN114037630A (en) Model training and image defogging method, device, equipment and storage medium
CN113920023A (en) Image processing method and device, computer readable medium and electronic device
CN113344064A (en) Event processing method and device
CN112991451A (en) Image recognition method, related device and computer program product
CN116134476A (en) Plane correction method and device, computer readable medium and electronic equipment
CN115361584B (en) Video data processing method and device, electronic equipment and readable storage medium
CN113312979B (en) Image processing method and device, electronic equipment, road side equipment and cloud control platform

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
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20211008