CN116416642A - Target detection method, target detection device, electronic equipment and computer readable storage medium - Google Patents

Target detection method, target detection device, electronic equipment and computer readable storage medium Download PDF

Info

Publication number
CN116416642A
CN116416642A CN202111630243.XA CN202111630243A CN116416642A CN 116416642 A CN116416642 A CN 116416642A CN 202111630243 A CN202111630243 A CN 202111630243A CN 116416642 A CN116416642 A CN 116416642A
Authority
CN
China
Prior art keywords
model
historical
coefficient
position information
motion
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111630243.XA
Other languages
Chinese (zh)
Inventor
范财理
赵智宝
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
TCL Technology Group Co Ltd
Original Assignee
TCL Technology Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by TCL Technology Group Co Ltd filed Critical TCL Technology Group Co Ltd
Priority to CN202111630243.XA priority Critical patent/CN116416642A/en
Publication of CN116416642A publication Critical patent/CN116416642A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/20Analysis of motion
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10016Video; Image sequence
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30196Human being; Person
    • G06T2207/30201Face

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • General Health & Medical Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Biomedical Technology (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Multimedia (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Image Analysis (AREA)

Abstract

The embodiment of the application discloses a target detection method, a target detection device, electronic equipment and a computer-readable storage medium; the method comprises the following steps: acquiring historical motion position information and current data to be detected of an object; updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model; and inputting the current data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object. By adopting the embodiment of the application, the accuracy of detecting the object is improved.

Description

Target detection method, target detection device, electronic equipment and computer readable storage medium
Technical Field
The present disclosure relates to the field of communications technologies, and in particular, to a target detection method, a target detection device, an electronic device, and a computer readable storage medium.
Background
In recent years, as research on target detection has been advanced in breakthrough, face recognition, gesture recognition and limb key point detection are increasingly applied in living scenes such as live broadcast, short video, face-beautifying cameras and video calls. Meanwhile, novel somatosensory games facing to human faces, gestures and limb perception gradually become a new trend of game development. The common general target detection model can achieve higher accuracy in detection of faces, hands and limbs. However, these face detection models have large parameter amounts and large calculation amounts, and cannot achieve real-time detection on the embedded device due to limited calculation resources. Thus, some face, hand and limb detection algorithms for embedded hardware have been developed.
However, the existing detection algorithm facing embedded hardware reduces the parameter amount and the operation amount of the model and weakens the detection accuracy and the detection rate to different degrees. For example, in an application scene of a home terminal (such as a smart television), a motion range of a detection target (usually a face, a palm and limbs) in a camera field of view is large, a scale is small, the limbs and the palm rapidly move, and shielding is caused behind objects such as moving furniture, so that the existing detection algorithm facing embedded hardware often cannot detect the face, the palm and the limbs, and a condition that a continuous multi-frame detection result is lost occurs.
Disclosure of Invention
The embodiment of the application provides a target detection method, a target detection device, electronic equipment and a computer readable storage medium, which can improve the accuracy of detecting an object.
The embodiment of the application provides a target detection method, which comprises the following steps:
acquiring historical motion position information and current data to be detected of an object;
updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model;
and inputting the current data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object.
Correspondingly, the embodiment of the application also provides a target detection device, which comprises:
the acquisition unit is used for acquiring historical motion position information of the object and current data to be detected;
the updating unit is used for updating the preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model;
the detection unit is used for inputting the current data to be detected into the updated motion estimation model for processing and outputting the current motion position information of the object.
Accordingly, the embodiment of the application further provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor implements the steps in any of the target detection methods provided in the embodiments of the application when executing the computer program.
Accordingly, embodiments of the present application also provide a computer readable storage medium storing a computer program which, when executed by a processor, implements the steps in the object detection method provided in any of the embodiments of the present application.
The embodiment of the application provides a target detection method, which updates a preset motion estimation model by utilizing historical motion position information of an object, so that the preset motion estimation model can learn a motion track of the object from the historical motion position information of the object. Therefore, when the updated motion estimation model is used for detecting the current data to be detected of the object, the detection can be performed according to the learned motion trail, and therefore the accuracy of detecting the object is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly introduced below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic view of a scenario of a target detection method provided in an embodiment of the present application;
fig. 2 is a schematic flow chart of a target detection method according to an embodiment of the present application;
FIG. 3 is a schematic diagram of a preset history coefficient record table according to an embodiment of the present application;
FIG. 4 is a schematic diagram of a preset history coefficient table according to an embodiment of the present disclosure;
FIG. 5 is a schematic diagram of detecting motion position information according to an embodiment of the present disclosure;
FIG. 6 is a schematic flow chart of a target detection method according to an embodiment of the present disclosure;
fig. 7 is a schematic structural diagram of an object detection device according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which embodiments of the present application are shown, however, in which embodiments are shown, by way of illustration, only, and not in any way all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments herein without making any inventive effort, are intended to be within the scope of the present application.
The embodiment of the application provides a target detection method which can be executed by electronic equipment. The electronic device may include at least one of a terminal, a server, and the like. I.e. the object detection method may be performed by the terminal or by the server.
The terminal may include a personal computer, a tablet computer, a smart television, a smart phone, a smart home, a wearable electronic device, a VR/AR device, a vehicle-mounted computer, and the like.
The server may be an interworking server or a background server among a plurality of heterogeneous systems, may be an independent physical server, may be a server cluster or a distributed system formed by a plurality of physical servers, and may be a cloud server for providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, basic cloud computing services such as big data and an artificial intelligent platform, and the like.
In an embodiment, as shown in fig. 1, specifically, the electronic device may acquire historical motion position information of the object and current data to be detected; updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model; and inputting the data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object.
The following detailed description is given, respectively, of the embodiments, and the description sequence of the following embodiments is not to be taken as a limitation of the preferred sequence of the embodiments.
The embodiment of the application describes the target detection method proposed in the embodiment of the application from the perspective that the target detection device is integrated in the server.
As shown in fig. 2, a target detection method is provided, and the specific flow includes:
101. and acquiring historical motion position information and current data to be detected of the object.
In an embodiment, in recent years, as research on object detection has been advanced in breakthrough, face recognition, gesture recognition, and limb key point detection are increasingly applied in living scenes such as live broadcast, short video, beauty camera, and video call. Meanwhile, novel somatosensory games facing to human faces, gestures and limb perception gradually become a new trend of game development. Meanwhile, research on detection technologies of faces, palms and limbs is gradually mature, and various face detection algorithms achieve good effects on the most popular and challenging data sets. The common general target detection model can achieve higher accuracy in detection of faces, hands and limbs. However, these face detection models have large parameter amounts and large calculation amounts, and cannot achieve real-time detection on the embedded device due to limited calculation resources. Thus, some face, hand and limb detection algorithms for embedded hardware have been developed.
When the algorithm facing the embedded hardware is applied to an application scene of the handheld mobile device, the actual effect of the detection algorithm can basically meet the application requirement due to the fact that the distance between the camera and the detection target (usually a face, a palm and limbs) is relatively short, the movement range of the detection target in the field of view of the camera is relatively small, the scale in the field of view of the image is relatively large and the change is relatively small.
However, when the algorithm oriented to the embedded hardware is applied to an application scene of a home terminal (such as an intelligent television), due to the fact that a movement range of a detection target (usually a face, a palm and limbs) in a camera field of view is large, a scale is small, accompanying illumination condition changes, limbs and palms rapidly move, shielding is caused behind objects such as moving furniture, and the like, the situation that the face, the palm and the limbs cannot be detected often occurs, and the situation is usually represented as that a continuous multi-frame detection result of a target detection model is missing.
Therefore, the embodiment of the application provides a target detection method, which can update the position change relation between adjacent frames in real time according to the detection result of the existing historical frame targets (human face, palm and limbs) under the condition that the detected targets on the images are invisible due to the fact that the collected images are blurred, noise is serious and other objects are shielded under the conditions of severe illumination change, rapid target movement and the like, so that the targets cannot be detected continuously and repeatedly.
Wherein the object may include a historical frame target. For example, the object may include a detected face, a detected limb or a detected palm, or the like.
Wherein, the historical motion position information of the object can comprise corresponding position information mapped to historical frames when the object moves. For example, the historical motion location information of the object may include coordinate information of the object among historical frames, and so on. For example, when the object is a palm, the historical motion location information may include coordinate information of the palm in the historical frame. For another example, when the object is a face, the historical motion location information may include coordinate information of the face in a historical frame.
The current data to be detected of the object may include data that the object currently needs to detect. For example, the current data to be detected for the object may include that the object is currently required to detect a video frame, and so on.
In one embodiment, a video in which a motion process of an object is recorded may be acquired, and then a frame of the object may be obtained by framing the video.
Then, the video frame can be detected by using a preset estimated motion model, and historical motion position information of the object is obtained.
In an embodiment, when the condition that the object cannot be detected exists in the video frame of the obtained object, the current data to be detected of the object can be detected by using the historical motion position information of the object.
In an embodiment, in order to ensure the reliability of detection, the historical motion position information of the object can be obtained by screening the historical motion data of the object. That is, the historical motion position information of the object is obtained by being filtered.
Wherein the historical motion data of the object may include all of the historical motion data of the object. For example, the historical motion data may include all video frames of the object. Historical motion location information may then be obtained by filtering the video frames.
Specifically, the step of "obtaining historical motion position information of the object" may include:
acquiring the number of historical moving images of an object;
and screening the plurality of pieces of preset detection motion position information based on the number of the historical motion images to obtain the historical motion position information of the object.
Wherein the historical moving image number of the object may include the number of all video frames of the object. For example, if the number of all video frames of the object is 100 frames, the number of the history moving images is 100.
The preset detected motion position information may be position information of the object obtained after the preset motion estimation model detects the video frame of the object.
In an embodiment, the historical motion position information may be obtained by filtering a plurality of pieces of preset detected motion position information based on the number of historical motion images. For example, nonlinear operation is performed on the number of historical moving images, and a target video frame is selected from all video frames according to the operation result. Then, the coordinate information of the object in the target video frame can be used as the historical motion position information.
Wherein, the historical motion image data can be subjected to nonlinear operation according to the following formula:
Figure BDA0003440839090000051
where n may represent the total number of historical motion pictures. t is t i May be the filtered historical motion location information. The above formula shows that the historical motion position information is filtered out by changing the value of i, wherein the value of i cannot be larger than the historical motion image data.
In one embodiment, the data points may be selected to form a historical frame sequence (including the filtered historical motion location information) according to the above formula. And then updating the preset motion estimation model by utilizing the historical motion position information.
102. And updating the preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model.
In an embodiment, when detecting the current data to be detected of the object by using the historical motion position information of the object, the preset motion estimation model may be updated by using the historical motion position information to obtain an updated motion estimation model. And then, detecting the current data to be detected by using the updated motion estimation model to obtain the current motion position information of the object.
The preset motion estimation model may include a model that is designed in advance and can detect motion position information of the object through a video frame.
In an embodiment, the predetermined motion estimation model may be a neural network model. For example, the preset motion estimation model may be a convolutional neural network (Convolutional Neural Networks, CNN), a regional convolutional neural network (Region-CNN, RCNN), or a deep convolutional neural network (Deep Neural Networks, DCNN), among others.
In an embodiment, the predetermined motion estimation model may be a custom model. For example, the motion estimation model may be a polynomial function of the coordinates p with respect to time t:
p=f(t)=a 0 +a 1 t+a 2 t 2 +…+a n-1 t n-1
Wherein a is 0 、a 1 、a 2 ...a n-1 May be coefficients of a polynomial function.
In an embodiment, the historical motion information may be used to update the preset motion estimation model to obtain an updated motion estimation model. Specifically, the step of updating the preset motion estimation model by using the historical motion position information to obtain an updated motion estimation model may include:
initializing model coefficient information of a preset motion estimation model;
updating a preset history coefficient record table based on the history movement position information to obtain an updated history coefficient record table;
calculating model coefficient information by using the updated history coefficient record table to obtain calculated model coefficients;
and updating the preset motion estimation model based on the calculated model coefficient to obtain an updated motion estimation model.
The model coefficient information may include information related to model coefficients of a preset motion estimation model. For example, the model coefficient information may include the number of model terms and the model coefficients to be solved.
The model term number may include a number that indicates that there are a plurality of model coefficients in the preset motion estimation model. For example, when the model coefficient of the preset motion estimation model is a 0 、a 1 And a 2 And if so, the number of model terms is 3. For another example, when the model coefficient of the preset motion estimation model is a 0 、a 1 、a 2 And a 3 And the number of model terms is 4.
The model coefficients to be solved may include coefficients of a specific value that is not yet known in the preset motion estimation model. For example, when the coefficient of the specific data which is still unknown in the preset motion estimation model is a 0 、a 1 And a 2 When the model coefficients to be solved may include a 0 、a 1 And a 2
The preset history coefficient record table may include preset model coefficient information stored in the preset history coefficient record table.
In an embodiment, the process of solving the model coefficient information may be recorded in a preset history coefficient record table. For example, the process of solving the model coefficient information may be made into a table, which is a preset history coefficient record table. For example, as shown in FIG. 3, the solution model coefficients a may be calculated k The process of (1) is to make a triangle form, and the triangle form is a preset history coefficient record form. The model coefficient information can then be calculated using the predetermined history coefficient record table.
In one embodiment, because the preset history coefficient record table is also generated during the calculation of the model coefficient information. Therefore, the preset history coefficient record table can be updated based on the history movement position information, and the updated history coefficient record table is obtained. Specifically, before the step of updating the preset history coefficient record table by using the history movement position information to obtain the updated history coefficient record table, the method further includes:
Acquiring a sample set corresponding to the historical motion position information, wherein the sample set comprises a plurality of historical motion position information samples;
performing logic operation processing on a plurality of historical motion position information samples to obtain a plurality of model coefficients;
and constructing a preset history coefficient record table based on the plurality of model coefficients.
In an embodiment, the motion position information of the object that has been predicted may be taken as a historical motion position information sample.
For example, there are n historical motion position information samples (t 0 ,f(t 0 )),(t 1 ,f(t 1 )),…,(t n-1 ,f(t n-1 ) And), wherein t 0 Time, f (t 0 ) Indicated at t 0 Coordinate information of this time object.
In one embodiment, a plurality of historical motion position information samples may be logically processed to obtain a plurality of model coefficients.
For example, when the preset motion estimation model is p=f (t) =a 0 +a 1 t+a 2 t 2 +…+a n-1 t n-1 When the method is used, n historical motion position information samples can be substituted into a preset motion estimation model, and n historical motion position information samples are substituted into the preset motion estimation model to obtain:
Figure BDA0003440839090000081
wherein, the liquid crystal display device comprises a liquid crystal display device,
Figure BDA0003440839090000082
through the deduction, in order to reduce the calculation amount, the embodiment of the application provides a method for iteratively solving the coefficients of a model to be solved.
Specifically, in the embodiments of the present application, it is defined that:
f[t k ]=f(t k )
Figure BDA0003440839090000083
Figure BDA0003440839090000084
the preset motion estimation model may then be rewritten as
f(t)=a 0 +a 1 (t-t 0 )+a 2 (t-t 0 )(t-t 1 )+…+a n-1 (t-t 0 )(t-t 1 )…(t-t n-1 )
Wherein a is k =f[t 0 ,t 1 ,…,t k ],k=0,1,2,…,n-1。
In one embodiment, after obtaining a plurality of model coefficients, a predetermined history coefficient record table may be constructed based on the model coefficients.
For example, a can be k For example, as shown in fig. 3, a table of predetermined history coefficients is shown, where n=3 is an example.
At this time, the model coefficient a of f (t) k May be the value corresponding to the top side of the triangle. For example, a 1 The corresponding data in the preset history coefficient record list is f [ t ] 0 ,t 1 ]. Also for example, a 2 The corresponding data in the preset history coefficient record list is f [ t ] 0 ,t 1 ,t 2 ]。
When one frame of data is newly added, only one line needs to be newly added at the bottom of the triangle. For example, when calculating the motion position information of the object in the 4 th frame, the model coefficient may be solved according to the information recorded in the preset history coefficient record table, to obtain the updated motion estimation model. Then, the motion position information of the object in the 4 th frame is calculated using the updated motion estimation model.
In one embodiment, after the history coefficient table is constructed, model coefficient information may be calculated from the history coefficient table.
Specifically, model coefficient information of the motion estimation model can be initialized according to historical motion position information and current to-be-detected data. For example, the number of model terms and model coefficients to be solved of the motion estimation model may be initialized based on the motion location information and the current data to be detected.
For example, the motion estimation model is p=f (t) =a 0 +a 1 t+a 2 t 2 +…+a n-1 t n-1 . The preset motion estimation model has predicted the motion position information of the object in the first three frames, and then needs to predict the motion position of the object in the 4 th frameInformation.
The model term number of the motion estimation model may then be initialized to 4, the model coefficients to be solved comprising a 0 、a 1 、a 2 And a 3 . At this time, the preset motion estimation model is initialized to p=f (t) =a 0 +a 1 t+a 2 t 2 +a 3 t 3
And then, calculating model coefficient information by using a preset history coefficient record table to obtain an updated motion estimation model.
For example, a may be calculated using a preset history coefficient record table 0 、a 1 、a 2 And a 3 Thereby obtaining an updated motion estimation model.
In one embodiment, the step of calculating the model coefficient information using the updated history coefficient record table to obtain the calculated model coefficient may include:
reading the history model coefficient information in the updated history coefficient record table;
and carrying out solving processing on the model coefficient to be solved based on the model term number and the historical model coefficient information to obtain the calculated model coefficient.
The history model coefficient information may include information recorded in a preset history coefficient recording table. For example, as shown in FIG. 3, f [ t ] in FIG. 3 0 ]、f[t 1 ]And so on, may be historical model coefficient information.
In an embodiment, after the historical model coefficient information in the historical coefficient record table is read, the model coefficient to be solved may be solved based on the model term number and the historical model coefficient information, so as to obtain the calculated model coefficient. Specifically, the step of solving the model coefficient to be solved based on the model term number and the historical model coefficient information to obtain a calculated model coefficient may include:
screening out a target historical model coefficient from the historical model coefficient information according to the model item number;
and carrying out logic operation processing on the target historical model coefficient and the model coefficient to be solved to obtain a calculated model coefficient.
For example, as shown in fig. 4, it is assumed that the model coefficient corresponding to n=3 has already been found, and the model coefficient corresponding to n=4 needs to be found at this time, that is, it corresponds to the solution of f [ t ] in fig. 4 0 ,t 1 ,t 2 ,t 3 ]. Then f t can be passed first 2 ]And f [ t ] 3 ]Solving for f [ t ] 2 ,t 3 ]. Then, through f [ t1 ]]、f[t 2 ]、f[t 3 ]、f[t 1 ,t 2 ]And f [ t ] 2 ,t 3 ]Solving for f [ t ] 1 ,t 2 ,t 3 ]. Finally, f [ t ] in the preset history coefficient record table can be utilized 0 ]、f[t 1 ]、f[t 2 ]、f[t 3 ]、f[t 0 ,t 1 ]、f[t 1 ,t 2 ]、f[t 2 ,t 3 ]、f[t 0 ,t 1 ,t 2 ]And f [ t ] 1 ,t 2 ,t 3 ]Solving for f [ t ] 0 ,t 1 ,t 2 ,t 3 ]。
In one embodiment, when calculating the target coefficient using the preset history coefficient record table, the following may be used:
1) Inputting n frames of data: t= (t 0 ,t 1 ,…,t n-1 ),p=(f(t 0 ),f(t 1 ),…,f(t n-1 ))
2) Initializing motion model coefficients: f [ t ] j ]=f(t j ) Wherein: j=0, 1, …, n-1
3) Sequentially and iteratively calculating coefficients corresponding to the table triangles:
Figure BDA0003440839090000101
where i=1, …, n-1, j=0, 1, …, n-i
4) The motion model is as follows:
Figure BDA0003440839090000102
wherein the time t can be normalized to [ -1,1] and let the real motion model be g (t). According to the cauchy theorem, the error of the target motion estimation model can be expressed as:
Figure BDA0003440839090000103
h(t)=(t-t 0 )(t-t 1 )…(t-t n-1 )
wherein θ is between the minimum and maximum values of t. From the above formula, when h (t) is minimum, error will obtain a small value, and the solved f (t) is the optimal motion position information of the object.
Wherein n data points can be reasonably selected over the interval [ -1,1] such that h (t) is as small as possible. When h (t) is as small as possible, there is
Figure BDA0003440839090000111
Therefore, when the historical motion position information of the object is acquired, the formula is adopted
Figure BDA0003440839090000112
The selected data points form a historical frame sequence.
103. And inputting the current data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object.
In an embodiment, after the updated motion estimation model is obtained, the current data to be detected may be detected by using the updated motion estimation model, so as to obtain the current motion position information of the object. Specifically, the step of inputting the current data to be detected into the updated motion estimation model to process, and outputting the current motion position information of the object may include:
Determining updated model coefficients of the updated motion estimation model;
determining an operation strategy corresponding to the current data to be detected according to the updated model coefficient;
and calculating the current data to be detected based on the calculation strategy to obtain the current movement position information of the object.
For example, the motion estimation model is preset to be f (t) =a 0 +a 1 t+a 2 t 2 +a 3 t 3 . The motion estimation model after update is f (t) =a 0 +a 1 t+a 2 t 2 +a 3 t 3 +a 4 t 4 . Then, the updated motion estimation model is identified to obtain an updated model coefficient a 0 、a 1 、a 2 、a 3 And a 4
Then, according to the updated model coefficient, determining a 1 The corresponding operation strategy of the current data to be detected is t, a 2 The corresponding operation strategy of the current data to be detected is t 2 ,a 3 The corresponding operation strategy of the current data to be detected is t 3
Then, the current data to be detected can be calculated based on the operation strategy, and then the calculated data and the operation strategy are multiplied to obtain the multiplied numerical value. And adding the multiplied data to obtain the current motion position information of the object.
The embodiment of the application provides a target detection method, which can aim at the situations that the detection target has a larger movement range in the field of view of a camera, the scale is smaller, the limbs and the palms rapidly move along with the change of illumination conditions, the back of an object such as moving furniture is shielded, and the like, and the face, the palms and the limbs of a person cannot be detected. In addition, the embodiment of the application can also aim at the condition that the continuous multi-frame detection result of the target detection model is missing. For example, when the continuous multi-frame detection result of the target detection model is missing, the target detection method provided by the embodiment of the application can update the preset motion estimation model by using the historical motion position information of the object, so as to obtain an updated motion estimation model. And then detecting the missing multiframes by using the updated motion estimation model, so as to obtain the motion position information of the object. By updating the preset motion estimation model by using the historical motion position information of the object, the preset motion estimation model can learn the motion trail of the object from the historical motion position information of the object. Therefore, when the updated motion estimation model is used for detecting the current data to be detected of the object, the detection can be performed according to the learned motion trail, and therefore the accuracy of detecting the object is improved.
Secondly, in the embodiment of the present application, the preset motion estimation model may also be updated by using a preset history coefficient record table. Wherein, a plurality of historical motion position information samples are recorded in a preset historical coefficient record table. Therefore, when the preset motion estimation model is updated by using the preset historical coefficient record table, the calculated model coefficient can be rapidly calculated through the historical motion position sample, so that the efficiency of detecting the object is improved.
In addition, the embodiment of the application can also model the preset motion estimation model into a polynomial form. The preset motion estimation model is modeled into a polynomial form, so that the preset motion estimation model can be fitted to various motion tracks of an object. For example, uniform motion or variable motion and the like can be fitted through a preset motion estimation model, so that the accuracy of detecting the motion position information of the object is improved. Moreover, when the historical motion position information of the object is acquired, the historical motion position information of the object is selected based on an optimal principle. Because the predicted value of the motion model always occurs near the right end point of the section of t, the fitting capacity of the model near the right end point of the section is improved, and the prediction effect of the model can be effectively improved. For example, as shown in FIG. 5, the upper is a schematic of uniform sampling according to the time axis, and the lower is according to
Figure BDA0003440839090000121
Schematic of non-uniform sampling. We follow->
Figure BDA0003440839090000122
Selecting data points in the buffer queue as history frames, wherein the data points are densely distributed near the right end pointThe data points on the right side of the interval are distributed sparsely, so that the errors of the motion model can be shared by the left side of the interval, and the errors of the motion model prediction can be reduced.
According to the method described in the above embodiments, examples are described in further detail below.
The method of the embodiment of the application will be described by taking the example that the target detection method is integrated on the server. For example, as shown in fig. 6, the target detection method provided in the embodiment of the present application may include:
201. and (5) reasoning a target detection model.
The object detection model may refer to a model for detecting motion position information of a video frame object, among others. The object detection model and the motion model may be the same model or different models.
In one embodiment, the object's motion location information may be detected using an object detection model. When the target detection model does not detect the movement position information of the object, the historical movement position information of the object can be acquired, and the current movement position information of the object is detected through the historical movement position information of the object.
202. The target center point data is inserted into the cache queue.
In one embodiment, the buffer queue and the historical frame sequence may be initialized to an empty queue when the object detection model does not detect motion position information of the object.
The buffer queue is used for storing all motion position information detected by the object.
The historical frame sequence is used for storing historical motion position information screened from all motion position information of the object.
203. Data points are extracted from the buffer queue to form a historical frame sequence.
In one embodiment, in order to improve the accuracy of the detection, all the detected motion position information is selected to be part of the historical motion position information, and the current motion position information of the object is detected by the historical motion position information.
Wherein, the historical motion position information can comprise a coordinate sequence formed from a past moment to a central point of the target detection result of the n frames of images.
Wherein, the historical motion position information can be screened from the buffer queue and stored into the historical frame sequence according to the following formula:
Figure BDA0003440839090000131
204. motion model coefficients are calculated.
The motion model may refer to a preset motion estimation model.
In an embodiment, after the historical frame sequence is formed, a preset historical coefficient record table corresponding to the preset motion estimation model may be calculated. And then calculating according to a preset history coefficient record table to obtain a motion model coefficient.
205. And updating the motion model.
After the motion model coefficient is obtained, the motion model can be updated, and the updated motion model is obtained.
206. The target position is predicted.
In one embodiment, after the updated motion model is obtained, the updated motion model may be used to predict the target location. For example, the motion position information of the object in the missing frame is predicted using the updated motion model.
207. Judging whether or not the detection is finished
In one embodiment, it may be determined whether the detection process is over, and when the detection process still needs to be performed, the execution of step 201 and subsequent steps may be continued.
According to the embodiment of the application, the situation that the continuous multi-frame detection result of the target detection model is missing can be aimed at. For example, when the continuous multi-frame detection result of the target detection model is missing, the target detection method provided by the embodiment of the application can update the preset motion estimation model by using the historical motion position information of the object, so as to obtain an updated motion estimation model. And then detecting the missing multiframes by using the updated motion estimation model, so as to obtain the motion position information of the object, and improve the accuracy of detecting the motion position information of the object.
In order to better implement the object detection method provided in the embodiments of the present application, in an embodiment, an object detection device is also provided, where the object detection device may be integrated in an electronic device. The meaning of the nouns is the same as that of the target detection method, and specific implementation details can be referred to in the description of the method embodiment.
In one embodiment, an object detection apparatus is provided, which may be integrated in an electronic device, as shown in fig. 7, and includes:
an acquiring unit 301, configured to acquire historical motion position information of an object and current data to be detected;
an updating unit 302, configured to update a preset motion estimation model by using the historical motion position information, so as to obtain an updated motion estimation model;
the detecting unit 303 is configured to input the current data to be detected into the updated motion estimation model for processing, and output current motion position information of the object.
In an embodiment, the updating unit 302 may include:
an initialization subunit, configured to initialize model coefficient information of a preset motion estimation model;
a record table updating subunit, configured to update a preset history coefficient record table by using the history movement position information, so as to obtain an updated history coefficient record table;
The calculating subunit is used for calculating model coefficient information by using the updated history coefficient record table to obtain calculated model coefficients;
and the model updating subunit is used for updating the preset motion estimation model based on the calculated model coefficient to obtain an updated motion estimation model.
In an embodiment, the computing subunit may include:
the reading module is used for reading the history model coefficient information in the updated history coefficient record table;
and the solving module is used for solving the model coefficient to be solved based on the model term number and the historical model coefficient information to obtain the calculated model coefficient.
In one embodiment, the solving module may include:
the screening sub-module is used for screening out target historical model coefficients from the historical model coefficient information according to the number of model items;
and the logic operation sub-module is used for carrying out logic operation processing on the target historical model coefficient and the model coefficient to be solved to obtain a calculated model coefficient.
In an embodiment, the updating unit 302 may further include:
the acquisition subunit is used for acquiring a sample set corresponding to the historical motion position information, wherein the sample set comprises a plurality of historical motion position information samples;
the logic operation subunit is used for carrying out logic operation processing on the plurality of historical motion position information samples to obtain a plurality of model coefficients;
And the construction subunit is used for constructing a preset historical coefficient record table based on the plurality of model coefficients.
In an embodiment, the detection unit 303 may include:
a model identification subunit, configured to determine updated model coefficients of the updated motion estimation model;
the strategy determination subunit is used for determining an operation strategy corresponding to the current data to be detected according to the updated model coefficient;
and the data operation subunit is used for operating the current data to be detected based on an operation strategy to obtain the current motion position information of the object.
In an embodiment, the object detection apparatus may further include:
a number acquisition subunit configured to acquire a number of historical moving images of the object;
and the screening subunit is used for screening the plurality of pieces of preset detection motion position information based on the number of the historical motion images to obtain the historical motion position information of the object.
In the implementation, each unit may be implemented as an independent entity, or may be implemented as the same entity or several entities in any combination, and the implementation of each unit may be referred to the foregoing method embodiment, which is not described herein again.
The object detection device can improve the accuracy of detecting the movement position information of the object.
The embodiment of the application also provides electronic equipment, which can comprise a terminal or a server; for example, the electronic device may be a server, such as an object detection server, or the like. As shown in fig. 8, a schematic structural diagram of a terminal according to an embodiment of the present application is shown, specifically:
the electronic device may include one or more processing cores 'processors 401, one or more computer-readable storage media's memory 402, power supply 403, and input unit 404, among other components. It will be appreciated by those skilled in the art that the electronic device structure shown in fig. 8 is not limiting of the electronic device and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components. Wherein:
the processor 401 is a control center of the electronic device, connects various parts of the entire electronic device using various interfaces and lines, and performs various functions of the electronic device and processes data by running or executing software programs and/or modules stored in the memory 402, and calling data stored in the memory 402, thereby performing overall monitoring of the electronic device. Optionally, processor 401 may include one or more processing cores; preferably, the processor 401 may integrate an application processor and a modem processor, wherein the application processor mainly processes an operating system, a user page, an application program, etc., and the modem processor mainly processes wireless communication. It will be appreciated that the modem processor described above may not be integrated into the processor 401.
The memory 402 may be used to store software programs and modules, and the processor 401 executes various functional applications and data processing by executing the software programs and modules stored in the memory 402. The memory 402 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program (such as a sound playing function, an image playing function, etc.) required for at least one function, and the like; the storage data area may store data created according to the use of the computer device, etc. In addition, memory 402 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 402 may also include a memory controller to provide the processor 401 with access to the memory 402.
The electronic device further comprises a power supply 403 for supplying power to the various components, preferably the power supply 403 may be logically connected to the processor 401 by a power management system, so that functions of managing charging, discharging, and power consumption are performed by the power management system. The power supply 403 may also include one or more of any of a direct current or alternating current power supply, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and the like.
The electronic device may further comprise an input unit 404, which input unit 404 may be used for receiving input digital or character information and generating keyboard, mouse, joystick, optical or trackball signal inputs in connection with user settings and function control.
Although not shown, the electronic device may further include a display unit or the like, which is not described herein. In particular, in this embodiment, the processor 401 in the electronic device loads executable files corresponding to the processes of one or more application programs into the memory 402 according to the following instructions, and the processor 401 executes the application programs stored in the memory 402, so as to implement various functions as follows:
acquiring historical motion position information and current data to be detected of an object;
updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model;
and inputting the current data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object.
The specific implementation of each operation above may be referred to the previous embodiments, and will not be described herein.
According to one aspect of the present application, there is provided a computer program application or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions to cause the computer device to perform the methods provided in the various alternative implementations of the above embodiments.
It will be appreciated by those of ordinary skill in the art that all or part of the steps of the various methods of the above embodiments may be performed by a computer program, or by computer program control related hardware, which may be stored in a computer readable storage medium and loaded and executed by a processor.
To this end, the embodiments of the present application also provide a computer readable storage medium, where the computer readable storage medium stores a computer program, which when executed by a processor, can implement steps in any of the object detection methods provided in the embodiments of the present application. For example, the computer program may perform the steps of:
acquiring historical motion position information and current data to be detected of an object;
updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model;
and inputting the current data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object.
The specific implementation of each operation above may be referred to the previous embodiments, and will not be described herein.
The steps in any one of the target detection methods provided in the embodiments of the present application may be executed by the computer program stored in the storage medium, so that the beneficial effects that any one of the target detection methods provided in the embodiments of the present application may be achieved, which are detailed in the previous embodiments and are not described herein.
The foregoing has described in detail the methods, apparatuses, electronic devices and computer readable storage medium for object detection provided by the embodiments of the present application, and specific examples have been applied to illustrate the principles and embodiments of the present application, where the foregoing examples are provided to assist in understanding the methods and core ideas of the present application; meanwhile, those skilled in the art will have variations in the specific embodiments and application scope in light of the ideas of the present application, and the present description should not be construed as limiting the present application in view of the above.

