Domain adaptive image data automatic collection method and system and electronic equipment

By automatically filtering high confidence targets and calculating comprehensive confidence, the problem of long-term acquisition of training data and high labor costs is solved, and the model migration is quickly adapted to different scenarios is achieved, reducing costs and improving labeling efficiency.

CN120407831APending Publication Date: 2025-08-01HANGZHOU INNOVATION RES INST OF BEIJING UNIV OF AERONAUTICS & ASTRONAUTICS +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510510776.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-23
Publication Date
2025-08-01

AI Technical Summary

Technical Problem

When training visual models, the existing technology requires a large amount of high-quality data to be acquired and sorted, which makes it difficult to quickly adapt to model migration in different scenarios.

Method used

The domain adaptive image data automatic collection method is adopted to obtain training data through the visual characteristics of the image itself and the video spatiotemporal correlation characteristics, and the object detection and tracking algorithm are used to filter high confidence targets, calculate the comprehensive confidence and horizontal perspective diversity parameters, and automatically filter the training data.

Benefits of technology

It significantly reduces the manual demand for data acquisition and labeling, improves labeling efficiency, reduces costs, and realizes rapid model migration to adapt to different scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120407831A_ABST
    Figure CN120407831A_ABST
Patent Text Reader

Abstract

The invention discloses a domain self-adaptive image data automatic collection method and system and electronic equipment, and the method comprises the steps: carrying out the preprocessing of original image sequence data, and obtaining the target labeling information needed by training data through the visual features of an image and the time-space correlation characteristics of a video; calculating the comprehensive confidence coefficient of the current image according to the obtained target labeling information, and performing data reliability screening through the comprehensive confidence coefficient; and then, according to a data reliability screening result, carrying out data diversity screening, calculating a target horizontal view diversity parameter, and if the horizontal view diversity parameter meets a preset condition, storing the current image and the corresponding target annotation information as training data. According to the method, rapid evaluation is carried out from the aspects of data diversity and reliability, the image data required by domain self-adaption is acquired to adjust the equipment vision algorithm model, and the comprehensive cost of acquiring corresponding data of the edge equipment in different scenes can be remarkably reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vision domain adaptation, and more specifically, to a domain adaptation image data automatic collection method, system and electronic device. Background Art

[0002] At present, due to its powerful feature extraction ability, deep learning technology has occupied a significant dominant position in the object detection algorithms of edge intelligent devices. The essence of deep learning lies in using a multi-layer stacked deep neural network to learn the feature distribution of scene data. Therefore, when a deep learning model trained based on a specific environment runs in another scene with a large difference, due to the data distribution difference between the source domain (training environment) and the target domain (application environment), its performance will decline to varying degrees, which may affect the normal operation of the algorithm.

[0003] To address the above performance degradation problem, vision domain adaptation uses methods such as pseudo-label self-training and feature adversarial learning to adapt the model to the current environment by adjusting the data feature distribution of the model, so as to achieve high accuracy in object detection in the target domain. Among them, the method based on pseudo-label self-training can better adapt to the characteristics of large amounts of video data and few labeled data, and has good potential in the application scenarios of edge intelligent devices.

[0004] However, the method of pseudo-label self-training requires a large amount of data to adjust the model, and the quality of the data is directly related to the performance of model domain adaptation. On the other hand, obtaining sufficient high-quality data often requires a large amount of direct economic cost and time cost. Summary of the Invention

[0005] Aiming at the problems of long working hours and high labor costs for obtaining / arranging training data required when training a vision model, and facing the unstructured operation scenarios of robots commonly used in vision algorithms, the present invention provides a domain adaptation image data automatic collection method, system and electronic device, which can quickly evaluate and obtain the image data required for domain adaptation from the perspectives of data diversity and reliability according to the target state information, so as to adjust the device vision algorithm model, thereby significantly reducing the comprehensive cost of obtaining corresponding data by edge intelligent devices in different scenarios.

