WO2019041406A1 - Indecent picture recognition method, terminal and device, and computer-readable storage medium - Google Patents

Indecent picture recognition method, terminal and device, and computer-readable storage medium Download PDF

Info

Publication number
WO2019041406A1
WO2019041406A1 PCT/CN2017/102866 CN2017102866W WO2019041406A1 WO 2019041406 A1 WO2019041406 A1 WO 2019041406A1 CN 2017102866 W CN2017102866 W CN 2017102866W WO 2019041406 A1 WO2019041406 A1 WO 2019041406A1
Authority
WO
WIPO (PCT)
Prior art keywords
preset
picture
tested
confidence
error
Prior art date
Application number
PCT/CN2017/102866
Other languages
French (fr)
Chinese (zh)
Inventor
王健宗
石磊
黄章成
肖京
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2019041406A1 publication Critical patent/WO2019041406A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/20Scenes; Scene-specific elements in augmented reality scenes
    • 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

Definitions

  • the present invention relates to the field of computer technologies, and in particular, to an indecent picture recognition method based on a convolutional neural network, a terminal, a device, and a computer readable storage medium.
  • Embodiments of the present invention provide an indecent picture recognition method, a terminal, a device, and a computer readable storage medium based on a convolutional neural network, which can automatically analyze an input picture and classify and identify the picture, thereby greatly improving the accuracy of the yellowing. Reduce the cost of yellowing.
  • an embodiment of the present invention provides an indecent picture recognition method based on a convolutional neural network, the method comprising:
  • the pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
  • the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
  • the picture data to be tested is determined to be indecent picture data.
  • an embodiment of the present invention further provides an indecent picture recognition terminal based on a convolutional neural network, where the terminal includes:
  • a pre-processing unit configured to perform pre-processing on the acquired image data to be tested
  • a detecting unit configured to separately input the pre-processed picture data to be input into multiple preset detection models to correspondingly obtain a plurality of different confidence levels
  • a confidence calculation unit configured to calculate all confidence levels according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, and the ratio of the ratios
  • the preset linear weighting ratio includes a plurality of ratios, and the ratio of the ratios
  • a determining unit configured to determine whether the picture confidence is greater than a preset reliability
  • the determining unit is configured to determine that the picture data to be tested is indecent picture data if the picture confidence is greater than a preset reliability.
  • an embodiment of the present invention further provides an indecent picture recognition device based on a convolutional neural network, the device comprising:
  • a memory for storing a program that implements indecent picture recognition
  • a processor for running a program for realizing indecent picture recognition stored in the memory to perform the following operations:
  • the pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
  • the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
  • the picture data to be tested is determined to be indecent picture data.
  • an embodiment of the present invention further provides a computer readable storage medium storing one or more programs, the one or more programs being executable by one or more processors Execute to implement the following steps:
  • the pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
  • the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
  • the picture data to be tested is determined to be indecent picture data.
  • the present invention has the following beneficial effects: the embodiment of the present invention performs pre-processing on the acquired image data to be tested; and inputs the pre-processed image data to be input into multiple preset detection models to obtain correspondingly a different confidence; calculating all the confidences according to the preset linear weighting ratio to obtain a picture confidence; if the picture confidence is greater than the preset reliability, determining that the picture data to be tested is an indecent picture Data, automatically analyze the input picture to be tested and classify and identify the picture, which greatly improves the accuracy of the yellowing and reduces the cost of the yellowing.
  • the multiple training and verification of the convolutional neural network can further reduce the error. And improve the recognition accuracy of the obtained detection model.
  • FIG. 1 is a schematic flow chart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention
  • FIG. 2 is another schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention
  • FIG. 3 is another schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention
  • FIG. 4 is another schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention
  • FIG. 5 is a schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to another embodiment of the present invention.
  • FIG. 6 is a schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention.
  • FIG. 7 is another schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention.
  • FIG. 8 is another schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention.
  • FIG. 9 is another schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention.
  • FIG. 10 is a schematic structural diagram of an indecent picture recognition device based on a convolutional neural network according to an embodiment of the present invention.
  • FIG. 1 is a schematic flow chart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention.
  • the method can be run on terminals such as smart phones (such as Android phones, IOS phones, etc.), tablets, laptops, and smart devices.
  • the method of the invention can automatically analyze the input picture to be tested and classify and identify the picture, thereby greatly improving the accuracy of the yellowing and reducing the cost of the yellowing.
  • the method includes steps S101 to S105.
  • S101 Perform pre-processing on the acquired picture data to be tested.
  • the picture data to be tested may be a regular picture, or may be a picture obtained by extracting a video key frame from the video data.
  • the picture data to be measured may be a regular picture, or may be a picture obtained by extracting a video key frame from the video data.
  • step S101 includes steps S201 to S202.
  • S201 Perform feature enhancement on the acquired image data to be tested.
  • step S201 includes steps S301 to S303.
  • all preset picture data can be adjusted to 256*256 RGB pictures.
  • the used pictures must also be RGB pictures of the same format. That is to say, the acquired image data to be tested needs to be adjusted to 256*256 RGB pictures.
  • the image data to be tested after the feature enhancement corresponding to the image data to be measured adjusted to the RGB image can be obtained.
  • the feature-enhanced picture data to be tested is divided according to a preset rule to obtain one or more sub-pictures.
  • each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
  • the image data to be tested after feature enhancement may be divided into one or more sub-pictures of 224*224.
  • it may be divided into one or more sub-pictures of other sizes according to actual conditions, so that To better extract features and reduce the interference of incoherent features.
  • all the preset picture data are correspondingly processed correspondingly, thereby increasing the number of trained picture data and further improving the accuracy of the subsequent detection model.
  • S102 Input the pre-processed picture data to be tested into multiple preset detection models to correspondingly obtain a plurality of different confidence levels.
  • the pre-processed picture data to be tested is input to each preset detection model, so that each preset detection model can obtain a confidence level.
  • the preset linear weighting ratio may be obtained by training the related algorithm, or obtaining the optimal linear weighting ratio according to the method of repeated experiments. For example, it is possible to comprehensively analyze the confidence obtained in each detection model for a plurality of indecent images, and then confirm an optimal linear weighting ratio.
  • the linear weighting ratio can be chosen to be 1:1, that is, the two confidence levels of the two detection models are each half, so that the final image confidence is obtained.
  • the picture confidence is not greater than the preset reliability, it is known that the picture data to be tested is normal picture data.
  • the preset reliability can be set correspondingly according to actual conditions. For example, when the pre-set reliability is 0.8, if the picture confidence is less than or equal to 0.8, the picture data to be tested is normal picture data.
  • the picture data to be tested when the picture confidence is greater than the preset reliability, the picture data to be tested may be known as indecent picture data.
  • the pre-set reliability is 0.8
  • the picture confidence is greater than 0.8
  • the picture data to be tested is indecent picture data.
  • the obtained image data to be tested is preprocessed; the preprocessed image data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels; Setting a linear weighting ratio to calculate all the confidence levels to obtain a picture confidence; if the picture confidence is greater than the pre-set reliability, determining that the picture data to be tested is indecent picture data, the input image can be automatically analyzed and Classification and identification of images greatly improve the accuracy of yellowing and reduce the cost of yellowing.
  • multiple training and verification of convolutional neural networks can further reduce errors and improve the recognition accuracy of the resulting detection models. .
  • step S101 in the method for identifying indecent picture based on the convolutional neural network according to the embodiment of the present invention further includes separately training a plurality of different volumes by using preset picture data.
  • the neural network is obtained to obtain a plurality of corresponding detection models, that is, specifically including the following steps S401 to S405:
  • the preset picture data is divided into a training set and a verification set.
  • the preset picture data may include indeterminate classified image data and normal picture data, which may be manually classified and filtered, and the two types of data are used as two scenes as input data to be convolved.
  • the neural network performs learning classification to obtain a detection model that can determine whether the picture is an indecent picture.
  • the training set includes several normal pictures as well as indecent pictures, and the verification set also includes several normal pictures as well as indecent pictures.
  • the training set is used for routine training of the convolutional neural network, and the verification set is used for corresponding classification detection of the model obtained by the trained convolutional neural network. In order to improve the accuracy of recognition, the training set and the verification set are needed.
  • the corresponding pre-processing such as feature enhancement, is performed before the convolutional neural network can be input for training.
  • Convolutional Neural Network (Convolutional Neural Network) Network, CNN) is a feedforward neural network whose artificial neurons can respond to a surrounding area of a part of the coverage and perform well for large image processing.
  • Different convolutional neural networks include different hierarchical structures.
  • a plurality of different convolutional neural networks can be separately trained, that is, the pictures in the training set and the classification corresponding to the picture are input into a plurality of different convolutional neural networks for training, and a plurality of corresponding intermediate models can be obtained.
  • each error set includes at least one error sample.
  • the image in the verification set is input into the intermediate model for classification detection to obtain the classification detection result, and when the classification detection result is inconsistent with the preset classification of the picture, the picture is identified as an error sample. Specifically, all the pictures whose classification detection result is inconsistent with the pre-classification of the picture can be classified as an error set.
  • each error set can include at least one error sample.
  • the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model.
  • the intermediate model corresponding to one of the error sets is trained to obtain a corresponding new intermediate model, thereby further improving the accuracy of the classification detection of the intermediate model.
  • step S404 may be returned.
  • the number of convolutional neural networks may be two, including a first convolutional neural network having an eight-layer structure and a second convolutional neural network having a twenty-two-layer structure.
  • the first convolutional neural network includes five convolutional layers, two fully connected layers, and one probability statistical layer.
  • the convolutional layer of each layer in the first convolutional neural network can filter the input picture data into a two-dimensional vector through the convolution kernel, and separately calculate its parameters in the training phase, and the full connection layer will input and weight.
  • the vector is multiplied, so the neurons in the next layer are all connected with the neurons in the previous layer. All neurons are accelerated by the activation function, and the probability and statistics layer is used to judge the indecent picture and the normal picture.
  • the second convolutional neural network is deeper than the first convolutional neural network layer, and the Inception structure consisting of two convolutional layers is used to widen the network, and the structure is repeated many times, and then the first convolution is performed.
  • a similar step in the neural network outputs a test result that can be classified.
  • FIG. 5 is a schematic flowchart of a method for recognizing an indecent picture based on a convolutional neural network according to another embodiment of the present invention.
  • the method can be run on terminals such as smart phones (such as Android phones, IOS phones, etc.), tablets, laptops, and smart devices.
  • the method mainly analyzes the input picture data and classifies and discriminates the picture, which greatly improves the accuracy of the yellowing and reduces the cost of the yellowing.
  • steps S501 to S506 of the method are shown in FIG. 5, steps S501 to S506 of the method.
  • the first convolutional neural network and the second convolutional neural network are respectively trained by using preset image data to obtain a corresponding first detection model and second detection model.
  • S502 Perform pre-processing on the acquired picture data to be tested.
  • the preprocessed picture data to be tested is input to the first detection model and the second detection model, respectively, to correspondingly obtain the first confidence and the second confidence.
  • S504 Calculate the first confidence and the second confidence according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes two ratios, and the ratio of the ratios The number of detection models is the same, and each ratio corresponds to a different detection model.
  • S505. Determine whether the picture confidence is greater than a preset reliability. When the picture confidence is not greater than the preset reliability, the picture data to be tested may be determined to be normal picture data.
  • the storage medium may be a magnetic disk, an optical disk, or a read-only storage memory (Read-Only) Memory, ROM), etc.
  • the embodiment of the present invention further provides an indecent picture recognition terminal based on a convolutional neural network, where the terminal 100 includes: a pre-processing unit 101 The detecting unit 102, the confidence calculating unit 103, the determining unit 104, and the determining unit 105.
  • the pre-processing unit 101 is configured to perform pre-processing on the acquired picture data to be tested.
  • the detecting unit 102 is configured to input the pre-processed picture data to be tested into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels.
  • the confidence calculation unit 103 is configured to calculate all confidence levels according to a preset linear weight ratio to obtain a picture confidence, wherein the preset linear weight ratio includes a plurality of ratios, and the number of the ratios The number is the same as the number of detection models, and each ratio corresponds to a different detection model.
  • the determining unit 104 is configured to determine whether the picture confidence is greater than a preset reliability.
  • the determining unit 105 is configured to determine that the picture data to be tested is indecent picture data if the picture confidence is greater than a pre-set confidence.
  • the terminal 100 further includes a classification unit 100a, a first training unit 100b, a verification unit 100c, and a second training unit 100d.
  • the classification unit 100a is configured to divide preset picture data into a training set and a verification set.
  • the first training unit 100b is configured to train a plurality of different convolutional neural networks by using the training set to obtain a plurality of corresponding intermediate models.
  • the verification unit 100c is configured to verify all the intermediate models by using the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample.
  • the second training unit 100d is configured to train an intermediate model corresponding to one of the error sets to obtain a correspondence if the number of error concentration errors in one of the errors is greater than or equal to a preset threshold. New intermediate model.
  • the verification unit 100c is further configured to verify the new intermediate model again by using the verification set until the number of error concentration error samples is less than a preset threshold, and determine a new intermediate model at this time. The model is detected for the corresponding preset.
  • the pre-processing unit 101 includes a strengthening unit 1011 and a dividing unit 1012.
  • the strengthening unit 1011 is configured to perform feature enhancement on the acquired picture data to be tested.
  • the dividing unit 1012 is configured to divide the feature-intensified picture data to be obtained according to a preset rule to obtain one or more sub-pictures.
  • the detecting unit 102 is further configured to input all the sub-pictures into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is The confidence level corresponding to the detection model.
  • the strengthening unit 1011 includes an adjustment unit 1011a, an average value calculation unit 1011b, and a target calculation unit 1011c.
  • the adjusting unit 1011a is configured to adjust the acquired picture data to be tested and all preset picture data to 256*256 RGB pictures.
  • the average value calculating unit 1011b is configured to calculate a pixel average value of all preset picture data after being adjusted to an RGB picture.
  • the target calculation unit 1011c is configured to subtract the pixel average value from the pixels of the image data to be measured adjusted to the RGB picture to obtain the picture data to be tested after feature enhancement.
  • FIG. 10 is a schematic structural diagram of an indecent picture recognition device based on a convolutional neural network according to the present invention.
  • the device 200 can include an input device 201, an output device 202, a transceiver device 203, a memory 204, and a processor 205, where:
  • the input device 201 is configured to receive input data of an external access control device.
  • the input device 201 in the embodiment of the present invention may include a keyboard, a mouse, a photoelectric input device, and a sound input.
  • the output device 202 is configured to output output data of the access control device to the outside.
  • the output device 202 is configured to output output data of the access control device to the outside.
  • the output device 202 described in the embodiments of the present invention may include a display, a speaker, a printer, and the like.
  • the transceiver device 203 is configured to send data to or receive data from other devices through a communication link.
  • the transceiver device 203 of the embodiment of the present invention may include a transceiver device such as a radio frequency antenna.
  • the memory 204 is configured to store a program that implements indecent picture recognition.
  • the memory 204 of an embodiment of the invention may be a system memory such as volatile (such as RAM), non-volatile (such as ROM, flash memory, etc.), or a combination of both.
  • the memory 204 of the embodiment of the present invention may also be an external memory outside the system, such as a magnetic disk, an optical disk, a magnetic tape, or the like.
  • the processor 205 is configured to run a program for implementing indecent picture recognition stored in the memory 204 to perform the following operations:
  • the pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
  • the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
  • the picture data to be tested is determined to be indecent picture data.
  • the preset picture data is divided into a training set and a verification set
  • Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
  • the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model
  • the new intermediate model is verified again by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding preset detection model.
  • the preprocessing the acquired image data to be tested includes:
  • each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
  • performing feature enhancement on the acquired image data to be tested includes:
  • the pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
  • the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second convolutional neural network having a twenty-two-layer structure, wherein the first convolutional nerve
  • the network consists of five convolutional layers, two fully connected layers, and a probabilistic layer.
  • an apparatus based on inconsistency picture recognition of a convolutional neural network may include more or fewer components than illustrated, or some components may be combined, or different component arrangements.
  • the device based on the inconsistency picture recognition of the convolutional neural network may include only the memory and the processor. In such an embodiment, the structure and function of the memory and the processor are the same as the embodiment shown in FIG. Consistent, no longer repeat them here.
  • the present invention provides a computer readable storage medium having stored one or more programs, the one or more programs being executable by one or more processors to implement the following steps:
  • the pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
  • the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
  • the picture data to be tested is determined to be indecent picture data.
  • the preset picture data is divided into a training set and a verification set
  • Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
  • the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model
  • the new intermediate model is again verified by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding detection model.
  • the preprocessing the acquired image data to be tested includes:
  • each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
  • performing feature enhancement on the acquired image data to be tested includes:
  • the pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
  • the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second convolutional neural network having a twenty-two-layer structure, wherein the first convolutional nerve
  • the network consists of five convolutional layers, two fully connected layers, and a probabilistic layer.
  • the foregoing storage medium of the present invention includes: a magnetic disk, an optical disk, and a read-only storage memory (Read-Only) Memory, ROM, and other media that can store program code.
  • the units in all embodiments of the present invention may be implemented by a general-purpose integrated circuit such as a CPU (Central Processing) Unit, central processing unit, or through ASIC (Application Specific Integrated circuit
  • the units in the terminal in the embodiment of the present invention may be combined, divided, and deleted according to actual needs.

Abstract

A convolutional-neural-network-based indecent picture recognition method, terminal (100) and device (200), and a computer-readable storage medium. The method comprises: performing preprocessing on data of an obtained picture to be detected (S101); respectively inputting the preprocessed data of the picture to be detected into a plurality of preset detection models to correspondingly obtain a plurality of different confidence degrees (S102); calculating all the confidence degrees according to a preset linear weighted ratio to obtain a picture confidence degree (S103); determining whether the picture confidence degree is greater than a preset confidence degree or not (S104); if the picture confidence degree is greater than the preset confidence degree, determining that the data of the picture to be detected is indecent picture data (S105). The method can automatically analyze the inputted pictures to be detected and perform classification and identification on the pictures, so that the pornography identification accuracy is greatly improved and the pornography identification cost is lowered.

Description

不雅图片识别方法、终端、设备及计算机可读存储介质  Indecent picture recognition method, terminal, device and computer readable storage medium
本申请要求于2017年8月28日提交中国专利局、申请号为CN 2017107527832、发明名称为“一种基于卷积神经网络的不雅图片识别方法、终端、设备及计算机可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application is required to be submitted to the China Patent Office on August 28, 2017, the application number is CN 2017107527832, and the invention name is “a method for identifying indecent pictures based on convolutional neural networks, terminals, devices and computer readable storage media”. The priority of the Chinese Patent Application, the entire contents of which is incorporated herein by reference.
技术领域Technical field
本发明涉及计算机技术领域,尤其涉及一种基于卷积神经网络的不雅图片识别方法、终端、设备及计算机可读存储介质。The present invention relates to the field of computer technologies, and in particular, to an indecent picture recognition method based on a convolutional neural network, a terminal, a device, and a computer readable storage medium.
背景技术Background technique
随着网络数据的爆炸性增长和人们越来越大的个性化需求,人们每天通过网络能够获取海量数据,在丰富精神生活的同时,也因此暴露在海量信息面前,更易接触到各类色情信息,必须对信息进行过滤再展示到受众特别是儿童面前,因此鉴黄一直是信息过滤中极其重要的一环。传统的人工鉴黄对从业者有很高的要求,鉴黄师承受着巨大的心理和生理的双重压力,企业人工成本过高,审核效率低下,不能适用于需要大规模审核的场景。目前卷积神经网络这样的深度学习算法被广泛应用于图片识别中,并在降低网络模型复杂度、提升图片数据处理能力等方面取得了显著的成效,但是现有通过卷积神经网络进行图片识别得到的结果还是存在一定程度的误差。With the explosive growth of network data and the increasing personalization needs of people, people can obtain massive amounts of data through the network every day. While enriching their spiritual life, they are exposed to massive information and are more exposed to all kinds of pornographic information. Information must be filtered and displayed to the audience, especially children, so the yellow has always been an extremely important part of information filtering. The traditional artificial yellowing has high requirements for practitioners. The Huangshi is under the dual psychological and physiological pressures. The labor cost of the enterprise is too high, and the audit efficiency is low. It cannot be applied to scenarios that require large-scale audits. At present, deep learning algorithms such as convolutional neural networks are widely used in image recognition, and have achieved remarkable results in reducing network model complexity and improving image data processing capabilities, but existing image recognition through convolutional neural networks. There is still a certain degree of error in the results obtained.
发明内容Summary of the invention
本发明实施例提供一种基于卷积神经网络的不雅图片识别方法、终端、设备及计算机可读存储介质,可以自动分析输入图片并对图片进行分类鉴别,大大提高了鉴黄的准确率,降低了鉴黄的成本。Embodiments of the present invention provide an indecent picture recognition method, a terminal, a device, and a computer readable storage medium based on a convolutional neural network, which can automatically analyze an input picture and classify and identify the picture, thereby greatly improving the accuracy of the yellowing. Reduce the cost of yellowing.
一方面,本发明实施例提供了一种基于卷积神经网络的不雅图片识别方法,该方法包括:In one aspect, an embodiment of the present invention provides an indecent picture recognition method based on a convolutional neural network, the method comprising:
对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
另一方面,本发明实施例还提供了一种基于卷积神经网络的不雅图片识别终端,该终端包括:On the other hand, an embodiment of the present invention further provides an indecent picture recognition terminal based on a convolutional neural network, where the terminal includes:
预处理单元,用于对获取的待测图片数据进行预处理;a pre-processing unit, configured to perform pre-processing on the acquired image data to be tested;
检测单元,用于将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;a detecting unit, configured to separately input the pre-processed picture data to be input into multiple preset detection models to correspondingly obtain a plurality of different confidence levels;
置信度计算单元,用于根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;a confidence calculation unit, configured to calculate all confidence levels according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, and the ratio of the ratios The number of detection models is the same, and each ratio corresponds to a different detection model;
判断单元,用于判断所述图片置信度是否大于预设置信度;a determining unit, configured to determine whether the picture confidence is greater than a preset reliability;
判定单元,用于若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。The determining unit is configured to determine that the picture data to be tested is indecent picture data if the picture confidence is greater than a preset reliability.
又一方面,本发明实施例还提供了一种基于卷积神经网络的不雅图片识别设备,该设备包括:In another aspect, an embodiment of the present invention further provides an indecent picture recognition device based on a convolutional neural network, the device comprising:
存储器,用于存储实现不雅图片识别的程序;以及a memory for storing a program that implements indecent picture recognition;
处理器,用于运行所述存储器中存储的实现不雅图片识别的程序,以执行以下操作:a processor for running a program for realizing indecent picture recognition stored in the memory to perform the following operations:
对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
再一方面,本发明实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有一个或者一个以上程序,所述一个或者一个以上程序可被一个或者一个以上的处理器执行,以实现以下步骤:In still another aspect, an embodiment of the present invention further provides a computer readable storage medium storing one or more programs, the one or more programs being executable by one or more processors Execute to implement the following steps:
对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
综上所述,本发明具有以下有益效果:本发明实施例通过对获取的待测图片数据进行预处理;将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度;若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据,自动分析输入的待测图片并对图片进行分类鉴别,大大提高了鉴黄的准确率,降低了鉴黄的成本;另外,对卷积神经网络的多次训练和验证,可以进一步减少误差并提高得到的检测模型的识别精准度。In summary, the present invention has the following beneficial effects: the embodiment of the present invention performs pre-processing on the acquired image data to be tested; and inputs the pre-processed image data to be input into multiple preset detection models to obtain correspondingly a different confidence; calculating all the confidences according to the preset linear weighting ratio to obtain a picture confidence; if the picture confidence is greater than the preset reliability, determining that the picture data to be tested is an indecent picture Data, automatically analyze the input picture to be tested and classify and identify the picture, which greatly improves the accuracy of the yellowing and reduces the cost of the yellowing. In addition, the multiple training and verification of the convolutional neural network can further reduce the error. And improve the recognition accuracy of the obtained detection model.
附图说明DRAWINGS
为了更清楚地说明本发明实施例技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly described below. It is obvious that the drawings in the following description are some embodiments of the present invention. For the ordinary technicians, other drawings can be obtained based on these drawings without any creative work.
图1是本发明实施例提供的一种基于卷积神经网络的不雅图片识别方法的示意流程图;1 is a schematic flow chart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention;
图2是本发明实施例提供的一种基于卷积神经网络的不雅图片识别方法的另一示意流程图;2 is another schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention;
图3是本发明实施例提供的一种基于卷积神经网络的不雅图片识别方法的另一示意流程图;3 is another schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention;
图4是本发明实施例提供的一种基于卷积神经网络的不雅图片识别方法的另一示意流程图;4 is another schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention;
图5是本发明另一实施例提供的一种基于卷积神经网络的不雅图片识别方法的示意流程图;FIG. 5 is a schematic flowchart of an indecent picture recognition method based on a convolutional neural network according to another embodiment of the present invention; FIG.
图6是本发明实施例提供的一种基于卷积神经网络的不雅图片识别终端的示意性框图;FIG. 6 is a schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention; FIG.
图7是本发明实施例提供的一种基于卷积神经网络的不雅图片识别终端的另一示意性框图;FIG. 7 is another schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention; FIG.
图8是本发明实施例提供的一种基于卷积神经网络的不雅图片识别终端的另一示意性框图;FIG. 8 is another schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention; FIG.
图9是本发明实施例提供的一种基于卷积神经网络的不雅图片识别终端的另一示意性框图;FIG. 9 is another schematic block diagram of an indecent picture recognition terminal based on a convolutional neural network according to an embodiment of the present invention; FIG.
图10是本发明实施例提供的一种基于卷积神经网络的不雅图片识别设备的结构组成示意图。FIG. 10 is a schematic structural diagram of an indecent picture recognition device based on a convolutional neural network according to an embodiment of the present invention.
具体实施方式Detailed ways
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are a part of the embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, those skilled in the art are not creative
动前提下所获得的所有其他实施例,都属于本发明保护的范围。All other embodiments obtained under the premise of the invention are within the scope of the invention.
应当理解,当在本说明书和所附权利要求书中使用时,术语“包括”和 “包含”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。It will be understood that the terms "comprise" and "the" when used in the specification and the appended claims "Comprising" indicates the existence of the described features, integers, steps, operations, elements and/or components, but does not exclude the presence of one or more other features, integers, steps, operations, elements, components and/or combinations thereof Add to.
还应当理解,在此本发明说明书中所使用的术语仅仅是出于描述特定实施例的目的而并不意在限制本发明。如在本发明说明书和所附权利要求书中所使It is also to be understood that the terminology of the present invention is to be construed as a As made in the specification of the invention and the appended claims
用的那样,除非上下文清楚地指明其它情况,否则单数形式的“一”、“一个”及“该”意在包括复数形式。As used in the singular, the s
请参阅图1,图1是本发明实施例提供的一种基于卷积神经网络的不雅图片识别方法的示意流程图。该方法可以运行在智能手机(如Android手机、IOS手机等)、平板电脑、笔记本电脑以及智能设备等终端中。本发明的方法可以自动分析输入的待测图片并对图片进行分类鉴别,大大提高了鉴黄的准确率,降低了鉴黄的成本。如图1所示,该方法包括步骤S101~S105。Please refer to FIG. 1. FIG. 1 is a schematic flow chart of an indecent picture recognition method based on a convolutional neural network according to an embodiment of the present invention. The method can be run on terminals such as smart phones (such as Android phones, IOS phones, etc.), tablets, laptops, and smart devices. The method of the invention can automatically analyze the input picture to be tested and classify and identify the picture, thereby greatly improving the accuracy of the yellowing and reducing the cost of the yellowing. As shown in FIG. 1, the method includes steps S101 to S105.
S101,对获取的待测图片数据进行预处理。S101: Perform pre-processing on the acquired picture data to be tested.
在本发明实施例中,待测图片数据可以是常规的图片,也可以是从视频数据中提取视频关键帧从而得到的图片。为了提高分类检测的准确性,需要对待测图片数据进行相应的处理。In the embodiment of the present invention, the picture data to be tested may be a regular picture, or may be a picture obtained by extracting a video key frame from the video data. In order to improve the accuracy of the classification detection, it is necessary to perform corresponding processing on the picture data to be measured.
具体地,如图2所示,步骤S101包括步骤S201~S202。Specifically, as shown in FIG. 2, step S101 includes steps S201 to S202.
S201,对获取的待测图片数据进行特征强化。S201: Perform feature enhancement on the acquired image data to be tested.
在本发明实施例中,为了便于进行特征识别,可以先对获取的待测图片数据进行特征强化。具体地,如图3所示,步骤S201包括步骤S301~S303。In the embodiment of the present invention, in order to facilitate feature recognition, feature acquisition of the acquired image data to be tested may be performed first. Specifically, as shown in FIG. 3, step S201 includes steps S301 to S303.
S301,将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片。S301. Adjust the acquired picture data to be tested and all preset picture data to 256*256 RGB pictures.
在本发明实施例中,可以将所有预设图片数据调整为256*256的RGB图片,同样的,在利用检测模型进行检测时,所用到的图片也必须是相同格式的RGB图片。也就是需要将获取的待测图片数据也调整为256*256的RGB图片。In the embodiment of the present invention, all preset picture data can be adjusted to 256*256 RGB pictures. Similarly, when using the detection model for detection, the used pictures must also be RGB pictures of the same format. That is to say, the acquired image data to be tested needs to be adjusted to 256*256 RGB pictures.
S302,计算被调整为RGB图片后的所有预设图片数据的像素平均值。S302. Calculate a pixel average value of all preset picture data after being adjusted to an RGB picture.
在本发明实施例中,为了使得待测图片数据的特征更为凸显,以提高分类检测结果的准确率,需要计算被调整为RGB图片后的所有预设图片数据的像素平均值,即得到一个所谓的平均图。In the embodiment of the present invention, in order to make the feature of the picture data to be measured more prominent, to improve the accuracy of the classification detection result, it is necessary to calculate the pixel average value of all the preset picture data after being adjusted to the RGB picture, that is, obtain a The so-called average map.
S303,将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。S303. Subtract the pixel average value from the pixels of the image data to be measured adjusted to the RGB picture to obtain the picture data to be tested after the feature enhancement.
在本发明实施例中,通过减去像素平均值,可以得到与被调整为RGB图片后的待测图片数据对应的特征强化后的待测图片数据。In the embodiment of the present invention, by subtracting the average value of the pixel, the image data to be tested after the feature enhancement corresponding to the image data to be measured adjusted to the RGB image can be obtained.
S202,根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片。S202. The feature-enhanced picture data to be tested is divided according to a preset rule to obtain one or more sub-pictures.
其中,将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。Wherein, all the sub-pictures are input into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
在本实施例中,可以将特征强化后的待测图片数据划分为一个或多个224*224的子图片,当然,也可以根据实际情况划分为一个或多个的其他尺寸的子图片,以便于更好地提取特征,减少不相干特征的干扰。同理,在训练卷积神经网络的过程中,所有预设图片数据也对应地进行相应地处理,从而增加训练的图片数据的数量,并进一步提高之后的检测模型的精准度。In this embodiment, the image data to be tested after feature enhancement may be divided into one or more sub-pictures of 224*224. Of course, it may be divided into one or more sub-pictures of other sizes according to actual conditions, so that To better extract features and reduce the interference of incoherent features. Similarly, in the process of training the convolutional neural network, all the preset picture data are correspondingly processed correspondingly, thereby increasing the number of trained picture data and further improving the accuracy of the subsequent detection model.
又由于一个或多个子图片输入每个检测模型后,会对应地的到一个或多个子置信度,故需要确定一个或多个子置信度中的最大值,从而将这个最大值确定为该检测模型对应的置信度。Since one or more sub-pictures are input to each detection model, corresponding to one or more sub-confidences, it is necessary to determine a maximum value of one or more sub-confidences, thereby determining the maximum value as the detection model. Corresponding confidence.
S102,将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度。S102: Input the pre-processed picture data to be tested into multiple preset detection models to correspondingly obtain a plurality of different confidence levels.
在本发明实施例中,将预处理后的待测图片数据输入每一个预设检测模型,以使得每个预设检测模型都能够得出一个置信度。In the embodiment of the present invention, the pre-processed picture data to be tested is input to each preset detection model, so that each preset detection model can obtain a confidence level.
S103,根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型。S103. Calculate all the confidence levels according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios and the number of the detection models. The same, and each ratio corresponds to a different detection model.
在本发明实施例中,所述预设的线性加权比可以通过对相关算法进行训练得到,也可以根据重复实验的方法获取最佳的线性加权比。例如,可以通过综合分析多张不雅图片在各个检测模型中得到的置信度,然后确认一个最佳的线性加权比。一般情况下,当有两个检测模型的时候,可以选择线性加权比为1:1,也即通过两个检测模型的两个置信度各占一半,从而得到最终的图片置信度。In the embodiment of the present invention, the preset linear weighting ratio may be obtained by training the related algorithm, or obtaining the optimal linear weighting ratio according to the method of repeated experiments. For example, it is possible to comprehensively analyze the confidence obtained in each detection model for a plurality of indecent images, and then confirm an optimal linear weighting ratio. In general, when there are two detection models, the linear weighting ratio can be chosen to be 1:1, that is, the two confidence levels of the two detection models are each half, so that the final image confidence is obtained.
S104,判断所述图片置信度是否大于预设置信度。S104. Determine whether the picture confidence is greater than a preset reliability.
在本发明实施例中,图片置信度如果不大于预设置信度,那么可知,该待测图片数据为正常图片数据。所述预设置信度可以根据实际情况进行相应的设定。比如,当预设置信度为0.8时,如果所述图片置信度小于或等于0.8,那么该待测图片数据为正常图片数据。In the embodiment of the present invention, if the picture confidence is not greater than the preset reliability, it is known that the picture data to be tested is normal picture data. The preset reliability can be set correspondingly according to actual conditions. For example, when the pre-set reliability is 0.8, if the picture confidence is less than or equal to 0.8, the picture data to be tested is normal picture data.
S105,若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。S105. If the picture confidence is greater than the preset reliability, determine that the picture data to be tested is indecent picture data.
在本发明实施例中,当所述图片置信度大于预设置信度时,可以知道这个待测图片数据为不雅图片数据。具体可以参见,当预设置信度为0.8时,如果所述图片置信度大于0.8,那么该待测图片数据为不雅图片数据。In the embodiment of the present invention, when the picture confidence is greater than the preset reliability, the picture data to be tested may be known as indecent picture data. For details, when the pre-set reliability is 0.8, if the picture confidence is greater than 0.8, the picture data to be tested is indecent picture data.
由以上可见,本发明实施例通过对获取的待测图片数据进行预处理;将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度;若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据,可以自动分析输入图像并对图像进行分类鉴别,大大提高了鉴黄的准确率,降低了鉴黄的成本;另外,对卷积神经网络的多次训练和验证,可以进一步减少误差并提高得到的检测模型的识别精准度。It can be seen that, in the embodiment of the present invention, the obtained image data to be tested is preprocessed; the preprocessed image data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels; Setting a linear weighting ratio to calculate all the confidence levels to obtain a picture confidence; if the picture confidence is greater than the pre-set reliability, determining that the picture data to be tested is indecent picture data, the input image can be automatically analyzed and Classification and identification of images greatly improve the accuracy of yellowing and reduce the cost of yellowing. In addition, multiple training and verification of convolutional neural networks can further reduce errors and improve the recognition accuracy of the resulting detection models. .
如图4所示,作为优选的实施例,本发明实施例所述的基于卷积神经网络的不雅图片识别方法中的步骤S101之前还包括利用预设的图片数据分别训练多个不同的卷积神经网络以得到多个对应的检测模型,即具体包括如下步骤S401~S405:As shown in FIG. 4, as a preferred embodiment, step S101 in the method for identifying indecent picture based on the convolutional neural network according to the embodiment of the present invention further includes separately training a plurality of different volumes by using preset picture data. The neural network is obtained to obtain a plurality of corresponding detection models, that is, specifically including the following steps S401 to S405:
S401,将预设的图片数据分为训练集以及验证集。S401. The preset picture data is divided into a training set and a verification set.
在本发明实施例中,预设的图片数据可以包括预设分类的不雅图片数据和正常图片数据,可由人工进行分类筛选,将这两类数据作为两个场景,作为输入数据提供给卷积神经网络进行学习分类,从而得到可以判断图片是否为不雅图片的检测模型。训练集中包括若干正常图片以及不雅图片,验证集也包括若干正常图片以及不雅图片。其中训练集用于对卷积神经网络进行常规训练,而验证集用于对训练后的卷积神经网络得到的模型进行相应的分类检测,为了提高识别的准确度,需要对训练集和验证集先进行相应的预处理,比如特征强化等,然后才能输入卷积神经网络进行训练。In the embodiment of the present invention, the preset picture data may include indeterminate classified image data and normal picture data, which may be manually classified and filtered, and the two types of data are used as two scenes as input data to be convolved. The neural network performs learning classification to obtain a detection model that can determine whether the picture is an indecent picture. The training set includes several normal pictures as well as indecent pictures, and the verification set also includes several normal pictures as well as indecent pictures. The training set is used for routine training of the convolutional neural network, and the verification set is used for corresponding classification detection of the model obtained by the trained convolutional neural network. In order to improve the accuracy of recognition, the training set and the verification set are needed. The corresponding pre-processing, such as feature enhancement, is performed before the convolutional neural network can be input for training.
S402,利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型。S402. Train the plurality of different convolutional neural networks with the training set to obtain a plurality of corresponding intermediate models.
在本发明实施例中,卷积神经网络(Convolutional Neural Network,CNN)是一种前馈神经网络,它的人工神经元可以响应一部分覆盖范围内的周围单元,对于大型图像处理有出色表现。不同的卷积神经网络包括不同的分层结构。In the embodiment of the present invention, Convolutional Neural Network (Convolutional Neural Network) Network, CNN) is a feedforward neural network whose artificial neurons can respond to a surrounding area of a part of the coverage and perform well for large image processing. Different convolutional neural networks include different hierarchical structures.
通过训练集可以分别对多个不同的卷积神经网络进行训练,即将训练集中的图片以及与该图片对应的分类输入多个不同的卷积神经网络进行训练,可以得到多个对应的中间模型。Through the training set, a plurality of different convolutional neural networks can be separately trained, that is, the pictures in the training set and the classification corresponding to the picture are input into a plurality of different convolutional neural networks for training, and a plurality of corresponding intermediate models can be obtained.
S403,利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本。S403. Verify all the intermediate models by using the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample.
在本发明实施例中,将验证集中的图片输入中间模型中进行分类检测以得到分类检测结果,当分类检测结果与该图片的预设分类不一致时,将该图片认定为一个错误样本。具体可以将所有分类检测结果与图片的预分类不一致的图片归类为错误集。综上可知,每个错误集均可以包括至少一个错误样本。In the embodiment of the present invention, the image in the verification set is input into the intermediate model for classification detection to obtain the classification detection result, and when the classification detection result is inconsistent with the preset classification of the picture, the picture is identified as an error sample. Specifically, all the pictures whose classification detection result is inconsistent with the pre-classification of the picture can be classified as an error set. In summary, each error set can include at least one error sample.
S404,若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型。S404. If the number of the error concentration error samples is greater than or equal to the preset threshold, the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model.
在本发明实施例中,如果其中一个错误集中错误样本的数量大于或等于预设阈值,则表明此时分类检测的结果的错误率在不可接受的范围内,此时需要利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型,从而进一步提高中间模型的分类检测的准确度。In the embodiment of the present invention, if the number of the error concentration error samples is greater than or equal to the preset threshold, it indicates that the error rate of the result of the classification detection is within an unacceptable range, and the error needs to be utilized at this time. The intermediate model corresponding to one of the error sets is trained to obtain a corresponding new intermediate model, thereby further improving the accuracy of the classification detection of the intermediate model.
S405,利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。S405. Verify the new intermediate model again by using the verification set until the number of error concentration error samples is less than a preset threshold, and determine that the new intermediate model at this time is a corresponding preset detection model.
在本发明实施例中,得到新的中间模型后,需要再利用验证集再次进行验证以得到新的分类检测结果,同时判断此时的错误集中的错误样本的数量是否小于预设阀值,当错误集中的错误样本的数量小于预设阀值,那么则可以判定此时的新的中间模型为对应的预设检测模型。而如果错误集中的错误样本的数量大于预或等于预设阀值,那么则可以返回步骤S404。In the embodiment of the present invention, after obtaining a new intermediate model, it is necessary to re-verify the verification set to obtain a new classification detection result, and determine whether the number of error samples in the error set at this time is less than a preset threshold. If the number of error samples in the error set is less than the preset threshold, then it can be determined that the new intermediate model at this time is the corresponding preset detection model. And if the number of error samples in the error set is greater than or equal to the preset threshold, then step S404 may be returned.
另外,作为优选的另一实施例,卷积神经网络的数量可以为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。其中第一卷积神经网络中的每层卷积层可以通过卷积核将输入的图片数据过滤为二维向量,在训练阶段对其参数进行单独计算,而全连接层将输入和带权重的向量进行点乘,因此后一层的神经元与前一层的神经元全部连接起来,所有神经元都通过激活函数进行学习加速,而概率统计层用于进行不雅图片与正常图片的判断。而第二卷积神经网路比第一卷积神经网络层数更深,采用由两层卷积层构成的Inception结构来加宽网络,且这一结构多次重复,再经过与第一卷积神经网络相似的步骤输出能够分类的检测结果。In addition, as another preferred embodiment, the number of convolutional neural networks may be two, including a first convolutional neural network having an eight-layer structure and a second convolutional neural network having a twenty-two-layer structure. The first convolutional neural network includes five convolutional layers, two fully connected layers, and one probability statistical layer. The convolutional layer of each layer in the first convolutional neural network can filter the input picture data into a two-dimensional vector through the convolution kernel, and separately calculate its parameters in the training phase, and the full connection layer will input and weight. The vector is multiplied, so the neurons in the next layer are all connected with the neurons in the previous layer. All neurons are accelerated by the activation function, and the probability and statistics layer is used to judge the indecent picture and the normal picture. The second convolutional neural network is deeper than the first convolutional neural network layer, and the Inception structure consisting of two convolutional layers is used to widen the network, and the structure is repeated many times, and then the first convolution is performed. A similar step in the neural network outputs a test result that can be classified.
具体请参阅图5,图5是本发明另一实施例提供的一种基于卷积神经网络的不雅图片识别方法的示意流程图。该方法可以运行在智能手机(如Android手机、IOS手机等)、平板电脑、笔记本电脑以及智能设备等终端中。该方法主要是分析输入图片数据并对图片进行分类鉴别,大大提高了鉴黄的准确率,降低了鉴黄的成本。如图5所示,该方法的步骤S501~S506。For details, refer to FIG. 5. FIG. 5 is a schematic flowchart of a method for recognizing an indecent picture based on a convolutional neural network according to another embodiment of the present invention. The method can be run on terminals such as smart phones (such as Android phones, IOS phones, etc.), tablets, laptops, and smart devices. The method mainly analyzes the input picture data and classifies and discriminates the picture, which greatly improves the accuracy of the yellowing and reduces the cost of the yellowing. As shown in FIG. 5, steps S501 to S506 of the method.
S501,利用预设的图片数据分别训练第一卷积神经网络和第二卷积神经网络,以得到对应的第一检测模型和第二检测模型。S501. The first convolutional neural network and the second convolutional neural network are respectively trained by using preset image data to obtain a corresponding first detection model and second detection model.
S502,对获取的待测图片数据进行预处理。S502: Perform pre-processing on the acquired picture data to be tested.
S503,将预处理后的待测图片数据分别输入第一检测模型和第二检测模型,以对应地得到第一置信度和第二置信度。S503. The preprocessed picture data to be tested is input to the first detection model and the second detection model, respectively, to correspondingly obtain the first confidence and the second confidence.
S504,根据预设的线性加权比对第一置信度和第二置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括两个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型。S504: Calculate the first confidence and the second confidence according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes two ratios, and the ratio of the ratios The number of detection models is the same, and each ratio corresponds to a different detection model.
S505,判断所述图片置信度是否大于预设置信度。当所述图片置信度不大于预设置信度时,可以判定所述待测图片数据为正常图片数据。S505. Determine whether the picture confidence is greater than a preset reliability. When the picture confidence is not greater than the preset reliability, the picture data to be tested may be determined to be normal picture data.
S506,若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。S506. If the picture confidence is greater than the preset reliability, determine that the picture data to be tested is indecent picture data.
本领域普通技术员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等。A person skilled in the art can understand that all or part of the process of implementing the above embodiments can be completed by a computer program to instruct related hardware, and the program can be stored in a computer readable storage medium. When executed, the flow of an embodiment of the methods as described above may be included. The storage medium may be a magnetic disk, an optical disk, or a read-only storage memory (Read-Only) Memory, ROM), etc.
请参阅图6,对应上述一种基于卷积神经网络的不雅图片识别方法,本发明实施例还提出一种基于卷积神经网络的不雅图片识别终端,该终端100包括:预处理单元101、检测单元102、置信度计算单元103、判断单元104、判定单元105。Referring to FIG. 6 , corresponding to the inconsistency picture recognition method based on the convolutional neural network, the embodiment of the present invention further provides an indecent picture recognition terminal based on a convolutional neural network, where the terminal 100 includes: a pre-processing unit 101 The detecting unit 102, the confidence calculating unit 103, the determining unit 104, and the determining unit 105.
其中,所述预处理单元101用于对获取的待测图片数据进行预处理。The pre-processing unit 101 is configured to perform pre-processing on the acquired picture data to be tested.
所述检测单元102用于将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度。The detecting unit 102 is configured to input the pre-processed picture data to be tested into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels.
所述置信度计算单元103用于根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型。The confidence calculation unit 103 is configured to calculate all confidence levels according to a preset linear weight ratio to obtain a picture confidence, wherein the preset linear weight ratio includes a plurality of ratios, and the number of the ratios The number is the same as the number of detection models, and each ratio corresponds to a different detection model.
所述判断单元104用于判断所述图片置信度是否大于预设置信度。The determining unit 104 is configured to determine whether the picture confidence is greater than a preset reliability.
所述判定单元105用于若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。The determining unit 105 is configured to determine that the picture data to be tested is indecent picture data if the picture confidence is greater than a pre-set confidence.
如图7所示,所述所述终端100还包括分类单元100a、第一训练单元100b、验证单元100c以及第二训练单元100d。As shown in FIG. 7, the terminal 100 further includes a classification unit 100a, a first training unit 100b, a verification unit 100c, and a second training unit 100d.
其中,所述分类单元100a用于将预设的图片数据分为训练集以及验证集。The classification unit 100a is configured to divide preset picture data into a training set and a verification set.
所述第一训练单元100b用于利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型。The first training unit 100b is configured to train a plurality of different convolutional neural networks by using the training set to obtain a plurality of corresponding intermediate models.
所述验证单元100c用于利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本。The verification unit 100c is configured to verify all the intermediate models by using the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample.
所述第二训练单元100d用于若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型。The second training unit 100d is configured to train an intermediate model corresponding to one of the error sets to obtain a correspondence if the number of error concentration errors in one of the errors is greater than or equal to a preset threshold. New intermediate model.
其中,所述验证单元100c还用于利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。The verification unit 100c is further configured to verify the new intermediate model again by using the verification set until the number of error concentration error samples is less than a preset threshold, and determine a new intermediate model at this time. The model is detected for the corresponding preset.
如图8所示,所述预处理单元101,包括强化单元1011以及划分单元1012。As shown in FIG. 8, the pre-processing unit 101 includes a strengthening unit 1011 and a dividing unit 1012.
其中,所述强化单元1011用于对获取的待测图片数据进行特征强化。The strengthening unit 1011 is configured to perform feature enhancement on the acquired picture data to be tested.
所述划分单元1012用于根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片。The dividing unit 1012 is configured to divide the feature-intensified picture data to be obtained according to a preset rule to obtain one or more sub-pictures.
其中,所述检测单元102还用于将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。The detecting unit 102 is further configured to input all the sub-pictures into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is The confidence level corresponding to the detection model.
如图9所示,所述强化单元1011包括调整单元1011a、平均值计算单元1011b以及目标计算单元1011c。As shown in FIG. 9, the strengthening unit 1011 includes an adjustment unit 1011a, an average value calculation unit 1011b, and a target calculation unit 1011c.
其中,所述调整单元1011a用于将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片。The adjusting unit 1011a is configured to adjust the acquired picture data to be tested and all preset picture data to 256*256 RGB pictures.
所述平均值计算单元1011b用于计算被调整为RGB图片后的所有预设图片数据的像素平均值。The average value calculating unit 1011b is configured to calculate a pixel average value of all preset picture data after being adjusted to an RGB picture.
所述目标计算单元1011c用于将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The target calculation unit 1011c is configured to subtract the pixel average value from the pixels of the image data to be measured adjusted to the RGB picture to obtain the picture data to be tested after feature enhancement.
图10为本发明一种基于卷积神经网络的不雅图片识别设备的结构组成示意图。如图10所示,该设备200可包括:输入装置201、输出装置202、收发装置203、存储器204以及处理器205,其中: FIG. 10 is a schematic structural diagram of an indecent picture recognition device based on a convolutional neural network according to the present invention. As shown in FIG. 10, the device 200 can include an input device 201, an output device 202, a transceiver device 203, a memory 204, and a processor 205, where:
所述输入装置201,用于接收外部访问控制设备的输入数据。具体实现中,本发明实施例所述的输入装置201可包括键盘、鼠标、光电输入装置、声音输The input device 201 is configured to receive input data of an external access control device. In a specific implementation, the input device 201 in the embodiment of the present invention may include a keyboard, a mouse, a photoelectric input device, and a sound input.
入装置、触摸式输入装置、扫描仪等。Into the device, touch input device, scanner, etc.
所述输出装置202,用于对外输出访问控制设备的输出数据。具体实现中,The output device 202 is configured to output output data of the access control device to the outside. In the specific implementation,
本发明实施例所述的输出装置202可包括显示器、扬声器、打印机等。The output device 202 described in the embodiments of the present invention may include a display, a speaker, a printer, and the like.
所述收发装置203,用于通过通信链路向其他设备发送数据或者从其他设备接收数据。具体实现中,本发明实施例的收发装置203可包括射频天线等收发器件。 The transceiver device 203 is configured to send data to or receive data from other devices through a communication link. In a specific implementation, the transceiver device 203 of the embodiment of the present invention may include a transceiver device such as a radio frequency antenna.
所述存储器204,用于存储实现不雅图片识别的程序。本发明实施例的存储器204可以是系统存储器,比如,挥发性的(诸如RAM),非易失性的(诸如ROM,闪存等),或者两者的结合。具体实现中,本发明实施例的存储器204还可以是系统之外的外部存储器,比如,磁盘、光盘、磁带等。The memory 204 is configured to store a program that implements indecent picture recognition. The memory 204 of an embodiment of the invention may be a system memory such as volatile (such as RAM), non-volatile (such as ROM, flash memory, etc.), or a combination of both. In a specific implementation, the memory 204 of the embodiment of the present invention may also be an external memory outside the system, such as a magnetic disk, an optical disk, a magnetic tape, or the like.
所述处理器205,用于运行所述存储器204中存储的实现不雅图片识别的程序,以执行如下操作:The processor 205 is configured to run a program for implementing indecent picture recognition stored in the memory 204 to perform the following operations:
对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
进一步地,还用于执行如下操作:Further, it is also used to perform the following operations:
将预设的图片数据分为训练集以及验证集;The preset picture data is divided into a training set and a verification set;
利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型;Training a plurality of different convolutional neural networks with the training set to obtain a plurality of corresponding intermediate models;
利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本;Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型;If the number of the error concentration error samples is greater than or equal to the preset threshold, the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model;
利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。The new intermediate model is verified again by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding preset detection model.
进一步地,所述对获取的待测图片数据进行预处理,包括:Further, the preprocessing the acquired image data to be tested includes:
对获取的待测图片数据进行特征强化;Performing feature enhancement on the acquired image data to be tested;
根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片;Dividing the image data to be tested after feature enhancement according to a preset rule to obtain one or more sub-pictures;
其中,将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。Wherein, all the sub-pictures are input into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
进一步地,所述对获取的待测图片数据进行特征强化,包括:Further, performing feature enhancement on the acquired image data to be tested includes:
将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片;Adjusting the acquired image data to be tested and all preset image data to 256*256 RGB images;
计算被调整为RGB图片后的所有预设图片数据的像素平均值;Calculating a pixel average of all preset picture data after being adjusted to an RGB picture;
将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
进一步地,卷积神经网络的数量为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。Further, the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second convolutional neural network having a twenty-two-layer structure, wherein the first convolutional nerve The network consists of five convolutional layers, two fully connected layers, and a probabilistic layer.
本领域技术人员可以理解,图10中示出的基于卷积神经网络的不雅图片识别的设备的实施例并不构成对基于卷积神经网络的不雅图片识别的设备具体构成的限定,在其他实施例中,基于卷积神经网络的不雅图片识别的设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。例如,在一些实施例中,基于卷积神经网络的不雅图片识别的设备可以仅包括存储器及处理器,在这样的实施例中,存储器及处理器的结构及功能与图10所示实施例一致,在此不再赘述。It will be understood by those skilled in the art that the embodiment of the device for identifying indecent picture based on convolutional neural network shown in FIG. 10 does not constitute a limitation on the specific configuration of the device based on the inconsistency of the convolutional neural network. In other embodiments, an apparatus based on inconsistency picture recognition of a convolutional neural network may include more or fewer components than illustrated, or some components may be combined, or different component arrangements. For example, in some embodiments, the device based on the inconsistency picture recognition of the convolutional neural network may include only the memory and the processor. In such an embodiment, the structure and function of the memory and the processor are the same as the embodiment shown in FIG. Consistent, no longer repeat them here.
本发明提供了一种计算机可读存储介质,计算机可读存储介质存储有一个或者一个以上程序,所述一个或者一个以上程序可被一个或者一个以上的处理器执行,以实现以下步骤:The present invention provides a computer readable storage medium having stored one or more programs, the one or more programs being executable by one or more processors to implement the following steps:
对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
进一步地,还实现如下步骤:Further, the following steps are also implemented:
将预设的图片数据分为训练集以及验证集;The preset picture data is divided into a training set and a verification set;
利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型;Training a plurality of different convolutional neural networks with the training set to obtain a plurality of corresponding intermediate models;
利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本;Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型;If the number of the error concentration error samples is greater than or equal to the preset threshold, the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model;
利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的检测模型。The new intermediate model is again verified by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding detection model.
进一步地,所述对获取的待测图片数据进行预处理,包括:Further, the preprocessing the acquired image data to be tested includes:
对获取的待测图片数据进行特征强化;Performing feature enhancement on the acquired image data to be tested;
根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片;Dividing the image data to be tested after feature enhancement according to a preset rule to obtain one or more sub-pictures;
其中,将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。Wherein, all the sub-pictures are input into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
进一步地,所述对获取的待测图片数据进行特征强化,包括:Further, performing feature enhancement on the acquired image data to be tested includes:
将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片;Adjusting the acquired image data to be tested and all preset image data to 256*256 RGB images;
计算被调整为RGB图片后的所有预设图片数据的像素平均值;Calculating a pixel average of all preset picture data after being adjusted to an RGB picture;
将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
进一步地,卷积神经网络的数量为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。Further, the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second convolutional neural network having a twenty-two-layer structure, wherein the first convolutional nerve The network consists of five convolutional layers, two fully connected layers, and a probabilistic layer.
本发明前述的存储介质包括:磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等各种可以存储程序代码的介质。The foregoing storage medium of the present invention includes: a magnetic disk, an optical disk, and a read-only storage memory (Read-Only) Memory, ROM, and other media that can store program code.
本发明所有实施例中的单元可以通过通用集成电路,例如CPU(Central Processing Unit,中央处理器),或通过ASIC (Application Specific Integrated The units in all embodiments of the present invention may be implemented by a general-purpose integrated circuit such as a CPU (Central Processing) Unit, central processing unit, or through ASIC (Application Specific Integrated
Circuit,专用集成电路)来实现。Circuit, ASIC) to achieve.
本发明实施例方法中的步骤可以根据实际需要进行顺序调整、合并和删减。The steps in the method of the embodiment of the present invention may be sequentially adjusted, merged, and deleted according to actual needs.
本发明实施例终端中的单元可以根据实际需要进行合并、划分和删减。The units in the terminal in the embodiment of the present invention may be combined, divided, and deleted according to actual needs.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,上述描述的设备、终端和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。A person skilled in the art can clearly understand that, for the convenience and brevity of the description, the specific working process of the device, the terminal, and the unit described above may be referred to the corresponding process in the foregoing method embodiments, and details are not described herein again.
以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到各种等效的修改或替换,这些修改或替换都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以权利要求的保护范围为准。The above is only the specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any equivalent person can be easily conceived within the technical scope of the present invention by any person skilled in the art. Modifications or substitutions are intended to be included within the scope of the invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims (20)

  1. 一种基于卷积神经网络的不雅图片识别方法,其特征在于,所述方法包括:An indecent picture recognition method based on a convolutional neural network, characterized in that the method comprises:
    对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
    将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
    根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
    判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
    若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
  2. 如权利要求1所述的方法,其特征在于,所述对获取的待测图片数据进行预处理之前,包括:The method according to claim 1, wherein the pre-processing of the acquired image data to be tested comprises:
    将预设的图片数据分为训练集以及验证集;The preset picture data is divided into a training set and a verification set;
    利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型;Training a plurality of different convolutional neural networks with the training set to obtain a plurality of corresponding intermediate models;
    利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本;Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
    若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型;If the number of the error concentration error samples is greater than or equal to the preset threshold, the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model;
    利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。The new intermediate model is verified again by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding preset detection model.
  3. 如权利要求1所述的方法,其特征在于,所述对获取的待测图片数据进行预处理,包括:The method according to claim 1, wherein the preprocessing the acquired image data to be tested comprises:
    对获取的待测图片数据进行特征强化;Performing feature enhancement on the acquired image data to be tested;
    根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片;Dividing the image data to be tested after feature enhancement according to a preset rule to obtain one or more sub-pictures;
    其中,将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。Wherein, all the sub-pictures are input into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
  4. 如权利要求3所述的方法,其特征在于,所述对获取的待测图片数据进行特征强化,包括:The method according to claim 3, wherein the characterizing the acquired image data to be tested comprises:
    将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片;Adjusting the acquired image data to be tested and all preset image data to 256*256 RGB images;
    计算被调整为RGB图片后的所有预设图片数据的像素平均值;Calculating a pixel average of all preset picture data after being adjusted to an RGB picture;
    将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
  5. 如权利要求1所述的方法,其特征在于,卷积神经网络的数量为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。The method of claim 1 wherein the number of convolutional neural networks is two, comprising a first convolutional neural network having an eight-layer structure and a second convolutional nerve having a twenty-two-layer structure A network, wherein the first convolutional neural network comprises five convolutional layers, two fully connected layers, and one probability statistical layer.
  6. 一种基于卷积神经网络的不雅图片识别终端,其特征在于,所述终端包括:An indecent picture recognition terminal based on a convolutional neural network, wherein the terminal comprises:
    预处理单元,用于对获取的待测图片数据进行预处理;a pre-processing unit, configured to perform pre-processing on the acquired image data to be tested;
    检测单元,用于将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;a detecting unit, configured to separately input the pre-processed picture data to be input into multiple preset detection models to correspondingly obtain a plurality of different confidence levels;
    置信度计算单元,用于根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;a confidence calculation unit, configured to calculate all confidence levels according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, and the ratio of the ratios The number of detection models is the same, and each ratio corresponds to a different detection model;
    判断单元,用于判断所述图片置信度是否大于预设置信度;a determining unit, configured to determine whether the picture confidence is greater than a preset reliability;
    判定单元,用于若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。The determining unit is configured to determine that the picture data to be tested is indecent picture data if the picture confidence is greater than a preset reliability.
  7. 如权利要求6所述的终端,其特征在于,所述终端还包括:The terminal according to claim 6, wherein the terminal further comprises:
    分类单元,用于将预设的图片数据分为训练集以及验证集;a classification unit, configured to divide preset picture data into a training set and a verification set;
    第一训练单元,用于利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型;a first training unit, configured to use the training set to train a plurality of different convolutional neural networks to obtain a plurality of corresponding intermediate models;
    验证单元,用于利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本;a verification unit, configured to verify all the intermediate models by using the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
    第二训练单元,用于若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型;a second training unit, configured to: if one of the error concentration error samples is greater than or equal to a preset threshold, use the one of the error sets to train an intermediate model corresponding to the one of the error sets to obtain a corresponding new Intermediate model
    其中,所述验证单元还用于利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。The verification unit is further configured to use the verification set to verify the new intermediate model again, until the number of the error concentration error samples is less than a preset threshold, and determine that the new intermediate model at this time is Corresponding preset detection model.
  8. 如权利要求6所述的终端,其特征在于,所述预处理单元,包括:The terminal according to claim 6, wherein the preprocessing unit comprises:
    强化单元,用于对获取的待测图片数据进行特征强化;a strengthening unit, configured to perform feature enhancement on the acquired image data to be tested;
    划分单元,用于根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片;a dividing unit, configured to divide the image data to be tested after feature enhancement according to a preset rule to obtain one or more sub-pictures;
    其中,所述检测单元还用于将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。The detecting unit is further configured to input all the sub-pictures into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the Detect the confidence level corresponding to the model.
  9. 如权利要求8所述的终端,其特征在于,所述强化单元,包括:The terminal according to claim 8, wherein the strengthening unit comprises:
    所述调整单元,用于将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片。The adjusting unit is configured to adjust the acquired picture data to be tested and all preset picture data to 256*256 RGB pictures.
    所述平均值计算单元,用于计算被调整为RGB图片后的所有预设图片数据的像素平均值。The average value calculating unit is configured to calculate a pixel average value of all preset picture data after being adjusted to an RGB picture.
    所述目标计算单元,用于将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The target calculation unit is configured to subtract the pixel average value from the pixels of the image data to be measured adjusted to the RGB image to obtain the image data to be tested after the feature enhancement.
  10. 如权利要求6所述的终端,其特征在于,卷积神经网络的数量为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。The terminal according to claim 6, wherein the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second convolutional nerve having a twenty-two-layer structure A network, wherein the first convolutional neural network comprises five convolutional layers, two fully connected layers, and one probability statistical layer.
  11. 一种基于卷积神经网络的不雅图片识别设备,其特征在于,包括:An indecent picture recognition device based on a convolutional neural network, comprising:
    存储器,用于存储实现不雅图片识别的程序;以及a memory for storing a program that implements indecent picture recognition;
    处理器,用于运行所述存储器中存储的实现不雅图片识别的程序,以执行以下操作:a processor for running a program for realizing indecent picture recognition stored in the memory to perform the following operations:
    对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
    将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
    根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
    判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
    若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
  12. 如权利要求11所述的设备,其特征在于,所述对获取的待测图片数据进行预处理之前,包括:The device according to claim 11, wherein before the pre-processing of the acquired image data to be tested, the method comprises:
    将预设的图片数据分为训练集以及验证集;The preset picture data is divided into a training set and a verification set;
    利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型;Training a plurality of different convolutional neural networks with the training set to obtain a plurality of corresponding intermediate models;
    利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本;Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
    若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型;If the number of the error concentration error samples is greater than or equal to the preset threshold, the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model;
    利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。The new intermediate model is verified again by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding preset detection model.
  13. 如权利要求11所述的设备,其特征在于,述对获取的待测图片数据进行预处理,包括:The device according to claim 11, wherein the pre-processing of the acquired image data to be tested comprises:
    对获取的待测图片数据进行特征强化;Performing feature enhancement on the acquired image data to be tested;
    根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片;Dividing the image data to be tested after feature enhancement according to a preset rule to obtain one or more sub-pictures;
    其中,将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。Wherein, all the sub-pictures are input into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
  14. 如权利要求13所述的设备,其特征在于,所述对获取的待测图片数据进行特征强化,包括:The device according to claim 13, wherein the characterizing the acquired image data to be tested comprises:
    将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片;Adjusting the acquired image data to be tested and all preset image data to 256*256 RGB images;
    计算被调整为RGB图片后的所有预设图片数据的像素平均值;Calculating a pixel average of all preset picture data after being adjusted to an RGB picture;
    将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
  15. 如权利要求11所述的设备,其特征在于,卷积神经网络的数量为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。The apparatus according to claim 11, wherein the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second convolutional nerve having a twenty-two-layer structure A network, wherein the first convolutional neural network comprises five convolutional layers, two fully connected layers, and one probability statistical layer.
  16. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有一个或者一个以上程序,所述一个或者一个以上程序可被一个或者一个以上的处理器执行,以实现以下步骤:A computer readable storage medium, characterized in that the computer readable storage medium stores one or more programs, the one or more programs being executable by one or more processors to implement the following steps:
    对获取的待测图片数据进行预处理;Pre-processing the acquired image data to be tested;
    将预处理后的待测图片数据分别输入多个预设检测模型以对应地得到多个不同的置信度;The pre-processed picture data to be tested is respectively input into a plurality of preset detection models to correspondingly obtain a plurality of different confidence levels;
    根据预设的线性加权比对所有的置信度进行计算以得到一图片置信度,其中,所述预设的线性加权比包括多个比值,所述比值的数量与所述检测模型的数量相同,且每个比值均对应一不同的检测模型;Calculating all the confidences according to a preset linear weighting ratio to obtain a picture confidence, wherein the preset linear weighting ratio includes a plurality of ratios, the number of the ratios being the same as the number of the detection models, And each ratio corresponds to a different detection model;
    判断所述图片置信度是否大于预设置信度;Determining whether the picture confidence is greater than a preset reliability;
    若所述图片置信度大于预设置信度,判定所述待测图片数据为不雅图片数据。If the picture confidence is greater than the preset reliability, the picture data to be tested is determined to be indecent picture data.
  17. 如权利要求16所述的计算机可读存储介质,其特征在于,所述对获取的待测图片数据进行预处理之前,包括:The computer readable storage medium according to claim 16, wherein the pre-processing of the acquired image data to be tested comprises:
    将预设的图片数据分为训练集以及验证集;The preset picture data is divided into a training set and a verification set;
    利用所述训练集对多个不同的卷积神经网络进行训练,以得到多个对应的中间模型;Training a plurality of different convolutional neural networks with the training set to obtain a plurality of corresponding intermediate models;
    利用所述验证集对所有的中间模型进行验证,以得到多个对应的错误集,其中每个错误集均包括至少一个错误样本;Verifying all intermediate models with the verification set to obtain a plurality of corresponding error sets, wherein each error set includes at least one error sample;
    若其中一错误集中错误样本的数量大于或等于预设阀值,利用所述其中一错误集训练与所述其中一错误集相对应的中间模型以得到一个对应的新的中间模型;If the number of the error concentration error samples is greater than or equal to the preset threshold, the intermediate model corresponding to the one of the error sets is trained by using one of the error sets to obtain a corresponding new intermediate model;
    利用所述验证集对所述新的中间模型再次进行验证,直至所述错误集中错误样本的数量小于预设阀值,并判定此时的新的中间模型为对应的预设检测模型。The new intermediate model is verified again by using the verification set until the number of error concentration error samples is less than a preset threshold, and it is determined that the new intermediate model at this time is a corresponding preset detection model.
  18. 如权利要求16所述的计算机可读存储介质,其特征在于,所述对获取的待测图片数据进行预处理,包括:The computer readable storage medium according to claim 16, wherein the preprocessing the acquired image data to be tested comprises:
    对获取的待测图片数据进行特征强化;Performing feature enhancement on the acquired image data to be tested;
    根据预设规则将特征强化后的待测图片数据进行划分以得到一个或多个子图片;Dividing the image data to be tested after feature enhancement according to a preset rule to obtain one or more sub-pictures;
    其中,将所有子图片输入每个检测模型,以使每个检测模型对应地得到一个或多个子置信度,并判定每个检测模型对应的最大的子置信度为该检测模型对应的置信度。Wherein, all the sub-pictures are input into each detection model, so that each detection model correspondingly obtains one or more sub-confidences, and determines that the maximum sub-confidence corresponding to each detection model is the confidence level corresponding to the detection model.
  19. 如权利要求18所述的计算机可读存储介质,其特征在于,所述对获取的待测图片数据进行特征强化,包括:The computer readable storage medium according to claim 18, wherein the performing feature enhancement on the acquired image data to be tested comprises:
    将获取的待测图片数据以及所有预设图片数据调整为256*256的RGB图片;Adjusting the acquired image data to be tested and all preset image data to 256*256 RGB images;
    计算被调整为RGB图片后的所有预设图片数据的像素平均值;Calculating a pixel average of all preset picture data after being adjusted to an RGB picture;
    将被调整为RGB图片的待测图片数据的像素减去所述像素平均值以得到特征强化后的待测图片数据。The pixels of the image to be tested that are adjusted to be RGB pictures are subtracted from the average of the pixels to obtain the picture data to be tested after feature enhancement.
  20. 如权利要求16所述的计算机可读存储介质,其特征在于,卷积神经网络的数量为两个,包括一个具有八层结构的第一卷积神经网络以及一个具有二十二层结构的第二卷积神经网络,其中所述第一卷积神经网络包括五个卷积层、两个全连接层以及一个概率统计层。A computer readable storage medium according to claim 16, wherein the number of convolutional neural networks is two, including a first convolutional neural network having an eight-layer structure and a second having a twenty-two-layer structure A second convolutional neural network, wherein the first convolutional neural network comprises five convolutional layers, two fully connected layers, and one probability statistical layer.
