Target relation identification method based on self-evolution domain migration
Through the self-evolving domain migration method and feature alignment module, the long-tail problem and domain gap problem in target relationship recognition are solved, and the performance and overall performance of the model on rare classes are improved.
Patent Information
- Application Number
- CN202410740105.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-07
- Publication Date
- 2024-09-10
- Estimated Expiration
- 2044-06-07
AI Technical Summary
When existing target relationship recognition models are trained on long-tail distribution data sets, it is difficult to perform well on rare classes, and the domain gap between generated data and real data limits performance improvement.
The self-evolving domain migration method is used to generate data through the generative model, and the feature alignment module (scene feature alignment module and instance feature alignment module) is used to reduce the domain difference between the generated data and real data, combined with the teacher-student model and pseudo labels Generate techniques to improve model performance.
It significantly improves the performance of the target relationship recognition model, reduces the dependence on high-quality real data, enhances the application value of generated data in actual training, and improves the model's performance on rare classes.
Smart Images

Figure CN118628768A
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer vision, and in particular to a method based on target relationship recognition. Background Art
[0002] The purpose of object relation recognition is to locate humans and objects in an image and identify their interactions. The relation interaction is represented by a triple <human, relation, object>. Object relation recognition allows machines to understand human activities in images at a fine-grained level, which is an important step towards advanced visual reasoning and scene understanding. Although many models have been proposed in recent years, due to the long-tail distribution of objects and relations in the dataset, the models trained on such datasets perform well on non-rare classes, but average on rare classes.
[0003] Previous methods for solving the long-tail problem can be divided into two paradigms. The first category is based on training strategies. They alleviate the long-tail problem by adopting strategies such as resampling and retraining, specifically by changing the sampling strategy of long-tail data or adjusting the loss function. Another type of research method is based on combinatorial learning. They use the concept of combinatorial learning to reconstruct the interactions between person-object pairs and different HOI instances as new training samples. In this way, they promote the generalization of knowledge between HOI classes and form new triples to alleviate the long-tail problem. Although these methods have made great progress, they have not fundamentally solved the long-tail problem caused by data imbalance. Recently, AI-generated content has made significant progress in generating images, which has also opened up the possibility of replacing real data with AI-generated data. Therefore, a straightforward idea is to use the generative model to synthesize rare classes in the target relationship recognition dataset, which can provide more training data and solve the long-tail distribution problem faced by target relationship recognition from the bottom up. However, simply using the target relationship recognition label as a language-guided generated picture to merge into the original dataset for training does not directly improve the performance of the model. After analysis, this is because there is a relatively large domain gap between the original data and the generated data. Summary of the invention
[0004] In order to overcome the deficiencies of the prior art, the present invention provides a target relationship identification method based on self-evolution domain migration.
[0005] This paper uses a generative model to generate data and uses a feature alignment method to bridge the domain difference between the generated data and the original data, thereby improving the performance of the target relationship recognition benchmark model. This method significantly reduces the reliance of target relationship recognition on large-scale high-quality real data, fills the data gap by generating images, and provides a new idea for using generated data for actual training and target relationship recognition.
[0006] The technical solution adopted by the present invention mainly includes the following parts: a data generation part, a pseudo-label generation part and a feature alignment part. First, in the data generation part, an existing generation model, such as blip-diffusion, is used to take the target relationship category as a language control to generate the required data. Secondly, in the pseudo-label generation part, a method based on a teacher-student model is adopted. After the generated image is weakly enhanced, it is sent to the teacher model to generate pseudo-label data that can be used for training. Finally, in the feature alignment part, a scene feature alignment module and an instance feature alignment module are introduced. These modules align the features in terms of scenes and instances for images of the original domain and the generated domain, respectively, to narrow the gap between the two domains. By combining these parts, the present invention realizes a target relationship recognition method based on self-evolution domain migration.
[0007] The technical solution adopted by the present invention to solve the technical problem includes the following steps:
[0008] Step 1: First, collect labels from the existing person relationship recognition dataset. The label is a triplet <person, relationship, object>. For example, the person relationship of a person riding a horse is represented by the triplet <person, riding, horse>. Then the triplet is represented as a text description of "a picture of a person + relationship + object", where the relationship represents the relationship category in the triplet and the object represents the object category in the triplet. For example, the triplet <person, relationship, object> is represented as a text description of "a picture of a person riding a horse". The text is input into the blip-diffusion model to generate the corresponding image I. gen ;
[0009] Step 2: The teacher-student model includes two target relationship recognition baseline models with the same architecture and the same initialization weights. The teacher model inputs the weakly enhanced generated image and generates a pseudo label. The student model inputs the strongly enhanced original image and the generated image, and is updated by back propagation using the pseudo label generated by the teacher model. The parameters of the teacher model are updated by the exponential moving average of the student model parameters, as shown in the following formula:
[0010] θ t =αθ t +(1-θ)θ s (1)
[0011] where θ t are the parameters of the teacher model, θ s is the parameter of the student model, α is a hyperparameter with a value range of 0-1; for the labels generated by the teacher model, a predefined threshold is set, and the threshold value range is 0-2;
[0012] Because the generated image has no corresponding label and cannot be trained, the generated image is first input into the teacher model. The teacher model outputs a label and its corresponding prediction score. If the prediction score is higher than the threshold, the label generated by the teacher model is used as a pseudo label for supervision of the generated image; if the prediction score output by the teacher model is lower than the threshold, the corresponding prediction is discarded;
[0013] Step 3: For the baseline model of object relationship recognition, CNN and Transformer encoder are used to extract visual features;
[0014] Step 4: In order to align the scene information of the image, a conditionally controlled image reconstruction method is proposed. By randomly masking some areas of the generated image, and under the conditional control of the original image features of the same category, the encoder and auxiliary decoder of the student model are used to reconstruct the masked areas, which helps to improve the model's ability to learn the generated domain features and improve the ability to migrate the generated domain features to the original domain features;
[0015] Step 5: The operation in step 4 effectively aligns the context scene features, but the target relationship recognition task is to locate the person-object pair instances and identify their relationships, so the instance-level features play a very important role. Therefore, an instance feature alignment module is proposed to align the person-object pair instance features.
[0016] Step 6: Calculate the overall network loss;
[0017] The loss function is used for back propagation, and then multiple models are obtained through training. The model with a map of 0.34 or above on the test set is selected for application. Finally, the relationship between the characters in the image can be obtained based on the output of the model.
[0018] In step 3, a picture I with a shape of (H, W, C) is fed into CNN, and CNN outputs features Where H′ represents the length of the feature, W′ represents the width of the feature, and D b Represents the dimension of the feature; then the feature X b After a linear mapping layer, the feature dimension is transformed into D c Next, the flattening operator is used to compress the spatial dimension into one dimension to generate the flattened feature Then X b ′ and position encoding The Transformer encoder learns global information and generates features with richer context information through the multi-head self-attention mechanism. After obtaining the Transformer encoder features, the Transformer encoder features Xe and example query The input instance decoder detects the location of people and objects in the image and the classification of objects, where N insq represents the number of queries, D insd Represents the feature dimension of the query; Transformer encoder feature X e and relationship queries Input relation decoder to predict the relation category corresponding to the person and object pair, where N intq represents the number of relational queries, D insd Represents the feature dimension of the relation query; finally, the relation decoder outputs the relation feature Where N intq represents the number of relational queries, D d Represents the feature dimension of the decoder.
[0019] In step 4, first, the image I is generated with a ratio L gen Perform random masking, and L in the present invention is set to 0.8 to obtain the mask image I mask ; Then the original image I src and mask image I mask The original image features X are obtained through the encoder of the model src and mask image feature X mask ; In order to improve the ability to learn the original image features, X src and X mask The condition controller Condition is a Transformer decoder. In the condition controller Condition, X src For query, X mask It is used as both a key and a value. The output of the conditional controller is represented as Sign. Considering that not all image blocks in the original image are helpful in reconstructing the generated image, a gating mechanism is used to select Signs greater than 0.5, which are finally used for the original image feature X of the conditional control. src_ond By Sign and X src The purpose of element-by-element multiplication is to mask out some original image features that are irrelevant to reconstruction. Sign is expressed as:
[0020] Sign=Gate(Condition(X src , X mask ) (2)
[0021] X src_ond =Sign*X src (3)
[0022] Where Condition and Gate represent the condition controller and gate mechanism respectively, and * represents element-wise dot product;
[0023] The original image features X that will be used for conditional control src_ond And the mask image feature X after masking mask The fused features are then sent to the auxiliary decoder to reconstruct the generated image and obtain the reconstructed image I recon :
[0024] I recon =Decoder(Concate(X src_ond ,X mask )) (4)
[0025] Where Decoder represents the auxiliary decoder, and Concate represents the concatenation operation;
[0026] Then the reconstructed image I recon And generate image I gen For comparison, the scene reconstruction loss L is calculated using the mean square error loss scn , the calculation formula is as follows:
[0027]
[0028] in and represent the reconstructed i-th image block and the i-th generated image block respectively.
[0029] In step 5, the specific steps are as follows:
[0030] Many previous domain alignment methods use the adversarial learning framework to align features. Most methods feed all relational queries into the discriminator for alignment. However, due to the existence of redundant or even erroneous queries, this will inevitably lead to the model not being able to focus on the desired relational queries, resulting in suboptimal results. To solve this problem, a prototype instance alignment method based on graph networks is proposed.
[0031] For the output of the relation decoder, due to the existence of redundant queries, considering that the average number of character relationships in a picture in the data set is about 6 groups, the 6 groups of relation queries with the highest scores are selected as instance prototypes, and the remaining queries are used as ordinary queries. In order to better aggregate instance information, ordinary queries can transmit instance feature information to the prototype. Considering the effectiveness of graph neural networks in formulating information transmission, graph neural networks are used to aggregate instance information; specifically, a graph G = (A, X) is constructed, X represents node features, specifically the output of the relation decoder, the prototype instance in the graph network is called the prototype node, the ordinary query is called the ordinary node, and A is the adjacency matrix. In order to aggregate instance information to the prototype, it is defined that the prototype node has an edge connection with the ordinary node and the remaining prototype nodes, and there is no edge connection between ordinary nodes and ordinary nodes. Then, a graph convolutional neural network is used to propagate node features. The formula is as follows:
[0032] X = GCN (A, X) (6)
[0033] X p ={X i |i∈P} (7)
[0034] Where GCN stands for graph convolutional neural network, P represents the index set of prototype nodes, A is the adjacency matrix, X represents node features, and X i represents the i-th node feature, X p Represents the prototype node characteristics;
[0035] The extracted prototype node feature X p As the instance feature obtained, it is input into the decoding feature discriminator for feature alignment, and the global feature X b and encoder feature X e They are also sent to the global feature discriminator and the encoding feature domain discriminator for feature alignment, as shown in the formula:
[0036]
[0037] Where D bac is the global feature domain discriminator, D enc is the encoding feature domain discriminator, src represents the original image, gen represents the generated image, and the instance loss is defined as follows:
[0038]
[0039] Where D dec is the decoding feature domain discriminator.
[0040] In step 6, the network accepts two inputs, namely the original image and the generated image, and uses L suprepresents the original image target relationship recognition loss calculated using the label of the original image, L unsup represents the generated image target relationship recognition loss calculated using pseudo labels, and the discriminator optimization target is shown in the following formula:
[0041]
[0042] Where T and D represent the relation recognition detector and discriminator respectively, L inst is the instance loss obtained by formula (9), L adv is the discriminator loss; the loss of the original image L src It includes the original image target relationship recognition loss and the original image discriminator loss, which is defined as:
[0043] L src =L sup +L advs (11)
[0044] Where L sup is the original image target relationship recognition loss, L advs The original image is fed into the model using formula (10) to obtain the original image discriminator loss;
[0045] The loss L for generating images gen It includes the generated image target relationship recognition loss, discriminator loss and context reconstruction loss, which are defined as:
[0046] L gen =L unsup +L scn +L advg (12)
[0047] Where L unsup To generate image-target relationship recognition loss, L scn is the scene reconstruction loss of formula (5), L advg The generated image is fed into the model using the generated image discriminator loss obtained using formula (10);
[0048] The total loss function is:
[0049] L loss =L src +L gen (13)
[0050] After obtaining the loss function, back propagation is performed using the loss function, and then multiple models are obtained through training. The model with a map of more than 0.34 on the test set is selected for application. Finally, the relationship between the characters in the image can be obtained based on the output of the model.
[0051] The beneficial effect of the present invention is that it adopts a target relationship recognition method based on self-evolution domain migration to solve the long-tail problem existing in the current target relationship recognition. Specifically, it is proposed to use a generative model to deal with the long-tail problem. At the same time, in order to bridge the domain gap between the generated data and the original data, a scene alignment module and an instance alignment module are proposed to align the context scene features and the person-object pair instance features. This provides a new idea for using generated data for actual training and target relationship recognition. Experimental results show that the new model framework has made progress in both accuracy and usability. The overall structure of the model is as follows Figure 1 shown. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 This is a model framework diagram of the target relationship identification method based on self-evolution domain migration in the present invention
[0053] Figure 2 This is the actual predicted effect of the present invention. DETAILED DESCRIPTION
[0054] The present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0055] The following is a specific implementation example of the present invention.
[0056] The present invention provides a target relationship identification method based on self-evolution domain migration, and the specific process is as follows:
[0057] 1. Image generation;
[0058] The target relationship category information is extracted, such as "person riding a horse", and then the category is expanded to "a picture of a person riding a horse" and sent to the blip-diffusion model to produce pictures of this category.
[0059] 2. Image feature extraction;
[0060] Given an original image I src And generate image I gen , resize it to 512×512, and then send it to the ResNet-50 convolutional neural network to obtain the image feature X to be detected b ∈R (16×16)×2048 , and then pass it through a linear mapping layer to make its feature dimension 256, the new feature is X b ′∈R (16×16)×256 Then it is sent to the Transformer encoder, and through the self-attention mechanism, the encoder output feature is X e ∈R 256×256 .
[0061] 3. Target category and location prediction;
[0062] The encoder feature X e The example decoder is Transforemer decoder. The query is set to 256. The output of the example decoder is X instd ∈R 256×256 For each query, three fully connected layers are connected to predict the coordinate box of the person, the coordinate box of the object, and the category of the object respectively.
[0063] 4. Target relationship prediction;
[0064] The encoder feature X e and instance decoder features X instd Input to the relational decoder, the relational decoder is the Transforemer decoder, set the query to 64, then the output of the relational decoder is X d ∈R 64×256 , for each query, a fully connected layer is connected to predict the relationship corresponding to this query.
[0065] 5. Scene feature alignment;
[0066] Generate Image I gen After being sent to the student model, a random mask is first performed at a ratio of 0.8 to obtain I mask , and then the original image I src And the masked mask image I mask The features X are obtained through the encoder of the model src ∈R 256×256 and X mask ∈R 256×256 , then X src and X mask It is sent to the condition controller and then passes through a gate unit to obtain the control signal Sign∈R 256×1 , then the control signal is expanded and X src Multiply element by element to get the conditional control signal X src_cond ∈R 256 ×256 The conditional control signal is concatenated with the feature obtained after occlusion to obtain the fused feature, which is then sent to the auxiliary decoder to reconstruct the generated image as shown in formula (4). Then, the reconstructed image is compared with the generated image according to formula (5) to obtain the context scene reconstruction loss L scn .
[0067] 6. Encoder feature alignment;
[0068] Then the ResNe-50 feature X bIt is sent to the global feature discriminator. Specifically, the discriminator consists of a two-dimensional convolution, and finally outputs the discriminator result D b ∈R (16×16)×1 , similarly, the encoder feature X e It is sent to a fully connected encoding feature discriminator, and finally the discriminator result D is output e ∈R 256×1 .
[0069] 7. Instance feature alignment;
[0070] For the output of the relation decoder, the predicted relation scores are sorted, and the 6 predictions with the highest scores are selected as prototype nodes, and the rest are used as ordinary nodes. Then, the adjacency matrix is constructed as described above to construct a graph G. The constructed graph is fed into a 2-layer graph convolutional neural network to obtain X. d ′∈R 64×256 The output of the prototype node is then extracted to obtain the prototype feature X p ′∈R 6×256 , and then send it to a decoding feature discriminator composed of full connections, and finally output the discriminator result D inst ∈R 6×1 . D e and D inst The discriminator loss is calculated according to formula (10), and then the overall loss is calculated according to formula (13) for back propagation.
[0071] 8. Model training;
[0072] The entire training process is end-to-end training. The experiments are mainly conducted on two different HOI datasets: HICO-Det and V-COCO. The threshold of the pseudo label is 1.4 on the two baseline models GEN-VLKT and HOICLIP, and 0.4 on the CDN baseline model. Fine-tuning is performed on the pre-trained weights of the HOI baseline model. The AdamW optimizer is used, the weight decay is 1e-4, and the generated image batch size is set to 16. All models are trained on 8 DCUs for 5 epochs. For CND, the RestNet learning rate is 1e-5, and the learning rate for the others is 1e-4. For GEN-VLKT and HOICLIP, the RestNet learning rate is 1e-6, and the learning rate for the others is 1e-4.
[0073] 9. Model application;
[0074] After the above training process, multiple models can be obtained. The best model (the one with the best test result on the test set) is selected for application. The parameters of the entire network model are fixed. Just input the image data and propagate forward. The image and language feature vectors X are obtained in turn.e , and the instance decoder X instd and the relational decoder outputs X d Then, the fully connected layer is used to classify and regress the position of the person, the category and position of the target, and the prediction result can be directly obtained. The actual effect diagram is as follows Figure 2 As shown, this method can significantly improve the target relationship recognition performance.
[0075] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention are within the protection scope of the present invention.
Claims
1. A target relationship identification method based on self-evolution domain migration, characterized in that The steps include: Step 1: First, collect labels from the existing person relationship recognition dataset. The label is a triplet <person, relationship, object>, where the relationship represents the relationship category in the triplet and the object represents the object category in the triplet. Input the text into the blip-diffusion model to generate the corresponding image I gen ; Step 2: The teacher-student model includes two target relationship recognition baseline models with the same architecture and the same initialization weights. The teacher model inputs the weakly enhanced generated image and generates a pseudo label. The student model inputs the strongly enhanced original image and the generated image, and is updated by back propagation using the pseudo label generated by the teacher model. The parameters of the teacher model are updated by the exponential moving average of the student model parameters, as shown in the following formula: i t =θ t +(1-α)θ s (1) where θ t are the parameters of the teacher model, θ s is the parameter of the student model, α is a hyperparameter with a value range of 0-1; for the labels generated by the teacher model, a predefined threshold is set, and the threshold value range is 0-2; Because the generated image has no corresponding label and cannot be trained, the generated image is first input into the teacher model. The teacher model outputs a label and its corresponding prediction score. If the prediction score is higher than the threshold, the label generated by the teacher model is used as a pseudo label for supervision of the generated image; if the prediction score output by the teacher model is lower than the threshold, the corresponding prediction is discarded; Step 3: For the baseline model of object relationship recognition, CNN and Transformer encoder are used to extract visual features; Step 4: In order to align the scene information of the image, a conditionally controlled image reconstruction method is proposed. By randomly masking some areas of the generated image, and under the conditional control of the original image features of the same category, the encoder and auxiliary decoder of the student model are used to reconstruct the masked areas, which helps to improve the model's ability to learn the generated domain features and improve the ability to migrate the generated domain features to the original domain features; Step 5: The operation in step 4 effectively aligns the context scene features, and an instance feature alignment module is proposed to align the instance features of person-object pairs; Step 6: Calculate the overall network loss; The loss function is used for back propagation, and then multiple models are obtained through training. The model with a map of 0.34 or above on the test set is selected for application. Finally, the relationship between the characters in the image can be obtained based on the output of the model.
2. The target relationship identification method based on self-evolution domain migration according to claim 1 is characterized in that: In step 3, a picture I with a shape of (H, W, C) is fed into CNN, and CNN outputs features Where H′ represents the length of the feature, W′ represents the width of the feature, and D b Represents the dimension of the feature; then the feature X b After a linear mapping layer, the feature dimension is transformed into D c Next, the flattening operator is used to compress the spatial dimension into one dimension to generate the flattened feature Then X b ′ and positional encoding The Transformer encoder learns global information and generates features with richer context information through the multi-head self-attention mechanism. After obtaining the Transformer encoder features, the Transformer encoder features X e and example query The input instance decoder detects the location of people and objects in the image and the classification of objects, where N insq represents the number of queries, D insd Represents the feature dimension of the query; Transformer encoder feature X e and relationship queries Input relation decoder to predict the relation category corresponding to the person and object pair, where N intq represents the number of relational queries, D insd Represents the feature dimension of the relation query; finally, the relation decoder outputs the relation feature Where N intq represents the number of relational queries, D d Represents the feature dimension of the decoder.
3. The target relationship identification method based on self-evolution domain migration according to claim 1 is characterized in that: In step 4, first, the image I is generated with a ratio L gen Perform random masking to obtain mask image I mask ; Then the original image I src and mask image I mask The original image features X are obtained through the encoder of the model src and mask image feature X mask ; In order to improve the ability to learn the original image features, X src and X mask Enter the condition controller Condition, which is a Transformer decoder; in the condition controller Condition, X src For query, X mask It is used as both a key and a value. The output of the conditional controller is represented as Sign. Considering that not all image blocks in the original image are helpful in reconstructing the generated image, a gating mechanism is used to select Signs greater than 0.5, which are finally used for the original image feature X of the conditional control. src_ond By Sign and X src The purpose of element-by-element multiplication is to mask out some original image features that are irrelevant to reconstruction. Sign is expressed as: Sign=Gate(Condition(X src ,X mask ) (2) X src_ond =Sign*X src (3) Where Condition and Gate represent the condition controller and gate mechanism respectively, and * represents element-wise dot product; The original image features X that will be used for conditional control src_ond And the mask image feature X after masking mask The fused features are then sent to the auxiliary decoder to reconstruct the generated image and obtain the reconstructed image I recon : I recon =Decoder(Concate(X src_ond ,X mask )) (4) Where Decoder represents the auxiliary decoder, and Concate represents the concatenation operation; Then the reconstructed image I recon And generate image I gen For comparison, the scene reconstruction loss L is calculated using the mean square error loss scn , the calculation formula is as follows: in and represent the reconstructed i-th image block and the i-th generated image block respectively.
4. The target relationship identification method based on self-evolution domain migration according to claim 3 is characterized in that: The L is set to 0.
8.
5. The target relationship identification method based on self-evolution domain migration according to claim 1 is characterized in that: In step 5, the specific steps are as follows: Construct a graph G = (A, X), where X represents the node feature, specifically the output of the relational decoder. The prototype instance in the graph network is called the prototype node, and the ordinary query is called the ordinary node. A is the adjacency matrix. In order to aggregate instance information to the prototype, it is defined that the prototype node has an edge connection with the ordinary node and the rest of the prototype nodes, and there is no edge connection between ordinary nodes. Then, a graph convolutional neural network is used to propagate the node features. The formula is as follows: X = GCN (A, X) (6) X p ={X i |i∈P} (7) Where GCN stands for graph convolutional neural network, P represents the index set of prototype nodes, A is the adjacency matrix, X represents node features, and X i represents the i-th node feature, X p Represents the prototype node characteristics; The extracted prototype node feature X p As the instance feature obtained, it is input into the decoding feature discriminator for feature alignment, and the global feature X b and encoder feature X e They are also sent to the global feature discriminator and the encoding feature domain discriminator for feature alignment, as shown in the formula: Where D bac is the global feature domain discriminator, D enc is the encoding feature domain discriminator, src represents the original image, gen represents the generated image, and the instance loss is defined as follows: Where D dec is the decoding feature domain discriminator.
6. The target relationship identification method based on self-evolution domain migration according to claim 1 is characterized in that: In step 6, the network accepts two inputs, namely the original image and the generated image, and uses L sup represents the original image target relationship recognition loss calculated using the label of the original image, L unsup represents the generated image target relationship recognition loss calculated using pseudo labels, and the discriminator optimization target is shown in the following formula: Where T and D represent the relation recognition detector and discriminator respectively, L inst is the instance loss obtained by formula (9), L adv is the discriminator loss; the loss of the original image L src It includes the original image target relationship recognition loss and the original image discriminator loss, which is defined as: L src =L sup +L advs (11) Where L sup is the original image target relationship recognition loss, L advs The original image is fed into the model using formula (10) to obtain the original image discriminator loss; The loss L for generating images gen It includes the generated image target relationship recognition loss, discriminator loss and context reconstruction loss, which are defined as: L gen =L unsup +L scn +L advg (12) Where L unsup To generate image-target relationship recognition loss, L scn is the scene reconstruction loss of formula (5), L advg The generated image is fed into the model using the generated image discriminator loss obtained using formula (10); The total loss function is: L loss =L src +L gen (13) After obtaining the loss function, back propagation is performed using the loss function, and then multiple models are obtained through training. The model with a map of more than 0.34 on the test set is selected for application. Finally, the relationship between the characters in the image can be obtained based on the output of the model.
Citation Information
Patent Citations
Cross-domain target detection method based on multi-level domain adaptive weak supervised learning
CN116342942A
Human-object interaction detection method based on virtual enhancement
CN117115695A