[0006] To achieve the above object, the technical solution adopted by the present invention is as follows:

[0007] In the first aspect, the present invention provides a domain adaptation image data automatic collection method, which includes the following steps:

[0008] S1: Preprocess the original image sequence data, and obtain the target annotation information required for training data by using the visual features of the image itself and the spatio-temporal correlation characteristics of the video;

[0009] S2: Calculate the comprehensive confidence of the current image based on the obtained target annotation information, and perform data reliability screening through the comprehensive confidence;

[0010] S3: According to the data reliability screening result, perform data diversity screening, calculate the target horizontal view angle diversity parameter. If the horizontal view angle diversity parameter meets the preset condition, save the current image and the corresponding target annotation information as training data.

[0011] Further, in S1, use the visual features of the image itself and the spatio-temporal correlation characteristics of the video to obtain the target annotation information required for training data, specifically including:

[0012] 1) For the image at a certain moment in the original image sequence data, obtain the information of the position, category, and confidence score of the initial target through the target detection and tracking algorithm; and use the high confidence threshold and the uncertainty threshold to divide the detected targets into high confidence targets, uncertain targets, and low confidence targets, and the rest are determined to be truly existing targets;

[0013]

[0014] Among them, o0 represents the initial target, s o represents the confidence score of the initial target, t u represents the uncertainty threshold, t h represents the high confidence threshold;

[0015] 2) Use the detected high confidence targets and the tracked targets to update the relevant information of the corresponding ID in the target status table. The method is as follows:

[0016] For the detected high confidence targets, match the target ID of the adjacent moment through the boundary box category, scale, and position information; for the same category targets, calculate the relative distance. When it is less than a specific threshold with the adjacent frame image, it is determined to be the same ID. The calculation formula is:

[0017] RD obj =Δx + Δy + Δw + Δh

[0018] Δx=(x2 - x1) / w1, Δy=(y2 - y1) / h1

[0019] Δw = log(w2 / w1), Δh = log(h2 / h1)

[0020] Among them, RD obj is the relative distance; Δx, Δy represent the relative deviation of the centroid, and Δw, Δh represent the scale deviation of the bounding box; the subscript 1 represents the previous frame, and the subscript 2 represents the next frame;

[0021] Filter out low-confidence targets. If the ID corresponding to the remaining targets exists in the target status table, reset the target loss frame count to 0, update the position and category of the corresponding ID in the table, and write the current confidence score into the queue. If the ID does not exist in the target status table, create a new target, write the position and category to the corresponding ID, initialize the confidence queue as an empty queue, write the corresponding target confidence score into the queue, and at the same time initialize the key frame pose value as a NaN value and the target loss frame count as 0. If the ID in the target status table is not in the algorithm target information, increase the target loss frame count by 1. When the target loss frame count reaches a certain threshold, delete the relevant information of this ID from the target status table.

[0022] Further, the target detection and tracking algorithm is the DeepSORT algorithm, and the detector in the algorithm uses YOLOv5.

[0023] Further, in S2, calculate the comprehensive confidence of the current image according to the obtained target annotation information, and the calculation formula is:

[0024] n c =ω h ·(n h +n t ) - ω u ·n u

[0025] In the formula, n c represents the comprehensive confidence; n h represents the number of high-confidence targets in the current image; n t represents the number of targets determined to exist by the algorithm; n u represents the number of targets with uncertain confidence; ω h and ω u are the weights of high-confidence targets and uncertain-confidence targets respectively.

[0026] Further, if the comprehensive confidence value is positive, transmit the current image and the annotation information to step 3 for processing, otherwise end the current processing process and transfer to process the next frame of image.

[0027] Further, in S3, the calculation formula for the horizontal view diversity parameter is:

[0028]

[0029] In the formula, θ represents the horizontal view diversity parameter; θ i represents the horizontal pose angle; n represents the number of targets; w represents the pixel width of the image; x represents the abscissa of the target centroid; θ w represents the horizontal field of view angle of the camera.

[0030] In a second aspect, the present invention further provides a domain adaptation image data automatic collection system, which applies the above-mentioned domain adaptation image data automatic collection method to collect training data. The system includes:

[0031] A target state acquisition module, which is used to preprocess the original image sequence data and obtain the target annotation information required for training data by using the visual features of the image itself and the spatio-temporal correlation characteristics of the video;

[0032] A data reliability evaluation and screening module, which is used to calculate the comprehensive confidence of the current image according to the obtained target annotation information and perform data reliability screening through the comprehensive confidence;

[0033] A data reliability evaluation and screening module, which is used to perform data diversity screening according to the data reliability screening results, calculate the target horizontal view angle diversity parameter, and if the horizontal view angle diversity parameter meets the preset conditions, save the current image and the corresponding target annotation information as training data.

[0034] In a third aspect, the present invention further provides an electronic device, including a processor and a memory. The memory stores machine-executable instructions that can be executed by the processor, and the processor executes the machine-executable instructions to implement the above-mentioned domain adaptation image data automatic collection method.

[0035] Compared with the prior art, the present invention provides a domain adaptation image data automatic collection method, system and electronic device, which at least have the following beneficial technical effects:

[0036] The present invention can automatically obtain high-quality training data, greatly reduce the manual operation requirements in the data acquisition, annotation and screening links, which is conducive to greatly reducing the data-related costs; significantly improve the annotation efficiency, enable the model migration work in different scenarios to be carried out quickly, and help save costs.

[0037] Other features and advantages of the present invention will be described in the following specification, and, in part, will become apparent from the specification, or will be understood by implementing the present invention. The objectives and other advantages of the present invention can be achieved and obtained by the structures specifically pointed out in the written specification and the drawings.

[0038] The technical solutions of the present invention will be further described in detail below through the drawings and embodiments. Description of the Drawings

[0039] To more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0040] The drawings are used to provide a further understanding of the present invention and constitute a part of the specification. They are used together with the embodiments of the present invention to explain the present invention and do not constitute a limitation to the present invention.

[0041] Figure 1 It is a schematic diagram of the working process of a domain adaptation image data automatic collection method provided by an embodiment of the present invention.

[0042] Figure 2 It is a schematic diagram of the logical relationship between the steps provided by an embodiment of the present invention.

[0043] Figure 3 It is a schematic diagram for describing the relative pose relationship between the target and the camera lens provided by an embodiment of the present invention.

[0044] Figure 4 It is a schematic diagram of an electronic device provided by an embodiment of the present invention. Detailed implementation manners

[0045] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention.

[0046] In the description of the present invention, it should be noted that in some processes described in the specification and drawings of the present application, there are multiple operations that appear in a specific order. However, it should be clearly understood that these operations may not be executed in the order in which they appear herein or may be executed in parallel. In addition, various serial numbers, etc. are only for descriptive purposes and cannot be understood as indicating or implying relative importance.

[0047] Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed present invention, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of the present invention.

[0048] See Figure 1 and Figure 2As shown, the method continuously obtains real-time video information from the camera lens, combines the target information at the current moment in the target status table at the current moment, and analyzes the obtained video in chronological order. The analysis steps are mainly divided into three steps: target status acquisition, data reliability evaluation, and data diversity evaluation. The execution steps are as follows Figure 1 and Figure 2 shown.

[0049] Next, in combination with Figures 1 to 3 shown, the working principle and implementation manner of the present invention will be introduced in detail:

[0050] In the embodiment of the present invention, the target status table (Table 1) is used to store the context information of all target positions, categories, confidence queues, IDs, and key frame poses in the previous frame image before the current moment of the video, as the prior information for analysis. The specific description of Table 1 is as follows.

[0051] Table 1 Target Status Table

[0052]

[0053] Step 1. Target status acquisition. Preprocess the image information of the camera lens, and use the visual features of the image itself and the spatio-temporal correlation characteristics of the video to obtain the annotation information required for training data; specifically as follows:

[0054] Step 1-1. Use the algorithm to obtain the target information at the current moment. For the image at a certain moment of the video, through the target detection and tracking algorithm, obtain the p, t, and s information of the initial target o0; subsequently, introduce a high confidence threshold t h and the uncertainty threshold t u , and divide the detected targets into three categories: high-confidence targets, uncertain targets, and low-confidence targets; in addition, the fourth category of targets is the targets determined to be truly existent by the target tracking algorithm.

[0055]

[0056] Step 1-2. Update the target status table. Use the detected high-confidence targets and tracked targets obtained by the algorithm to update the relevant information of the corresponding ID in the target status table; specifically as follows:

[0057] For the detected high-confidence targets, match the target ID at adjacent moments through the bounding box category, scale, and position information. For targets of the same category, calculate the relative distance, and when it is less than a specific threshold with the adjacent frame image, it is determined to be the same ID.

[0058] RD obj =Δx + Δy + Δw + Δh

[0059] Δx=(x2 - x1) / w1, Δy=(y2 - y1) / h1

[0060] Δw = log(w2 / w1), Δh = log(h2 / h1)

[0061] where, RD obj is the relative distance; Δx and Δy represent the relative deviation of the centroid, and Δw and Δh represent the scale deviation of the bounding box; the subscript 1 represents the previous frame, and the subscript 2 represents the subsequent frame. For the tracked target, the target ID corresponds to an ID in the target state table.

[0062] Filter out targets with low confidence. If the remaining target IDs exist in the target state table, reset the l value to 0, update p and t of the corresponding ID in the table, and write the current confidence score into the queue; if the above IDs do not exist in the target state table, create new targets, write p and t into the corresponding IDs, initialize the q as an empty queue, write the corresponding target s into the queue, and at the same time initialize the k value as a NaN value and the l value as 0; if the ID in the target state table is not in the algorithm target information, increase the l value by 1; when the l value reaches a certain threshold, delete the information related to this ID from the target state table.

[0063] Step 2. Data reliability evaluation and screening. For the images and annotation information in Step 1, evaluate the comprehensive confidence of the selected image annotation results, and screen out sufficiently reliable image data and annotation data for the next-step evaluation; specifically as follows:

[0064] Step 2-1. Comprehensive confidence calculation. For all s corresponding to the targets obtained in Step 1, calculate the comprehensive confidence of the current image, as described below:

[0065] Record the number of high-confidence targets in the current image as n h , the number of targets with uncertain confidence as n u , the number of targets determined to exist by the tracking algorithm as n t , and the comprehensive confidence n c is denoted as:

[0066] n c = ω h ·(n h + n t ) - ω u ·n u

[0067] where, ω h , ω u are both positive numbers, which are the weights of high-confidence targets and targets with uncertain confidence respectively.

[0068] Step 2-2. Data reliability evaluation and screening. If the comprehensive confidence value is positive, pass the data reliability evaluation, and pass the current image and annotation information to Step 3; otherwise, end the current processing process and turn to process the next frame of image.

[0069] Step 3. Data diversity evaluation and screening. For the images and annotation information passed in from Step 2, use the relative pose change between the camera lens and the target to evaluate the similarity of frames at different moments in the video and screen the images to diversify the data while controlling the redundancy degree, as follows:

[0070] Step 3-1. Calculate the relative pose between the target and the camera lens. For the images and annotation information screened in Step 2, screen out the targets with uncertain confidence; then, according to the abscissa of the centroid of all targets, calculate the angle between the line connecting the target and the optical center of the camera lens and the optical axis of the camera (horizontal pose angle) as the relative pose between the two. The target-camera lens relative pose is as Figure 3 shown.

[0071] According to the centroid position of the target in the field of view, calculate the horizontal pose angles θ1,..., θ of all targets respectively n

[0072]