Claims (10)

1. A method of detecting an object, comprising:
acquiring historical motion position information and current data to be detected of an object;
updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model;
and inputting the current data to be detected into the updated motion estimation model for processing, and outputting the current motion position information of the object.
2. The method of claim 1, wherein updating the predetermined motion estimation model using the historical motion location information to obtain an updated motion estimation model comprises:
Initializing model coefficient information of a preset motion estimation model;
updating a preset historical coefficient record table by utilizing the historical motion position information to obtain an updated historical coefficient record table;
calculating the model coefficient information by using the updated history coefficient record table to obtain a calculated model coefficient;
and updating the preset motion estimation model based on the calculated model coefficient to obtain an updated motion estimation model.
3. The method according to claim 2, wherein the model coefficient information includes a model term number and a model coefficient to be solved; the calculating the model coefficient information by using the updated history coefficient record table to obtain a calculated model coefficient comprises the following steps:
reading the historical model coefficient information in the updated historical coefficient record table;
and solving the model coefficient to be solved based on the model term number and the historical model coefficient information to obtain a calculated model coefficient.
4. A method according to claim 3, wherein the solving the model coefficient to be solved based on the model term number and the historical model coefficient information to obtain a calculated model coefficient comprises:
Screening out a target historical model coefficient from the historical model coefficient information according to the model item number;
and carrying out logic operation processing on the target historical model coefficient and the model coefficient to be solved to obtain a calculated model coefficient.
5. The method of claim 2, wherein said calculating said model coefficient information using said updated history coefficient record table, prior to obtaining calculated model coefficients, further comprises:
acquiring a sample set corresponding to the historical motion position information, wherein the sample set comprises a plurality of historical motion position information samples;
performing logic operation processing on the historical motion position information samples to obtain a plurality of model coefficients;
and constructing the preset history coefficient record table based on the model coefficients.
6. The method according to any one of claims 1-5, wherein said inputting the current data to be detected into the updated motion estimation model for processing, outputting current motion position information of the object, comprises:
determining updated model coefficients of the updated motion estimation model;
determining an operation strategy corresponding to the current data to be detected according to the updated model coefficient;
And calculating the current data to be detected based on the calculation strategy to obtain the current movement position information of the object.
7. The method of any of claims 1-5, wherein the obtaining historical motion location information of the subject comprises:
acquiring the number of historical moving images of an object;
and screening a plurality of pieces of preset detection motion position information based on the number of the historical motion images to obtain the historical motion position information of the object.
8. An object detection apparatus, comprising:
the acquisition unit is used for acquiring historical motion position information of the object and current data to be detected;
the updating unit is used for updating a preset motion estimation model by utilizing the historical motion position information to obtain an updated motion estimation model;
and the detection unit is used for inputting the current data to be detected into the updated motion estimation model for processing and outputting the current motion position information of the object.
9. An electronic device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, the processor implementing the steps in the object detection method according to any one of claims 1 to 7 when the computer program is executed.
10. A computer readable storage medium, characterized in that the computer readable storage medium stores a computer program which, when executed by a processor, implements the steps in the object detection method according to any one of claims 1 to 7.
CN202111630243.XA 2021-12-28 2021-12-28 Target detection method, target detection device, electronic equipment and computer readable storage medium Pending CN116416642A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111630243.XA CN116416642A (en) 2021-12-28 2021-12-28 Target detection method, target detection device, electronic equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111630243.XA CN116416642A (en) 2021-12-28 2021-12-28 Target detection method, target detection device, electronic equipment and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN116416642A true CN116416642A (en) 2023-07-11

