CN108229556A - Object classification and model training method, device, medium and system - Google Patents

Object classification and model training method, device, medium and system Download PDF

Info

Publication number
CN108229556A
CN108229556A CN201711481948.3A CN201711481948A CN108229556A CN 108229556 A CN108229556 A CN 108229556A CN 201711481948 A CN201711481948 A CN 201711481948A CN 108229556 A CN108229556 A CN 108229556A
Authority
CN
China
Prior art keywords
classification
grader
feature
training
parameter
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201711481948.3A
Other languages
Chinese (zh)
Inventor
张行程
杨磊
林达华
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Sensetime Technology Development Co Ltd
Original Assignee
Beijing Sensetime Technology Development Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Sensetime Technology Development Co Ltd filed Critical Beijing Sensetime Technology Development Co Ltd
Priority to CN201711481948.3A priority Critical patent/CN108229556A/en
Publication of CN108229556A publication Critical patent/CN108229556A/en
Pending legal-status Critical Current

Links

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/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2413Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on distances to training or reference patterns

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)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

This application provides a kind of object classification and model training method, device, medium and systems.Object classification model includes feature extractor and grader.Training method includes:Through feature extractor from the data item comprising object extracting object feature;Categorized device concentrates down-sampling to go out partial category from predefined candidate categories, obtains the response for the partial category that extracted feature goes out down-sampling and is classified based on response to object;And the parameter in grader and/or feature extractor is adjusted according to the result of classification.

Description

