CN102074017B - Method and device for detecting and tracking barbell central point - Google Patents

Method and device for detecting and tracking barbell central point Download PDF

Info

Publication number
CN102074017B
CN102074017B CN2009102387361A CN200910238736A CN102074017B CN 102074017 B CN102074017 B CN 102074017B CN 2009102387361 A CN2009102387361 A CN 2009102387361A CN 200910238736 A CN200910238736 A CN 200910238736A CN 102074017 B CN102074017 B CN 102074017B
Authority
CN
China
Prior art keywords
barbell
point
matrix
central point
image
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.)
Expired - Fee Related
Application number
CN2009102387361A
Other languages
Chinese (zh)
Other versions
CN102074017A (en
Inventor
毋立芳
刘超
邓亚丽
武文斌
刘书琴
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing University of Technology
Original Assignee
Beijing University of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing University of Technology filed Critical Beijing University of Technology
Priority to CN2009102387361A priority Critical patent/CN102074017B/en
Publication of CN102074017A publication Critical patent/CN102074017A/en
Application granted granted Critical
Publication of CN102074017B publication Critical patent/CN102074017B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Analysis (AREA)

Abstract

The invention relates to a method and device for detecting and tracking a barbell central point. The method comprises the following steps of: extracting a barbell central point in a first image frame; making a rhombic matrix for all image frames on the basis of the barbell central point, recording the position of each matrix point and setting the weight of each matrix point; carrying out LK pyramid optical-flow method tracking on a central point of the rhombic matrix in every adjacent two image frames to obtain a tracking point and carrying out optical-flow method tracking on the rest multiple matrix dots to obtain respective tracking points; removing the wrong tracking point and removing a tracking point symmetric to the tracking point with respect to a rhombic central point; and averaging the weight of all the tracking points after adding to obtain a smooth tracking vector of the barbell central point and confirming the tracked barbell central point, wherein the weight of all the tracking points is the weight of the corresponding matrix dots. The method provided by the invention can realize the detection and tracking of the barbell central point and effectively inhibit a tracking error brought by a trailing phenomenon.

Description

The method and apparatus that a kind of barbell central point detects and follows the tracks of
Technical field
The present invention relates to field of video processing, be specifically related to the method and apparatus that a kind of barbell central point detects and follows the tracks of.
Background technology
Therefore at the sports analysis field, the sportsman can strengthen training burden usually in order to improve games results, tends to the sportsman is damaged and increase training strength inadequately, is necessary to study science, quantitative athletic training system.
Weight lifting is the traditionally strong event of China, has up to the present obtained 24 pieces of Olympic Games gold medals.Can the quality of weightlifting diagnostic techniques is decision sportsman final games results directly, therefore, be problems of a current weight lifting scientific research urgent need solution for sportsman and trainer provide effectively practical Motion Technology quick diagnosis means.The weight lifting diagnosis of technique mainly was divided into etiologic diagnosis and quantitative Diagnosis dual mode in the past.Etiologic diagnosis is mainly accomplished through the manual work video of watching training, and this mode is more directly perceived, but lacks quantizating index for coach's reference, can't satisfy the demand of sentific training.Quantitative Diagnosis is mainly resolved through manual work and is carried out, and often could be the report of trainer's feedback test in test after several days, because feedback speed is too slow, scientific research test effect is had a greatly reduced quality.
In order to instruct athletic training effectively; Just must analyze athletic movement posture or movement locus; Find out the effective ways that improve games results; With weight training exercises is example, and experienced coach can pinpoint the problems according to barbell central motion track, thereby corrects athletic incorrect weight lifting posture.In the weight training exercises the earliest, bind a writing brush at an end of barbell, the track of barbell is along with the writing brush that barbell moves in the above paints on paper.At present, can carry out the tracking of barbell central point movement locus according to video; Classical motion tracking algorithm comprises block matching algorithm and LK pyramid optical flow method.
The piece coupling is mated according to piece, is difficult to extract the rotation parameter of barbell, and the movable information of more barbell so just can not be provided to the coach.LK pyramid optical flow method and BMA come ratio, have had to improve, and have solved the problem of barbell rotation, but still because long reason of the time shutter of weight lifting video when shooting with video-corder exists some hangover and motion blur phenomenons.
Such image can interfere with the tracking accuracy of piece coupling and optical flow method, thereby can produce some errors.Time shutter of revising video camera is the generation that can revise the image recording conditions of streaking; But so do the viewing effect that can have a strong impact on the weight lifting spectators; Though removed conditions of streaking because shorten the time shutter, but drawn the bad shortcoming of image continuity, can make spectators feel that image is always discontinuous; One jumps, and is impracticable so do like this.
Summary of the invention
The technical matters that the present invention will solve provides the method and apparatus that a kind of barbell central point detects and follows the tracks of, and under the situation of not changing the video time shutter, improves the tracking effect to barbell central motion track.
In order to address the above problem, the invention provides the method that a kind of barbell central point detects and follows the tracks of, comprising:
Barbell central point in the video of A, extraction input in first picture frame;
B, for each picture frame in the said video, set out by the barbell central point and to do a rhombus matrix; Write down the position of each matrix dot in this rhombus matrix, and the weight of each matrix dot is set; For each two adjacent picture frame; The central point of the rhombus matrix in these two picture frames is carried out LK pyramid optical flow method obtain its trace point, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of and obtain these all the other a plurality of matrix dots trace point separately; Remove and do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix; With average after the weight addition of each trace point, obtain the level and smooth tracking vector of barbell central point, confirm the barbell central point that traces into according to said barbell central point and this level and smooth tracking vector; The weight of each trace point is the weight of its corresponding matrix dot.
Further, said step B specifically comprises:
B1, in current image frame, set out by said barbell central point and to do a rhombus matrix, comprise several matrix dots; The central moment lattice point of this rhombus matrix is said barbell central point; Write down the position of each matrix dot, give different weights each said matrix dot;
Current image frame and adjacent next picture frame are carried out the following step:
B2, said central moment lattice point is done the LK pyramid optical flow method of two interframe, obtain the trace point of central moment lattice point;
B3, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of, obtain the trace point of these all the other a plurality of matrix dots;
B4, in the rhombus matrix, remove and do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix;
B5, with after the weight addition of each trace point according to its corresponding matrix dot, do on average again, obtain the level and smooth tracking vector of barbell central point; Confirm the barbell central point that traces into according to the barbell central point in the current image frame and this level and smooth tracking vector;
B6, with the barbell central point of the said barbell central point that traces into as said next picture frame, said next picture frame as current image frame, is returned step B1 then.
Further, said step B2 specifically comprises:
31, picture frame is carried out pyramid transform, do optical flow method, obtain the motion vector V of said central moment lattice point at the pyramid of top layer;
32, window center is moved to the motion vector V place that has just calculated, iterative computation motion vector V is till convergence;
33, import convergent motion vector V into next tomographic image pyramid;
34, judge whether image, if then find optimal match point as trace point into the image pyramid bottom; Otherwise return step 32.
Further, among the said step B1, give different weights to each said matrix dot and specifically be meant:
To the matrix dot of first Delta Region of rhombus matrix dot, be provided with than the big weight of matrix dot in second Delta Region of this rhombus matrix.
Further, among the said step B1, set out by said barbell central point and to do a rhombus matrix and specifically be meant:
Set up the rhombus matrix of 9 points that launched to obtain by said barbell central point, the horizontal ordinate of said barbell central point is a, and ordinate is b; The coordinate of other eight points is respectively in the rhombus matrix:
First horizontal ordinate is a, and ordinate is b+15;
Second horizontal ordinate is a, and ordinate is b-15;
Horizontal ordinate thirdly is a+15, and ordinate is b;
The 4th horizontal ordinate is a-15, and ordinate is b;
The 5th horizontal ordinate is a+7, and ordinate is b+7;
The 6th horizontal ordinate is a+7, and ordinate is b-7;
The 7th horizontal ordinate is a-7, and ordinate is b+7;
The 8th horizontal ordinate is a-7, and ordinate is b-7;
Unit is a pixel;
Giving different weights to each said matrix dot specifically is meant:
With said central point, thirdly be made as 5, the second weight and be made as the weight that weight that 0, the first weight is made as and at 10, the five at the 7th is made as and at 7, the six at the 8th and be made as 2 with the 4th weight.
Further, said steps A specifically comprises:
A1, input picture frame; First picture frame to input carries out the following step;
A2, carry out colour according to preset color and cut apart, qualified part is kept;
A3, the image that filters out after colour cut apart carries out the several times corrosion and several times expand; With the approximate location zone of the zone of satisfying the predetermined constraints condition as the barbell place; Said constraint condition comprises the scope of predetermined zone length breadth ratio and area;
Rim detection is carried out in A4, the said barbell approximate location zone that in the original image frame, the front is obtained;
A5, carry out Hough transformation and seek out the barbell central point in this picture frame.
Further, said steps A 2 specifically comprises:
A21, first picture frame is carried out the conversion of RGB color space to the hsv color space;
A22, each pixel in the picture frame is screened, the H value is satisfied the pixel of the H value scope in the preset hsv color model, the effective value of this pixel is changed to 1, otherwise is changed to 0 according to the H value;
A23, output effective value are 1 pixel, obtain the image that filters out after colour is cut apart.
Further, said steps A 4 specifically comprises:
A41, each pixel in the said barbell approximate location zone is obtained its gray-scale value according to following formula, obtain the gray level image in said barbell approximate location zone;
A42, said gray level image is carried out boundary operation;
A43, the gray level image through boundary operation is being done binaryzation; Be set to 255 greater than the gray-scale value threshold value and gray values of pixel points that be included in the said barbell approximate location zone, less than said gray-scale value threshold value or not the gray-scale value of the point in said barbell approximate location zone be set to 0.
Further, said gray-scale value threshold value is:
Figure G2009102387361D00051
The device that the present invention also provides a kind of barbell central point to detect and follow the tracks of comprises:
Image input module is used to receive the video of input, promptly continuous some picture frames;
Detection module is used for detecting the barbell central point in first picture frame of said video;
Tracking module is used in each picture frame of said video, following the tracks of said barbell central point;
Said tracking module specifically comprises:
Matrix generates submodule, is used for for each picture frame, is set out by the barbell central point and does a rhombus matrix; Write down the position of each matrix dot in this rhombus matrix, and the weight of each matrix dot is set;
The optical flow method submodule; Be used for for each two adjacent picture frame; The central point of the rhombus matrix in these two picture frames is carried out LK pyramid optical flow method obtain its trace point, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of and obtain these all the other a plurality of matrix dots trace point separately;
Filter submodule, in said rhombus matrix, remove and do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix;
The vector submodule with average after the weight addition of each trace point, obtains the level and smooth tracking vector of barbell central point, confirms the barbell central point that traces into according to said barbell central point and this level and smooth tracking vector; The weight of each trace point is the weight of its corresponding matrix dot.
Technical scheme of the present invention can be carried out automatic recognition and tracking to barbell central point in the weightlifting.At barbell central point identification division; Used a kind of comparatively robust; Adaptability hsv color model is preferably carried out color and is cut apart; Obtained the approximate location zone of barbell, then used the algorithm based on the direction rim detection that the barbell center of circle is extracted, this algorithm is superior to the present Hough conversion that generally is used.Aspect target following, technical scheme of the present invention has proposed a kind of level and smooth tracking scheme based on LK pyramid optical flow method comes the central point of barbell is smoothly followed the tracks of, and can realize the tracking of barbell, and effectively suppress the tracking error that conditions of streaking brings.
Description of drawings
Fig. 1 is the schematic flow sheet that carries out the step of barbell central point detection among the embodiment one;
Fig. 2 is the schematic flow sheet of the step of carrying out colour among the embodiment one and cutting apart;
The process flow diagram of Fig. 3 for carrying out the HOUGH conversion among the embodiment one;
Fig. 4 is for carrying out the process flow diagram of LK pyramid optical flow method among the embodiment one;
Fig. 5 is the synoptic diagram of rhombus matrix among the embodiment one;
Fig. 6 is for carrying out the process flow diagram that the barbell central point is followed the tracks of among the embodiment one.
Embodiment
To combine accompanying drawing and embodiment that technical scheme of the present invention is explained in more detail below.
Embodiment one, and the method that a kind of barbell central point detects and follows the tracks of comprises two big steps:
A, first picture frame in the video of input is carried out barbell and cuts apart; Promptly detect the barbell central point in (extraction) each picture frame; Among this paper; Barbell in the picture frame refers to the disc facing to that end of camera lens, and barbell central point as herein described refers to the center of circle of barbell facing to the disc of that end of camera lens.
For barbell central point accurate localization is come out, said steps A specifically comprises:
Input video; Said video is a plurality of continuous images frames;
First picture frame in the said video carries out following steps:
Earlier barbell is carried out coarse positioning, remove most of background noise;
Result according to coarse positioning confirms the barbell central point to Hough (Hough) conversion that it carries out the localized area again, thereby reaches pinpoint effect.
B, in each picture frame, carry out the barbell central point and follow the tracks of;
Because the weightlifting video is time shutter and barbell rotation when taking, the tracking results of block matching algorithm and LK pyramid optical flow method is not ideal; In the present embodiment, proposed to realize following the tracks of, for the motion tracking track of drawing barbell provides good guarantee based on the multiple spot smoothing error tracking scheme of LK pyramid optical flow method.
Step B specifically comprises:
For each picture frame in the said video, set out by the barbell central point and to do a rhombus matrix; Write down the position of each matrix dot in this rhombus matrix, and the weight of each matrix dot is set; For each two adjacent picture frame; The central point of the rhombus matrix in these two picture frames is carried out LK pyramid optical flow method obtain its trace point, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of and obtain these all the other a plurality of matrix dots trace point separately; Remove and obviously do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix; With average after the weight addition of each trace point, obtain the level and smooth tracking vector of barbell central point, confirm the barbell central point that traces into according to said barbell central point and this level and smooth tracking vector; The weight of each trace point is the weight of its corresponding matrix dot.
To introduce two steps respectively in detail below.
Follow the tracks of the movement locus of whole barbell, will at first confirm barbell central point in the picture frame, the coupling of utilizing said barbell central point to carry out each picture frame is again followed the tracks of.Because the background in the weight lifting competition is non-fixed background, therefore there is not available background information, can't obtain the moving region with the method that background subtracts, can only utilize the characteristic of barbell self to detect; Consider that barbell and sportsman are taken by close shot all the time; It promptly is the main motion object in the video image; And the barbell color of standard is several kinds of fixing colors; The barbell-shaped of side is circular, so in the present embodiment, utilizes the CF characteristic of barbell to detect the central point of barbell automatically.
Steps A is as shown in Figure 1 in the present embodiment, specifically comprises:
A1, input picture frame; First picture frame to input carries out the following step;
A2, carry out colour according to preset color and cut apart, qualified part is kept; This step is that rough segmentation is cut;
A3, the image that filters out after colour cut apart carry out morphology and handle; Utilize constraint condition and---such as length breadth ratio and area size---confirm the approximate location zone at barbell place;
Rim detection is carried out in A4, the said barbell approximate location zone that in the original image frame, the front is obtained;
A5, carry out Hough transformation and seek out the barbell central point in this picture frame.
Describe steps A 2 below in detail; Introduce earlier in color and cut apart in the field color model hsv color model commonly used, the color that this model will be used to barbell is in the present embodiment cut apart.
The hsv color space is the color space of a column, and this color model makes it become the chrominance space commonly used of image segmentation, rim detection, color clustering and graphical analysis and understanding owing to it and in the matched well of human-eye visual characteristic.The picture of the bmp form of generally using under the windows platform is now all arranged with rgb format, therefore must the image transitions of rgb format commonly used be arrived under the hsv color space, and then processes.
RGB to the conversion formula of HSV is:
Figure G2009102387361D00081
H=h*60
V=max (R, G, B) (formula 1.1)
S=mm/V(mm=max(R,G,B)-min(R,G,B))
r=(V-r)/mm?g=(V-r)/mmb=(V-r)/mm
In the HSV space, the combination of many groups RGB that one group of HVS is corresponding.
Colour need be asked for the H value of barbell before cutting apart earlier, H value be again come according to the color of barbell fixed, below just introduction play the Standard Colors of barbell.In formal competition, adopt the standard barbell, the disc color of Different Weight is different, 25 kilograms (redness); 20 kilograms (blueness), 15 kilograms (yellow); 10 kilograms (green); 5 kilograms (white); 2.5 kilogram (redness); 2 kilograms (blueness); 1.5 kilogram (yellow); 1.0 kilogram (green) and 0.5 kilogram (white).Corresponding H (tone Hue) value of these colors is respectively red (0); Yellow (60); Green (120); Blue (240).Utilize different H values to distinguish the color of barbell in the present embodiment, thereby can under complex background, find the accurate position of barbell.
Therefore with the barbell color is that blueness is an example, and what following of this situation will detect is exactly the center of barbell blue portion, and what will split in rough segmentation jog section is exactly blue barbell zone.
In the present embodiment, the span of blue color in the hsv color space of barbell is: 200<H<240.Though the brightness of each image is not quite alike; But blue H value is floated in this scope all the time by a small margin; Change the formula of HSV according to the RGB of front; Original picture frame to input carries out color conversion, and according to the span of above-mentioned H this original picture frame is retrained, and in this original image frame, finds out the pixel that the H value satisfies above-mentioned span.
In a kind of embodiment of present embodiment, said steps A 2 is as shown in Figure 2, specifically can comprise:
A21, first picture frame is carried out the conversion of RGB color space to the hsv color space;
A22, according to the H value each pixel in the picture frame being screened, is the pixel that the H value is satisfied the H value scope (200<H<240) in the preset hsv color model in the present embodiment, the effective value of this pixel is changed to 1, otherwise is changed to 0;
The pixel that A23, output filter out obtains the image that filters out after colour is cut apart; Be that the output effective value is 1 pixel in the present embodiment.
Certainly, do not get rid of other implementation in the practical application, such as: the effective value that will satisfy the pixel of H value scope is changed to 0, is output as 0 pixel; This effective value can but be not limited to a zone bit.
After the process colour is cut apart; Basically can intactly be partitioned into the barbell zone, but the subregion on the barbell, especially barbell edge and center possibly " dug up "; And cut apart the back in color and also stayed many noise points above the entire image, this will bring unnecessary interference to follow-up.Therefore will carry out simple morphology to segmentation result handles; The computing of just corroding and expanding, doing one like this is can play the connected domain that makes the image after cutting apart more significantly to act on, the 2nd, also can play the effect of simple filter; Filter the noise point in the image; Thereby as far as possible preselected area is reverted to real barbell size, and remove less interference as far as possible, for next step processing is laid a solid foundation.
In the said steps A 3 of present embodiment, adopt the mode of corrosion and expansion to carry out the morphology processing, thereby reach denoising and the effect that strengthens connected domain.The principle that to introduce corrosion below and expand.
Corrosion specifically is meant: obtain Sx behind the bar structure element S translation x, if Sx is contained in X, then write down this x point, all set of satisfying the x point composition of above-mentioned condition are called X by the result of S corrosion (Erosion).Be formulated as: XS = { x | Sx ⋐ X }
X is that all make the still set of the x in X behind the S translation x with the result of S corrosion.In other words, corrode the set that set that X obtains is S origin position of S when being included among the X fully with S.
Corroding method is, takes the initial point of S and the point on the X to contrast singly, if the institute on the S has a few all in the scope of X, and the then some reservation of the initial point of S correspondence, otherwise this point is removed; The right is the result after the corrosion.Can find out that it and lacks than the point that X comprises still in the scope of original X, just as the X one deck that has been corroded.
Origin that it should be noted that structural element is very important, if structure element shape invariance, and origin changes, then the result of erosion operation is different.When the initial point of structural element is in the middle of structural element, then erode the boundary member of target in the image.So the effect of corrosion is to eliminate the object boundary point.Corrosion can be removed the object (burr, small embossment) less than structural element; If between two objects tiny connection is arranged, when structural element is enough big, can be separately through erosion operation with two objects.
Said expansion is meant: obtaining Sx behind the bar structure element S translation x, is not empty if Sx and X intersect, and writes down this x point, and all set of satisfying the x point composition of above-mentioned condition are called X by the result of S expansion ((dilation)).Be formulated as: X ⊕ S = { x | Sx ∪ X ≠ } (formula 1.2)
The result who expands can make target become big.
The method that expands is, takes the initial point of S and the point on the X to contrast singly, if there is a point to drop in the scope of X on the S, the point that then initial point of S is corresponding is an image just; The right is the result after expanding.Can find out that it comprises all scopes of X, just as X expanded one the circle.Equally, the origin of structural element is different, and the result of dilation operation is the different translation that can realize image with corrosion and dilation operation.If when the self-defined structure element, select not a point at initial point as structural element, the picture shape that then obtains has no change, and just the position has taken place to move.
In the present embodiment, carry out the morphology processing and be meant: the image that filters out after colour is cut apart carries out the several times corrosion and several times expand, and such as corrosion 3 times, expands 4 times.
After the morphology processing; The little noise point of some of original image or disappeared, or become the big noise point of very easy resolution, however these big noise points the area size of connected domain with all obviously be different from above the length breadth ratio by the barbell that coarse positioning comes out regional.Calculate the area and the length breadth ratio of each connected domain respectively, and alternative area is retrained, finally obtain the approximate location zone of barbell according to the domain knowledge of weight lifting.
In the present embodiment, according to the domain knowledge of weight lifting alternative area is retrained and to be meant and to filter out the zone of satisfying following two conditions, keep each pixel in this zone:
Condition one, length breadth ratio>0.9, and length breadth ratio<1.1;
Condition two, area>10*10 pixel, and area<100*100 pixel;
Can find out the approximate location zone of barbell after the screening, thereby for following accurate location good condition is provided, if because fixed good of coarse positioning, will be the accurate a lot of background interference noise of location removal.
After having obtained barbell approximate location zone; Pass resulting this barbell approximate location zone back former figure; And rim detection is done in this barbell approximate location zone in former figure; Do like this for next step carries out the Hough conversion to the barbell central point and extract the barbell central point and prepare, the image that is used to do the Hough conversion is if edge image, with the central point that better extracts barbell through the edge contour of barbell.
Below, introduce the notion and the ultimate principle of edge extracting earlier.At first first talking about, what is an edge of image.Edge of image is meant the set of the pixel that its surrounding pixel gray scale single order changes, and is one of the most basic characteristic of image, and it extensively is present between object and background, object and object, primitive and the primitive.Obtain edge image and at first will the original colorful image gray processing be carried out edge extracting then in the gray scale territory, the image binaryzation that at last edge extracting is come out imports in the last Hough computing.
In the present embodiment, said steps A 4 comprised for three steps:
A41, gray scale computing;
A42, boundary operation;
A43, binaryzation.
To specifically introduce this three step respectively below:
Steps A 41, image is carried out the gray scale computing;
The gray scale computing is carried out the gray scale computing with target area image exactly, and soon coloured image is mapped in 256 different grey levels through formula and goes, and calculates according to the most basic gray-scale value formula 1.3 of asking exactly below:
Gray-scale value=(R+G+B)/3 (formula 1.3)
In the present embodiment; What adopt is the greyscale transformation formula of the RGB three look mean values of classics; Each pixel in the said barbell approximate location zone is obtained its gray-scale value according to following formula; Obtain the gray level image in said barbell approximate location zone, be mapped in the gray scale territory, obtain a gray level image by resulting said barbell approximate location zone, front.
Steps A 42, said gray level image is carried out boundary operation;
Carry out boundary operation in the face of the gray level image that obtains down.The traditional image edge detection algorithm extracts marginal information mostly from the high fdrequency component of image, differentiating is the main means of rim detection and extraction.Usually adopt two types and differentiate, i.e. first order differential computing (claiming gradient operator again) serves as typical case's representative with Robert operator, Sobel operator, PreWitt operator etc.; Another kind of then is to be the second-order differential computing of representative with the Laplacian operator.(x, y), gradient operator is in that (x, gradient vector y) can be expressed as to continuous function f ▿ f ( x , y ) = [ ∂ f ∂ x , ∂ f ∂ y ] , The Laplacian operator is in that (x, gradient vector y) can be expressed as ▿ 2 f ( x , y ) = [ ∂ 2 f ∂ x 2 , ∂ 2 f ∂ y 2 ] .
And in the present embodiment Robert operator, Sobel operator, Laplacian operator are tested; From the comparison of various boundary operators, choose the more satisfactory operator of edge effect; Finally adopted for circular image effect PreWitt operator preferably; With it said gray level image is carried out boundary operation again, thereby can more conveniently obtain the barbell edge, and definite center of circle.PreWitt operator nuclear is:
- 1 - 1 - 1 0 0 0 1 1 1 - 1 0 1 - 1 0 1 - 1 0 1
Steps A 43, edge image binaryzation;
Be exactly to carry out binary conversion treatment to gray level image at last, for the Hough conversion is laid the groundwork through boundary operation.The binaryzation of image is exactly with on 256 grey scale mapping to 0 of image and 255 two grey levels through given gray-scale value threshold value.The gray level image that is about to 256 brightness degrees is chosen to obtain to reflect the binary image of integral image and local feature through suitable gray-scale value threshold values.If certain certain objects has the gray-scale value of uniformity in inside, and it is in a homogeneous background with other grade gray-scale values, uses threshold method just can obtain reasonable segmentation effect.If object with the difference performance (different such as texture) not on gray-scale value of background, can convert this distinction into the difference of gray scale, utilize the threshold values selecting technology to cut apart this image then.Dynamic adjustments gray-scale value threshold values realizes that the binaryzation of image can dynamic observe the concrete outcome of its split image, has strengthened the universality of this algorithm.
In the present embodiment, be automatic average threshold value to the gray-scale value threshold value of choosing when doing binaryzation through the gray level image of boundary operation, the gray-scale value threshold value can change according to the difference of image automatically like this, thereby has increased the robustness and the universality of this algorithm.The computing formula of gray-scale value threshold value is a formula 1.4:
Figure G2009102387361D00131
(formula 1.4)
In the example of present embodiment; The last gray-scale value threshold value of being calculated is 59.959766; Be set to 255 greater than said gray-scale value threshold value and gray values of pixel points that be included in the said barbell approximate location zone; Less than said gray-scale value threshold value or not the gray-scale value of the point in said barbell approximate location zone be set to 0, just accomplished the binaryzation under the color constraint.
At last, can also further carry out the connected domain constraint to the image after the binaryzation; After image had been done binaryzation, still there was the noise point of some backgrounds outside, the edge of barbell, and these points still more or less have influence on the extraction to the barbell central point.Can be known by preceding text, use the expansion principle in the morphology when barbell in the image is carried out coarse positioning for the first time, the UNICOM zone that surface expansion obtains before can further utilizing now retrains, the pixel that the filtering barbell is outer.
According to the principle that expands, the back connected domain that expands is certainly greater than real barbell size.Therefore can utilize this point to remove the outer noise point of most of barbell, for the central point that extracts barbell more accurately provides better pictures.
In the said steps A 5 of present embodiment, adopt the HOUGH change detection center of circle; Can detect the parametric line in the image because of the Hough conversion when using the Hough conversion, and describe out with parametric equation.Its major advantage is that the ability of detection curve receives the influence of interference such as the curve point of interruption less, therefore selects for use the Hough conversion to do the extraction in the center of circle.
The standard Hough conversion once of following first brief account.
What the Hough conversion realized is a kind of mapping from the image space to the parameter space.It detects problem with the cluster that edge feature information complicated in the image space is converted in the parameter space.If the contour curve in the image meets certain analytical expression, with several variablees in this analytical expression and the relation between the variable, can constitute a parameter space so.Characteristic curve in the original image, the concentrated area is for a point of parameter space relatively.So, the information in extracting parameter space has just correspondingly obtained the information of virgin curve exactly.
Because handled object (barbell) all is circular in the present embodiment, therefore only introduce the method for utilizing the Hough conversion to extract circle.
The equation of locus of circle is: (x-a) 2+ (y-b) 2=r 2X wherein, y is a variable.Constant a, b, r represent horizontal stroke, ordinate and the circular radius in the circular center of circle respectively.According to the basic thought of Hough conversion, can select a, b, r come the constructing variable coordinate system.This parameter coordinate system is three-dimensional.A wherein, b has constituted center of circle parameter plane, and the size of this parameter plane should be consistent with the plane sizes of original image; One dimension is the radius parameter that is made up of r in addition.
In the parameter coordinate system, x, y are constant, and a, b are variablees.Get on the original image (coordinate is mapped to it in parameter coordinate system for (x0, y0)), just can obtain a lot of circles more arbitrarily.These circles have constituted the cone at a no end.If the institute in the original image has a few and all does above-mentioned processing, in the three-dimensional parameter coordinate system, just can obtain much such cones.(a, b is r) just corresponding to circle in the original image and these several cones are through that maximum points.Based on this Several Parameters, just can write out round analytical expression accurately.
In the present embodiment, use standard Hough conversion to handle image, because the circular radius size of known barbell is probably between 50 to 60, so the realization of Hough conversion just can be simplified operation time greatly.Use radius to carry out the Hough conversion as the circle circulation between the 50-60, the maximal value of a Hough conversion of each radius calculation is further extracted the maximal value in the maximal value that all radiuscopes calculate then, and the corresponding center of circle of this maximal value is definite thereupon with radius r.The central coordinate of circle that the result who carries out the Hough conversion obtains barbell is (466,449).
The process flow diagram that carries out the HOUGH conversion in the steps A 5 is as shown in Figure 3, comprising:
A51, initialization HOUGH matrix A (x, y, r)=0;
If A52 is scanned through pixels all in the image after the rim detection, then finish; Otherwise not scanned pixel im in the scan image;
(i j) is frontier point, then carries out A54 if A53 is im; Otherwise return A52;
A54, make (x-i) 2+ (y-j) 2=r 2
A55, make A (x, y, r)=(x, y r)+1, return A52 to A.
What step B carried out in the present embodiment is motion tracking.
According to steps A, can obtain the barbell central point accurately, will carry out tracking below to said barbell central point.
In order under the situation of not changing the video time shutter, to improve tracking effect; A kind of level and smooth LK pyramid of multiple spot optical flow tracking scheme based on LK pyramid optical flow method has been proposed in the present embodiment; Introduce the scheme of image pyramid; And with the logotype of LK optical flow method, can be good at removing the inaccurate situation of tracking that conditions of streaking brings.
Said image pyramid can be good at solving excessive and the problem that tracking target that bring is lost of motion vector.With the length and width dimension shrinks of piece image half the (thereby the resolution of image is condensed to original 1/4), and make dwindle before and after two width of cloth images keep to a certain degree " similar " as much as possible; Repeat this process, up to image finally is condensed to a bit, the sequence image that obtains thus is called as image pyramid (image pyramid), and each width of cloth in the said sequence image is also referred to as one deck of pyramid diagram picture.When being transformed into the pyramid image sequence to original image, to have used Gaussian convolution to examine image is carried out upward filtration and obtains, convolution formula 1.6 is following:
I L ( x , y ) = 1 4 I L - 1 ( 2 x , 2 y ) +
1 8 ( I L - 1 ( 2 x - 1,2 y ) + I L - 1 ( 2 x + 1,2 y ) + I L - 1 ( 2 x , 2 y - 1 ) + I L - 1 ( 2 x , 2 y + 1 ) ) +
1 16 ( I L - 1 ( 2 x - 1,2 y - 1 ) + I L - 1 ( 2 x + 1,2 y + 1 ) + I L - 1 ( 2 x - 1,2 y + 1 ) + I L - 1 ( 2 x + 1,2 y - 1 ) )
(formula 1.6)
In the present embodiment; When the barbell central point is carried out the tracking of LK pyramid optical flow method, earlier picture frame is carried out pyramid transform, in the image of the pyramidal the superiors, do the tracking processing of optical flow method; Downward again one deck pyramid is propagated after obtaining motion vector; And the ratio of modification motion vector, final, the optimal match point that in the undermost image of pyramid, finds is the trace point that LK pyramid optical flow method draws.
The flow process of carrying out LK pyramid optical flow method in the present embodiment is as shown in Figure 4, comprising:
41, picture frame is carried out pyramid transform, do optical flow method, obtain the motion vector V of said central moment lattice point at the pyramid of top layer;
42, window center is moved to the motion vector V place that has just calculated, iterative computation motion vector V is till convergence;
43, import convergent motion vector V into next tomographic image pyramid;
44, judge whether image,, obtain the motion vector that to follow the tracks of if the optimal match point that then finds is the trace point that LK pyramid optical flow method draws into the image pyramid bottom; Otherwise return step 42.
The trace point result who utilizes LK pyramid optical flow method to calculate wants Billy more accurate with the trace point result that the macro block tracing calculates; And can solve the rotation problem of barbell; Because optical flow method is point-to-point matching algorithm, and the piece coupling is the matching algorithm between macro block and the macro block.Yet; In weight lifting competition, people are in order to make record weight lifting competition video more coherent, often the time shutter of video camera transfer long; Doing like this can make continuous videos when being divided into single-frame images; Motion blur and hangover ghost phenomena in single-frame images, occur, this phenomenon can seriously influence the degree of accuracy that barbell is followed the tracks of, and this conditions of streaking often human eye all is difficult to accurately orient barbell central point accurately; And the realization of the level and smooth tracking scheme of multiple spot in the present embodiment is based on the LK pyramid optical flow method that realizes the front; But LK pyramid optical flow method is to the tracking of single unique point; If there is the phenomenon of fuzzy hangover in image; The tracking of a point will certainly be affected, and in order to address this problem, present embodiment uses above the barbell other and puts and do auxiliary trace point and come the tracking error that smooth motion is fuzzy and the hangover ghost brings.
At first set up a rhombus matrix that is launched to obtain by aforementioned barbell central point, suppose to set up the rhombus matrix of one 9 points, in this rhombus matrix, the position of each p1~p8 and barbell central point p0 relation is as shown in Figure 5:
The coordinate of said barbell central point p0 be (a, b), as a point in the rhombus matrix, its horizontal ordinate is a with this barbell central point, ordinate is b; The horizontal ordinate of rhombus matrix mid point p1 is a, and ordinate is b+15, and the horizontal ordinate of rhombus matrix mid point p2 is a, and ordinate is b-15; The horizontal ordinate of rhombus matrix mid point p3 is a+15, and ordinate is b, and the horizontal ordinate of rhombus matrix mid point p4 is a-15; Ordinate is b, and the horizontal ordinate of rhombus matrix mid point p5 is a+7, and ordinate is b+7; The horizontal ordinate of rhombus matrix mid point p6 is a+7, and ordinate is b-7, and the horizontal ordinate of rhombus matrix mid point p7 is a-7; Ordinate is b+7, and the horizontal ordinate of rhombus matrix mid point p8 is a-7, and ordinate is b-7.Above unit is pixel.
When following the tracks of, give different weights for each point in the said rhombus matrix, the reason of doing like this is the domain knowledge according to weight lifting competition, barbell by on the speed carried be the speed apparently higher than other time, be the most difficult part of following the tracks of in the weight lifting process.Therefore, in the present embodiment, with the more weight of point of giving first Delta Region of rhombus matrix dot; Because the conditions of streaking of barbell central point mainly is the point that has influence on below the barbell central point in the last process of carrying; The lower half circle that is barbell is more unintelligible, if level and smooth thereby the tracking results that increases the clear area is carried out the influence of image and the summation that converts, just can overcome the drawback of streaking; Same reason is composed the littler weight in second Delta Region of giving the rhombus matrix.
In the present embodiment, the weight of each point in the matrix of rhombus described in Fig. 5 is provided with as follows:
The weight of a p0, p3 and p4 is made as 5, and the weight of some p2 is made as 0, and the weight of some p1 is made as 10, and some p5 is made as 7 with the weight of some p7, and some p6 is made as 2 with the weight of some p8.
In the present embodiment, add repeatedly to test according to domain knowledge to the weight of each point configuration to obtain.The weights that obtain by this method prove through experiment has certain robustness and universality.During practical application, also do not get rid of count more than 9 situation of rhombus matrix, weight can be provided with according to mentioned above principle and experiment.
In obtaining said rhombus matrix behind the motion vector of the consecutive frame of each point; Multiply by addition after the weight of this point respectively; And then count sum divided by the weight of rhombus matrix dot; The motion vector that obtains at last is the motion vector after the level and smooth track algorithm of the multiple spot of LK pyramid optical flow method calculates, the i.e. motion vector of barbell central point.Computing formula is as 1.9:
Vector ( x , y ) = Σ Point ( x , y ) * Weight Σ Weight (formula 1.9)
In the present embodiment, the idiographic flow of said step B is as shown in Figure 6, comprising:
61, in current image frame, set out by said barbell central point and to do a rhombus matrix, comprise several matrix dots; The central moment lattice point of this rhombus matrix is said barbell central point; Write down the position of each matrix dot; According to the difference of the matrix dot position in the rhombus matrix, each said matrix dot is provided with different weights; If counting of rhombus matrix confirms that weight is set can only be provided with once.
Current image frame and adjacent next picture frame are carried out the following step:
62, said central moment lattice point is done the LK pyramid optical flow method between two picture frames, obtain the trace point of central moment lattice point, specific practice is seen the description of above-mentioned steps 41~44;
63, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method and follow the tracks of, obtain the trace point of these all the other a plurality of matrix dots;
64, in the rhombus matrix, remove the obvious correct trace point of not following the tracks of; Be that obviously big than other trace point trace point of motion vector and move distance is (such as motion vector and move distance respectively greater than motion vector threshold value and move distance threshold value; These two threshold values can rule of thumb or be tested and are provided with), and remove the trace point of this trace point about the central point of rhombus matrix;
65, with after the weight addition of each trace point according to its corresponding matrix dot, do again on average, obtain the level and smooth tracking vector of barbell central point, confirm the barbell central point that traces into according to the barbell central point in the current image frame and this level and smooth tracking vector;
66, with the barbell central point of the said barbell central point that traces into as said next picture frame; Said next picture frame as current image frame, is returned step 61 then, that is: in next picture frame, regenerate the rhombus matrix; The line trace of going forward side by side all has been processed up to picture frame.
For the video of input, first picture frame of this video be the current image frame of first time during execution in step 61, to first, second picture frame carry out follow-up tracking step; After follow the tracks of accomplishing, again with second picture frame as current image frame, execution in step 61 is carried out subsequent step to second, the 3rd picture frame then; ...; By that analogy.
Through the method that the level and smooth track algorithm of multiple spot of LK pyramid optical flow method is followed the tracks of, the noise spot in the tracing process is removed in the smoothly influence of motion blur and conditions of streaking in the weight lifting image, guarantees the degree of accuracy of following the tracks of to the full extent.Originally when not using multiple spot LK pyramid optical flow method, can receive the influence of motion blur and hangover to the tracking of barbell central point, finally lose tracking target.Yet after using multiple spot LK pyramid optical flow method; On even some point is not followed the tracks of in the rhombus matrix, but because the first half conditions of streaking of barbell and not serious, tracking effect still is fine; The weight of the trace point of the first half is very big again; Still can be from mistake oneself recover, thereby obtain the central point of barbell, the proposition of this method has strengthened the robustness and the universality of LK pyramid optical flow method in the tracking field.Great prospect.
The device that embodiment two, a kind of barbell central point detect and follow the tracks of comprises:
Image input module is used to receive the video of input, promptly continuous some picture frames;
Detection module is used for detecting the barbell central point in first picture frame of said video;
Tracking module is used in each picture frame of said video, following the tracks of said barbell central point.
In the present embodiment, said detection module specifically comprises:
Submodule is cut in rough segmentation, is used for according to preset color first picture frame being carried out colour and cuts apart, with qualified part output;
Submodule is confirmed in the zone, is used for that the image that submodule output is cut in rough segmentation is carried out morphology and handles, and some noise points are removed; And utilize constraint conditions such as length breadth ratio and area size to confirm the approximate location zone at barbell place;
The rim detection submodule is used at the original image frame rim detection being carried out in the said barbell approximate location zone that the front obtains;
Transformation submodule is used for that the image after the rim detection is carried out Hough transformation and seeks out the barbell central point.
In the present embodiment, said rough segmentation is cut submodule and specifically can be comprised:
Initialization unit is used for first picture frame is carried out the conversion of RGB color space to the hsv color space; And the H value scope in the setting hsv color model;
The unit is set, is used for each pixel of picture frame is judged; If the H value of a pixel satisfies preset H value scope, then the value with this pixel is changed to 1, otherwise is changed to 0;
Output unit is used for output valve and is 1 pixel.
In the present embodiment, said zone confirms that submodule utilizes length breadth ratio and area size to confirm that the approximate location zone at barbell place is meant and filters out the zone of satisfying following two conditions, keeps each pixel in this zone:
Condition one, length breadth ratio>0.9, and length breadth ratio<1.1;
Condition two, area>100*100 pixel, and area<100*100 pixel.
In the present embodiment, said rim detection submodule specifically can comprise:
The gray scale arithmetic element is used to obtain the regional gray level image of said barbell approximate location; Each gray values of pixel points is (R+G+B)/3 of this pixel in the said barbell approximate location zone;
The boundary operation unit is used to adopt the PreWitt operator that said gray level image is carried out boundary operation, and PreWitt operator nuclear is:
- 1 - 1 - 1 0 0 0 1 1 1 - 1 0 1 - 1 0 1 - 1 0 1
Binarization unit is used for being set to 255 greater than said gray-scale value threshold value and gray values of pixel points that be included in said barbell approximate location zone, less than said gray-scale value threshold value or not the gray-scale value of point in the zone be set to 0.
In the present embodiment, said transformation submodule is carried out Hough transformation and specifically is meant:
Initialization HOUGH matrix A (x, y, r)=0;
Each pixel in the scan image one by one, (i in the time of j), makes (x-1) when scanning frontier point im 2+ (y-j) 2=r 2, and make A (x, y, r)=A (x, y, r)+1 continued scanning.
In the present embodiment, said tracking module specifically can comprise:
Matrix generates submodule, is used for for each picture frame, is set out by the barbell central point and does a rhombus matrix; Write down the position of each matrix dot in this rhombus matrix, and the weight of each matrix dot is set;
The optical flow method submodule; Be used for for each two adjacent picture frame; The central point of the rhombus matrix in these two picture frames is carried out LK pyramid optical flow method obtain its trace point, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of and obtain these all the other a plurality of matrix dots trace point separately;
Filter submodule, in said rhombus matrix, remove and obviously do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix;
The vector submodule with average after the weight addition of each trace point, obtains the level and smooth tracking vector of barbell central point, confirms the barbell central point that traces into according to said barbell central point and this level and smooth tracking vector; The weight of each trace point is the weight of its corresponding matrix dot.
Other details that each module realizes is with embodiment one.
Certainly; The present invention also can have other various embodiments; Under the situation that does not deviate from spirit of the present invention and essence thereof; Those of ordinary skill in the art work as can make various corresponding changes and distortion according to the present invention, but these corresponding changes and distortion all should belong to the protection domain of claim of the present invention.

Claims (8)

1. the barbell central point method that detects and follow the tracks of comprises:
Barbell central point in the video of A, extraction input in first picture frame; Wherein, said barbell central point is meant that barbell faces toward the center of circle of the disc of that end of camera lens;
B, for each picture frame in the said video, set out by the barbell central point and to do a rhombus matrix; Write down the position of each matrix dot in this rhombus matrix, and the weight of each matrix dot is set; For each two adjacent picture frame; The central point of the rhombus matrix in these two picture frames is carried out LK pyramid optical flow method obtain its trace point, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of and obtain these all the other a plurality of matrix dots trace point separately; Remove and do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix; With average after the weight addition of each trace point, obtain the level and smooth tracking vector of barbell central point, confirm the barbell central point that traces into according to said barbell central point and this level and smooth tracking vector; The weight of each trace point is the weight of its corresponding matrix dot;
Wherein, set out by said barbell central point and do a rhombus matrix and specifically be meant:
Set up the rhombus matrix of 9 points that launched to obtain by said barbell central point, the horizontal ordinate of said barbell central point is a, and ordinate is b; The coordinate of other eight points is respectively in the rhombus matrix:
First horizontal ordinate is a, and ordinate is b+15;
Second horizontal ordinate is a, and ordinate is b-15;
Horizontal ordinate thirdly is a+15, and ordinate is b;
The 4th horizontal ordinate is a-15, and ordinate is b;
The 5th horizontal ordinate is a+7, and ordinate is b+7;
The 6th horizontal ordinate is a+7, and ordinate is b-7;
The 7th horizontal ordinate is a-7, and ordinate is b+7;
The 8th horizontal ordinate is a-7, and ordinate is b-7;
Unit is a pixel;
The said weight that each matrix dot is set specifically is meant:
With said central point, thirdly be made as 5, the second weight and be made as the weight that weight that 0, the first weight is made as and at 10, the five at the 7th is made as and at 7, the six at the 8th and be made as 2 with the 4th weight.
2. the method for claim 1 is characterized in that, said step B specifically comprises:
B 1, in current image frame, set out by said barbell central point and to do said rhombus matrix, the central moment lattice point of this rhombus matrix is said barbell central point; Write down the position of 9 matrix dots of said rhombus, give set weight each said matrix dot;
Current image frame and adjacent next picture frame are carried out the following step:
B2, said central moment lattice point is done the LK pyramid optical flow method of two interframe, obtain the trace point of central moment lattice point;
B3, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of, obtain the trace point of these all the other a plurality of matrix dots;
B4, in the rhombus matrix, remove and do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix;
B5, with after the weight addition of each trace point according to its corresponding matrix dot, do on average again, obtain the level and smooth tracking vector of barbell central point; Confirm the barbell central point that traces into according to the barbell central point in the current image frame and this level and smooth tracking vector;
B6, with the barbell central point of the said barbell central point that traces into as said next picture frame, said next picture frame as current image frame, is returned step B1 then.
3. method as claimed in claim 2 is characterized in that, said step B2 specifically comprises:
31, picture frame is carried out pyramid transform, do optical flow method, obtain the motion vector V of said central moment lattice point at the pyramid of top layer;
32, window center is moved to the motion vector V place that has just calculated, iterative computation motion vector V is till convergence;
33, import convergent motion vector V into next tomographic image pyramid;
34, judge whether image, if then find optimal match point as trace point into the image pyramid bottom; Otherwise return step 32.
4. like each described method in the claim 1 to 3, it is characterized in that said steps A specifically comprises:
A1, input picture frame; First picture frame to input carries out the following step;
A2, carry out colour according to preset color and cut apart, qualified part is kept;
A3, the image that filters out after colour cut apart carries out the several times corrosion and several times expand; With the approximate location zone of the zone of satisfying the predetermined constraints condition as the barbell place; Said constraint condition comprises: condition one, length breadth ratio>0.9, and length breadth ratio<1.1; And condition two, area>10*10 pixel, and area<100*100 pixel;
Rim detection is carried out in A4, the said barbell approximate location zone that in the original image frame, the front is obtained;
A5, carry out Hough transformation and seek out the barbell central point in this picture frame.
5. method as claimed in claim 4 is characterized in that, said steps A 2 specifically comprises:
A21, first picture frame is carried out the conversion of RGB color space to the hsv color space;
A22, each pixel in the picture frame is screened, the H value is satisfied the pixel of the H value scope in the preset hsv color model, the effective value of this pixel is changed to 1, otherwise is changed to 0 according to the H value;
A23, output effective value are 1 pixel, obtain the image that filters out after colour is cut apart.
6. method as claimed in claim 4 is characterized in that, said steps A 4 specifically comprises:
A41, each pixel in the said barbell approximate location zone is obtained its gray-scale value according to following formula, obtain the gray level image in said barbell approximate location zone;
A42, said gray level image is carried out boundary operation;
A43, the gray level image through boundary operation is being done binaryzation; Be set to 255 greater than the gray-scale value threshold value and gray values of pixel points that be included in the said barbell approximate location zone, less than said gray-scale value threshold value or not the gray-scale value of the point in said barbell approximate location zone be set to 0.
7. method as claimed in claim 6 is characterized in that, said gray-scale value threshold value is:
Figure FSB00000865015300031
8. the device that the barbell central point detects and follows the tracks of is characterized in that, comprising:
Image input module is used to receive the video of input, promptly continuous some picture frames;
Detection module is used for detecting the barbell central point in first picture frame of said video;
Tracking module is used in each picture frame of said video, following the tracks of said barbell central point;
Said detection module specifically comprises:
Submodule is cut in rough segmentation, is used for according to preset color first picture frame being carried out colour and cuts apart, with qualified part output;
Submodule is confirmed in the zone, is used for that the image that submodule output is cut in rough segmentation is carried out morphology and handles, and some noise points are removed; And utilize constraint conditions such as length breadth ratio and area size to confirm the approximate location zone at barbell place, wherein said constraint condition comprises: condition one, length breadth ratio>0.9, and length breadth ratio<1.1; And condition two, area>10*10 pixel, and area<100*100 pixel;
The rim detection submodule is used at the original image frame rim detection being carried out in the said barbell approximate location zone that the front obtains;
Transformation submodule is used for that the image after the rim detection is carried out Hough transformation and seeks out the barbell central point;
Said tracking module specifically comprises:
Matrix generates submodule, is used for for each picture frame, is set out by the barbell central point and does a rhombus matrix; Write down the position of each matrix dot in this rhombus matrix, and the weight of each matrix dot is set;
The optical flow method submodule; Be used for for each two adjacent picture frame; The central point of the rhombus matrix in these two picture frames is carried out LK pyramid optical flow method obtain its trace point, all the other a plurality of matrix dots in the rhombus matrix are carried out optical flow method follow the tracks of and obtain these all the other a plurality of matrix dots trace point separately;
Filter submodule, in said rhombus matrix, remove and do not follow the tracks of correct trace point, and remove the trace point of this trace point about the central point of rhombus matrix;
The vector submodule with average after the weight addition of each trace point, obtains the level and smooth tracking vector of barbell central point, confirms the barbell central point that traces into according to said barbell central point and this level and smooth tracking vector; The weight of each trace point is the weight of its corresponding matrix dot.
CN2009102387361A 2009-11-23 2009-11-23 Method and device for detecting and tracking barbell central point Expired - Fee Related CN102074017B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2009102387361A CN102074017B (en) 2009-11-23 2009-11-23 Method and device for detecting and tracking barbell central point

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2009102387361A CN102074017B (en) 2009-11-23 2009-11-23 Method and device for detecting and tracking barbell central point

Publications (2)

Publication Number Publication Date
CN102074017A CN102074017A (en) 2011-05-25
CN102074017B true CN102074017B (en) 2012-11-28

Family

ID=44032546

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2009102387361A Expired - Fee Related CN102074017B (en) 2009-11-23 2009-11-23 Method and device for detecting and tracking barbell central point

Country Status (1)

Country Link
CN (1) CN102074017B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103235939A (en) * 2013-05-08 2013-08-07 哈尔滨工业大学 Datum point positioning method based on machine vision
CN105023278B (en) * 2015-07-01 2019-03-05 中国矿业大学 A kind of motion target tracking method and system based on optical flow method
CN107220645B (en) * 2017-05-24 2021-02-26 河北省计量监督检测研究院 Water meter identification method based on dynamic image processing
CN108007345A (en) * 2017-12-01 2018-05-08 南京工业大学 A kind of digger operating device measuring method based on monocular camera
CN109974958A (en) * 2019-03-25 2019-07-05 昆山顺扬工业成套设备有限公司 High-precision impact test machine
CN110136195B (en) * 2019-06-27 2021-09-03 武汉轻工大学 Infusion alarm method, alarm device, storage medium and device
CN113674299A (en) * 2020-05-13 2021-11-19 中国科学院福建物质结构研究所 3D printing method and device
CN112329664A (en) * 2020-11-11 2021-02-05 赛芒(北京)信息技术有限公司 Method for evaluating prokaryotic quantity of prokaryotic embryo

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5731849A (en) * 1992-03-13 1998-03-24 Canon Kabushiki Kaisha Movement vector detecting apparatus
CN101009841A (en) * 2006-01-26 2007-08-01 深圳艾科创新微电子有限公司 Estimation method for quick video motion
CN101184233A (en) * 2007-12-12 2008-05-21 中山大学 CFRFS based digital video compressed encoding method
CN101216941A (en) * 2008-01-17 2008-07-09 上海交通大学 Motion estimation method under violent illumination variation based on corner matching and optic flow method
CN101523440A (en) * 2006-11-30 2009-09-02 三菱电机株式会社 Motion vector detecting device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5731849A (en) * 1992-03-13 1998-03-24 Canon Kabushiki Kaisha Movement vector detecting apparatus
CN101009841A (en) * 2006-01-26 2007-08-01 深圳艾科创新微电子有限公司 Estimation method for quick video motion
CN101523440A (en) * 2006-11-30 2009-09-02 三菱电机株式会社 Motion vector detecting device
CN101184233A (en) * 2007-12-12 2008-05-21 中山大学 CFRFS based digital video compressed encoding method
CN101216941A (en) * 2008-01-17 2008-07-09 上海交通大学 Motion estimation method under violent illumination variation based on corner matching and optic flow method

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
JP特开2004-220059A 2004.08.05
刘勋,等.基于自适应对象模型的篮球运动跟踪方法.《信号处理》.2005,第21卷(第4A期), *
江志军,等.一种基于图像金字塔光流的特征跟踪方法.《武汉大学学报(信息科学版)》.2007,第32卷(第08期), *

Also Published As

Publication number Publication date
CN102074017A (en) 2011-05-25

Similar Documents

Publication Publication Date Title
CN102074017B (en) Method and device for detecting and tracking barbell central point
CN110544251B (en) Dam crack detection method based on multi-migration learning model fusion
CN105335725B (en) A kind of Gait Recognition identity identifying method based on Fusion Features
CN103955949B (en) Moving target detecting method based on Mean-shift algorithm
CN103886308B (en) A kind of pedestrian detection method of use converging channels feature and soft cascade grader
CN106650770A (en) Mura defect detection method based on sample learning and human visual characteristics
CN105741276A (en) Ship waterline extraction method
CN104715238A (en) Pedestrian detection method based on multi-feature fusion
CN109540925B (en) Complex ceramic tile surface defect detection method based on difference method and local variance measurement operator
CN109376740A (en) A kind of water gauge reading detection method based on video
CN107154058B (en) Method for guiding user to restore magic cube
CN104766344B (en) Vehicle checking method based on movement edge extractor
CN103914827A (en) Method for visual inspection of shortages of automobile sealing strip profile
CN107389693A (en) A kind of printed matter defect automatic testing method based on machine vision
WO2018032630A1 (en) Teaching toy kit and method for identifying programming module by using color and counter
CN109544694A (en) A kind of augmented reality system actual situation hybrid modeling method based on deep learning
CN104123554A (en) SIFT image characteristic extraction method based on MMTD
CN108460833A (en) A kind of information platform building traditional architecture digital protection and reparation based on BIM
CN112734761A (en) Industrial product image boundary contour extraction method
CN105405138A (en) Water surface target tracking method based on saliency detection
CN106327464A (en) Edge detection method
CN114926387A (en) Weld defect detection method and device based on background estimation and edge gradient suppression
CN106897982A (en) Real Enhancement Method based on the unmarked identification of image
CN103955693A (en) Nine-ball computer-assisted detection identification method
Gao et al. Design of an efficient multi-objective recognition approach for 8-ball billiards vision system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20121128

Termination date: 20171123

CF01 Termination of patent right due to non-payment of annual fee