Family

ID=87056419

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111630243.XA Pending CN116416642A (en) 2021-12-28 2021-12-28 Target detection method, target detection device, electronic equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN116416642A (en)

Similar Documents

Publication Publication Date Title
CN108898118B (en) Video data processing method, device and storage medium
CN110189246B (en) Image stylization generation method and device and electronic equipment
CN108876804B (en) Matting model training and image matting method, device and system and storage medium
CN109951595A (en) Intelligence adjusts method, apparatus, storage medium and the mobile terminal of screen intensity
CN107578453A (en) Compressed image processing method, apparatus, electronic equipment and computer-readable medium
CN109685797B (en) Bone point detection method, device, processing equipment and storage medium
CN105830429B (en) For handling the method and system for the video frame damaged by camera motion
CN109598250B (en) Feature extraction method, device, electronic equipment and computer readable medium
CN112132017B (en) Image processing method and device and electronic equipment
CN113284142B (en) Image detection method, image detection device, computer-readable storage medium and computer equipment
CN109215037A (en) Destination image partition method, device and terminal device
CN115294275A (en) Method and device for reconstructing three-dimensional model and computer readable storage medium
CN108875519B (en) Object detection method, device and system and storage medium
CN113838134B (en) Image key point detection method, device, terminal and storage medium
CN110166696A (en) Image pickup method, device, terminal device and computer readable storage medium
CN116416642A (en) Target detection method, target detection device, electronic equipment and computer readable storage medium
CN109242031B (en) Training method, using method, device and processing equipment of posture optimization model
CN113761965B (en) Motion capture method, motion capture device, electronic equipment and storage medium
CN111760276B (en) Game behavior control method, device, terminal, server and storage medium
CN116546304A (en) Parameter configuration method, device, equipment, storage medium and product
CN106296722B (en) Information processing method and electronic equipment
CN112712006A (en) Target picture snapshot method, system, medium and device
CN112948763A (en) Method and device for predicting quantity of component, electronic equipment and storage medium
CN111796928A (en) Terminal resource optimization method and device, storage medium and terminal equipment
CN115909489A (en) Model training method and device, electronic equipment and computer storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication