WO2021082428A1 - 基于半监督学习的图片分类方法、装置和计算机设备 - Google Patents

基于半监督学习的图片分类方法、装置和计算机设备 Download PDF

Info

Publication number
WO2021082428A1
WO2021082428A1 PCT/CN2020/093430 CN2020093430W WO2021082428A1 WO 2021082428 A1 WO2021082428 A1 WO 2021082428A1 CN 2020093430 W CN2020093430 W CN 2020093430W WO 2021082428 A1 WO2021082428 A1 WO 2021082428A1
Authority
WO
WIPO (PCT)
Prior art keywords
picture
oct
feature vector
vector
preset
Prior art date
Application number
PCT/CN2020/093430
Other languages
English (en)
French (fr)
Inventor
郭晏
张成奋
吕彬
吕传峰
谢国彤
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2021082428A1 publication Critical patent/WO2021082428A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/22Matching criteria, e.g. proximity measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques

Definitions

  • This application relates to the field of artificial intelligence, and in particular to a method, device, computer equipment and storage medium for image classification based on semi-supervised learning.
  • OCT optical coherence tomography
  • the main purpose of this application is to provide a method, device, computer equipment and storage medium for image classification based on semi-supervised learning, aiming to improve the accuracy of OCT image classification.
  • this application proposes a method for image classification based on semi-supervised learning, which includes the following steps:
  • the feature vector generator in the preset OCT picture classification model to process the OCT picture to be classified to obtain the first feature vector X generated by the first encoder of the feature vector generator; wherein
  • the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected;
  • the OCT image classification model is obtained by training with sample data through a semi-supervised learning training method, and the sample data is only composed of negative OCT picture composition;
  • the OCT picture to be classified is classified as a negative picture.
  • This application provides a picture classification device based on semi-supervised learning, including:
  • the OCT picture obtaining unit is used to obtain the OCT picture to be classified
  • the first feature vector X generating unit is configured to use the feature vector generator in the preset OCT image classification model to process the OCT picture to be classified to obtain the feature vector generator generated by the first encoder
  • the first feature vector X wherein the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected; the OCT image classification model is trained using sample data through a semi-supervised learning training method As a result, the sample data is only composed of negative OCT pictures;
  • a decoded picture acquiring unit configured to use the first decoder to decode the first feature vector X to obtain a decoded picture
  • a second feature vector Y generating unit configured to encode the decoded picture by using the second encoder to generate a second feature vector Y;
  • the similarity threshold judgment unit is configured to calculate the similarity value of the first feature vector X and the second feature vector Y according to a preset similarity calculation method, and determine whether the similarity value is greater than a preset Similarity threshold;
  • the negative picture classification unit is configured to classify the OCT picture to be classified as a negative picture if the similarity value is greater than a preset similarity threshold.
  • the present application provides a computer device, including a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, a method for image classification based on semi-supervised learning is implemented, including the following steps:
  • the feature vector generator in the preset OCT picture classification model to process the OCT picture to be classified to obtain the first feature vector X generated by the first encoder of the feature vector generator; wherein
  • the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected;
  • the OCT image classification model is obtained by training with sample data through a semi-supervised learning training method, and the sample data is only composed of negative OCT picture composition;
  • the OCT picture to be classified is classified as a negative picture.
  • the present application provides a computer-readable storage medium on which a computer program is stored.
  • a method for image classification based on semi-supervised learning is realized, which includes the following steps:
  • the feature vector generator in the preset OCT picture classification model to process the OCT picture to be classified to obtain the first feature vector X generated by the first encoder of the feature vector generator; wherein
  • the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected;
  • the OCT image classification model is obtained by training with sample data through a semi-supervised learning training method, and the sample data is only composed of negative OCT picture composition;
  • the OCT picture to be classified is classified as a negative picture.
  • the semi-supervised learning-based image classification method, device, computer equipment, and storage medium of the present application obtain the OCT image to be classified; use the feature vector generator in the preset OCT image classification model to perform the classification on the OCT image to be classified Processing to obtain a first feature vector X generated by the first encoder of the feature vector generator; use the first decoder to decode the first feature vector X to obtain a decoded picture; use the The second encoder encodes the decoded picture to generate a second feature vector Y; calculates the similarity value between the first feature vector X and the second feature vector Y according to a preset similarity calculation method, And it is determined whether the similarity value is greater than a preset similarity threshold; if the similarity value is greater than the preset similarity threshold, the OCT picture to be classified is classified as a negative picture. In this way, OCT image classification is completed without the need for positive data, and the defect of difficulty in collecting positive data is overcome.
  • FIG. 1 is a schematic flowchart of a picture classification method based on semi-supervised learning according to an embodiment of this application;
  • FIG. 2 is a schematic block diagram of the structure of a picture classification device based on semi-supervised learning according to an embodiment of the application;
  • FIG. 3 is a schematic block diagram of the structure of a computer device according to an embodiment of the application.
  • an embodiment of the present application provides a method for image classification based on semi-supervised learning, including the following steps:
  • the feature vector generator in the preset OCT picture classification model to process the OCT picture to be classified to obtain the first feature vector X generated by the first encoder of the feature vector generator; where
  • the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected;
  • the OCT image classification model is obtained by training with sample data through a semi-supervised learning training method, and the sample data is only Consists of negative OCT pictures;
  • the semi-supervised learning-based image classification method of the present application is used for any feasible use other than disease diagnosis and treatment methods, for example, used to analyze and organize a large number of unclassified OCT images to classify and store OCT images of different categories. It is convenient for data storage and data analysis.
  • OCT images optical coherence tomography images
  • OCT images are images that use the principle of bright coherence to perform tomography, for example, are suitable for the exploration of ocular structure.
  • the initial state of OCT pictures is to be classified, and ordinary people lack sufficient knowledge to classify OCT pictures.
  • the OCT picture to be classified can be classified through the preset OCT picture classification model.
  • the feature vector generator in the preset OCT picture classification model is used to process the OCT picture to be classified to obtain the first code generated by the first encoder of the feature vector generator.
  • Feature vector X wherein the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected;
  • the OCT image classification model is obtained by training with sample data through a semi-supervised learning training method, The sample data consists of only negative OCT pictures.
  • the OCT picture classification model may have any structure, for example, a network structure based on a deep convolutional confrontation generation network.
  • the OCT picture classification model of the present application includes a feature vector generator, and the feature vector generator is used to classify OCT pictures during normal operation.
  • the feature vector generator has a first encoder, a first decoder, and a second encoder that are sequentially connected, which is not available in ordinary deep convolutional confrontation generation networks. It is based on the first encoder, the first decoder, and the In the second encoder, the positive picture cannot be fully extracted by the first encoder after being transmitted to the network, and therefore cannot be completely reconstructed by the first decoder. Therefore, the decoded picture generated by the first decoder has feature loss compared with the positive picture. Eventually, the feature Y generated by the second encoder does not match the feature X generated by the first encoder, and the feature Y obtained by the negative image is very close to the feature X and basically matches, so the abnormal image is detected.
  • the OCT picture classification model further includes a discriminator for discriminating whether the OCT picture and the decoded picture are similar, and the feature vector generator and the discriminator use the same sample data. training.
  • the first encoder may have any structure, for example, a convolutional network composed of multiple convolutional layers, and its final output is a feature vector.
  • the first feature vector X is decoded by the first decoder to obtain a decoded picture.
  • the first decoder can be a decoder of any structure, but the first feature vector X can be, for example, a multi-layer network structure that can perform multiple convolution and deconvolution operations. Since the first decoder is based on the decoding processing of the first feature vector X, and the first feature vector X is extracted from the OCT picture to be classified, if the data loss in the extraction process is too much, it will cause the decoded picture and the to be classified The OCT picture is too different.
  • the first decoder obtains the result on the premise that the OCT picture to be classified is a negative picture
  • the decoded picture of is the same or similar to the OCT picture to be classified; and if the OCT picture to be classified is a positive picture, the decoded picture obtained by the first decoder is different from the OCT picture to be classified of.
  • the second encoder is used to encode the decoded picture, thereby generating a second feature vector Y.
  • the second encoder may have any structure, for example, a convolutional network composed of multiple convolutional layers, and its final output is a feature vector.
  • the structure of the second encoder is the same as that of the first encoder, or is different from the first encoder, but can also be used to encode the decoded picture to generate a second feature vector Y.
  • the similarity calculation method calculates the similarity value of the first feature vector X and the second feature vector Y, and determine whether the similarity value is greater than the preset similarity Degree threshold.
  • the similarity calculation method can be any method, for example, according to the formula:
  • the similarity value dis of the first feature vector X and the second feature vector Y is calculated, where xi is the value of the i-th component of the first feature vector X, and yi is the first feature The value of the i-th component vector of the vector Y.
  • Both the first feature vector X and the second feature vector Y include n component vectors.
  • the OCT picture to be classified is classified as a negative picture. If the OCT picture to be classified is not a negative picture, the feature is inevitably lost during a series of processing of the first encoder, the first decoder, and the second encoder (because this application is based on semi-supervised learning, Only negative pictures are used for training, so only on the premise of negative pictures, there may be no feature loss), and the final similarity value will not be greater than the preset similarity threshold. Accordingly, if the similarity value is greater than the preset similarity threshold, it indicates that the first feature vector X and the second feature vector Y are the same or similar, and the OCT pictures to be classified are classified accordingly.
  • the generator part in this application is improved.
  • the image is directly used as input, the image is converted to the feature space through the first encoder, and then the feature vector is reconstructed by the first decoder to generate the decoded image, and then the additional second is connected.
  • the second encoder re-converts the generated image to the feature space, and compares the output of the first encoder and the second encoder to realize the classification of OCT images, which not only has a much higher detection accuracy than traditional algorithms, but also has better detection accuracy. High test efficiency. Further, if the similarity value is not greater than a preset similarity threshold, either the OCT picture to be classified is directly classified as a positive picture, or the OCT picture to be classified is further analyzed whether it is a positive picture.
  • the OCT picture classification model further includes a discriminator for discriminating whether the OCT picture and the decoded picture are the same, and the feature vector generator and the discriminator use the same
  • the sample data are jointly trained, and the feature vector generator in the preset OCT image classification model is used to process the OCT pictures to be classified to obtain the first encoder generated by the first encoder of the feature vector generator.
  • Feature vector X wherein the feature vector generator includes a first encoder, a first decoder, and a second encoder that are sequentially connected;
  • the OCT image classification model is obtained by training with sample data through a semi-supervised learning training method, Before step S2 in which the sample data is composed of only negative OCT pictures, it includes:
  • S13 Determine whether the first vector similarity value is greater than a preset vector similarity threshold, and determine whether the first picture similarity value is greater than a preset picture similarity threshold;
  • the first vector similarity value is greater than a preset vector similarity threshold, and the first picture similarity value is greater than a preset picture similarity threshold, the parameters of the OCT picture classification model are not changed, and the parameters of the OCT picture classification model are not changed, and the parameters of the OCT picture classification model are not changed.
  • the designated negative OCT picture is deleted from the training set.
  • the OCT picture classification model further includes a discriminator for discriminating whether the OCT picture and the decoded picture are the same, and the feature vector generator and the discriminator are jointly trained using the same sample data.
  • the discriminator only works during the training process, but does not work during the image classification process, thereby optimizing the OCT image classification model and improving the speed of image classification. And because the same training data is used for common training, the discriminator and the feature vector generator are more adaptable and more robust.
  • the training set only includes negative OCT pictures.
  • the model can correctly classify the designated negative OCT pictures, without changing the parameters of the OCT picture classification model, and delete the designated negative OCT pictures from the training set.
  • the discriminator can be of any structure, for example, a deep convolutional network composed of a series of convolutional layers and pooling layers.
  • the step S12 of calculating the first picture similarity value between the designated negative OCT picture and the temporary picture includes:
  • S121 sequentially compare corresponding pixels in the designated negative OCT picture and the temporary picture, and count the number of the same pixels;
  • the same proportion the number of the same pixels/the number of all the pixels in the designated negative OCT picture, the same proportion value is calculated;
  • the calculation of the first picture similarity value between the designated negative OCT picture and the temporary picture is realized.
  • the method includes :
  • the first vector similarity value is not greater than a preset vector similarity threshold, or the first picture similarity value is not greater than a preset picture similarity threshold, use to increase the first vector similarity value. Or the principle of increasing the similarity value of the first picture, and using the reverse propagation rule to jointly update the parameters of the feature vector generator and the discriminator in the OCT picture classification model;
  • S134 Determine whether the second vector similarity value is greater than a preset vector similarity threshold, and determine whether the second picture similarity value is greater than a preset picture similarity threshold;
  • the parameter update is realized. If the first vector similarity value is not greater than the preset vector similarity threshold, or the first picture similarity value is not greater than the preset image similarity threshold, it indicates that the current OCT image classification model cannot perform the specified negative OCT The pictures are correctly classified, so the parameters of the OCT picture classification model need to be updated. Among them, the parameter update adopts the reverse conduction rule for common update.
  • the reverse conduction law is based on the gradient descent method, and its input-output relationship is essentially a mapping relationship: the function of a neural network with n inputs and m outputs is from n-dimensional Euclidean space to m-dimensional Ou A continuous mapping of a finite field in the space, this mapping has a high degree of non-linearity.
  • the information processing ability of the network of the reverse conduction law comes from the multiple recombination of simple non-linear functions, so it has strong function reproducibility.
  • the principle of the parameter update is to increase the similarity value of the first vector or increase the similarity value of the first picture.
  • the second vector similarity value is greater than the preset vector similarity threshold, and it is determined whether the second picture similarity value is greater than the preset picture similarity threshold. If the second vector similarity value is greater than the preset vector similarity threshold, and the second picture similarity value is greater than the preset picture similarity threshold, it indicates that the OCT picture classification model can perform the specified negative OCT picture According to the correct classification, the parameters of the OCT picture classification model are not changed, and the designated negative OCT picture is deleted from the training set.
  • the first encoder and the second encoder each include multiple convolutional layers
  • the OCT picture classification model further includes a convolutional image discriminator
  • the second encoder Before step S4 of encoding the decoded picture to generate a second feature vector Y, the method includes:
  • the structure of the first encoder and the second encoder may be the same or different, but both include multiple convolutional layers, and the first encoder includes a designated convolutional layer (used to output the first convolutional layer).
  • Image the second encoder includes a convolution layer corresponding to the specified convolution layer (used to output a second convolution image), where the specified convolution layer is, for example, the second convolution layer of the first encoder,
  • the corresponding convolutional layer corresponding to the designated convolutional layer is, for example, the second convolutional layer of the second encoder.
  • the convolution image discriminator receives the first convolution image and the second convolution image, and is used to discriminate whether the first convolution image and the second convolution image are similar. If the discrimination result is dissimilar, it indicates that the OCT picture classification model has lost too many features during the classification process, that is, the OCT picture to be classified is not a negative picture (because the OCT picture classification model is only trained by negative pictures. Therefore, when the non-negative image is processed, the feature loss will occur). If the discrimination result is similar, a second encoder needs to be used for further classification, and an encoding instruction is generated accordingly. The encoding instruction is used to instruct to use the second encoder to encode the decoded picture. Therefore, by setting a convolutional image discriminator, non-negative pictures are recognized in advance, and the accuracy of classification is further improved.
  • the similarity value of the first feature vector X and the second feature vector Y is calculated according to a preset similarity calculation method, and it is determined whether the similarity value is greater than a preset Step S5 of the similarity threshold includes:
  • the similarity value dis of the first feature vector X and the second feature vector Y is calculated, where xi is the value of the i-th component of the first feature vector X, and yi is the first feature
  • the value of the i-th component vector of the vector Y, the first feature vector X and the second feature vector Y each include n component vectors;
  • S502 Determine whether the similarity value dis is greater than a preset similarity threshold.
  • the similarity value of the first feature vector X and the second feature vector Y is calculated, and it is determined whether the similarity value is greater than the preset similarity. Threshold.
  • the formula of the preset similarity calculation method is:
  • the similarity value dis is equal to 1, that is, the maximum value of the similarity value dis is 1. The farther the similarity value dis is from the value 1, the more dissimilar the first feature vector X and the second feature vector Y are. Therefore, the similarity value dis can measure the degree of similarity between the first feature vector X and the second feature vector Y.
  • the similarity value dis is greater than the preset similarity threshold, it is determined that the first feature vector X and the second feature vector Y are similar, which also indicates that the OCT picture to be classified is the OCT picture classification model It can be fully recognized, so the OCT picture to be classified is a negative picture (therefore, the OCT picture classification model is only obtained by training negative pictures, and therefore can only fully recognize negative pictures).
  • the similarity value of the first feature vector X and the second feature vector Y is calculated according to a preset similarity calculation method, and it is determined whether the similarity value is greater than a preset After step S5 of the similarity threshold, it includes:
  • the similarity value is not greater than a preset similarity threshold, input the OCT picture to be classified into a preset positive picture classification model based on a deep convolutional confrontation generation network for processing, and the positive picture
  • the classification model is obtained by training with sample data through a semi-supervised learning training method, where the sample data is only composed of positive OCT pictures;
  • the input picture may be entered incorrectly. For example, if a non-OCT picture is input into the OCT picture classification model, the classification result is not negative, but it should not be classified as positive either. Or the input picture is a special negative picture (which is quite different from the negative picture used for training), so the OCT picture classification model cannot perform correct classification.
  • this application additionally sets up a positive picture classification model based on a deep convolutional adversarial generation network for processing.
  • the positive picture classification model is trained using sample data through a semi-supervised learning training method, where the sample data is only The positive OCT pictures are formed to further identify the positive pictures.
  • the structure of the positive picture classification model may be the same as the OCT picture classification model, or it may be the structure of a traditional deep convolutional confrontation generation network. If the processing result output by the positive picture classification model is positive, it indicates that the positive picture classification model can accurately identify the OCT pictures to be classified, and the positive picture classification model is only obtained by training the positive OCT pictures. The OCT picture to be classified is classified as a positive picture.
  • an embodiment of the present application provides a picture classification device based on semi-supervised learning, including:
  • the OCT picture obtaining unit 10 is configured to obtain OCT pictures to be classified
  • the first feature vector X generating unit 20 is configured to use the feature vector generator in the preset OCT picture classification model to process the OCT picture to be classified to obtain the first encoder by the feature vector generator The generated first feature vector X; wherein the feature vector generator includes a first encoder, a first decoder, and a second encoder connected in sequence; the OCT image classification model adopts sample data through a semi-supervised learning training method Obtained by training, the sample data is only composed of negative OCT pictures;
  • the decoded picture acquiring unit 30 is configured to use the first decoder to decode the first feature vector X to obtain a decoded picture;
  • the second feature vector Y generating unit 40 is configured to use the second encoder to encode the decoded picture to generate a second feature vector Y;
  • the similarity threshold judgment unit 50 is configured to calculate the similarity value of the first feature vector X and the second feature vector Y according to a preset similarity calculation method, and determine whether the similarity value is greater than a preset The similarity threshold;
  • the negative picture classification unit 60 is configured to classify the OCT picture to be classified as a negative picture if the similarity value is greater than a preset similarity threshold.
  • the OCT picture classification model further includes a discriminator for discriminating whether the OCT picture and the decoded picture are the same, and the feature vector generator and the discriminator use the same
  • the sample data is jointly trained, and the device includes:
  • the designated negative OCT picture extraction unit is used to extract designated negative OCT pictures from a preset training set, and input the designated negative OCT pictures into the feature vector generator, thereby obtaining the first code of the feature vector generator A first training vector A1 generated by a first decoder, a temporary picture generated by a first decoder, and a second training vector A2 generated by a second encoder;
  • the similarity value calculation unit is used to calculate the first vector similarity value between the first training vector A1 and the second training vector A2, and use the discriminator to calculate the specified negative OCT picture and the The first picture similarity value between the temporary pictures;
  • a similarity threshold determination unit configured to determine whether the first vector similarity value is greater than a preset vector similarity threshold, and determine whether the first picture similarity value is greater than a preset picture similarity threshold;
  • Specify a negative OCT picture deletion unit configured to not change the OCT picture if the first vector similarity value is greater than a preset vector similarity threshold, and the first picture similarity value is greater than a preset picture similarity threshold Classify the parameters of the model, and delete the designated negative OCT picture from the training set.
  • the similarity value calculation unit includes:
  • the same pixel point counting subunit is used to sequentially compare the corresponding pixels in the designated negative OCT picture and the temporary picture, and count the number of identical pixels;
  • the first picture similarity value marking subunit is used to record the same proportion value as the first picture similarity value between the designated negative OCT picture and the temporary picture.
  • the device includes:
  • the parameter update unit is configured to: if the first vector similarity value is not greater than a preset vector similarity threshold, or the first picture similarity value is not greater than a preset picture similarity threshold, use the first vector
  • the principle that the similarity value increases or the first picture similarity value increases, and the reverse propagation rule is used to jointly update the parameters of the feature vector generator and the discriminator in the OCT picture classification model;
  • An update vector obtaining unit configured to process the designated negative OCT picture again using the OCT picture classification model after parameter update, to obtain the first update vector B1 and the first decoding generated by the first encoder of the feature vector generator The updated picture generated by the encoder and the second update vector B2 generated by the second encoder;
  • a second vector similarity value calculation unit configured to calculate a second vector similarity value between the first update vector B1 and the second update vector B2, and calculate the designated negative OCT picture and the update picture The second picture similarity value between;
  • a vector similarity threshold judging unit configured to judge whether the second vector similarity value is greater than a preset vector similarity threshold, and to judge whether the second picture similarity value is greater than a preset picture similarity threshold;
  • the deleting unit is configured to: if the second vector similarity value is greater than a preset vector similarity threshold, and the second picture similarity value is greater than a preset picture similarity threshold, then the parameters of the OCT picture classification model are not changed , And delete the designated negative OCT picture from the training set.
  • the first encoder and the second encoder each include a plurality of convolutional layers
  • the OCT picture classification model further includes a convolutional image discriminator
  • the device includes:
  • a convolutional image acquisition unit for acquiring a first convolutional image output by a designated convolutional layer in the first encoder, and acquiring a convolutional layer corresponding to the designated convolutional layer in the second encoder The output second convolution image;
  • the discrimination result acquisition unit is configured to input the first convolution image and the second convolution image into the convolution image discriminator, so as to obtain the discrimination result output by the convolution image discriminator, and determine State whether the discrimination results are similar;
  • the encoding instruction generating unit is configured to generate an encoding instruction if the discrimination result is similar, and the encoding instruction is used to instruct to use the second encoder to encode the decoded picture.
  • the similarity threshold judgment unit 50 includes:
  • the similarity value dis calculation subunit is used according to the formula:
  • the similarity value dis of the first feature vector X and the second feature vector Y is calculated, where xi is the value of the i-th component of the first feature vector X, and yi is the first feature
  • the value of the i-th component vector of the vector Y, the first feature vector X and the second feature vector Y each include n component vectors;
  • the similarity value dis judging subunit is used to judge whether the similarity value dis is greater than a preset similarity threshold.
  • the device includes:
  • a positive picture classification model calculation unit configured to, if the similarity value is not greater than a preset similarity threshold, input the OCT picture to be classified into a preset positive picture classification model based on a deep convolution adversarial generation network
  • the positive picture classification model is obtained by training with sample data through a semi-supervised learning training method, where the sample data is only composed of positive OCT pictures;
  • a positive judgment unit configured to obtain the processing result output by the positive picture classification model, and determine whether the processing result is positive
  • the positive picture classification unit is configured to classify the OCT picture to be classified as a positive picture if the processing result is positive.
  • an embodiment of the present application also provides a computer device.
  • the computer device may be a server, and its internal structure may be as shown in the figure.
  • the computer equipment includes a processor, a memory, a network interface, and a database connected through a system bus. Among them, the processor designed by the computer is used to provide calculation and control capabilities.
  • the memory of the computer device includes a non-volatile storage medium and an internal memory.
  • the non-volatile storage medium stores an operating system, a computer program, and a database.
  • the memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium.
  • the database of the computer equipment is used to store data used in the image classification method based on semi-supervised learning.
  • the network interface of the computer device is used to communicate with an external terminal through a network connection.
  • the computer program is executed by the processor to realize a semi-supervised learning-based image classification method.
  • the above-mentioned processor executes the above-mentioned semi-supervised learning-based image classification method, wherein the steps included in the method respectively correspond to the steps of executing the semi-supervised learning-based image classification method of the foregoing embodiment, and will not be repeated here.
  • the image classification method based on semi-supervised learning includes: obtaining OCT pictures to be classified; using a feature vector generator in a preset OCT image classification model to process the OCT pictures to be classified to obtain the characteristics
  • the first feature vector X generated by the first encoder of the vector generator; wherein the feature vector generator includes a first encoder, a first decoder, and a second encoder connected in sequence; the OCT picture classification model passes
  • the training method of semi-supervised learning is obtained by training with sample data, the sample data is composed of only negative OCT pictures; the first decoder is used to decode the first feature vector X to obtain decoded pictures;
  • the second encoder encodes the decoded picture to generate a second feature vector Y; calculates the similarity value between the first feature vector X and the second feature vector Y according to a preset similarity calculation method, And it is determined whether the similarity value is greater than a preset similarity threshold; if the similarity value is greater than the preset similarity threshold, the OCT picture
  • An embodiment of the present application also provides a computer-readable storage medium.
  • the storage medium is a volatile storage medium or a non-volatile storage medium.
  • the supervised learning image classification method wherein the steps included in the method respectively correspond to the steps of executing the semi-supervised learning-based image classification method of the foregoing embodiment, and will not be repeated here.
  • the image classification method based on semi-supervised learning includes: obtaining OCT pictures to be classified; using a feature vector generator in a preset OCT image classification model to process the OCT pictures to be classified to obtain the characteristics
  • the first feature vector X generated by the first encoder of the vector generator; wherein the feature vector generator includes a first encoder, a first decoder, and a second encoder connected in sequence; the OCT picture classification model passes
  • the training method of semi-supervised learning is obtained by training with sample data, the sample data is composed of only negative OCT pictures; the first decoder is used to decode the first feature vector X to obtain decoded pictures;
  • the second encoder encodes the decoded picture to generate a second feature vector Y; calculates the similarity value between the first feature vector X and the second feature vector Y according to a preset similarity calculation method, And it is determined whether the similarity value is greater than a preset similarity threshold; if the similarity value is greater than the preset similarity threshold, the OCT picture

Landscapes

  • Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Biology (AREA)
  • Evolutionary Computation (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Image Analysis (AREA)

Abstract

本申请涉及人工智能领域,揭示了一种基于半监督学习的图片分类方法、装置、计算机设备和存储介质,所述方法包括:获取待分类的OCT图片;利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到第一个编码器生成的第一特征向量X;利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;利用所述第二编码器生成第二特征向量Y;计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;若所述相似度值大于预设的相似度阈值,则将待分类的OCT图片分类为阴性图片。从而在无需阳性数据的情况下完成OCT图片分类,并克服了阳性数据收集困难的缺陷。

Description

基于半监督学习的图片分类方法、装置和计算机设备
本申请要求于2019年10月29日提交中国专利局、申请号为201911037289.3,发明名称为“基于半监督学习的图片分类方法、装置和计算机设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及到人工智能领域,特别是涉及到一种基于半监督学习的图片分类方法、装置、计算机设备和存储介质。
背景技术
OCT(光学相干断层扫描,optical coherence tomography)影像已经成为临床上比较常见的眼科疾病检查及诊断手段,基于人工智能方法进行基于OCT影像进行眼科疾病筛查具有重要意义。常见的解决方案是将这类问题定义为二分类任务来处理,通过收集一批正常的阴性样本以及异常的阳性样本,即每一张OCT图片都被赋予了标签,然后选择不同的分类模型,通过一定量数据训练之后,自动预测图像正常、异常的类别预测,实现基于OCT图像的眼科疾病筛查。但是发明人意识到,这类监督学习方法存在两个明显的缺陷:(1)需要收集大量的样本进行模型训练,特别是异常图片。在医学图像领域,比较容易收集到是正常的阴性样本,而异常样本的收集费时且需要专家标注,成本较大;(2)由于阳性样本收集的难度,非常容易造成样本分布不均衡,即正常样本较多,异常样本较少,训练得到的模型精度难以保证,特别是用于疾病筛查场景,召回率存在着极大风险,有待改善。因此,传统技术在未获取足够量的阳性样本的前提下,无法对OCT图像进行准确的分类。
技术问题
本申请的主要目的为提供一种基于半监督学习的图片分类方法、装置、计算机设备和存储介质,旨在提高OCT图像分类的准确性。
技术解决方案
为了实现上述目的,本申请提出一种基于半监督学习的图片分类方法,包括以下步骤:
获取待分类的OCT图片;
利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
本申请提供一种基于半监督学习的图片分类装置,包括:
OCT图片获取单元,用于获取待分类的OCT图片;
第一特征向量X生成单元,用于利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
解码图片获取单元,用于利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
第二特征向量Y生成单元,用于利用所述第二编码器对所述解码图片进行编码,从而 生成第二特征向量Y;
相似度阈值判断单元,用于根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
阴性图片分类单元,用于若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
本申请提供一种计算机设备,包括存储器和处理器,所述存储器存储有计算机程序,所述处理器执行所述计算机程序时实现一种基于半监督学习的图片分类方法,包括以下步骤:
获取待分类的OCT图片;
利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
本申请提供一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现一种基于半监督学习的图片分类方法,包括以下步骤:
获取待分类的OCT图片;
利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
有益效果
本申请的基于半监督学习的图片分类方法、装置、计算机设备和存储介质,获取待分类的OCT图片;利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。从而在无需阳性数据的情况下完成OCT图片分类,克服了阳性数据收集困难的缺陷。
附图说明
图1为本申请一实施例的基于半监督学习的图片分类方法的流程示意图;
图2为本申请一实施例的基于半监督学习的图片分类装置的结构示意框图;
图3为本申请一实施例的计算机设备的结构示意框图。
本申请的最佳实施方式
参照图1,本申请实施例提供一种基于半监督学习的图片分类方法,包括以下步骤:
S1、获取待分类的OCT图片;
S2、利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
S3、利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
S4、利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
S5、根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
S6、若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
本申请的基于半监督学习的图片分类方法用于除疾病的诊断和治疗方法之外的任意可行用途,例如用于对大量的未分类OCT图片进行分析整理,以分类存储不同类别的OCT图片,便于数据存储与数据分析等。
如上述步骤S1所述,获取待分类的OCT图片。OCT图片(光学相干断层扫描图片,optical coherence tomography)是利用光明相干原理进行断层扫描的图片,例如适用于眼部结构探查。OCT图片的初始状态是待分类的,而普通人缺乏足够的知识对OCT图片进行分类。而本申请通过预设的OCT图片分类模型能够实现对待分类的OCT图片进行分类。
如上述步骤S2所述,利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成。其中所述OCT图片分类模型可以为任意结构,例如为基于深度卷积对抗生成网络的网络结构。并且本申请的OCT图片分类模型包括特征向量生成器,所述特征向量生成器用于正常工作时进行OCT图片分类。其中特征向量生成器具有依次连接的第一编码器、第一解码器和第二编码器,这是普通的深度卷积对抗生成网络所不具备的,基于第一编码器、第一解码器和第二编码器,阳性图片传入网络后无法被第一编码器完全提取特征,因此也无法被第一解码器完全重构,因此第一解码器生成的解码图片与阳性图片相比存在特征丢失的现象,最终导致第二编码器生成的特征Y与第一编码器生成的特征X不匹配,而阴性图像得到的特征Y与特征X非常接近,基本匹配,故异常图像得到检出。进一步地,所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相似,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练。其中所述第一编码器可以为任意结构,例如为由多个卷积层构成的卷积网络,其最终输出为特征向量。
如上述步骤S3所述,利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片。其中所述第一解码器可以为任意结构的解码器,但能够对所述第一特征向量X,例如为能够进行多个卷积和反卷积操作组成的多层网络结构。由于第一解码器是基于第一特征向量X的解码处理,而第一特征向量X是从待分类的OCT图片中提取的,若提取过程的数据损失过多,将导致解码图片与待分类的OCT图片区别过大。若待分类的OCT图片为阴性图片,由于所述OCT图片分类模型是仅由阴性OCT图片构成样本数据训练得到,因此在待分类的OCT图片为阴性图片的前提下,所述第一解码器得到的解码图片与所述待分类的OCT图片是相同或相似的;而若待分类的OCT图片为阳性图片,则所述第一解码器得到的解码图片与所述待分类的OCT图片是不相同的。
如上述步骤S4所述,利用所述第二编码器对所述解码图片进行编码,从而生成第二特 征向量Y。其中所述第二编码器可以为任意结构,例如为由多个卷积层构成的卷积网络,其最终输出为特征向量。并且所述第二编码器的结构与所述第一编码器相同,或者与所述第一编码器不相同,但同样能够用于对所述解码图片进行编码,从而生成第二特征向量Y。
如上述步骤S5所述,根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值。其中所述相似度计算方法可以为任意方法,例如为根据公式:
Figure PCTCN2020093430-appb-000001
计算得到所述第一特征向量X和所述第二特征向量Y的相似度值dis,其中,xi为所述第一特征向量X的第i个分向量的数值,yi为所述第一特征向量Y的第i个分向量的数值,所述第一特征向量X和所述第二特征向量Y均包括n个分向量。
如上述步骤S6所述,若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。若所述待分类的OCT图片不为阴性图片,则由于第一编码器、第一解码器、第二编码器的一系列处理过程中必然出现的特征丢失(因为本申请是基于半监督学习,仅采用阴性图片进行训练,因此仅在阴性图片的前提下,才可能不出现特征丢失),最终的相似度值将不大于预设的相似度阈值。据此,若所述相似度值大于预设的相似度阈值,表明所述第一特征向量X和所述第二特征向量Y是相同或是相似的,据此将所述待分类的OCT图片分类为阴性图片。本申请中的生成器部分进行改进,直接以图像作为输入,经过第一编码器将图像转换至特征空间,再经过第一解码器将特征向量重构并生解码图像,之后再连接额外的第二编码器,将生成图像重新转换到特征空间,通过比对第一编码器与第二编码器的输出,以实现OCT图片的分类,从而不仅在检测精度上大大高于传统算法,并且具有更高的测试效率。进一步地,若所述相似度值不大于预设的相似度阈值,则或者将所述待分类的OCT图片直接分类为阳性图片,或者对所述待分类的OCT图片进一步分析是否为阳性图片。
在一个实施方式中,所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相同,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练,所述利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成的步骤S2之前,包括:
S11、从预设的训练集中提取指定阴性OCT图片,并将所述指定阴性OCT图片输入所述特征向量生成器中,从而得到所述特征向量生成器的第一编码器生成的第一训练向量A1、第一解码器生成的暂时图片和第二编码器生成的第二训练向量A2;
S12、计算所述第一训练向量A1和所述第二训练向量A2之间的第一向量相似度值,并且利用所述辨别器计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值;
S13、判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值;
S14、若所述第一向量相似度值大于预设的向量相似阈值,并且所述第一图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
如上所述,实现了对所述OCT图片分类模型进行训练。其中所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相同,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练。所述辨别器仅在训练过程中起作用,而在图片分类过程中并不工作,从而优化所述OCT图片分类模型并提高图片分类的速 度。并且由于采用的是相同的训练数据进行共同训练,因此所述辨别器与所述特征向量生成器的适应性更高,更具鲁棒性。其中所述训练集中仅包括阴性OCT图片。若基于所述指定阴性OCT图片获得的所述第一向量相似度值大于预设的向量相似阈值,并且所述第一图片相似度值大于预设的图片相似阈值,则表明当前的OCT图片分类模型能够对所述指定阴性OCT图片进行正确分类,据此不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。其中所述辨别器可为任意结构,例如为一系列卷积层、池化层组成的深度卷积分类网络。
在一个实施方式中,所述计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值的步骤S12,包括:
S121、依次对比所述指定阴性OCT图片与所述暂时图片中对应的像素点,并统计相同像素点的数量;
S122、根据公式:相同占比=相同像素点的数量/所述指定阴性OCT图片中所有像素点的数量,计算得到所述相同占比数值;
S123、将所述相同占比数值记为所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值。
如上所述,实现了计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值。为了计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值,本实施方式采用逐次比对像素点的方式进行判断。若所述指定阴性OCT图片与所述暂时图片是相同的,那么相同像素点的数量应当占绝大多数,即所述相同占比趋近于1。据此,根据公式:相同占比=相同像素点的数量/所述指定阴性OCT图片中所有像素点的数量,计算得到所述相同占比数值,若所述相同像素点占比大于预设的占比阈值,则判定所述指定阴性OCT图片与所述暂时图片相同。
在一个实施方式中,所述判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值的步骤S13之后,包括:
S131、若所述第一向量相似度值不大于预设的向量相似阈值,或者所述第一图片相似度值不大于预设的图片相似阈值,则采用使所述第一向量相似度值增大或者所述第一图片相似度值增大的原则,并利用反向传导法则共同更新所述OCT图片分类模型中的所述特征向量生成器和所述辨别器的参数;
S132、利用参数更新后的OCT图片分类模型再次对所述指定阴性OCT图片进行处理,得到所述特征向量生成器的第一编码器生成的第一更新向量B1、第一解码器生成的更新图片和第二编码器生成的第二更新向量B2;
S133、计算所述第一更新向量B1和所述第二更新向量B2之间的第二向量相似度值,并且计算所述指定阴性OCT图片与所述更新图片之间的第二图片相似度值;
S134、判断所述第二向量相似度值是否大于预设的向量相似阈值,并且判断所述第二图片相似度值是否大于预设的图片相似阈值;
S135、若所述第二向量相似度值大于预设的向量相似阈值,并且所述第二图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
如上所述,实现了参数更新。若所述第一向量相似度值不大于预设的向量相似阈值,或者所述第一图片相似度值不大于预设的图片相似阈值,表明当前的OCT图片分类模型不能对所述指定阴性OCT图片进行正确的分类,因此需要更新所述OCT图片分类模型的参数。其中参数更新采用反向传导法则进行共同更新。所述反向传导法则建立在梯度下降法的基础上,其输入输出关系实质上是一种映射关系:一个n输入m输出的神经网络所完成的功能是从n维欧氏空间向m维欧氏空间中一有限域的连续映射,这一映射具有高度非线性。反向传导法则的网络的信息处理能力来源于简单非线性函数的多次复合,因此具有很强的函数复现能力。其中所述参数更新的原则为:使所述第一向量相似度值变大或者所述第一 图片相似度值变大。据此,再次判断所述第二向量相似度值是否大于预设的向量相似阈值,并且判断所述第二图片相似度值是否大于预设的图片相似阈值。若所述第二向量相似度值大于预设的向量相似阈值,并且所述第二图片相似度值大于预设的图片相似阈值,表明所述OCT图片分类模型能对所述指定阴性OCT图片进行正确的分类,据此不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
在一个实施方式中,所述第一编码器和所述第二编码器均包括多个卷积层,所述OCT图片分类模型还包括卷积图像辨别器,所述利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y的步骤S4之前,包括:
S31、获取所述第一编码器中的指定卷积层输出的第一卷积图像,以及获取所述第二编码器中与所述指定卷积层对应的卷积层输出的第二卷积图像;
S32、将所述第一卷积图像和所述第二卷积图像输入所述卷积图像辨别器中,从而得到所述卷积图像辨别器输出的辨别结果,并判断所述辨别结果是否为相似;
S33、若所述辨别结果为相似,则生成编码指令,所述编码指令用于指示利用所述第二编码器对所述解码图片进行编码。
如上所述,实现了利用卷积图像辨别器进一步提高分类准确度。其中所述第一编码器与所述第二编码器的结构可以相同,也可以不同,但是均包括多个卷积层,并且第一编码器包括指定卷积层(用于输出第一卷积图像),第二编码器包括与所述指定卷积层对应的卷积层(用于输出第二卷积图像),其中指定卷积层例如为第一编码器的第二层卷积层,相应的与所述指定卷积层对应的卷积层例如为第二编码器的第二层卷积层。卷积图像辨别器接收所述第一卷积图像和所述第二卷积图像,并用于辨别所述第一卷积图像和所述第二卷积图像是否相似。若所述辨别结果为不相似,表明OCT图片分类模型在分类过程中丢失了过多的特征,也即所述待分类的OCT图片不为阴性图片(因为OCT图片分类模型仅由阴性图片训练而成,因此在对非阴性图片进行处理之时,会出动特征丢失的情况)。若所述辨别结果为相似,则需要利用第二编码器进一步进行分类,据此生成编码指令,所述编码指令用于指示利用所述第二编码器对所述解码图片进行编码。从而,以设置卷积图像辨别器的方式,提前识别出非阴性图片,进一步提高分类的准确性。
在一个实施方式中,所述根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值的步骤S5,包括:
S501、根据公式:
Figure PCTCN2020093430-appb-000002
计算得到所述第一特征向量X和所述第二特征向量Y的相似度值dis,其中,xi为所述第一特征向量X的第i个分向量的数值,yi为所述第一特征向量Y的第i个分向量的数值,所述第一特征向量X和所述第二特征向量Y均包括n个分向量;
S502、判断所述相似度值dis是否大于预设的相似度阈值。
如上所述,实现了根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值。其中预设的相似度计算方法的公式为:
Figure PCTCN2020093430-appb-000003
当所述第一特征向量X和所述第二特征向量Y完全相同时,所述相似度值dis等于1,即所述相似度值dis的最大值为1。所述相似度值dis离数值1越远,表明所述第一特征向量X和所述第二特征向量Y越不相似。从而所述相似 度值dis能够衡量所述第一特征向量X和所述第二特征向量Y的相似程度。若所述相似度值dis大于预设的相似度阈值,则判定所述第一特征向量X和所述第二特征向量Y相似,也表明所述待分类的OCT图片是所述OCT图片分类模型能够完全识别的,因此所述待分类的OCT图片为阴性图片(因此所述OCT图片分类模型仅由阴性图片训练得到,因此仅能完全识别阴性图片)。
在一个实施方式中,所述根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值的步骤S5之后,包括:
S51、若所述相似度值不大于预设的相似度阈值,则将所述待分类的OCT图片输入预设的基于深度卷积对抗生成网络的阳性图片分类模型中进行处理,所述阳性图片分类模型通过半监督学习的训练方法采用样本数据训练而得,其中样本数据仅由阳性OCT图片构成;
S52、获取所述阳性图片分类模型输出的处理结果,并判断所述处理结果是否为阳性;
S53、若所述处理结果为阳性,则将所述待分类的OCT图片分类为阳性图片。
如上所述,实现了对非阴性图片进一步分类。输入的图片有可能出现误输入的状况,例如将非OCT图片输入所述OCT图片分类模型中,因此分类结果不为阴性,但也不应被分类为阳性。或者输入的图片是特殊的阴性图片(与训练用过的阴性图片区别较大),因此OCT图片分类模型也无法进行正确分类。为进一步分类,本申请另外设置了基于深度卷积对抗生成网络的阳性图片分类模型中进行处理,所述阳性图片分类模型通过半监督学习的训练方法采用样本数据训练而得,其中样本数据仅由阳性OCT图片构成,从而进一步识别出阳性图片。其中所述阳性图片分类模型的结构可以与所述OCT图片分类模型相同,也可以为传统的深度卷积对抗生成网络的结构。若所述阳性图片分类模型输出的处理结果为阳性,表明阳性图片分类模型能对所述待分类的OCT图片进行准确的识别,并且所述阳性图片分类模型仅由阳性OCT图片训练得到,据此将所述待分类的OCT图片分类为阳性图片。
参照图2,本申请实施例提供一种基于半监督学习的图片分类装置,包括:
OCT图片获取单元10,用于获取待分类的OCT图片;
第一特征向量X生成单元20,用于利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
解码图片获取单元30,用于利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
第二特征向量Y生成单元40,用于利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
相似度阈值判断单元50,用于根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
阴性图片分类单元60,用于若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
其中上述单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
在一个实施方式中,所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相同,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练,所述装置,包括:
指定阴性OCT图片提取单元,用于从预设的训练集中提取指定阴性OCT图片,并将所述指定阴性OCT图片输入所述特征向量生成器中,从而得到所述特征向量生成器的第一编码器生成的第一训练向量A1、第一解码器生成的暂时图片和第二编码器生成的第二训练向 量A2;
相似度值计算单元,用于计算所述第一训练向量A1和所述第二训练向量A2之间的第一向量相似度值,并且利用所述辨别器计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值;
相似阈值判断单元,用于判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值;
指定阴性OCT图片删除单元,用于若所述第一向量相似度值大于预设的向量相似阈值,并且所述第一图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
其中上述单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
在一个实施方式中,所述相似度值计算单元,包括:
相同像素点统计子单元,用于依次对比所述指定阴性OCT图片与所述暂时图片中对应的像素点,并统计相同像素点的数量;
相同占比数值计算子单元,用于根据公式:相同占比=相同像素点的数量/所述指定阴性OCT图片中所有像素点的数量,计算得到所述相同占比数值;
第一图片相似度值标记子单元,用于将所述相同占比数值记为所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值。
其中上述子单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
在一个实施方式中,所述装置,包括:
参数更新单元,用于若所述第一向量相似度值不大于预设的向量相似阈值,或者所述第一图片相似度值不大于预设的图片相似阈值,则采用使所述第一向量相似度值增大或者所述第一图片相似度值增大的原则,并利用反向传导法则共同更新所述OCT图片分类模型中的所述特征向量生成器和所述辨别器的参数;
更新向量获取单元,用于利用参数更新后的OCT图片分类模型再次对所述指定阴性OCT图片进行处理,得到所述特征向量生成器的第一编码器生成的第一更新向量B1、第一解码器生成的更新图片和第二编码器生成的第二更新向量B2;
第二向量相似度值计算单元,用于计算所述第一更新向量B1和所述第二更新向量B2之间的第二向量相似度值,并且计算所述指定阴性OCT图片与所述更新图片之间的第二图片相似度值;
向量相似阈值判断单元,用于判断所述第二向量相似度值是否大于预设的向量相似阈值,并且判断所述第二图片相似度值是否大于预设的图片相似阈值;
删除单元,用于若所述第二向量相似度值大于预设的向量相似阈值,并且所述第二图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
其中上述单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
在一个实施方式中,所述第一编码器和所述第二编码器均包括多个卷积层,所述OCT图片分类模型还包括卷积图像辨别器,所述装置,包括:
卷积图像获取单元,用于获取所述第一编码器中的指定卷积层输出的第一卷积图像,以及获取所述第二编码器中与所述指定卷积层对应的卷积层输出的第二卷积图像;
辨别结果获取单元,用于将所述第一卷积图像和所述第二卷积图像输入所述卷积图像辨别器中,从而得到所述卷积图像辨别器输出的辨别结果,并判断所述辨别结果是否为相似;
编码指令生成单元,用于若所述辨别结果为相似,则生成编码指令,所述编码指令用 于指示利用所述第二编码器对所述解码图片进行编码。
其中上述单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
在一个实施方式中,所述相似度阈值判断单元50,包括:
相似度值dis计算子单元,用于根据公式:
Figure PCTCN2020093430-appb-000004
计算得到所述第一特征向量X和所述第二特征向量Y的相似度值dis,其中,xi为所述第一特征向量X的第i个分向量的数值,yi为所述第一特征向量Y的第i个分向量的数值,所述第一特征向量X和所述第二特征向量Y均包括n个分向量;
相似度值dis判断子单元,用于判断所述相似度值dis是否大于预设的相似度阈值。
其中上述子单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
在一个实施方式中,所述装置,包括:
阳性图片分类模型计算单元,用于若所述相似度值不大于预设的相似度阈值,则将所述待分类的OCT图片输入预设的基于深度卷积对抗生成网络的阳性图片分类模型中进行处理,所述阳性图片分类模型通过半监督学习的训练方法采用样本数据训练而得,其中样本数据仅由阳性OCT图片构成;
阳性判断单元,用于获取所述阳性图片分类模型输出的处理结果,并判断所述处理结果是否为阳性;
阳性图片分类单元,用于若所述处理结果为阳性,则将所述待分类的OCT图片分类为阳性图片。
其中上述单元分别用于执行的操作与前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。
参照图3,本申请实施例中还提供一种计算机设备,该计算机设备可以是服务器,其内部结构可以如图所示。该计算机设备包括通过系统总线连接的处理器、存储器、网络接口和数据库。其中,该计算机设计的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质、内存储器。该非易失性存储介质存储有操作系统、计算机程序和数据库。该内存器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的数据库用于存储基于半监督学习的图片分类方法所用数据。该计算机设备的网络接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种基于半监督学习的图片分类方法。
上述处理器执行上述基于半监督学习的图片分类方法,其中所述方法包括的步骤分别与执行前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。所述基于半监督学习的图片分类方法,包括:获取待分类的OCT图片;利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
本申请一实施例还提供一种计算机可读存储介质,所述存储介质为易失性存储介质或 非易失性存储介质,其上存储有计算机程序,计算机程序被处理器执行时实现基于半监督学习的图片分类方法,其中所述方法包括的步骤分别与执行前述实施方式的基于半监督学习的图片分类方法的步骤一一对应,在此不再赘述。所述基于半监督学习的图片分类方法,包括:获取待分类的OCT图片;利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。

Claims (20)

  1. 一种基于半监督学习的图片分类方法,包括:
    获取待分类的OCT图片;
    利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
    利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
    利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
    根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
    若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
  2. 根据权利要求1所述的基于半监督学习的图片分类方法,所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相同,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练,所述利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成的步骤之前,包括:
    从预设的训练集中提取指定阴性OCT图片,并将所述指定阴性OCT图片输入所述特征向量生成器中,从而得到所述特征向量生成器的第一编码器生成的第一训练向量A1、第一解码器生成的暂时图片和第二编码器生成的第二训练向量A2;
    计算所述第一训练向量A1和所述第二训练向量A2之间的第一向量相似度值,并且利用所述辨别器计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值;
    判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值;
    若所述第一向量相似度值大于预设的向量相似阈值,并且所述第一图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
  3. 根据权利要求2所述的基于半监督学习的图片分类方法,所述计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值的步骤,包括:
    依次对比所述指定阴性OCT图片与所述暂时图片中对应的像素点,并统计相同像素点的数量;
    根据公式:相同占比=相同像素点的数量/所述指定阴性OCT图片中所有像素点的数量,计算得到所述相同占比数值;
    将所述相同占比数值记为所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值。
  4. 根据权利要求2所述的基于半监督学习的图片分类方法,所述判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值的步骤之后,包括:
    若所述第一向量相似度值不大于预设的向量相似阈值,或者所述第一图片相似度值不大于预设的图片相似阈值,则采用使所述第一向量相似度值增大或者所述第一图片相似度值增大的原则,并利用反向传导法则共同更新所述OCT图片分类模型中的所述特征向量生成器和所述辨别器的参数;
    利用参数更新后的OCT图片分类模型再次对所述指定阴性OCT图片进行处理,得到所 述特征向量生成器的第一编码器生成的第一更新向量B1、第一解码器生成的更新图片和第二编码器生成的第二更新向量B2;
    计算所述第一更新向量B1和所述第二更新向量B2之间的第二向量相似度值,并且计算所述指定阴性OCT图片与所述更新图片之间的第二图片相似度值;
    判断所述第二向量相似度值是否大于预设的向量相似阈值,并且判断所述第二图片相似度值是否大于预设的图片相似阈值;
    若所述第二向量相似度值大于预设的向量相似阈值,并且所述第二图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
  5. 根据权利要求1所述的基于半监督学习的图片分类方法,所述第一编码器和所述第二编码器均包括多个卷积层,所述OCT图片分类模型还包括卷积图像辨别器,所述利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y的步骤之前,包括:
    获取所述第一编码器中的指定卷积层输出的第一卷积图像,以及获取所述第二编码器中与所述指定卷积层对应的卷积层输出的第二卷积图像;
    将所述第一卷积图像和所述第二卷积图像输入所述卷积图像辨别器中,从而得到所述卷积图像辨别器输出的辨别结果,并判断所述辨别结果是否为相似;
    若所述辨别结果为相似,则生成编码指令,所述编码指令用于指示利用所述第二编码器对所述解码图片进行编码。
  6. 根据权利要求1所述的基于半监督学习的图片分类方法,所述根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值的步骤,包括:
    根据公式:
    Figure PCTCN2020093430-appb-100001
    计算得到所述第一特征向量X和所述第二特征向量Y的相似度值dis,其中,xi为所述第一特征向量X的第i个分向量的数值,yi为所述第一特征向量Y的第i个分向量的数值,所述第一特征向量X和所述第二特征向量Y均包括n个分向量;
    判断所述相似度值dis是否大于预设的相似度阈值。
  7. 根据权利要求1所述的基于半监督学习的图片分类方法,所述根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值的步骤之后,包括:
    若所述相似度值不大于预设的相似度阈值,则将所述待分类的OCT图片输入预设的基于深度卷积对抗生成网络的阳性图片分类模型中进行处理,所述阳性图片分类模型通过半监督学习的训练方法采用样本数据训练而得,其中样本数据仅由阳性OCT图片构成;
    获取所述阳性图片分类模型输出的处理结果,并判断所述处理结果是否为阳性;
    若所述处理结果为阳性,则将所述待分类的OCT图片分类为阳性图片。
  8. 一种基于半监督学习的图片分类装置,包括:
    OCT图片获取单元,用于获取待分类的OCT图片;
    第一特征向量X生成单元,用于利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
    解码图片获取单元,用于利用所述第一解码器对所述第一特征向量X进行解码处理, 得到解码图片;
    第二特征向量Y生成单元,用于利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
    相似度阈值判断单元,用于根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
    阴性图片分类单元,用于若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
  9. 一种计算机设备,包括存储器和处理器,所述存储器存储有计算机程序,所述处理器执行所述计算机程序时实现一种基于半监督学习的图片分类方法,所述方法包括:
    获取待分类的OCT图片;
    利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
    利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
    利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
    根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
    若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
  10. 根据权利要求9所述的计算机设备,所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相同,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练,所述利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成的步骤之前,包括:
    从预设的训练集中提取指定阴性OCT图片,并将所述指定阴性OCT图片输入所述特征向量生成器中,从而得到所述特征向量生成器的第一编码器生成的第一训练向量A1、第一解码器生成的暂时图片和第二编码器生成的第二训练向量A2;
    计算所述第一训练向量A1和所述第二训练向量A2之间的第一向量相似度值,并且利用所述辨别器计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值;
    判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值;
    若所述第一向量相似度值大于预设的向量相似阈值,并且所述第一图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
  11. 根据权利要求10所述的计算机设备,所述计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值的步骤,包括:
    依次对比所述指定阴性OCT图片与所述暂时图片中对应的像素点,并统计相同像素点的数量;
    根据公式:相同占比=相同像素点的数量/所述指定阴性OCT图片中所有像素点的数量,计算得到所述相同占比数值;
    将所述相同占比数值记为所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值。
  12. 根据权利要求10所述的计算机设备,所述判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值的步骤 之后,包括:
    若所述第一向量相似度值不大于预设的向量相似阈值,或者所述第一图片相似度值不大于预设的图片相似阈值,则采用使所述第一向量相似度值增大或者所述第一图片相似度值增大的原则,并利用反向传导法则共同更新所述OCT图片分类模型中的所述特征向量生成器和所述辨别器的参数;
    利用参数更新后的OCT图片分类模型再次对所述指定阴性OCT图片进行处理,得到所述特征向量生成器的第一编码器生成的第一更新向量B1、第一解码器生成的更新图片和第二编码器生成的第二更新向量B2;
    计算所述第一更新向量B1和所述第二更新向量B2之间的第二向量相似度值,并且计算所述指定阴性OCT图片与所述更新图片之间的第二图片相似度值;
    判断所述第二向量相似度值是否大于预设的向量相似阈值,并且判断所述第二图片相似度值是否大于预设的图片相似阈值;
    若所述第二向量相似度值大于预设的向量相似阈值,并且所述第二图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
  13. 根据权利要求9所述的计算机设备,所述第一编码器和所述第二编码器均包括多个卷积层,所述OCT图片分类模型还包括卷积图像辨别器,所述利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y的步骤之前,包括:
    获取所述第一编码器中的指定卷积层输出的第一卷积图像,以及获取所述第二编码器中与所述指定卷积层对应的卷积层输出的第二卷积图像;
    将所述第一卷积图像和所述第二卷积图像输入所述卷积图像辨别器中,从而得到所述卷积图像辨别器输出的辨别结果,并判断所述辨别结果是否为相似;
    若所述辨别结果为相似,则生成编码指令,所述编码指令用于指示利用所述第二编码器对所述解码图片进行编码。
  14. 根据权利要求9所述的计算机设备,所述根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值的步骤,包括:
    根据公式:
    Figure PCTCN2020093430-appb-100002
    计算得到所述第一特征向量X和所述第二特征向量Y的相似度值dis,其中,xi为所述第一特征向量X的第i个分向量的数值,yi为所述第一特征向量Y的第i个分向量的数值,所述第一特征向量X和所述第二特征向量Y均包括n个分向量;
    判断所述相似度值dis是否大于预设的相似度阈值。
  15. 根据权利要求9所述的计算机设备,所述根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值的步骤之后,包括:
    若所述相似度值不大于预设的相似度阈值,则将所述待分类的OCT图片输入预设的基于深度卷积对抗生成网络的阳性图片分类模型中进行处理,所述阳性图片分类模型通过半监督学习的训练方法采用样本数据训练而得,其中样本数据仅由阳性OCT图片构成;
    获取所述阳性图片分类模型输出的处理结果,并判断所述处理结果是否为阳性;
    若所述处理结果为阳性,则将所述待分类的OCT图片分类为阳性图片。
  16. 一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现一种基于半监督学习的图片分类方法,所述方法包括:
    获取待分类的OCT图片;
    利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成;
    利用所述第一解码器对所述第一特征向量X进行解码处理,得到解码图片;
    利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y;
    根据预设的相似度计算方法,计算所述第一特征向量X和所述第二特征向量Y的相似度值,并判断所述相似度值是否大于预设的相似度阈值;
    若所述相似度值大于预设的相似度阈值,则将所述待分类的OCT图片分类为阴性图片。
  17. 根据权利要求16所述的计算机可读存储介质,所述OCT图片分类模型还包括辨别器,所述辨别器用于辨别所述OCT图片和所述解码图片是否相同,并且所述特征向量生成器与所述辨别器采用相同的样本数据共同训练,所述利用预设的OCT图片分类模型中的特征向量生成器对所述待分类的OCT图片进行处理,得到由所述特征向量生成器的第一个编码器生成的第一特征向量X;其中所述特征向量生成器包括依次连接的第一编码器、第一解码器和第二编码器;所述OCT图片分类模型通过半监督学习的训练方法采用样本数据训练而得,所述样本数据仅由阴性OCT图片构成的步骤之前,包括:
    从预设的训练集中提取指定阴性OCT图片,并将所述指定阴性OCT图片输入所述特征向量生成器中,从而得到所述特征向量生成器的第一编码器生成的第一训练向量A1、第一解码器生成的暂时图片和第二编码器生成的第二训练向量A2;
    计算所述第一训练向量A1和所述第二训练向量A2之间的第一向量相似度值,并且利用所述辨别器计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值;
    判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值;
    若所述第一向量相似度值大于预设的向量相似阈值,并且所述第一图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
  18. 根据权利要求17所述的计算机可读存储介质,所述计算所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值的步骤,包括:
    依次对比所述指定阴性OCT图片与所述暂时图片中对应的像素点,并统计相同像素点的数量;
    根据公式:相同占比=相同像素点的数量/所述指定阴性OCT图片中所有像素点的数量,计算得到所述相同占比数值;
    将所述相同占比数值记为所述指定阴性OCT图片与所述暂时图片之间的第一图片相似度值。
  19. 根据权利要求17所述的计算机可读存储介质,所述判断所述第一向量相似度值是否大于预设的向量相似阈值,并且判断所述第一图片相似度值是否大于预设的图片相似阈值的步骤之后,包括:
    若所述第一向量相似度值不大于预设的向量相似阈值,或者所述第一图片相似度值不大于预设的图片相似阈值,则采用使所述第一向量相似度值增大或者所述第一图片相似度值增大的原则,并利用反向传导法则共同更新所述OCT图片分类模型中的所述特征向量生成器和所述辨别器的参数;
    利用参数更新后的OCT图片分类模型再次对所述指定阴性OCT图片进行处理,得到所述特征向量生成器的第一编码器生成的第一更新向量B1、第一解码器生成的更新图片和第二编码器生成的第二更新向量B2;
    计算所述第一更新向量B1和所述第二更新向量B2之间的第二向量相似度值,并且计 算所述指定阴性OCT图片与所述更新图片之间的第二图片相似度值;
    判断所述第二向量相似度值是否大于预设的向量相似阈值,并且判断所述第二图片相似度值是否大于预设的图片相似阈值;
    若所述第二向量相似度值大于预设的向量相似阈值,并且所述第二图片相似度值大于预设的图片相似阈值,则不改变所述OCT图片分类模型的参数,并且将所述指定阴性OCT图片从所述训练集中删除。
  20. 根据权利要求16所述的计算机可读存储介质,所述第一编码器和所述第二编码器均包括多个卷积层,所述OCT图片分类模型还包括卷积图像辨别器,所述利用所述第二编码器对所述解码图片进行编码,从而生成第二特征向量Y的步骤之前,包括:
    获取所述第一编码器中的指定卷积层输出的第一卷积图像,以及获取所述第二编码器中与所述指定卷积层对应的卷积层输出的第二卷积图像;
    将所述第一卷积图像和所述第二卷积图像输入所述卷积图像辨别器中,从而得到所述卷积图像辨别器输出的辨别结果,并判断所述辨别结果是否为相似;
    若所述辨别结果为相似,则生成编码指令,所述编码指令用于指示利用所述第二编码器对所述解码图片进行编码。
PCT/CN2020/093430 2019-10-29 2020-05-29 基于半监督学习的图片分类方法、装置和计算机设备 WO2021082428A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201911037289.3A CN111008643B (zh) 2019-10-29 2019-10-29 基于半监督学习的图片分类方法、装置和计算机设备
CN201911037289.3 2019-10-29

Publications (1)

Publication Number Publication Date
WO2021082428A1 true WO2021082428A1 (zh) 2021-05-06

Family

ID=70111050

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/093430 WO2021082428A1 (zh) 2019-10-29 2020-05-29 基于半监督学习的图片分类方法、装置和计算机设备

Country Status (2)

Country Link
CN (1) CN111008643B (zh)
WO (1) WO2021082428A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113655002A (zh) * 2021-08-30 2021-11-16 华侨大学 基于高光谱技术的表面含砂浆的再生骨料质量检测系统

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111008643B (zh) * 2019-10-29 2024-03-19 平安科技(深圳)有限公司 基于半监督学习的图片分类方法、装置和计算机设备
CN111199193B (zh) * 2019-12-23 2022-03-18 平安国际智慧城市科技股份有限公司 基于数字切片的图片分类方法、装置和计算机设备
CN112686289A (zh) * 2020-12-24 2021-04-20 微梦创科网络科技(中国)有限公司 图片分类方法和装置
CN113222983A (zh) * 2021-06-03 2021-08-06 北京有竹居网络技术有限公司 图像处理方法、装置、可读介质和电子设备
CN114037868B (zh) * 2021-11-04 2022-07-01 杭州医策科技有限公司 图像识别模型的生成方法及装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110102051A (zh) * 2019-05-06 2019-08-09 网易(杭州)网络有限公司 游戏外挂的检测方法及装置
CN110110600A (zh) * 2019-04-04 2019-08-09 平安科技(深圳)有限公司 眼部oct图像病灶识别方法、装置及存储介质
CN110147323A (zh) * 2019-04-24 2019-08-20 北京百度网讯科技有限公司 一种基于生成对抗网络的变更智能检查方法及装置
CN110458039A (zh) * 2019-07-19 2019-11-15 华中科技大学 一种工业过程故障诊断模型的构建方法及其应用
CN111008643A (zh) * 2019-10-29 2020-04-14 平安科技(深圳)有限公司 基于半监督学习的图片分类方法、装置和计算机设备

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108764241A (zh) * 2018-04-20 2018-11-06 平安科技(深圳)有限公司 分割股骨近端的方法、装置、计算机设备和存储介质
CN108764299B (zh) * 2018-05-04 2020-10-23 北京物灵智能科技有限公司 故事模型训练及生成方法、系统、机器人及存储设备
CN110362684B (zh) * 2019-06-27 2022-10-25 腾讯科技(深圳)有限公司 一种文本分类方法、装置及计算机设备

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110110600A (zh) * 2019-04-04 2019-08-09 平安科技(深圳)有限公司 眼部oct图像病灶识别方法、装置及存储介质
CN110147323A (zh) * 2019-04-24 2019-08-20 北京百度网讯科技有限公司 一种基于生成对抗网络的变更智能检查方法及装置
CN110102051A (zh) * 2019-05-06 2019-08-09 网易(杭州)网络有限公司 游戏外挂的检测方法及装置
CN110458039A (zh) * 2019-07-19 2019-11-15 华中科技大学 一种工业过程故障诊断模型的构建方法及其应用
CN111008643A (zh) * 2019-10-29 2020-04-14 平安科技(深圳)有限公司 基于半监督学习的图片分类方法、装置和计算机设备

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113655002A (zh) * 2021-08-30 2021-11-16 华侨大学 基于高光谱技术的表面含砂浆的再生骨料质量检测系统
CN113655002B (zh) * 2021-08-30 2023-11-24 华侨大学 基于高光谱技术的表面含砂浆的再生骨料质量检测系统

Also Published As

Publication number Publication date
CN111008643B (zh) 2024-03-19
CN111008643A (zh) 2020-04-14

Similar Documents

Publication Publication Date Title
WO2021082428A1 (zh) 基于半监督学习的图片分类方法、装置和计算机设备
JP7058373B2 (ja) 医療画像に対する病変の検出及び位置決め方法、装置、デバイス、及び記憶媒体
Li et al. Automatic detection of diabetic retinopathy in retinal fundus photographs based on deep learning algorithm
WO2021008328A1 (zh) 图像处理方法、装置、终端及存储介质
WO2020253629A1 (zh) 检测模型训练方法、装置、计算机设备和存储介质
CN108182394B (zh) 卷积神经网络的训练方法、人脸识别方法及装置
CN108921051B (zh) 基于循环神经网络注意力模型的行人属性识别网络及技术
JP6994588B2 (ja) 顔特徴抽出モデル訓練方法、顔特徴抽出方法、装置、機器および記憶媒体
WO2021196632A1 (zh) 一种全景数字病理图像智能分析系统及方法
JP2019521443A (ja) 適応型追加学習を用いた細胞のアノテーション法及びアノテーションシステム
WO2016205286A1 (en) Automatic entity resolution with rules detection and generation system
CN110956615B (zh) 图像质量评估模型训练方法、装置、电子设备及存储介质
Tennakoon et al. Image quality classification for DR screening using convolutional neural networks
Li et al. Coda: Counting objects via scale-aware adversarial density adaption
CN110135505B (zh) 图像分类方法、装置、计算机设备及计算机可读存储介质
CN113222149B (zh) 模型训练方法、装置、设备和存储介质
EP3564857A1 (en) Pattern recognition method of autoantibody immunofluorescence image
CN113706472B (zh) 公路路面病害检测方法、装置、设备及存储介质
CN113283368B (zh) 一种模型训练方法、人脸属性分析方法、装置及介质
CN111723852B (zh) 针对目标检测网络的鲁棒训练方法
WO2023123923A1 (zh) 人体重识别方法、人体重识别装置、计算机设备及介质
CN114359787A (zh) 目标属性识别方法、装置、计算机设备及存储介质
CN112084913B (zh) 一种端到端的人体检测与属性识别方法
KR102320005B1 (ko) 영상 분석 기반 비정상 객체 검출 시스템 및 방법
WO2024011853A1 (zh) 人体图像质量检测方法、装置、电子设备及存储介质

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: 20881614

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20881614

Country of ref document: EP

Kind code of ref document: A1