PCT/CN2017/102866 2017-08-28 2017-09-22 Indecent picture recognition method, terminal and device, and computer-readable storage medium WO2019041406A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710752783.2 2017-08-28
CN201710752783.2A CN107665333A (en) 2017-08-28 2017-08-28 A kind of indecency image identification method, terminal, equipment and computer-readable recording medium based on convolutional neural networks

Publications (1)

Publication Number Publication Date
WO2019041406A1 true WO2019041406A1 (en) 2019-03-07

Family

ID=61098257

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/102866 WO2019041406A1 (en) 2017-08-28 2017-09-22 Indecent picture recognition method, terminal and device, and computer-readable storage medium

Country Status (2)

Country Link
CN (1) CN107665333A (en)
WO (1) WO2019041406A1 (en)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110084130A (en) * 2019-04-03 2019-08-02 深圳鲲云信息科技有限公司 Face screening technique, device, equipment and storage medium based on multiple target tracking
CN110083517A (en) * 2019-04-29 2019-08-02 秒针信息技术有限公司 A kind of optimization method and device of user's portrait confidence level
CN110232401A (en) * 2019-05-05 2019-09-13 平安科技(深圳)有限公司 Lesion judgment method, device, computer equipment based on picture conversion
CN111652259A (en) * 2019-04-16 2020-09-11 上海铼锶信息技术有限公司 Method and system for cleaning data
CN111968078A (en) * 2020-07-28 2020-11-20 北京恒通智控机器人科技有限公司 Appearance detection method, device, equipment and storage medium for power transformation equipment
CN112182441A (en) * 2019-07-02 2021-01-05 中国移动通信集团贵州有限公司 Method and device for detecting violation data
CN113763348A (en) * 2021-09-02 2021-12-07 北京格灵深瞳信息技术股份有限公司 Image quality determination method and device, electronic equipment and storage medium
WO2021243724A1 (en) * 2020-06-05 2021-12-09 北京嘀嘀无限科技发展有限公司 Image processing method, electronic device, vehicle traveling data recorder, and server
CN110298541B (en) * 2019-05-23 2024-04-09 中国平安人寿保险股份有限公司 Data processing method, device, computer equipment and storage medium

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110136198B (en) * 2018-02-09 2023-10-03 腾讯科技(深圳)有限公司 Image processing method, apparatus, device and storage medium thereof
CN108491866B (en) * 2018-03-06 2022-09-13 平安科技(深圳)有限公司 Pornographic picture identification method, electronic device and readable storage medium
CN108564138A (en) * 2018-05-08 2018-09-21 广州优视网络科技有限公司 Pornographic applies detection method, device, computer readable storage medium and server
CN109034279B (en) * 2018-06-04 2023-04-25 平安科技(深圳)有限公司 Handwriting model training method, handwriting character recognition method, device, equipment and medium
CN109272016B (en) * 2018-08-08 2021-03-23 广州视源电子科技股份有限公司 Target detection method, device, terminal equipment and computer readable storage medium
CN110875875B (en) * 2018-09-03 2022-04-22 Oppo广东移动通信有限公司 Electronic red packet message detection method and device and terminal equipment
CN109491970A (en) * 2018-10-11 2019-03-19 平安科技(深圳)有限公司 Imperfect picture detection method, device and storage medium towards cloud storage
CN109241951A (en) * 2018-10-26 2019-01-18 北京陌上花科技有限公司 Porny recognition methods, identification model construction method and identification model and computer readable storage medium
CN109886865B (en) * 2019-01-07 2024-01-23 平安科技(深圳)有限公司 Method, device, computer equipment and storage medium for automatically shielding bad information
CN110414471B (en) * 2019-08-06 2022-02-01 福建省趋普物联科技有限公司 Video identification method and system based on double models
CN112529152A (en) * 2020-12-03 2021-03-19 开放智能机器(上海)有限公司 System and method for detecting watermelon maturity based on artificial intelligence
CN113076998A (en) * 2021-04-01 2021-07-06 重庆邮电大学 Distributed classification method based on kubernets deep neural network model
WO2023061506A1 (en) * 2021-10-15 2023-04-20 北京极智嘉科技股份有限公司 Container identification method and apparatus, container access device, and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101081168A (en) * 2007-07-06 2007-12-05 深圳市迈科龙电子有限公司 Method for shielding sex part on foetus image for preventing recognizing foetus sex
CN105808610A (en) * 2014-12-31 2016-07-27 中国科学院深圳先进技术研究院 Internet picture filtering method and device
CN105989330A (en) * 2015-02-03 2016-10-05 阿里巴巴集团控股有限公司 Picture detection method and apparatus
WO2017096758A1 (en) * 2015-12-11 2017-06-15 腾讯科技(深圳)有限公司 Image classification method, electronic device, and storage medium
CN106951848A (en) * 2017-03-13 2017-07-14 平安科技(深圳)有限公司 The method and system of picture recognition

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104881673B (en) * 2014-02-28 2018-06-01 国际商业机器公司 The method and system of pattern-recognition based on information integration
CN104182735A (en) * 2014-08-18 2014-12-03 厦门美图之家科技有限公司 Training optimization pornographic picture or video detection method based on convolutional neural network
CN106295502B (en) * 2016-07-25 2019-07-12 厦门中控智慧信息技术有限公司 A kind of method for detecting human face and device
CN106776842B (en) * 2016-11-28 2021-03-19 腾讯科技(上海)有限公司 Multimedia data detection method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101081168A (en) * 2007-07-06 2007-12-05 深圳市迈科龙电子有限公司 Method for shielding sex part on foetus image for preventing recognizing foetus sex
CN105808610A (en) * 2014-12-31 2016-07-27 中国科学院深圳先进技术研究院 Internet picture filtering method and device
CN105989330A (en) * 2015-02-03 2016-10-05 阿里巴巴集团控股有限公司 Picture detection method and apparatus
WO2017096758A1 (en) * 2015-12-11 2017-06-15 腾讯科技(深圳)有限公司 Image classification method, electronic device, and storage medium
CN106951848A (en) * 2017-03-13 2017-07-14 平安科技(深圳)有限公司 The method and system of picture recognition

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110084130B (en) * 2019-04-03 2023-07-25 深圳鲲云信息科技有限公司 Face screening method, device, equipment and storage medium based on multi-target tracking
CN110084130A (en) * 2019-04-03 2019-08-02 深圳鲲云信息科技有限公司 Face screening technique, device, equipment and storage medium based on multiple target tracking
CN111652259B (en) * 2019-04-16 2024-03-08 上海铼锶信息技术有限公司 Method and system for cleaning data
CN111652259A (en) * 2019-04-16 2020-09-11 上海铼锶信息技术有限公司 Method and system for cleaning data
CN110083517A (en) * 2019-04-29 2019-08-02 秒针信息技术有限公司 A kind of optimization method and device of user's portrait confidence level
CN110083517B (en) * 2019-04-29 2023-08-25 秒针信息技术有限公司 User image confidence optimization method and device
CN110232401B (en) * 2019-05-05 2023-08-04 平安科技(深圳)有限公司 Focus judging method, device and computer equipment based on picture conversion
CN110232401A (en) * 2019-05-05 2019-09-13 平安科技(深圳)有限公司 Lesion judgment method, device, computer equipment based on picture conversion
CN110298541B (en) * 2019-05-23 2024-04-09 中国平安人寿保险股份有限公司 Data processing method, device, computer equipment and storage medium
CN112182441A (en) * 2019-07-02 2021-01-05 中国移动通信集团贵州有限公司 Method and device for detecting violation data
WO2021243724A1 (en) * 2020-06-05 2021-12-09 北京嘀嘀无限科技发展有限公司 Image processing method, electronic device, vehicle traveling data recorder, and server
CN111968078A (en) * 2020-07-28 2020-11-20 北京恒通智控机器人科技有限公司 Appearance detection method, device, equipment and storage medium for power transformation equipment
CN113763348A (en) * 2021-09-02 2021-12-07 北京格灵深瞳信息技术股份有限公司 Image quality determination method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN107665333A (en) 2018-02-06

