Data processing method and device
By using matching conditions of time and position features in the tracking chain acquired by cameras, combined with fitting and labeling processing, the problem of merging data acquired by multiple cameras is solved, and efficient trajectory management and tracking of the same object under low computing power conditions is achieved.
Patent Information
- Application Number
- CN202110226213.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-03-01
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2041-10-28
AI Technical Summary
Existing technologies struggle to efficiently merge data to identify the same object when acquiring images and videos of objects within a scene using multiple cameras. This is especially true because the high accuracy requirements for image features necessitate high computing power, making them unsuitable for digital scene management.
By merging tracking chains with the same image features using first and second time features, merging can be achieved by utilizing the continuity of the head and tail timestamps, or by merging based on the matching conditions of position and time features. Combined with fitting and labeling processing, trajectory management and tracking of the same tracking object can be realized.
It enables efficient merging of data for the same tracked object under low computing power conditions, improving the accuracy and efficiency of object management within the scene and reducing the dependence on high computing power equipment.
Smart Images

Figure CN112927265B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of camera device technology, and in particular to a data processing method and apparatus. Background Technology
[0002] When managing offline scenarios digitally, multiple cameras are needed to capture images and videos of objects within the scene to determine their actions and thus achieve management. During this process, data from the same object needs to be merged. Currently, determining whether acquired data belongs to the same object typically involves comparing image features corresponding to that object, such as using image features to create a 3D model and comparing 3D features to determine if they are identical. However, this method requires high accuracy of the acquired image features and usually necessitates the use of neural network models or other high-computing methods, requiring significant on-site computing power and thus not being well-suited for digital scenarios. Summary of the Invention
[0003] This invention provides a data processing method and apparatus that can manage and track the movement trajectory of a tracked object.
[0004] One aspect of this invention provides a data processing method, the method comprising: obtaining a first tracking chain, the first tracking chain corresponding to a first temporal feature and a first image feature; when a second tracking chain exists that is consistent with the first image feature, determining a second temporal feature corresponding to the second tracking chain; merging the first tracking chain and the second tracking chain according to the first temporal feature and the second temporal feature to obtain a third tracking chain.
[0005] In one possible implementation, merging the first tracking chain and the second tracking chain according to the first time feature and the second time feature to obtain a third tracking chain includes: determining a head timestamp corresponding to the first tracking chain according to the first time feature; determining a tail timestamp corresponding to the second tracking chain according to the second time feature; and merging the head of the first tracking chain to the tail of the second tracking chain when the head timestamp and the tail timestamp are consecutive to obtain the third tracking chain.
[0006] In one possible implementation, the method further includes: when there is no second tracking chain consistent with the first image feature, determining a fourth tracking chain set based on a first acquisition point corresponding to the first image feature, the fourth tracking chain set containing at least one fourth tracking chain; determining a first position feature corresponding to the first tracking chain; matching the fourth tracking chain set with the first position feature and the first time feature, and merging the fourth tracking chain that satisfies the first matching condition with the first tracking chain to obtain a fifth tracking chain.
[0007] In one possible implementation, the first matching condition includes at least one of the following matching conditions: a first feature matching condition for characterizing the matching degree of time features, a second feature matching condition for characterizing the matching degree of position features, a third feature matching condition for characterizing the matching degree of velocity features, and a fourth feature matching condition for characterizing the matching degree of direction features.
[0008] In one possible implementation, the method further includes: when there is no fourth tracking chain that satisfies the first matching condition, determining a second acquisition point based on the acquisition range corresponding to the first position feature; determining a sixth tracking chain set based on the second acquisition point, the sixth tracking chain set containing at least one sixth tracking chain; matching the sixth tracking chain set with the first position feature and the first time feature, merging the sixth tracking chain that satisfies the second matching condition and the first tracking chain to obtain a seventh tracking chain; wherein the first acquisition point completely covers the acquisition range, and the second acquisition point partially covers the acquisition range; the second matching condition is the same as or different from the first matching condition.
[0009] In one possible implementation, merging the first tracking chain and the sixth tracking chain based on the first position feature and the sixth position feature to obtain a seventh tracking chain includes: determining the overlapping position feature of the first position feature and the sixth position feature; fitting the overlapping position feature to obtain a fitted position feature; marking the overlapping position feature; and determining the seventh tracking chain based on the first tracking chain, the sixth tracking chain, and the fitted position feature.
[0010] In one embodiment, the method further includes: obtaining a queue to be merged, the queue containing at least one tracking chain to be merged; sorting the tracking chains to be merged from first to last according to the time characteristics corresponding to the tracking chains to be merged, and determining the tracking chain at the beginning of the sort as the first tracking chain.
[0011] In one embodiment, the method further includes: storing the second tracking chain according to the first image features to obtain a stored tracking chain; and outputting the stored tracking chain when the stored tracking chain meets the output conditions.
[0012] In one embodiment, the output condition includes at least one of the following: a first output condition characterizing the storage tracking chain leaving all acquisition points; a second output condition characterizing the time characteristics corresponding to the storage tracking chain satisfying a specific time length; and a third output condition characterizing the real-time output of the storage tracking chain.
[0013] Another aspect of this invention provides a data processing apparatus, the apparatus comprising: an obtaining module for obtaining a first tracking chain, the first tracking chain corresponding to a first temporal feature and a first image feature; a determining module for determining a second temporal feature corresponding to the second tracking chain when a second tracking chain exists that is consistent with the first image feature; and a merging module for merging the first tracking chain and the second tracking chain according to the first temporal feature and the second temporal feature to obtain a third tracking chain.
[0014] In one possible implementation, the merging module includes: a first determining submodule, configured to determine a head timestamp corresponding to the first tracking chain based on the first time feature; the first determining submodule is further configured to determine a tail timestamp corresponding to the second tracking chain based on the second time feature; and a first merging submodule, configured to merge the head of the first tracking chain into the tail of the second tracking chain to obtain a third tracking chain when the head timestamp and the tail timestamp are consecutive.
[0015] In one embodiment, the determining module is further configured to, when no second tracking chain is found to match the first image feature, determine a fourth tracking chain set based on a first acquisition point corresponding to the first image feature, wherein the fourth tracking chain set contains at least one fourth tracking chain; the determining module is further configured to determine a first position feature corresponding to the first tracking chain; the device further includes: a matching module, configured to match the fourth tracking chain set based on the first position feature and the first time feature, and merge the fourth tracking chain that satisfies the first matching condition with the first tracking chain to obtain a fifth tracking chain.
[0016] In one possible implementation, the first matching condition includes at least one of the following matching conditions: a first feature matching condition for characterizing the matching degree of time features, a second feature matching condition for characterizing the matching degree of position features, a third feature matching condition for characterizing the matching degree of velocity features, and a fourth feature matching condition for characterizing the matching degree of direction features.
[0017] In one possible implementation, the determining module is further configured to, when no fourth tracking chain satisfies the first matching condition, determine a second acquisition point based on the acquisition range corresponding to the first position feature; the determining module is further configured to, based on the second acquisition point, determine a sixth tracking chain set, the sixth tracking chain set containing at least one sixth tracking chain; the matching module is further configured to, based on the first position feature and the first time feature, match the sixth tracking chain set, and merge the sixth tracking chain that satisfies the second matching condition with the first tracking chain to obtain a seventh tracking chain; wherein, the first acquisition point completely covers the acquisition range, and the second acquisition point partially covers the acquisition range; the second matching condition is the same as or different from the first matching condition.
[0018] In one possible implementation, the matching module includes: a fitting submodule, configured to determine the overlapping position features of the first position feature and the sixth position feature, and to fit the overlapping position features to obtain fitted position features; and a marking submodule, configured to mark the overlapping position features and to determine a seventh tracking chain based on the first tracking chain, the sixth tracking chain, and the fitted position features.
[0019] In one embodiment, the obtaining module is used to obtain a queue to be merged, the queue to be merged containing at least one tracking chain to be merged; the device further includes: a sorting module, used to sort the tracking chains to be merged from first to last according to the time characteristics corresponding to the tracking chains to be merged, and to determine the tracking chain that is sorted first as the first tracking chain.
[0020] In one embodiment, the device further includes: a storage module for storing the second tracking chain according to the first image features to obtain a stored tracking chain; and an output module for outputting the stored tracking chain when the stored tracking chain meets the output conditions.
[0021] In one embodiment, the output condition includes at least one of the following: a first output condition characterizing the storage tracking chain leaving all acquisition points; a second output condition characterizing the time characteristics corresponding to the storage tracking chain satisfying a specific time length; and a third output condition characterizing the real-time output of the storage tracking chain.
[0022] The data processing method and apparatus provided in this embodiment of the invention merge a first tracking chain and a second tracking chain with the same first image features based on a first time feature and a second time feature to obtain a third tracking chain corresponding to the same tracking object, thereby realizing the management and tracking of the movement trajectory of the same tracking object. Attached Figure Description
[0023] The above and other objects, features, and advantages of exemplary embodiments of the present invention will become readily apparent from the following detailed description taken in conjunction with the accompanying drawings. Several embodiments of the invention are illustrated in the drawings by way of example and not limitation, wherein:
[0024] In the accompanying drawings, the same or corresponding reference numerals indicate the same or corresponding parts.
[0025] Figure 1 This is a schematic diagram illustrating the implementation flow of a data processing method according to an embodiment of the present invention;
[0026] Figure 2 This is a schematic diagram illustrating the implementation process of a data processing method for merging tracking chains according to an embodiment of the present invention;
[0027] Figure 3 This is a schematic diagram illustrating the implementation flow of a data processing method according to another embodiment of the present invention;
[0028] Figure 4 This is a schematic diagram illustrating the implementation process of a data processing method for merging tracking chains according to another embodiment of the present invention;
[0029] Figure 5 This is a schematic diagram of an implementation module for a data processing method according to another embodiment of the present invention;
[0030] Figure 6a This is a schematic diagram illustrating a data processing method according to a first priority attempting to merge data, as described in another embodiment of the present invention.
[0031] Figure 6b This is a schematic diagram illustrating a data processing method according to a second priority attempting to merge data, as described in another embodiment of the present invention.
[0032] Figure 6c This is a schematic diagram illustrating a data processing method according to a third priority in another embodiment of the present invention, showing a scenario where the data processing method attempts to merge data based on a third priority.
[0033] Figure 6d This is a schematic diagram illustrating an implementation scenario of a data processing method based on a third priority fitting according to another embodiment of the present invention;
[0034] Figure 6e This is a schematic diagram illustrating a data processing method for fitting and merging data according to a third priority, as described in another embodiment of the present invention.
[0035] Figure 7 This is a schematic diagram of an implementation module of a data processing device according to an embodiment of the present invention. Detailed Implementation
[0036] To make the objectives, features, and advantages of this invention more apparent and understandable, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this invention, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0037] Figure 1 This is a schematic diagram illustrating the implementation flow of a data processing method according to an embodiment of the present invention.
[0038] See Figure 1 One embodiment of the present invention provides a data processing method, the method comprising: operation 101, obtaining a first tracking chain, the first tracking chain corresponding to a first time feature and a first image feature; operation 102, when a second tracking chain consistent with the first image feature exists, determining a second time feature corresponding to the second tracking chain; operation 103, merging the first tracking chain and the second tracking chain according to the first time feature and the second time feature to obtain a third tracking chain.
[0039] The data processing method provided in this embodiment of the invention merges a first tracking chain and a second tracking chain with the same first image features based on a first time feature and a second time feature to obtain a third tracking chain corresponding to the same tracking object, thereby realizing the management and tracking of the movement trajectory of the same tracking object.
[0040] In operation 101, the first tracking chain can be the movement trajectory corresponding to the tracked object in the image or video data acquired by the camera device. Depending on the actual situation, the same camera device can acquire one tracked object and its corresponding movement trajectory within the same time period, or it can acquire multiple tracked objects and their corresponding multiple tracking trajectories within the same time period. When there are multiple tracking trajectories, the movement trajectory corresponding to each tracked object can be obtained by segmenting and extracting the acquired image or video data.
[0041] The first time feature can be used to characterize the time information corresponding to the first tracking chain. The first time feature can be characterized by the head timestamp and tail timestamp corresponding to the first tracking chain, for example: tracking chain one → 10:30 to 10:31.
[0042] The first image feature can be obtained by image recognition of the tracked object using an image recognition model. Specifically, a frame can be extracted from the video data corresponding to the first tracking chain for image recognition to determine the first image feature corresponding to the first tracking chain. The image features identified by the image recognition model for different tracked objects are different. The specific image features identified by the image recognition model are selected as obvious features corresponding to the tracked object, such as one or more features corresponding to the tracked object, such as overall features, height features, gender features, clothing features, hairstyle features, head-shoulder ratio features, etc. The specific duration of the tracking chain can be consistent with the time from when the tracked object enters the current camera device to when it leaves the current camera device. Alternatively, the tracking duration of the tracking chain can be preset. When the recording time of the tracked object by the camera device meets the tracking duration, the tracking chain is added to the merging queue as a tracking chain to be merged, and the recording of the next tracking chain begins.
[0043] In one embodiment, the method further includes: first, obtaining a queue to be merged, the queue containing at least one tracking chain to be merged; then, sorting the tracking chains to be merged from first to last according to their corresponding time characteristics, and determining the tracking chain at the front of the sorted queue as the first tracking chain. All tracking chains acquired by the camera device can be stored in the queue as tracking chains to be merged. The tracking chains to be merged in the queue can be sorted according to the order of their header timestamps, and the tracking chain at the front of the queue is selected as the first tracking chain, that is, the first tracking chain refers to the tracking chain to be merged.
[0044] In operation 102, the second tracking chain may include merged tracking chains, or it may be a tracking chain that has been determined not to be merged with other tracking chains. The set of second tracking chains contains at least one second tracking chain, and each second tracking chain corresponds to a second image feature. It is understood that different second tracking chains correspond to different second image features. The second tracking chains can be named or labeled using the second image features corresponding to them to facilitate subsequent management. For example: Tracking chain one → Image feature A. By matching the second image feature with the first image feature, the second tracking chain corresponding to the second image feature that matches the first image feature is determined as the tracking chain for merging operations with the first tracking chain. For example: Tracking chain one → Image feature A, Tracking chain two → Image feature A. It is known that tracking chain one and tracking chain two have the same image feature, so tracking chain two is determined as the tracking chain for merging operations with tracking chain one. The second time feature corresponding to the second tracking chain is determined, i.e., at least one of the head timestamp and tail timestamp corresponding to the second tracking chain.
[0045] In operation 103, the head and tail timestamps corresponding to the first tracking chain and the head and tail timestamps corresponding to the second tracking chain are merged to obtain the third tracking chain. Specifically, if either the head or tail timestamps of the first and second tracking chains form a continuous time sequence, the first and second tracking chains can be merged to obtain the third tracking chain. For example, if tracking chain one → 10:30 to 10:31 and tracking chain two → 10:31 to 10:32, tracking chain two can be merged into the tail of tracking chain one. If the obtained third tracking chain does not meet the output conditions, the third tracking chain can be determined as the updated second tracking chain for matching and merging with the first tracking chain determined in the next round.
[0046] Figure 2 This is a schematic diagram illustrating the implementation process of a data processing method for merging tracking chains according to an embodiment of the present invention.
[0047] See Figure 2 In one possible implementation, operation 103, merging the first tracking chain and the second tracking chain according to the first time feature and the second time feature to obtain a third tracking chain, includes: operation 1031, determining the head timestamp corresponding to the first tracking chain according to the first time feature; operation 1032, determining the tail timestamp corresponding to the second tracking chain according to the second time feature; operation 1033, when the head timestamp and the tail timestamp are consecutive, merging the head of the first tracking chain to the tail of the second tracking chain to obtain the third tracking chain.
[0048] In this method, the queue to be merged is sorted according to the head timestamp of the tracking chains to be merged. That is, the earlier the head timestamp, the higher the sorting position of the tracking chain to be merged in the queue. This method determines the tracking chain at the front of the queue to be merged as the first tracking chain, and the second tracking chain is the tracking chain that has already undergone the merging operation. The head timestamp of the second tracking chain is earlier than the head timestamp of the first tracking chain. When the image features of the first tracking chain and the second tracking chain are the same, since the tracking object corresponding to the same image feature will not appear in two places at the same time, this method determines whether the head of the first tracking chain can be connected to the tail of the second tracking chain by determining whether the head timestamp of the first tracking chain and the tail timestamp of the second tracking chain are continuous.
[0049] Specifically, the head of the first tracking chain refers to the positional feature corresponding to the head of the first tracking chain, and the tail of the second tracking chain refers to the positional feature corresponding to the tail of the second tracking chain. When the head timestamp of the first tracking chain and the tail timestamp of the second tracking chain are consecutive, the head of the first tracking chain is merged into the tail of the second tracking chain to obtain the third tracking chain. It should be noted that if the second tracking chain has undergone multiple merging operations, it may have multiple head timestamps and tail timestamps due to the lack of tracking chains for certain time periods. When the second tracking chain has multiple head timestamps and tail timestamps, the head timestamps and tail timestamps of the first tracking chain can be matched one-to-one with the head timestamps and tail timestamps of the second tracking chain to determine the merging position of the first tracking chain corresponding to the second tracking chain. In one scenario, due to occlusion by objects within the scene, part of the tracking object's movement path cannot be captured by the acquisition device. When the image features of the first and second tracking chains are identical, but their head and tail timestamps are not consecutive, if the time difference between the head and tail timestamps does not exceed a certain time threshold, the first and second tracking chains can be fitted, and the fitted positions marked to obtain a third tracking chain. If the difference between the head and tail timestamps exceeds a certain threshold, tracking chains can be merged based on their corresponding positional features, and positions where the first and second tracking chains cannot be connected can be marked to obtain a third tracking chain. In another implementation scenario, when the tracking chains to be merged in the queue are not sorted, a random tracking chain can be selected as the first tracking chain. The head and tail timestamps of both the first and second tracking chains need to be determined simultaneously for the merging operation.
[0050] Figure 3 This is a schematic diagram illustrating the implementation flow of a data processing method according to another embodiment of the present invention.
[0051] See Figure 3 In one embodiment, the method further includes: operation 301, when there is no second tracking chain consistent with the first image feature, determining a fourth tracking chain set based on the first acquisition point corresponding to the first image feature, the fourth tracking chain set containing at least one fourth tracking chain; operation 302, determining a first position feature corresponding to the first tracking chain; operation 303, matching the fourth tracking chain set with the first position feature and the first time feature, merging the fourth tracking chain and the first tracking chain that satisfy the first matching condition to obtain a fifth tracking chain.
[0052] Since the tracked object is usually in motion while the acquisition device is in a fixed position, the image recognition model may identify different tracking chains of the same tracked object as different image features due to the movement of the tracked object or other reasons, due to limitations in computing power.
[0053] In operation 301, when merging the first tracking chain and the second tracking chain, a second tracking chain that matches the first image features cannot be matched. In this case, a first acquisition point corresponding to the first tracking chain is determined, i.e., the acquisition device corresponding to the first tracking chain. Then, a fourth tracking chain set acquired by the acquisition device is determined based on the acquisition device. The fourth tracking chain set contains at least one fourth tracking chain. When there are multiple fourth tracking chains, each fourth tracking chain can correspond to multiple different tracking objects. Furthermore, the fourth tracking chain can be either a merged tracking chain or an unmerged tracking chain.
[0054] In operation 302, the first position feature refers to the set of position coordinate points corresponding to the first tracking chain. Specifically, this method can determine the position-related image features of the tracked object in an image or video using an image recognition model, and then map these position-related image features to obtain the set of position coordinate points corresponding to the first tracking chain. The first position feature can be represented using two-dimensional coordinates, or it can be represented using three-dimensional coordinates by combining image features related to height. The first position feature may also include movement path, movement speed, displacement direction, etc.
[0055] In operation 303, the fourth position feature and fourth time feature corresponding to each fourth tracking chain in the fourth tracking chain set are determined. Then, the first time feature and the fourth time feature are matched according to the first matching condition, and the first position feature and the fourth position feature are matched. The fourth tracking chains corresponding to the fourth time feature and the fourth position feature that can satisfy the first matching condition are determined as tracking chains that can be merged with the first tracking chain. The fourth tracking chains that satisfy the first matching condition are then merged with the first tracking chain to obtain the fifth tracking chain.
[0056] Specifically, the merging position between the first and fourth tracking chains can be determined based on the first and fourth time features, and the first and fourth position features. The merging position can be the head of the fourth tracking chain merging with the tail of the first tracking chain, or the tail of the fourth tracking chain merging with the head of the first tracking chain, thereby obtaining the fifth tracking chain.
[0057] For example, when the first positional feature and the fourth positional feature are continuous, and the first time feature and the fourth time feature are continuous, the continuous positions of the first and fourth tracking chains can be determined as merging points to merge the first and fourth tracking chains and obtain the fifth tracking chain. When there is a distance difference between the first and fourth positional features, and a time difference between the first and fourth time features, the corresponding movement speed and direction are determined based on the first and fourth positional features. The movement speed and direction are matched with the distance and time difference. If the movement speed and direction allow the tracked object to move from the tail of the first tracking chain to the head of the fourth tracking chain, or from the tail of the fourth tracking chain to the tail of the first tracking chain, the fifth tracking chain is obtained by fitting the first and fourth tracking chains based on the movement speed and direction. When the fifth tracking chain does not meet the output conditions, the fifth tracking chain can be determined as the second tracking chain for merging with other tracking chains. The image features corresponding to the fifth tracking chain can include the first image features and the fourth image features.
[0058] In one embodiment, the first matching condition includes at least one of the following matching conditions: a first feature matching condition for characterizing the matching degree of time features, a second feature matching condition for characterizing the matching degree of position features, a third feature matching condition for characterizing the matching degree of velocity features, and a fourth feature matching condition for characterizing the matching degree of direction features.
[0059] The first feature matching condition is based on the temporal characteristics of the two tracking chains; the closer the temporal characteristics of the tracking chains, the higher the matching degree. The second feature matching condition is based on the position coordinate sets of the two tracking chains; the higher the overlap between the position coordinates of the head and tail of the two tracking chains, the higher the matching degree. The third feature matching condition is based on the movement speed of the tracked object corresponding to the two tracking chains; the closer the movement speed of the tracked object corresponding to the two tracking chains, the higher the matching degree. The fourth feature matching condition is determined based on the movement direction of the tracked object corresponding to the two tracking chains; the more similar the movement directions of the head and tail of the two tracking chains, the higher the matching degree. This method can set corresponding matching degree thresholds based on the above matching conditions; when the matching degree exceeds the matching degree threshold, the two tracking chains can be determined as a match.
[0060] Figure 4 This is a schematic diagram illustrating the implementation process of a data processing method for merging tracking chains according to another embodiment of the present invention.
[0061] See Figure 4In one embodiment, the method further includes: operation 401, when there is no fourth tracking chain that satisfies the first matching condition, determining a second acquisition point based on the acquisition range corresponding to the first position feature; operation 402, determining a sixth tracking chain set based on the second acquisition point, the sixth tracking chain set containing at least one sixth tracking chain; operation 403, matching the sixth tracking chain set with the first position feature and the first time feature, merging the sixth tracking chain that satisfies the second matching condition and the first tracking chain to obtain a seventh tracking chain; wherein, the first acquisition point completely covers the acquisition range, and the second acquisition point partially covers the acquisition range; the second matching condition is the same as or different from the first matching condition.
[0062] In another implementation scenario, when there is no fourth tracking chain that meets the first matching condition, i.e., the tracking chain captured by the same camera cannot be matched with the first tracking chain, in this case, operation 401 is executed. This method matches the first tracking chain with the sixth tracking chain set captured by other acquisition devices, and determines the tracking chain that can be merged with the first tracking chain in the sixth tracking chain set. The other acquisition devices in this method can be selected as acquisition devices whose acquisition range overlaps with the acquisition range of the acquisition device corresponding to the first acquisition point. Further, acquisition devices with overlapping acquisition ranges with the head or tail position of the first tracking chain can be selected, thus defining the second acquisition point. It is understood that there can be one or more second acquisition points. For example, if three cameras can capture the area where the tail of the first tracking chain is located, then there can be three second acquisition points, i.e., three acquisition devices.
[0063] In operation 402, the tracking chains collected by the second acquisition point are used to determine the sixth tracking chain set. The sixth tracking chain set contains at least one sixth tracking chain. The sixth tracking chain can be a tracking chain that has undergone merging or a tracking chain that has not undergone merging.
[0064] In operation 403, the second matching condition may be the same as or different from the first matching condition. Since the acquisition devices corresponding to the sixth tracking chain and the first tracking chain are different, the matching threshold corresponding to the second matching condition can be adjusted to match the sixth position feature and the sixth time feature corresponding to each sixth tracking chain in the sixth tracking chain set according to the first position feature and the first time feature. The sixth tracking chain that meets the second matching condition and the first tracking chain are merged to obtain the seventh tracking chain. When the seventh tracking chain does not meet the output condition, the seventh tracking chain can be determined as the updated second tracking chain for merging with other tracking chains. The image features corresponding to the seventh tracking chain may include the first image feature and the sixth image feature.
[0065] In one possible implementation, operation 403, merging the first tracking chain and the sixth tracking chain according to the first position feature and the sixth position feature to obtain the seventh tracking chain, includes: first, determining the overlapping position feature of the first position feature and the sixth position feature, fitting the overlapping position feature to obtain the fitted position feature; then, marking the overlapping position feature, and determining the seventh tracking chain according to the first tracking chain, the sixth tracking chain and the fitted position feature.
[0066] Since the first and sixth tracking chains are acquired from the first and second acquisition points respectively, and the acquisition points of the two tracking chains are different, the merged regions corresponding to the first and sixth tracking chains do not completely overlap when extracting their corresponding positional features. This method first determines the overlapping positional features based on the first and sixth positional features. These overlapping positional features characterize the intersecting parts of the first and sixth tracking chains. Then, the first and sixth tracking chains are fitted and connected using positional coordinate fitting to obtain the seventh tracking chain. Simultaneously, the overlapping positions are marked to facilitate subsequent searching and operations. Specifically, the fitting strategy of this method can be chosen as follows: the midpoint of the coordinate positions of the first and sixth tracking chains is determined as the fitting positional feature; the first and sixth tracking chains are then connected using the fitted positional feature to determine the seventh tracking chain.
[0067] In another specific implementation scenario, when the first tracking chain, the second tracking chain, the fourth tracking chain, and the sixth tracking chain cannot be merged, the first tracking chain is determined as the second tracking chain based on the image features corresponding to the first tracking chain, so as to be merged with the first tracking chain in the next round.
[0068] In one embodiment, the method further includes: first, storing the second tracking chain based on the first image features to obtain a stored tracking chain; then, outputting the stored tracking chain when it meets the output conditions. When the tracking chain performing the merging operation meets the output conditions, the tracking chain that meets the output conditions can be output for subsequent operations. Specifically, the output conditions may include at least one of the following: a first output condition characterizing that the stored tracking chain leaves all acquisition points; a second output condition characterizing that the time features corresponding to the stored tracking chain meet a specific time length; and a third output condition characterizing that the stored tracking chain outputs in real time.
[0069] The first output condition is that the tracking object enters the scene as the head of the tracking chain and the tracking object leaves the scene as the tail of the tracking chain. That is, the tracking chain is generated when the tracking object enters the scene, and is considered complete after the tracking object leaves the scene, and is then stored and output.
[0070] The second output condition is a preset time length threshold or position length threshold. When the time length or position length of the tracking chain exceeds the threshold, it is considered that the continued merging of the tracking chain may lead to performance issues. The tracking chain is then stored and output.
[0071] The third output condition is real-time output, which can output the merged tracking chain while merging the tracking chains, so as to facilitate subsequent real-time operations.
[0072] Figure 5 This is a schematic diagram of an implementation module for a data processing method according to another embodiment of the present invention.
[0073] See Figure 5 To facilitate a further understanding of the above embodiments, a scenario-based implementation is provided below. In this scenario-based implementation, the apparatus applying this method includes an input pool, a merging operation pool, and an output pool. The input pool of this method is communicatively connected to multiple cameras. The cameras acquire the tracking chains to be merged through image acquisition. The duration of each segment of the tracking chain to be merged is set to not exceed a tracking chain duration threshold, or the distance of each segment of the tracking chain to be merged is set to not exceed a tracking chain distance threshold.
[0074] The input pool contains an input queue, which stores and processes trace chains to be merged. The urgency value for each trace chain to be merged is determined based on the maximum number of cacheable queues or a set cache trigger time. The trace chains to be merged are sorted from highest to lowest urgency value, and the trace chains at the top of the sorted list are input into the merge operation pool as the first trace chain. The maximum number of cacheable queues can be determined by sorting the trace chains according to their input order, placing the trace chains with earlier inputs at the front of the queues. The cache trigger time can be represented by the timestamp at the beginning of the trace chain to be merged.
[0075] The merge operation pool stores a second trace chain that has undergone merge operations, including merge operations that have already been performed and operations that are determined to be unable to be merged.
[0076] The merging of the first and second tracking chains is performed and attempted sequentially according to the priority of the merging strategy. That is, if the same tracking chain has been merged in a high-priority strategy, it will not be attempted to be merged in a low-priority strategy. In this method, the priorities set include first priority, second priority, third priority, and fourth priority.
[0077] Figure 6a This is a schematic diagram illustrating a data processing method according to a first priority attempting to merge data, as described in another embodiment of the present invention.
[0078] See Figure 6aThe first priority is to determine whether to merge tracking chains with the same image features based on whether their time stamps are consecutive. When merging tracking chains with the same image features, only the continuity of the start and end time stamps is considered; that is, there should be no temporal overlap. If the start and end time stamps are consecutive, the two tracking chains are merged. If there are two tracking chains within the acquisition range corresponding to camera 715, and the image features of the two tracking chains are identical, and the start time stamp of one tracking chain is consecutive with the end time stamp of the other, the two tracking chains are merged. If the start and end time stamps are not consecutive, the process jumps directly to the fourth priority.
[0079] Figure 6b This is a schematic diagram illustrating a data processing method according to a second priority in another embodiment of the present invention, showing a scenario where the data is attempted to be merged.
[0080] See Figure 6b The second priority is to merge tracking chains under the same camera. When the image features of the two tracking chains are inconsistent, it is determined whether they can be merged based on the time features and distance features corresponding to the two tracking chains. The distance features include the distance between the two tracking chains and the direction of travel between the two tracking chains.
[0081] In this merging process, two tracking chains exist within the acquisition range of camera 715. When the image features of the two tracking chains are inconsistent, it cannot be directly assumed that the two tracking chains correspond to the same tracked object. More judgment factors need to be introduced to determine whether they can be merged. The specific judgment strategy is as follows: First, determine the breakpoint time of the two tracking chains, that is, determine the time difference between the tail timestamp of the tracking chain with the earlier head timestamp and the head timestamp of the tracking chain with the later head timestamp. Determine whether this time difference is less than a set time difference threshold and greater than 0. It can be understood that the same tracked object under the same camera cannot generate two coordinates at the same time point, that is, the two tracking chains do not have temporal overlap. Next, determine whether the distance between the breakpoint positions of the two tracking chains is less than a set distance threshold. Finally, determine whether the travel direction and travel speed of the two tracking chains match. If all the above conditions are met, the two tracking chains are merged.
[0082] Figure 6c This is a schematic diagram illustrating a data processing method according to a third priority in another embodiment of the present invention, showing a scenario where the data is attempted to be merged. Figure 6d This is a schematic diagram illustrating a data processing method based on a third priority fitting scenario, which is another embodiment of the present invention. Figure 6e This is a schematic diagram illustrating a data processing method according to a third priority and then merging data, which is another embodiment of the present invention.
[0083] The third priority is the merging of two tracking chains under different cameras. First, it is necessary to determine which cameras the first tracking chain is simultaneously located under. Then, the tracking chains corresponding to the cameras covering the first tracking chain are obtained, and the tracking chains that may overlap are identified from these chains. The overlap between the first tracking chain and the potentially overlapping tracking chains in time and position is determined, using the travel direction and speed corresponding to the two tracking chains as a reference. Finally, when all the above conditions simultaneously meet certain threshold restrictions, the two tracking chains are merged.
[0084] If the first tracking chain is acquired by camera 716, the sixth tracking chain acquired by camera 715 is determined based on the coverage area. When the merging conditions are met, the two tracking chains are fitted by connecting the intersection of their position coordinates in a zigzag pattern, and the fitted part is marked to obtain the merged tracking chain.
[0085] The fourth priority is that when the first priority, second priority, and third priority cannot merge the first tracking chain, the first tracking chain is saved as a new tracking chain, and the first tracking chain is marked according to the first image feature corresponding to the first tracking chain.
[0086] It should be noted that all the above merging does not involve changing the original data; it simply stores multiple tracking chains in the same data structure, which is used to identify the tracking chain set corresponding to the same tracked object. For the same tracking trajectory under different cameras, it is marked to indicate that the segment is overlapping, and the overlapping part can be deleted.
[0087] The merged tracking chains are stored in the merge operation pool if they do not meet the output conditions. When the output conditions are met, the tracking chains that meet the output conditions are output to the output pool.
[0088] The output conditions include the following three strategies:
[0089] (1) Limit output tracking chain: When the tracking chain of the merged operation pool exceeds the set threshold in any of the tracking time, tracking distance, or coordinate point corresponding to the tracking distance, the tracking chain is output to the output pool.
[0090] (2) Output the complete tracking chain. If the tracking chain in the merge operation pool has not been merged within the set time threshold, or the tracking object corresponding to the tracking chain has left the tracking scene area, the tracking chain is output to the output pool.
[0091] (3) Partial output tracking chain. When the real-time tracking requirements are high, the tracking chain can be merged while the merged tracking chain is being output.
[0092] Figure 7This is a schematic diagram of an implementation module of a data processing device according to an embodiment of the present invention.
[0093] See Figure 7 In another aspect, this invention provides a data processing apparatus, comprising: an acquisition module 701 for acquiring a first tracking chain, the first tracking chain corresponding to a first time feature and a first image feature; a determination module 702 for determining a second time feature corresponding to the second tracking chain when a second tracking chain exists that is consistent with the first image feature; and a merging module 703 for merging the first tracking chain and the second tracking chain according to the first time feature and the second time feature to obtain a third tracking chain.
[0094] In one embodiment, the merging module 703 includes: a first determining submodule, configured to determine a head timestamp corresponding to the first tracking chain based on the first time feature; the first determining submodule is further configured to determine a tail timestamp corresponding to the second tracking chain based on the second time feature; and a first merging submodule, configured to merge the head of the first tracking chain into the tail of the second tracking chain to obtain a third tracking chain when the head timestamp and the tail timestamp are consecutive. In one embodiment, the determining module 702 is further configured to determine a fourth tracking chain set based on a first acquisition point corresponding to the first image feature when there is no second tracking chain consistent with the first image feature, the fourth tracking chain set containing at least one fourth tracking chain; the determining module 702 is further configured to determine a first position feature corresponding to the first tracking chain; the device further includes: a matching module 704, configured to match the fourth tracking chain set based on the first position feature and the first time feature, and merge the fourth tracking chain and the first tracking chain that satisfy the first matching condition to obtain a fifth tracking chain.
[0095] In one embodiment, the first matching condition includes at least one of the following matching conditions: a first feature matching condition for characterizing the matching degree of time features, a second feature matching condition for characterizing the matching degree of position features, a third feature matching condition for characterizing the matching degree of velocity features, and a fourth feature matching condition for characterizing the matching degree of direction features.
[0096] In one embodiment, the determining module 702 is further configured to determine a second acquisition point based on the acquisition range corresponding to the first position feature when there is no fourth tracking chain that satisfies the first matching condition; the determining module 702 is further configured to determine a sixth tracking chain set based on the second acquisition point, the sixth tracking chain set containing at least one sixth tracking chain; the matching module 704 is further configured to match the sixth tracking chain set based on the first position feature and the first time feature, and merge the sixth tracking chain that satisfies the second matching condition with the first tracking chain to obtain a seventh tracking chain; wherein, the first acquisition point completely covers the acquisition range, and the second acquisition point partially covers the acquisition range; the second matching condition is the same as or different from the first matching condition.
[0097] In one embodiment, the matching module 704 includes: a fitting submodule 7041, used to determine the overlapping position features of the first position feature and the sixth position feature, and to fit the overlapping position features to obtain the fitted position features; and a marking submodule 7042, used to mark the overlapping position features and to determine a seventh tracking chain based on the first tracking chain, the sixth tracking chain and the fitted position features.
[0098] In one embodiment, the obtaining module 701 is used to obtain a queue to be merged, the queue to be merged containing at least one tracking chain to be merged; the device further includes: a sorting module 705, used to sort the tracking chains to be merged from first to last according to the time characteristics corresponding to the tracking chains to be merged, and determine the tracking chain that is sorted first as the first tracking chain.
[0099] In one embodiment, the device further includes: a storage module 706, used to store the second tracking chain according to the first image features to obtain a stored tracking chain; and an output module 707, used to output the stored tracking chain when the stored tracking chain meets the output conditions.
[0100] In one possible implementation, the output conditions include at least one of the following: a first output condition characterizing the storage tracking chain leaving all acquisition points; a second output condition characterizing the time characteristics corresponding to the storage tracking chain satisfying a specific time length; and a third output condition characterizing the real-time output of the storage tracking chain.
[0101] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the present invention. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of those different embodiments or examples.
[0102] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.
[0103] The above are merely specific embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A data processing method, the method comprising: A first tracking chain is obtained, and the first tracking chain corresponds to a first temporal feature and a first image feature; When a second tracking chain exists that is consistent with the first image features, determine the second temporal features corresponding to the second tracking chain; The first tracking chain and the second tracking chain are merged based on the first time feature and the second time feature to obtain a third tracking chain; When there is no second tracking chain that matches the first image feature, a fourth tracking chain set is determined based on the first acquisition point corresponding to the first image feature, the fourth tracking chain set containing at least one fourth tracking chain; and a first position feature corresponding to the first tracking chain is determined. The fourth tracking chain set is matched with the first location feature and the first time feature. The fourth tracking chain that meets the first matching condition is merged with the first tracking chain to obtain the fifth tracking chain.
2. The method according to claim 1, wherein the first tracking chain and the second tracking chain are merged based on the first time feature and the second time feature to obtain a third tracking chain, comprising: Determine the head timestamp corresponding to the first tracking chain based on the first time feature; Determine the tail timestamp corresponding to the second tracking chain based on the second time feature; When the head timestamp and the tail timestamp are consecutive, the head of the first tracking chain is merged into the tail of the second tracking chain to obtain a third tracking chain.
3. The method according to claim 1, wherein the first matching condition includes at least one of the following matching conditions: a first feature matching condition for characterizing the matching degree of time features, a second feature matching condition for characterizing the matching degree of position features, a third feature matching condition for characterizing the matching degree of velocity features, and a fourth feature matching condition for characterizing the matching degree of direction features.
4. The method according to claim 1, further comprising: If there is no fourth tracking chain that meets the first matching condition, the second acquisition point is determined according to the acquisition range corresponding to the first position feature; A sixth tracking chain set is determined based on the second acquisition point, and the sixth tracking chain set contains at least one sixth tracking chain; The first position feature and the first time feature are matched with the sixth position feature and the sixth time feature corresponding to the sixth tracking chain in the sixth tracking chain set. The sixth tracking chain that meets the second matching condition is merged with the first tracking chain to obtain the seventh tracking chain. Wherein, the first collection point completely covers the collection range, and the second collection point partially covers the collection range; the second matching condition is the same as or different from the first matching condition.
5. The method according to claim 4, wherein the first tracking chain and the sixth tracking chain are merged according to the first position feature and the sixth position feature to obtain a seventh tracking chain, comprising: Determine the overlapping position features of the first position feature and the sixth position feature, and fit the overlapping position features to obtain the fitted position features; The overlapping position features are marked, and a seventh tracking chain is determined based on the first tracking chain, the sixth tracking chain, and the fitted position features.
6. The method according to claim 1, further comprising: Obtain a queue to be merged, the queue to be merged containing at least one tracking chain to be merged; The tracking chains to be merged are sorted from first to last according to their time characteristics, and the tracking chain at the beginning of the sort is determined as the first tracking chain.
7. The method according to claim 1, further comprising: The second tracking chain is stored based on the first image features to obtain the stored tracking chain; When the storage tracking chain meets the output conditions, the storage tracking chain is output.
8. The method according to claim 7, wherein the output conditions include at least one of the following: The first output condition is used to characterize the storage tracking chain leaving all acquisition points; the second output condition is used to characterize the time characteristics corresponding to the storage tracking chain satisfying a specific time length; and the third output condition is used to characterize the real-time output of the storage tracking chain.
9. A data processing apparatus, the apparatus comprising: The acquisition module is used to acquire a first tracking chain, which corresponds to a first temporal feature and a first image feature; The determination module is used to determine the second temporal feature corresponding to the second tracking chain when a second tracking chain that is consistent with the first image feature exists. The merging module is used to merge the first tracking chain and the second tracking chain according to the first time feature and the second time feature to obtain a third tracking chain; The determining module is further configured to, when there is no second tracking chain consistent with the first image feature, determine a fourth tracking chain set based on a first acquisition point corresponding to the first image feature, wherein the fourth tracking chain set contains at least one fourth tracking chain; and determine a first position feature corresponding to the first tracking chain; The matching module is used to match the fourth tracking chain set with the first position feature and the first time feature, and merge the fourth tracking chain that meets the first matching condition with the first tracking chain to obtain the fifth tracking chain.
Citation Information
Patent Citations
Video portrait tracking method based on human face identification in complex scenario
CN105069408A
Method, device and system for searching target object based on monitoring cameras
CN106878666A
Pedestrian tracking method and device and cross-camera pedestrian tracking method and device
CN108629791A