[0073] where w is the pixel width of the image, x is the abscissa of the target centroid, and θ w is the horizontal field of view angle of the camera.

[0074] Step 3-2. Evaluate the data diversity based on the relative pose and screen the current image. Compare the horizontal pose angles of all targets with the pose of the key frame in the target state table, and calculate the target horizontal view angle diversity. The formula is as follows:

[0075]

[0076] If the horizontal view angle diversity parameter is greater than the diversity threshold, the current frame successfully passes the diversity evaluation and screening and is used as training data; otherwise, the current data is discarded.

[0077] To better understand the purpose and function of the present invention, the following introduces the specific implementation manner in which the present invention plays the role of quickly collecting training data.

[0078] In this embodiment, a camera is used as the image perception hardware; DeepSORT is used as the image target state acquisition algorithm; pedestrians wearing long trousers are used as the recognition target; the source domain is pedestrians wearing long trousers in the daytime downtown area, and the target domain is pedestrians wearing long trousers in the nighttime suburban area.

[0079] 1. Acquisition of image sequence information. Place cameras of the same model in the target domain environment to obtain the original image sequence data. Set an appropriate frame rate and continuously collect images for four to six hours at night, avoiding dusk and dawn to make the image environment brightness meet the requirements of the target domain; continue for several days to obtain sufficient image information. This step can be almost entirely carried out without manual intervention.

[0080] 2. Training data collection. This step uses the method of the present invention to obtain sufficient and high-quality training data with less manual intervention.

[0081] 2-1. Using the DeepSORT method to assist in annotating the original image sequence. Input the original image sequence into the DeepSORT algorithm program, and utilize the target visual features and the correlation characteristics of the front and back frames of the image sequence through the Tracking by Detection method. For some targets with sufficiently high confidence and stable recognition performance, obtain stable target annotation information through DeepSORT as the targets that are determined to truly exist by the tracking algorithm (abbreviated as tracked targets); for targets that have not yet formed stability, only use targets that meet the high-confidence requirement as annotation data (abbreviated as high-confidence targets). Among them, the detector in the algorithm uses YOLOv5, and this detector model has been pre-trained using the source domain dataset.

[0082] After the data is input into the algorithm, the algorithm outputs high-confidence targets obj h 1 ,..., obj h n :

[0083] obj h = {p, t, s}

[0084] Tracked target obj at the current moment t 1 ,..., obj t n :

[0085] obj t = {p, t, id}

[0086] In this embodiment, the high-confidence threshold t h is taken as 0.9, and the uncertainty threshold t u is taken as 0.3. According to the s value of the target unit, the detected targets can be divided into high-confidence targets, uncertain-confidence targets, low-confidence targets, and tracked targets, and the low-confidence targets are screened out.

[0087] 2-2. Data reliability evaluation and screening. According to the annotation information obtained in step 2-1, the number of high-confidence targets is n h , and the number of uncertain-confidence targets is n u ; calculate the comprehensive confidence of the current image according to the target information. If the comprehensive confidence is positive, then screen out the uncertain-confidence targets from the current annotation information, and input the modified annotation information and the image into the next step.

[0088] 2-3. Data diversity evaluation and screening. Calculate the horizontal perspective diversity parameter for all the targets screened in step 2-2. If the horizontal perspective diversity parameter is greater than 5 degrees, save the current image and the corresponding target annotation information as training data.

[0089] 3. Model domain adaptation training. After performing the operations in step 2 on all the images obtained in step 1, use the images and annotations collected in step 2 as training data to train the source domain model, thereby completing the migration operation of the model from the source domain to the target domain.

[0090] From the description of the above embodiments, those skilled in the art can know that: In view of the problems of long working hours and high labor costs for obtaining / arranging training data required for training a visual model, the present invention designs a method for automatically obtaining high-quality training data for the unstructured operation scenarios of robots commonly used in visual algorithms. This method can quickly evaluate and obtain the image data required for domain adaptation from the perspectives of data diversity and reliability according to the target's current position information to adjust the device's visual algorithm model. This method significantly reduces the manual operation requirements in the data acquisition, annotation, and screening links, greatly reducing the data-related costs; significantly improving the annotation efficiency and facilitating the rapid progress of model migration work for different scenarios.

[0091] Furthermore, the embodiment of the present invention also provides a domain adaptation image data automatic collection system, which applies the domain adaptation image data automatic collection method of the above embodiment to collect training data. The system includes:

[0092] A target state acquisition module, which is used to preprocess the original image sequence data and obtain the target annotation information required for training data by using the visual features of the image itself and the spatio-temporal correlation characteristics of the video.

[0093] A data reliability evaluation and screening module, which is used to calculate the comprehensive confidence of the current image according to the obtained target annotation information and perform data reliability screening through the comprehensive confidence.

[0094] A data reliability evaluation and screening module, which is used to perform data diversity screening according to the data reliability screening results, calculate the target horizontal perspective diversity parameter, and if the horizontal perspective diversity parameter meets the preset conditions, save the current image and the corresponding target annotation information as training data.

[0095] The implementation principle and the technical effects generated by the domain adaptation image data automatic collection system provided by the embodiment of the present invention are the same as those of the foregoing method embodiment. For the sake of brief description, for the parts not mentioned in this embodiment, reference can be made to the corresponding content in the foregoing method embodiment, and details will not be repeated here.

[0096] Furthermore, refer to Figure 4As shown in the figure, an embodiment of the present invention further provides an electronic device, which may include a processor 10, a memory 11, a communication bus 12, and a communication interface 13, and may also include a computer program stored in the memory 11 and executable on the processor 10. The processor executes the computer program to implement the domain adaptation image data automatic collection method in the above method embodiment.

[0097] Among them, the processor 10 may be composed of integrated circuits in some embodiments. For example, it may be composed of a single packaged integrated circuit, or may be composed of multiple packaged integrated circuits with the same or different functions, including a combination of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips. The processor 10 is the control core of the electronic device, connecting various components of the entire electronic device through various interfaces and circuits, and executing various functions of the electronic device and processing data by running or executing programs or modules stored in the memory 11, and calling data stored in the memory 11.

[0098] Those skilled in the art should understand that the embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present invention may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk memories, CD-ROMs, optical memories, etc.) containing computer-usable program code.

[0099] It should be noted that the word "comprising" does not exclude the existence of components or steps not listed in the claims. The word "a" or "an" preceding a component does not exclude the existence of a plurality of such components. The present invention can be implemented by means of hardware including several different components and by means of a suitably programmed computer.

[0100] The various embodiments in this specification are described in a progressive manner. Each embodiment focuses on the differences from other embodiments. The same or similar parts among the various embodiments can be referred to each other.

[0101] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be obvious to those skilled in the art. The general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to these embodiments shown herein, but will be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. An automatic domain adaptation image data collection method, characterized in that The method includes the following steps: S1: Preprocess the original image sequence data, and obtain the target annotation information required for training data by using the visual features of the image itself and the spatio-temporal correlation characteristics of the video; S2: Calculate the comprehensive confidence of the current image according to the obtained target annotation information, and perform data reliability screening through the comprehensive confidence; S3: According to the data reliability screening results, perform data diversity screening, calculate the target horizontal view diversity parameter. If the horizontal view diversity parameter meets the preset conditions, save the current image and the corresponding target annotation information as training data.