Similar Documents

Publication Publication Date Title
WO2019041406A1 (en) Indecent picture recognition method, terminal and device, and computer-readable storage medium
WO2015127859A1 (en) Sensitive text detecting method and apparatus
WO2019029261A1 (en) Micro-expression recognition method, device and storage medium
WO2015184760A1 (en) Air gesture input method and apparatus
WO2016082267A1 (en) Voice recognition method and system
WO2019051899A1 (en) Terminal control method and device, and storage medium
WO2019080249A1 (en) Alarm processing method and apparatus, computer device, and storage medium
WO2020080827A1 (en) Ai encoding apparatus and operation method of the same, and ai decoding apparatus and operation method of the same
WO2015184982A1 (en) Classifier training method and apparatus, identity authentication method and system
WO2019085495A1 (en) Micro-expression recognition method, apparatus and system, and computer-readable storage medium
EP3903240A1 (en) Device and method for compressing machine learning model
WO2019051890A1 (en) Terminal control method and device, and computer-readable storage medium
WO2019051895A1 (en) Terminal control method and device, and storage medium
WO2018149191A1 (en) Method, apparatus and device for underwriting insurance policy, and computer-readable storage medium
WO2021261830A1 (en) Video quality assessment method and apparatus
WO2019019376A1 (en) Service process management method, apparatus, and device, and computer readable storage medium
WO2018233367A1 (en) Case registration method and apparatus, terminal, and computer readable storage medium
WO2019085103A1 (en) Training management method, device, computer apparatus, and storage medium
WO2020010671A1 (en) Display method and device, television set, and storage medium
WO2018166236A1 (en) Claim settlement bill recognition method, apparatus and device, and computer-readable storage medium
WO2022154471A1 (en) Image processing method, image processing apparatus, electronic device and computer-readable storage medium
WO2019019351A1 (en) User behaviour data processing method and apparatus, and computer readable storage medium
WO2019051866A1 (en) Right and interest information management method, device, and apparatus, and computer-readable storage medium
WO2017084337A1 (en) Identity verification method, apparatus and system
WO2017217656A1 (en) Method and apparatus for video compression and computer program therefor

Legal Events

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

Ref document number: 17923346

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

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

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

122 Ep: pct application non-entry in european phase

Ref document number: 17923346

Country of ref document: EP

Kind code of ref document: A1