Object classification and model training method, device, medium and system
Technical field
This application involves artificial intelligence (AI) field, more particularly, to a kind of object classification and model training method, dress It puts, medium and system.
Background technology
In recent years, have benefited from the development of deep learning, many technological break-throughs have occurred in AI fields.AI fields, which have, is permitted Multiple-limb developing direction, but object classification problem is a key problem always.
In object classification problem, often some candidate categories are predefined for object to be sorted.When candidate categories increase When, the difficulty of classification increases.For example, increase for performing the training difficulty of the model of classification.When candidate categories increase to centainly During degree (for example, hundreds thousand of magnitudes even millions of magnitudes), which develops into ultra-large classification (Massive Classification) problem.
Invention content
This application provides the technical solutions for object classification and its training.
The one side of the embodiment of the present application provides a kind of training method of object classification model.Object classification model includes Feature extractor and grader.Training method includes:Through feature extractor from the data item comprising object extracting object spy Sign;Categorized device concentrates down-sampling to go out partial category from predefined candidate categories, obtains extracted feature for down-sampling The response of the partial category gone out and based on response classify to object;And according to the result of classification adjust grader and/ Or the parameter in feature extractor.
According to the embodiment of the present application, adjusting the parameter in grader according to the result of classification may include:According to the knot of classification Parameter in fruit adjustment grader for classifying to object.
According to the embodiment of the present application, categorized device is concentrated down-sampling to go out partial category and can be wrapped from predefined candidate categories It includes:Categorized device and according to the parameter classified to object is used in grader, is adopted under predefined candidate categories concentration Sample goes out partial category.
According to the embodiment of the present application, adjusting the parameter in grader according to the result of classification may include:By adjusting parameter Process is divided into multiple stages, and each stage in multiple stages includes a certain number of training and recycles;And in each stage Parameter when adjustment classifies to object during starting.
According to the embodiment of the present application, for may include at least one of to the parameter that object is classified:Down-sampling The quantity of partial category, the quantity of classification cluster based on the generation of candidate categories collection, classification cluster update cycle.
According to the embodiment of the present application, can with the trained quantity for gradually decrease the partial category of down-sampling, gradually Increase the quantity of the classification cluster generated based on candidate categories collection, and/or gradually increase the number of training cycle in the single stage.
According to the embodiment of the present application, down-sampling is concentrated to go out partial category from predefined candidate categories may include:It will be candidate Classification successively two is divided into binary tree, and the quantity of classification that each leaf node of binary tree is included is less than or equal to the first quantity; Feature is successively included into the next node of binary tree from the root node of binary tree, until what the node that feature is included into included The quantity of classification meets the quantity of predetermined classification cluster;And the node selection partial category that feature based is included into.
According to the embodiment of the present application, binary tree can be multiple.
According to the embodiment of the present application, candidate categories successively two are divided into binary tree and may include:Based on arbitrary in candidate categories Theorem in Euclid space is divided into two by two classifications, the first hyperplane in theorem in Euclid space where structure candidate categories, the first hyperplane A first subspace;And for the first subspace comprising the classification more than the first quantity, based on arbitrary in the first subspace Two classifications are as second the first subspace of hyperplane Loop partition, until the number of classification that the subspace marked off is included Amount is less than or equal to the first quantity.
The another aspect of the application provides a kind of object classification method, including:By feature extractor from pending The feature of extracting object in data item;Object point is carried out by feature of the grader based on extraction and predefined candidate categories collection Class, wherein, training is completed in advance using above-mentioned training method for feature extractor and grader.
The another aspect of the embodiment of the present application provides a kind of object classification device, which includes:Feature Extractor, the feature of feature extractor extracting object from the data item comprising object;Grader, grader is from predefined time Select classification that down-sampling is concentrated to go out partial category, obtain the partial category that extracted feature goes out down-sampling response and Classified based on response to object;And training aids, training aids adjust grader and/or feature extraction according to the result of classification Parameter in device.
According to the embodiment of the present application, training aids can adjust in grader according to the result of classification and be used to classify to object Parameter.
According to the embodiment of the present application, grader can be according to being used for the parameter classified to object, from predetermined in grader The candidate categories of justice concentrate down-sampling to go out partial category.
According to the embodiment of the present application, training aids may include:Training counter, training counter divide the process of adjusting parameter Into multiple stages, each stage in multiple stages includes a certain number of training and recycles;And renovator, renovator is each Parameter when adjustment classifies to object during the starting in stage.
According to the embodiment of the present application, for may include at least one of to the parameter that object is classified:Down-sampling The quantity of partial category, the quantity of classification cluster based on the generation of candidate categories collection, classification cluster update cycle.
According to the embodiment of the present application, training aids can be with the trained number for gradually decrease the partial category of down-sampling It measures, gradually increase the quantity of the classification cluster generated based on candidate categories collection, and/or gradually increase training cycle in the single stage Number.
According to the embodiment of the present application, grader may include:Binary tree composer, binary tree composer by candidate categories successively Two are divided into binary tree, and the quantity of classification that each leaf node of binary tree is included is less than or equal to the first quantity;Addressing device is sought Feature is successively included into the next node of binary tree by location device from the root node of binary tree, until the node packet that feature is included into The quantity of the classification contained meets the quantity of predetermined classification cluster;And partial category extractor, partial category extractor feature based The node selection partial category being included into.
According to the embodiment of the present application, binary tree can be multiple.
According to the embodiment of the present application, binary tree composer may include:Trunk composer, trunk composer are based on candidate categories Middle any two classification builds the first hyperplane in the theorem in Euclid space where candidate categories, and the first hyperplane is by theorem in Euclid space It is divided into two the first subspaces;Branches and leaves composer, branches and leaves composer are empty for the first son comprising the classification more than the first quantity Between, based on any two classification in the first subspace as second the first subspace of hyperplane Loop partition, until being marked off The quantity of classification that is included of subspace be less than or equal to the first quantity.
The another aspect of the application provides a kind of object classification device, which includes:Feature extractor, The feature of feature extractor extracting object from pending data item;Grader, feature and predefined time based on extraction Classification collection is selected to carry out object classification, wherein, training is completed in advance using above-mentioned training method for feature extractor and grader.
The another further aspect of the embodiment of the present application provides a kind of system for object classification model.Training system includes: Memory stores executable instruction;And one or more processors, it communicates to perform executable instruction so as to complete with memory Into operation corresponding with above-mentioned training method or complete the corresponding operation of object classification method as described above.
The another aspect of the embodiment of the present application provides a kind of computer storage media, and computer storage media can store Computer-readable instruction causes processor to perform operation corresponding with above-mentioned training method when computer-readable instruction is performed Or perform the corresponding operation of object classification method as described above.
The technical solution of the application down-sampling partial category from candidate categories carries out the training of object classification model, can use In the training of the object model of more object classifications, the complexity of object classification model training process is simplified, reduces model Resource burden in training process.
Description of the drawings
By reading the detailed description made to non-limiting example made with reference to the following drawings, the application's is other Feature, objects and advantages will become more apparent upon:
Fig. 1 is the flow chart according to the training method for object classification model of the embodiment of the present application;
Fig. 2 is the flow chart according to the method that candidate categories are carried out with down-sampling of the embodiment of the present application;
Fig. 3 is the flow chart according to the method for the structure binary tree of the embodiment of the present application;
Fig. 4 is the schematic block diagram according to the binary tree of the embodiment of the present application;
Fig. 5 is the schematic diagram according to the binary tree building process of the embodiment of the present application;
Fig. 6 is the block diagram according to the object classification device of the embodiment of the present application;And
Fig. 7 is the block diagram according to the training system for object classification model of the embodiment of the present application.
Specific embodiment
The application is described in further detail with reference to the accompanying drawings and examples.It is understood that herein Described specific embodiment is used only for explaining the application rather than the application is defined.It also should be noted that For ease of description, it is illustrated only in attached drawing and the relevant part of the application.Come below with reference to accompanying drawings and in conjunction with the embodiments detailed Describe bright the application in detail.It should be understood that unless otherwise stated, ordinal number used herein, " first ", " second " etc., It is only used for distinguishing an element with another element, and does not indicate that importance or priority.For example, the first weight and the second power Different weights is represented again.
It should be noted that in the absence of conflict, the feature in embodiment and embodiment in the application can phase Mutually combination.The application is described in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
Fig. 1 is the flow chart according to the training method 1000 for object classification model of the embodiment of the present application.
Object classification model can be the model for performing object classification task, including feature extractor and grader. In step S1100, feature extractor extracts the feature of the object from the data item comprising object.Object can be for example face People in identification mission, data item can include the picture of the people.For another example object can be sound in voice recognition tasks Owner, data item can include the audio fragment of the sound.Can suitable feature extraction be selected according to the type of data item Method, so as to be extracted to the feature of object.Feature extractor using various ways realize, including but not limited to:Nerve net The feature extractor (such as fisher, hand-crafted, hog) of network (such as convolutional neural networks) or non-neural network.Example Such as, the feature vector of appropriate deep neural network (Deep Neural Network) extracting object can be used.In another example when When data item is picture, it can be used and be configured with the feature extractors such as residual error network the characteristics of objects in picture is extracted.
In step S1200, categorized device concentrates down-sampling to go out partial category from predefined candidate categories, and acquisition is carried The response for the partial category that the feature taken goes out down-sampling and based on response classify to object.
Grader as described herein can be implemented using neural network, can also utilize other schemes such as support vector machines To implement.As mentioned above, in ultra-large classification problem, the quantity for the predefined candidate categories of object may be Hundreds thousand of meters or even millions of meters.For example, in recognition of face task, it is possible to be related to personage's picture of million magnitudes.At this In kind recognition of face task, each personage's individual is a classification in object classification problem.When for the predefined time of object When selecting categorical measure excessive, two classes may be led to the problem of:(1) for training the scale of the parameter of object classification excessively huge, So that have exceeded the capacity of memory;And (2) occupy a large amount of computing resources, it is excessive when being accounted for so as to cause training process.However, For many ultra-large classification problems, even if the quantity for the predefined candidate categories of object is very huge, but the feature of object Only there may be high response to minimal amount of classification.In this case, can from the candidate categories of substantial amounts down-sampling Go out the partial category to characteristics of objects sensitivity.Hereinafter, the partial category being downsampled out so also referred to as enlivens classification (Active Class)。
After down-sampling goes out partial category, the sound for the partial category that extracted feature goes out down-sampling can be obtained It should.By taking recognition of face task as an example, the feature of the object extracted in step S1100 can be from the figure comprising facial image The feature vector extracted in piece.It in this case, can be by using the feature of the weight matrix comprising classification information and object Vector carries out matrix multiplication to obtain this characteristic response.Specifically, every a line of weight matrix can represent the spy of each classification Sign vector.It, can be corresponding from weight matrix when down-sampling goes out partial category from a large amount of candidate categories in step S1200 Row corresponding with this partial category is picked out on ground, so as to only obtain the sound of partial category that extracted feature goes out down-sampling It should.
After the response for obtaining the partial category that extracted feature goes out down-sampling, can be based on response to object into Row classification.These characteristic responses are swashed using the activation primitive (Activation Function) of such as softmax It is living, so as to obtain the probability vector of object.The probability vector of object reflects that object belongs to the probability value of each classification.To waiting In the case of classification progress down-sampling is selected to select partial category, object can be belonged to other classifications except this partial category Probability value be set as 0.On this basis, it can for example arrange to judge which classification object belongs to or can according to probability value descending Which classification can be belonged to.Go out since the quantity of the classification involved by object classification is reduced to institute's down-sampling from the quantity of candidate categories Partial category quantity, so the processing complexity of activation primitive is also accordingly minimized.
In step S1300, the parameter in grader and/or feature extractor is adjusted according to the result of classification.Will be right After being classified, the result of classification often and true value (Ground Truth) there are deviations.It therefore, can be according to classification As a result the parameter in grader and/or feature extractor is adjusted.
Present inventor has found during the application is put into practice, the training for the object model of more object classifications, such as Fruit training characteristics extractor and grader in the case where all categories are completely in state of activation are particularly big in candidate categories quantity In the scene of (such as extensive classification or ultra-large classification), training complexity is very big, and resource overhead is very big.And with reference to Fig. 1 The training method of description is by the way that from candidate categories collection down-sampling partial category, (such as down-sampling goes out from the candidate categories of substantial amounts A small amount of enlivens classification) it is trained to carry out gradation, then the complexity of training process is significantly simplified, reduces training process Resource is born.For example, above-mentioned training method occupies lesser amount of memory and occupies less computing resource.Pass through this side Formula can simplify the complexity of the training process of object classification model, and can solve the problems, such as above-described two class.
According to one embodiment of the application, the parameter in grader is adjusted according to the result of classification and is included:According to classification Result adjustment grader in for the parameter classified to object.Specifically, pass through deep neural network in grader Deviation between classification results and correct option in the case of implementing, can be carried out gradient backpropagation, so as to correct by mode The network parameter of the deep neural network, including but not limited to, in deep neural network the weight (Weight) of each neuron and Deviant (Bias).For another example such parameter may also include the quantity of partial category that institute's down-sampling goes out.People in the art Member could be aware that the quantity for the partial category that down-sampling goes out is more, and the generalization ability of the model trained is stronger;What down-sampling went out The quantity of partial category is fewer, and trained resource burden is smaller, but is more susceptible to over-fitting.Therefore, in the training process, may be used To be adjusted according to the result of classification for the parameter classified to object in grader, so that with trained progress, Not only it had improved the classification capacity of object classification model but also had reduced the resource consumption of object classification model.
According to one embodiment of the application, categorized device concentrates down-sampling to go out partial category from predefined candidate categories Including:Categorized device and according to being used for the parameter classified to object in grader, under predefined candidate categories concentration Sample out partial category.A kind of mode of alternative down-sampling is:Predefine the quantity of required partial category;It calculates The response of all candidate categories that the feature of object concentrates candidate categories;Then according to the quantity of predetermined partial category These maximum classifications of response are selected as the partial category from candidate categories concentration.Alternatively adopt down The mode of sample is:The response of all candidate categories that the feature of computing object concentrates candidate categories;By these responses and preset Threshold value is compared;Then it is candidate categories being concentrated, be chosen for institute with being more than the corresponding candidate categories of response of predetermined threshold value State partial category.
In one embodiment of the application, of all categories in candidate categories collection can be closed to each other without priori level The parallel classification of system.For example, candidate categories collection can be multiple and different people, everyone is defined as a classification.These classes It is parallel to each other between not.In such a case, it is possible to down-sampling is carried out to candidate categories collection according to scheduled down-sampling standard.Cause This, using different down-sampling standards, possible down-sampling goes out different category sets.Such category set is referred to as herein For classification cluster.Such classification cluster reflects the set of classification obtained under specific down-sampling standard.Obviously, if using more A different down-sampling standard, may more fully reflect with characteristics of objects it is closely related enliven classification.
According to one embodiment of the application, the parameter in grader is adjusted according to the result of classification and is included:Adjustment is joined Several processes is divided into multiple stages, and each stage in multiple stages includes a certain number of training and recycles;And in every single order Parameter when adjustment classifies to object during the starting of section.
Such as those skilled in the art institute it should be appreciated that deep neural network can be used object classification model is configured. In this case, which should learn the sample of training set by training process to improve object classification All kinds of parameters of model.According to the type of deep neural network, adoptable training method may, for example, be gradient backpropagation, Backpropagation of gradient containing when etc..It will be appreciated, however, that in the training process, the efficiency of trained precision and training is often to ginseng Number proposes the demand of opposite direction.Therefore, the application proposes a kind of process of dynamic training.According to the application, can will adjust The process of parameter is divided into multiple stages, wherein, each stage includes a certain number of training and recycles.Training process can be in every single order Its update parameters of the initial time of section.In this case, the quantity of training cycle that each stage is included can be referred to as For the update cycle.It is contemplated that the update cycle is smaller, and trained precision is higher, and the efficiency of training is lower.In addition, it is anticipated that It arrives, the quantity with classification cluster increases, and trained precision increases, but the efficiency of training reduces.It is referred to above to object Parameter when being classified may include all kinds of parameters that can influence object classification.This parameter includes but not limited to:Down-sampling The quantity of partial category, the quantity of classification cluster based on the generation of candidate categories collection, classification cluster update cycle.
Since at the beginning of deep neural network is established, parameters are larger with trained being changed.Therefore, in training Without too high precision, and it should more take trained efficiency into account the early period of process.With trained progress, parameters will It can tend towards stability.Therefore, in the later stage of training process, parameter can be suitably adjusted to obtain higher training precision.In addition, In the early period of training process, if the quantity setting for the partial category that down-sampling goes out is very few, over-fitting is may result in, from And influence training effect.
Based on above-mentioned thought, in one embodiment of the application, can carry out gradually decreasing down-sampling with trained Partial category quantity, gradually increase the quantity of the classification cluster generated based on candidate categories collection, and/or gradually increase single rank The number of training cycle in section.In this way, trained precision and efficiency can dynamically be taken into account.
Fig. 2 shows one embodiment of the step S1200 in Fig. 1.
With reference to Fig. 2, in step S1210, candidate categories successively two are divided into binary tree, each leaf node institute of binary tree Comprising classification quantity be less than or equal to the first quantity.That is, in step S1210, it is not based on any priori and constructs A kind of binary tree structure.In the binary tree, by two points layer by layer of candidate categories from root node, until class included in node Until other quantity is less than or equal to the first quantity.Final no longer divided node is known as leaf node.First quantity can be remote Less than the quantity of candidate categories.The set of candidate categories can show as the form of a weight matrix.Weight matrix it is each Row can represent the feature vector of each classification.Weight matrix can apply to the feature vector of object to obtain object for every one kind Other response.As described above, this response can be used for classifying to object.Therefore, it is retouched with reference to step S1210 The process stated is equivalent to establishes a kind of index structure of stratification for this weight matrix.It is appreciated that binary tree is only this One optional realization method of application category cluster.
In step S1220, feature is successively included into the next node of binary tree from the root node of binary tree, until The quantity for the classification that the node that feature is included into includes meets the quantity of predetermined classification cluster.That is, build binary tree structure it Afterwards, feature can be addressed based on the binary tree.For example, the feature vector that can will be extracted from the data item comprising object It is input in the binary tree.At the same time, second quantity can be set, which can be greater than or equal to the first quantity. On this basis, this feature vector is addressed layer by layer since root node, until this feature vector be included into comprising classification Quantity be less than or equal to the second quantity node.
In step S1230, node selection partial category that feature based is included into.For example, feature can be included into The all categories that node includes are elected to be as the partial category.Alternatively, the parent node of the node can be retracted into, and the mother is saved The all categories that point includes are chosen for the partial category.Or all categories included in these nodes can be formed one Then category set calculates European (Euclid) distance in category set between each classification and characteristics of objects, most at last Several classifications of Euclidean distance minimum are elected to be as the partial category.
Fig. 2 shows embodiment proposed to candidate categories carry out down-sampling be not based on fetching portion class method for distinguishing Any priori and be automatically performed, reduce the intervention degree of the mankind.
Fig. 3 shows one embodiment of the step S1210 in Fig. 2.Fig. 4 and Fig. 5 is schematically depicted to be retouched with reference to Fig. 3 The method stated obtains the schematic diagram of binary tree.
As shown in figure 3, in step S1211, based on any two classification in candidate categories, where building candidate categories Theorem in Euclid space is divided into two the first subspaces by the first hyperplane in theorem in Euclid space, the first hyperplane.Candidate categories can be with The form performance of candidate categories feature vector.In this case, candidate categories can regard the point being scattered in theorem in Euclid space as.Cause This, based on any two classification in candidate categories, can construct the hyperplane that the theorem in Euclid space is divided into two.
Such point embodies some features of candidate categories in itself.For example, when candidate categories collection is different people, use In build the first hyperplane two classifications can be candidate categories concentrate two people.In this case, it is the first super flat Face reflects some distinguishing hierarchy standards that the feature deduction based on the two people goes out.Such as:All people for wearing skirt return Class is positioned at the first subspace of the first hyperplane side;All people for not wearing skirt are classified as another positioned at the first hyperplane First subspace of side.Again for example:The people of all long hairs is classified as positioned at the first subspace of the first hyperplane side;Institute There is shorthead to be all classified as positioned at the first subspace of the first hyperplane opposite side.Distinguishing hierarchy standard listed above is only It is not intended to carry out any restrictions to the application for purposes of illustration.In fact, this distinguishing hierarchy standard can be from time Select some abstract characteristics that classification is extracted.
With reference to Fig. 4, theorem in Euclid space 4000 is divided into the first subspace 4100 and 4200 by the first hyperplane.First hyperplane The point passed through can be included into according to pre-defined algorithm in the first subspace 4100 or the first subspace 4200.
In step S1212, for the first subspace comprising the classification more than the first quantity, based in the first subspace Any two classification is as second the first subspace of hyperplane Loop partition, until the classification that the subspace marked off is included Quantity be less than or equal to the first quantity.Similar as abovely, the point that the second hyperplane is passed through can return according to pre-defined algorithm Enter in any subordinate subspace.I.e., it is possible to the subspace iteration execution comprising the classification more than the first quantity and step S1211 Similar operation, until the quantity of classification that any subspace marked off includes is respectively less than or equal to the first quantity.Reference Fig. 4, according to the quantity of classification, the first subspace 4100 is divided into subspace 4110 and subspace 4120.First subspace 4200 It is divided into subspace 4210 and subspace 4220.Further, subspace 4220 is also divided into subspace 4221 and subspace 4222.Finally, the quantity of classification included in theorem in Euclid space with the least significant end subspace corresponding to each leaf node of binary tree Respectively less than or equal to the first quantity.
Fig. 5 schematically depicts the theorem in Euclid space divided by iteration two where candidate categories to construct showing for binary tree It is intended to.In Figure 5, such as by the first quantity set it is 5.With the least significant end subspace institute corresponding to each leaf node of binary tree Comprising classification quantity be respectively less than or equal to 5.For example, least significant end subspace 4110,4210,4221 and 4222 includes 5 Classification, and least significant end subspace 4120 includes 4 classifications.
Binary tree is built independent of any priori by referring to the method that Fig. 3 to Fig. 5 is described, and is not based on appointing The priori category distribution of what lack of balance.Further, since in binary tree building process, by referring to classification in theorem in Euclid space Position distribution obtains the hierarchical structure of binary tree, so the division of this hierarchical structure takes into account the phase between classification and classification Like property, so as to help to train the deep neural network for performing object classification.
Down-sampling is carried out to obtain a kind of improvement for enlivening class method for distinguishing as to candidate categories, can be configured multiple two Fork tree.Since the building process of binary tree is independent of each other and with certain randomness, so more binary trees are configured The affinity information between classification can more completely be embodied.It should be appreciated that the quantity of binary tree is more, trained precision is higher, And the efficiency of training is lower.Therefore, parameter referred to above may include the quantity of binary tree.It, can be with trained progress Gradually increase the quantity of binary tree.
The application also provides a kind of object classification method, including:It is carried from pending data item by feature extractor Take the feature of object;Object classification is carried out by feature of the grader based on extraction and predefined candidate categories collection, wherein, it is special Levying extractor and grader, training is completed in advance using above-mentioned training method.With the object classification described above by reference to Fig. 1 to Fig. 5 The training method of model is different, and the object classification method that the application provides does not include the process of parameter adjustment.For example, object classification The process of any gradient backpropagation is not included in method.In addition, carry out object in the object classification model that training is used to complete During classification, all categories that candidate categories are concentrated all in state of activation, without in training process to classification into The process of row down-sampling.
Fig. 6 shows the block diagram of the object classification device 6000 according to the embodiment of the present application.
Object classification device 6000 includes:Feature extractor 6100, the extracting object from the data item comprising object Feature;Grader 6200 concentrates down-sampling to go out partial category from predefined candidate categories, obtain extracted feature for The response for the partial category that down-sampling goes out and based on response classify to object;And training aids 6300, according to classification Result adjustment grader and/or feature extractor in parameter.
Training aids 6300 can adjust the parameter in grader for classifying to object according to the result of classification.
Grader 6200 can be according to the parameter for being used to classify to object in grader, from predefined candidate categories collection Middle down-sampling goes out partial category.
Training aids 6300 may include:Training counter, the process of adjusting parameter is divided into multiple stages by training counter, more Each stage in a stage includes a certain number of training and recycles;And renovator, renovator is in the starting in each stage Parameter when adjustment classifies to object.
For may include at least one of to the parameter that object is classified:The quantity of the partial category of down-sampling, base The update cycle of quantity, classification cluster in the classification cluster of candidate categories collection generation.
Training aids can gradually decrease the quantity of the partial category of down-sampling with trained progress, gradually increase based on candidate The quantity of the classification cluster of classification collection generation, and/or the number for gradually increasing training cycle in the single stage.
Grader 6200 may include:Candidate categories successively two are divided into binary tree by binary tree composer, binary tree composer, The quantity of classification that each leaf node of binary tree is included is less than or equal to the first quantity;Addressing device, addressing device by feature from The root node of binary tree, which sets out, is successively included into the next node of binary tree, until the number of classification that the node that feature is included into includes Amount meets the quantity of predetermined classification cluster;And partial category extractor, the node that partial category extractor feature based is included into Selected part classification.According to actual demand, multiple binary trees can be configured.
Binary tree composer may include:Trunk composer, trunk composer are based on any two classification in candidate categories, structure Build the first hyperplane in the theorem in Euclid space where candidate categories, it is empty that theorem in Euclid space is divided into two first sons by the first hyperplane Between;Branches and leaves composer, branches and leaves composer is for the first subspace comprising the classification more than the first quantity, based on the first subspace Middle any two classification is as second the first subspace of hyperplane Loop partition, until the class that the subspace marked off is included Other quantity is less than or equal to the first quantity.
Present invention also provides a kind of object classification device, which includes:Feature extractor, feature extraction The feature of device extracting object from pending data item;Grader, feature and predefined candidate categories collection based on extraction Object classification is carried out, wherein, training is completed in advance using above-mentioned training method for feature extractor and grader.
The embodiment of the present application additionally provides a kind of electronic equipment, such as can be mobile terminal, personal computer (PC), put down Plate computer, server etc..Below with reference to Fig. 7, it illustrates suitable for being used for realizing the terminal device of the embodiment of the present application or service The structure diagram of the electronic equipment 700 of device:As shown in fig. 7, computer system 700 includes one or more processors, communication Portion etc., one or more of processors are for example:One or more central processing unit (CPU) 701 and/or one or more Image processor (GPU) 713 etc., processor can according to the executable instruction being stored in read-only memory (ROM) 702 or From the executable instruction that storage section 708 is loaded into random access storage device (RAM) 703 perform various appropriate actions and Processing.Communication unit 712 may include but be not limited to network interface card, and the network interface card may include but be not limited to IB (Infiniband) network interface card.
Processor can communicate with read-only memory 702 and/or random access storage device 630 to perform executable instruction, It is connected by bus 704 with communication unit 712 and is communicated through communication unit 712 with other target devices, is implemented so as to complete the application The corresponding operation of any one method that example provides, such as:Through feature extractor from the data item comprising object extracting object Feature;Categorized device concentrates down-sampling to go out partial category from predefined candidate categories, obtains extracted feature and is adopted under The response for the partial category that sample goes out and based on response classify to object;And grader is adjusted according to the result of classification And/or the parameter in feature extractor.Alternatively, the operation can be related to object classification method described above.
In addition, in RAM 703, it can also be stored with various programs and data needed for device operation.CPU 701、ROM 702 and RAM 703 is connected with each other by bus 704.In the case where there is RAM 703, ROM 702 is optional module.RAM Executable instruction is written in 703 storage executable instructions into ROM 702 at runtime, and executable instruction holds processor 701 The corresponding operation of the above-mentioned communication means of row.Input/output (I/O) interface 705 is also connected to bus 704.Communication unit 712 can collect Into setting, may be set to be with multiple submodule (such as multiple IB network interface cards), and in bus link.
I/O interfaces 705 are connected to lower component:Importation 706 including keyboard, mouse etc.;It is penetrated including such as cathode The output par, c 707 of spool (CRT), liquid crystal display (LCD) etc. and loud speaker etc.;Storage section 708 including hard disk etc.; And the communications portion 709 of the network interface card including LAN card, modem etc..Communications portion 709 via such as because The network of spy's net performs communication process.Driver 710 is also according to needing to be connected to I/O interfaces 705.Detachable media 711, such as Disk, CD, magneto-optic disk, semiconductor memory etc. are mounted on driver 710, as needed in order to be read from thereon Computer program be mounted into storage section 708 as needed.
Need what is illustrated, framework as shown in Figure 7 is only a kind of optional realization method, can root during concrete practice The component count amount and type of above-mentioned Fig. 7 are selected, are deleted, increased or replaced according to actual needs;It is set in different function component Put, can also be used it is separately positioned or integrally disposed and other implementations, such as GPU and CPU separate setting or can be by GPU collection Into on CPU, communication unit separates setting, can also be integrally disposed on CPU or GPU, etc..These interchangeable embodiments Each fall within protection domain disclosed in the present application.
Particularly, according to an embodiment of the present application, it may be implemented as computer above with reference to the process of flow chart description Software program.For example, embodiments herein includes a kind of computer program product, it is machine readable including being tangibly embodied in Computer program on medium, computer program are included for the program code of the method shown in execution flow chart, program code It may include the corresponding instruction of corresponding execution method and step provided by the embodiments of the present application, such as:Through feature extractor from comprising right The feature of extracting object in the data item of elephant;Categorized device concentrates down-sampling to go out partial category from predefined candidate categories, obtains It takes the response for the partial category that extracted feature goes out down-sampling and is classified based on response to object;And root The parameter in grader and/or feature extractor is adjusted according to the result of classification.Alternatively, instruction can be with object classification described above The step of method, corresponds to.In such embodiments, which can be downloaded by communications portion 709 from network And installation and/or from detachable media 711 be mounted.When the computer program is performed by central processing unit (CPU) 701, Perform the above-mentioned function of being limited in the present processes.
The present processes and device, equipment may be achieved in many ways.For example, software, hardware, firmware can be passed through Or any combinations of software, hardware, firmware realize the present processes and device, equipment.The step of for method Sequence is stated merely to illustrate, the step of the present processes is not limited to sequence described in detail above, unless with other Mode illustrates.In addition, in some embodiments, the application can be also embodied as recording program in the recording medium, this A little programs include being used to implement the machine readable instructions according to the present processes.Thus, the application also covers storage for holding The recording medium gone according to the program of the present processes.
The description of the present application provides for the sake of example and description, and is not exhaustively or by the application It is limited to disclosed form.Many modifications and variations are obvious for the ordinary skill in the art.It selects and retouches Embodiment is stated and be the principle and practical application in order to more preferably illustrate the application, and those of ordinary skill in the art is enable to manage The application is solved so as to design the various embodiments with various modifications suitable for special-purpose.

Claims (10)

1. a kind of training method of object classification model, which is characterized in that the object classification model include feature extractor and Grader, the training method include:
The feature of the object is extracted from the data item comprising object through the feature extractor;
Down-sampling is concentrated to go out partial category from predefined candidate categories through the grader, obtain extracted feature under The response of the partial category sampled out and based on it is described response classify to the object;And
Parameter in the grader and/or the feature extractor is adjusted according to the result of classification.
2. training method according to claim 1, which is characterized in that adjusted in the grader according to the result of classification Parameter includes:Parameter in the grader for classifying to the object is adjusted according to the result of classification.
3. training method according to claim 2, which is characterized in that through the grader from predefined candidate categories collection Middle down-sampling goes out partial category, including:
Through the grader and according to the parameter for being used to classify to the object in the grader, from predefined candidate Classification concentrates down-sampling to go out partial category.
4. the training method according to Claims 2 or 3, which is characterized in that the grader is adjusted according to the result of classification In parameter include:
The process of adjusting parameter is divided into multiple stages, each stage in the multiple stage is followed including a certain number of training Ring;And
Parameter when adjustment classifies to the object in the starting in each stage.
5. according to any training methods of claim 2-4, which is characterized in that described to be used to classify to the object Parameter include at least one of:The quantity of the partial category of down-sampling, the classification cluster based on candidate categories collection generation Quantity, classification cluster update cycle.
6. a kind of object classification method, which is characterized in that including:
Pass through the feature of feature extractor extracting object from pending data item;
Object classification is carried out by feature of the grader based on extraction and predefined candidate categories collection, wherein, the feature carries Taking device and the grader, training is completed in advance using the method as described in claim 1-5 is any.
7. a kind of object classification device, which is characterized in that the object classification device includes:
Feature extractor, the feature extractor extract the feature of the object from the data item comprising object;
Grader, the grader concentrate down-sampling to go out partial category from predefined candidate categories, obtain extracted feature The response of the partial category gone out for down-sampling and classified based on the response to the object;And
Training aids, the training aids adjust the parameter in the grader and/or the feature extractor according to the result of classification.
8. a kind of object classification device, which is characterized in that including:
Feature extractor, the feature of feature extractor extracting object from pending data item;
Grader, the feature based on extraction and predefined candidate categories collection carry out object classification, wherein, the feature carries Taking device and the grader, training is completed in advance using the method as described in claim 1-5 is any.
9. a kind of system for object classification, which is characterized in that the training system includes:
Memory stores executable instruction;And
One or more processors communicate with the memory to perform executable instruction, so as to complete and such as claim 1-5 In the corresponding operation of any training method or complete the corresponding behaviour of object classification method as claimed in claim 6 Make.
10. a kind of computer storage media, the computer storage media can store computer-readable instruction, when the calculating Machine readable instruction is performed, and processor is caused to perform behaviour corresponding with the training method as described in any in claim 1-5 Make or perform the corresponding operation of object classification method as claimed in claim 6.
CN201711481948.3A 2017-12-29 2017-12-29 Object classification and model training method, device, medium and system Pending CN108229556A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711481948.3A CN108229556A (en) 2017-12-29 2017-12-29 Object classification and model training method, device, medium and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711481948.3A CN108229556A (en) 2017-12-29 2017-12-29 Object classification and model training method, device, medium and system

Publications (1)

Publication Number Publication Date
CN108229556A true CN108229556A (en) 2018-06-29

Family

ID=62646367

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711481948.3A Pending CN108229556A (en) 2017-12-29 2017-12-29 Object classification and model training method, device, medium and system

Country Status (1)

Country Link
CN (1) CN108229556A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110151169A (en) * 2019-07-04 2019-08-23 中山大学 A kind of sleep state method for identifying and classifying based on electrocardiogram (ECG) data
CN112990389A (en) * 2021-05-18 2021-06-18 上海冰鉴信息科技有限公司 Flow layering method and device under wind control scene

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102402508A (en) * 2010-09-07 2012-04-04 华东师范大学 Similar image search device and search method thereof
CN105512681A (en) * 2015-12-07 2016-04-20 北京信息科技大学 Method and system for acquiring target category picture
CN106022317A (en) * 2016-06-27 2016-10-12 北京小米移动软件有限公司 Face identification method and apparatus
CN106033432A (en) * 2015-03-12 2016-10-19 中国人民解放军国防科学技术大学 A decomposition strategy-based multi-class disequilibrium fictitious assets data classifying method
CN106127232A (en) * 2016-06-16 2016-11-16 北京市商汤科技开发有限公司 Convolutional neural networks training method and system, object classification method and grader

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102402508A (en) * 2010-09-07 2012-04-04 华东师范大学 Similar image search device and search method thereof
CN106033432A (en) * 2015-03-12 2016-10-19 中国人民解放军国防科学技术大学 A decomposition strategy-based multi-class disequilibrium fictitious assets data classifying method
CN105512681A (en) * 2015-12-07 2016-04-20 北京信息科技大学 Method and system for acquiring target category picture
CN106127232A (en) * 2016-06-16 2016-11-16 北京市商汤科技开发有限公司 Convolutional neural networks training method and system, object classification method and grader
CN106022317A (en) * 2016-06-27 2016-10-12 北京小米移动软件有限公司 Face identification method and apparatus

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110151169A (en) * 2019-07-04 2019-08-23 中山大学 A kind of sleep state method for identifying and classifying based on electrocardiogram (ECG) data
CN112990389A (en) * 2021-05-18 2021-06-18 上海冰鉴信息科技有限公司 Flow layering method and device under wind control scene

Similar Documents

Publication Publication Date Title
US11537884B2 (en) Machine learning model training method and device, and expression image classification method and device
CN111444236B (en) Mobile terminal user portrait construction method and system based on big data
CN111079639B (en) Method, device, equipment and storage medium for constructing garbage image classification model
CN107766929B (en) Model analysis method and device
WO2022057658A1 (en) Method and apparatus for training recommendation model, and computer device and storage medium
CN112613552B (en) Convolutional neural network emotion image classification method combined with emotion type attention loss
CN113378940B (en) Neural network training method and device, computer equipment and storage medium
CN107438050A (en) Identify the method and system of the potential malicious user of website
CN104091038A (en) Method for weighting multiple example studying features based on master space classifying criterion
CN108228684A (en) Training method, device, electronic equipment and the computer storage media of Clustering Model
Alsaafin et al. A minimal subset of features using feature selection for handwritten digit recognition
CN113569895A (en) Image processing model training method, processing method, device, equipment and medium
CN108229556A (en) Object classification and model training method, device, medium and system
CN115239429A (en) Attribute information encoding method, device, equipment, medium and product
CN114299304A (en) Image processing method and related equipment
CN112819499A (en) Information transmission method, information transmission device, server and storage medium
CN116204599A (en) User information analysis system and method based on federal learning
CN111984842B (en) Bank customer data processing method and device
CN109657710A (en) Data screening method, apparatus, server and storage medium
WO2022123619A1 (en) Learning system, learning method, and program
Kotsiantis et al. Bagging model trees for classification problems
Xiao et al. Cost-sensitive semi-supervised ensemble model for customer churn prediction
CN111967973A (en) Bank client data processing method and device
Zakaria et al. Improved VGG Architecture in CNNs for Image Classification
CN112215441A (en) Prediction model training method and system

Legal Events

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