2. The automatic domain adaptation image data collection method according to claim 1, wherein, In the above S1, obtaining the target annotation information required for training data by using the visual features of the image itself and the spatio-temporal correlation characteristics of the video specifically includes: 1) For an image at a certain moment in the original image sequence data, obtain the information of the position, category, and confidence score of the initial target through the object detection and tracking algorithm; and use the high confidence threshold and the uncertainty threshold to divide the detected targets into high-confidence targets, uncertain targets, and low-confidence targets, and the rest are determined as truly existing targets; Among them, o0 represents the initial target, s o represents the confidence score of the initial target, t u represents the uncertainty threshold, t h represents the high confidence threshold; 2) Use the obtained detected high-confidence targets and tracked targets to update the relevant information of the corresponding ID in the target status table. The method is as follows: For the detected high-confidence targets, match the target ID at adjacent moments through the bounding box category, scale, and position information; for targets of the same category, calculate the relative distance, and when it is less than a specific threshold with the adjacent frame image, it is determined to be the same ID. The calculation formula is: RD obj = Δx + Δy + Δw + Δh Δx = (x2 - x1) / w1, Δy = (y2 - y1) / h1 Δw = log(w2 / w1), Δh = log(h2 / h1) Among them, RD obj is the relative distance; Δx and Δy represent the relative deviation of the centroid, and Δw and Δh represent the scale deviation of the bounding box; the subscript 1 represents the previous frame, and the subscript 2 represents the subsequent frame; Eliminate the low-confidence targets. If the ID corresponding to the remaining targets exists in the target status table, reset the target lost frame number to 0, update the position and category of the corresponding ID in the table, and write the current confidence score into the queue; if the ID does not exist in the target status table, create a new target, write the position and category into the corresponding ID, initialize the confidence queue as an empty queue, write the corresponding target confidence score into the queue, and at the same time initialize the key frame pose value as the NaN value and the target lost frame number as 0; if the ID in the target status table is not in the algorithm target information, the target lost frame number is incremented by 1; when the target lost frame number reaches a certain threshold, delete the relevant information of this ID from the target status table.

3. The automatic domain adaptation image data collection method according to claim 2, wherein The object detection and tracking algorithm is the DeepSORT algorithm, and the detector in the algorithm uses YOLOv5.

4. The automatic domain adaptation image data collection method according to claim 1, characterized in that In the above S2, calculate the comprehensive confidence of the current image according to the obtained target annotation information. The calculation formula is: n c = ω h ·(n h + n t ) - ω u ·n u Where n c represents the comprehensive confidence level; n h represents the number of high-confidence targets in the current image; n t represents the number of targets determined by the algorithm to exist; n u represents the number of targets with uncertain confidence levels; ω h and ω u are the weights of high-confidence targets and targets with uncertain confidence levels, respectively.

5. The automatic domain adaptation image data collection method according to claim 4, wherein If the comprehensive confidence value is positive, transfer the current image and the annotation information to step 3 for processing, otherwise end the current processing process and transfer to process the next frame of image.

6. The automatic domain adaptation image data collection method according to claim 1, characterized in that In the above S3, the calculation formula of the horizontal view diversity parameter is: In the formula, θ represents the horizontal view diversity parameter; θ i represents the horizontal pose angle; n represents the number of targets; w represents the image pixel width; x represents the abscissa of the target centroid; θ w represents the horizontal field of view angle of the camera.

7. An automatic domain adaptation image data collection system, characterized in that, Apply a domain adaptation image data automatic collection method according to any one of claims 1-6 to collect training data. The system includes: A target state acquisition module, which is used to preprocess the original image sequence data, and obtain the target annotation information required for training data by using the visual features of the image itself and the spatio-temporal correlation characteristics of the video; A data reliability evaluation and screening module, which is used to calculate the comprehensive confidence of the current image according to the obtained target annotation information, and perform data reliability screening through the comprehensive confidence; A data reliability evaluation and screening module, which is used to perform data diversity screening according to the data reliability screening results, calculate the target horizontal view angle diversity parameter, and if the horizontal view angle diversity parameter meets the preset conditions, save the current image and the corresponding target annotation information as training data.

8. An electronic device, characterized in that, It includes a processor and a memory, the memory stores machine-executable instructions that can be executed by the processor, and the processor executes the machine-executable instructions to implement a domain adaptation image data automatic collection method as described in any one of claims 1-6.