CN103106407A - Recognition method of single-pig side view frame property in video-frequency band - Google Patents

Recognition method of single-pig side view frame property in video-frequency band Download PDF

Info

Publication number
CN103106407A
CN103106407A CN2012105490559A CN201210549055A CN103106407A CN 103106407 A CN103106407 A CN 103106407A CN 2012105490559 A CN2012105490559 A CN 2012105490559A CN 201210549055 A CN201210549055 A CN 201210549055A CN 103106407 A CN103106407 A CN 103106407A
Authority
CN
China
Prior art keywords
pig
sigma
view
video
frame
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
CN2012105490559A
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.)
Anhui University of Technology AHUT
Original Assignee
Anhui University of Technology AHUT
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 Anhui University of Technology AHUT filed Critical Anhui University of Technology AHUT
Priority to CN2012105490559A priority Critical patent/CN103106407A/en
Publication of CN103106407A publication Critical patent/CN103106407A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Image Analysis (AREA)

Abstract

The invention discloses a recognition method of a single-pig side view frame property in a video-frequency band. The method comprises the steps: according to a pig continuous outline map, extracting a ration of the height and the length of a simultaneous pig external rectangle and a Fourier coefficient with low frequency to construct a pig side view feature vector, obtaining a mean value and a variance of an ideal side view feature vector and a non-ideal side view feature vector according to a sample training set, and recognizing a category of an unknown property from a testing video through utilization of a mahalanobis distance discrimination method. The recognition method of the single-pig side view frame property in the video-frequency band is suitable for recognition of the video-frequency band of an ideal side view in a single-bar pig house monitoring video, and supplies favorable conditions for a subsequent analysis on actions of a single suspected sick pig.

Description

Single pig side view Frame Properties recognition methods in video-frequency band
Affiliated technical field
The present invention relates to single pig video segmentation technology, belong to the computer vision application.
Background technology
Along with the utilization of video monitoring system in the modernized pig raising field, monitoring analysis robotization and intellectuality are its development trends.At present, plant generally can pick out doubtful sick pig and be placed in the observation cultivation of single hurdle, if pass through monitor video, be partitioned into the video-frequency band of being convenient to observe the pig behavior, help to improve analysis efficiency, still, there is no at present the method for this type of video-frequency band of auto Segmentation.Generally obtain by wide-long shot the ideal scenario image that target is not touched the camera picture frame, as put pig activity in a less closed region, but the less observation analysis that is unfavorable for follow-up details behavior of target; In addition, in order to obtain image comparatively clearly, also can adopt camera closely to take temporarily, take the people and directly take the ideal scenario video on side, pig zone of action, but easily make pig produce stress reaction, simultaneously, the shooting working strength is larger.And in the pig house monitoring scene of reality, pig migration in pig house, not in monitored picture, the part health is in picture sometimes sometimes, and complete body contour is all in picture sometimes.Situation in single hurdle in the pig house scene can be divided into two classes, there is no the background scene and the scene that pig is arranged of pig.Desirable scene image is the positive side view of pig, because fully having showed its body characteristics over against camera in its side, and obtain researcher's attention, often be used as desirable visual angle, actual side view shows that because of the pig health angle is different, and how identifying required side view is significant work.
The objective of the invention is in order to overcome the above-mentioned deficiency in present technology, the every frame that proposes video-frequency band increases the side view attribute tags of one single pig profile diagram, and when the logical value of label was 1, the pig that represents present frame was desirable side view.
In video-frequency band, single pig side view Frame Properties recognizer is as follows:
A) for the side view attribute tags of single pig profile diagram of every frame, initial value is 0, represents imperfect lateral-view image;
B) frame of video foreground detection filters out the video-frequency band that only contains pig, enters c);
C) extract pig contour shape eigenwert, as the unknown properties sample, differentiate, if be desirable side view, the attribute-bit variate-value is 1, otherwise is 0.
B in above-mentioned algorithm) related technology forefathers have done research comparatively fully, and existing many methods can be obtained the video-frequency band that only contains pig; C) related technical foundation is general by extraction video foreground target area, then, utilizes the active contour method to obtain the continuous type profile of target, still, there is no the side view Frame Properties determination methods of single pig.
The present invention can be integrated in intelligent video monitoring system on the PC platform, increase hardly cost, whether have the judgement of desirable side view, the video segment that is comprised of for 1 successive frame side view attribute-bit variate-value provides desirable material for the details behavioural analyses such as abdominal breathing exercise of follow-up as sick pig if being applicable to single pig in video scene.
Summary of the invention
For solving the problem that can't determine single pig side view Frame Properties value in above-mentioned algorithm, the process flow diagram of institute of the present invention extracting method is seen part in dotted line frame in Fig. 1.
Process for the shared zone employing of the pig profile of every frame boundary rectangle frame, as shown in Figure 2, obtain cross-directional length value (w) and the vertical direction height value (h) of rectangle, as the one-component in pig side view proper vector, weigh pig side view characteristic with the normalized value of both ratio h/w.
Pig profile for every frame adopts Fourier descriptor to express, and the profile of establishing pig can be expressed as a coordinate sequence: and x (n), y (n): n=0,1 ..., N-1}, the expression of its plural form see formula (1).
Z(n)=x(n)+jy(n),n=0,1,2,...,N-1 (1)
The pig profile is a closed outline, so this sequence has periodically, and the cycle is N.Formula (2) and (3) are seen in its discrete Fourier transformation (DFT).
Z ( n ) = Σ k = 0 N - 1 Z ( k ) exp [ j 2 πkn N ] , 0 ≤ n ≤ N - 1 - - - ( 2 )
Z ( k ) = 1 N Σ n = 0 N - 1 Z ( n ) exp [ j 2 πkn N ] , 0 ≤ n ≤ N - 1 - - - ( 3 )
In order to make | Z (k) | have nothing to do with the selection of rotation, translation and spring of curve, redefine the Fourier descriptor of pig profile, see formula (4).In order to use Fast Fourier Transform (FFT) (FFT) to calculate Fourier coefficient, need to be to the contour curve even number of sampling.At first calculate the profile perimeter L, the distance on vertical or horizontal direction of the distance between neighbor is 1, on diagonal is
Figure DEST_PATH_GSB00001045927700023
The resampling M that counts gets and makes 2 k>N sets up minimum k, resamples to be spaced apart L/2 kThen calculate successively the coordinate of each sampled point along the border.Again the coordinate sequence after resampling is made FFT, get Fourier coefficient z (k), k=0,1 ..., M *-1, Fourier coefficient is made standardization processing, in pig contour shape proper vector
Figure DEST_PATH_GSB00001045927700024
Value.
Fd ( k ) = 0 , k = 0 | Z ( k ) | | Z ( 1 ) | , k = - 1 , . . . , - M 2 - 1 | Z ( k ) | | Z ( 1 ) | , k = 1 , . . . , M 2 - - - ( 4 )
Because Fourier coefficient has the characteristic that energy is concentrated to low frequency, therefore just can reach the purpose of distinguishing the difformity border with less coefficient.Therefore, can select enough few one group of coefficient Fd (k) normalized value as the group component in pig contour shape proper vector, weigh pig side view characteristic, k=1,2 ..., M *
Structure pig contour shape feature vector, X, namely In vector, each element is scalar, wherein, and x 1Be the high long ratio of the normalization of pig profile boundary rectangle,
Figure DEST_PATH_GSB00001045927700027
It is the unitary Fourier descriptor coefficient of a group.If G is M *+ 1 dimension pig contour shape proper vector is overall, and its distribution mean vector and covariance matrix calculate sees formula (5).
μ = μ 1 μ 2 . . . μ m * + 1 , Σ = σ 11 σ 12 . . . σ 1 M * + 1 σ 21 σ 22 . . . σ 2 M * + 1 . . . . . . . . . σ 1 M * + 1 σ 2 M * + 1 . . . σ [ M * + 1 [ M * + 1 ] ] - - - ( 5 )
If
Figure DEST_PATH_GSB000010459277000210
For taking from the sample of overall G, definition X sees formula (6) to square mahalanobis distance of overall G, supposes ∑>0 (∑ is positive definite matrix).
d 2(X,G)=(X-μ)′∑ -1(X-μ) (6)
Set training set, near the frame sample the positive side view of pig a priori is made as the overall G of desirable side view 1, other be made as the overall G of imperfect side view 2, the mean vector of distribution is respectively μ 1, μ 2, covariance matrix is respectively ∑ 1>0, ∑ 2>0.Because fact of case is ∑ 1≠ ∑ 2And unknown, need carry out
Figure DEST_PATH_GSB000010459277000211
Estimate:
μ ^ 1 = X ‾ 1 , μ ^ 2 = X ‾ 2 , Σ ^ 1 = S 1 , Σ ^ 2 = S 2 - - - ( 7 )
Figure DEST_PATH_GSB000010459277000216
Be corresponding sample average, S 1, S 2Be corresponding sample standard deviation.
The sample of an existing unknown classification is designated as X *, the estimation that can get square mahalanobis distance:
Figure DEST_PATH_GSB000010459277000217
Figure DEST_PATH_GSB000010459277000218
Be quadric discriminant function:
J ^ ( X * ) = d ^ 2 ( X * , G 1 ) - d ^ 2 ( X * , G 2 ) - - - ( 9 )
Because imperfect side view unanimity of samples is relatively poor, therefore, judgement X *Ownership, the correction decision rule is:
Figure DEST_PATH_GSB00001045927700031
Belong to G 1The sample frame property value be 1, represent that in this frame, pig is desirable side view; The Frame Properties value of other samples is 0, represents that in this frame, pig is imperfect side view.
Description of drawings
Fig. 1 is Video processing process flow diagram of the present invention.
Fig. 2 is pig boundary rectangle block diagram of the present invention.
Fig. 3 is the continuous type profile of pig in test case abstraction sequence frame of the present invention.
Fig. 4 is the continuous type profile of pig in test case reproducing sequence frame of the present invention.
Embodiment
Video processing process flow diagram of the present invention as shown in Figure 1, and is existing with a test case, and the present invention is described in further detail.
Step 1: the pig profile extracts.The experiment video comes from the monitor video on great Xiang agriculture and animal husbandry company limited's scale pig farm, Anhui, be photographed daytime during in July, 2012, video file is the AVI form, video resolution is 320 * 240 pixels, frame speed is 30FPS, monitoring objective is the Landrace at 10 monthly ages in single hurdle, in experiment, video adopts background subtraction through pre-service, obtain pig target area binary map, then, by the Sobel operator extraction should the zone discrete profile as initial profile, utilize the continuous type profile that GVF Snake track and extract should the zone.As shown in Figure 3.
Step 2: structural configuration proper vector.Extract the continuous type profile of pig for the video frame images pre-service, employing formula (4) is calculated pig profile Fourier descriptor, during Fourier inversion, with Fourier coefficient quantity M *Be respectively 4,6,8,10,12,14 and rebuild objective contour, because Fourier descriptor has shift invariant, therefore the profile diagram of reconstruct is positioned at image central authorities, corresponding to Fig. 3, the reconstruct profile diagram as shown in Figure 4.Contrast pig region shape original image, M *Larger, profile is more accurate, but the high calculated amount of dimension is also large, finds M *=8 can reflect the characteristics of pig health display surface substantially.According to the scope of these 8 Fourier coefficient values, adopt linear function normalization.
According to the pig body region, carry out the boundary rectangle frame of horizontal direction and process, extract the h/w value, according to the h/w value that some frames are carried, determine that its scope is 0.4~2.1, adopt linear function normalization.
Step 3: the sample training benchmark image eigenwert of known side view frames attribute.The artificial selected overall G of desirable side view 1(200 frame), the overall G2 of imperfect side view (300 frames wherein do not contain background frames) as the benchmark image eigenwert, calculates 4 proper vector values
Figure DEST_PATH_GSB00001045927700032
S 1, S 2, wherein See the following form.
Figure DEST_PATH_GSB00001045927700035
Step 4: the sample side view Frame Properties that test is unknown.The video-frequency band content of unknown sample relates to a pig walks from left to right, stop a moment in the middle of the scene, and totally 467 frames, desirable side view 275 frames of artificial cognition wherein, imperfect side-looking Figure 192 frame is comprising background frames 58 frames that do not contain pig.Test video only carries out pre-service to the promising frame of video of tool after foreground detection, extract pig contour shape eigenwert, calculates by formula (8), (9), and so back-pushed-type (10) is determined test side view Frame Properties.The artificial two class side view frame numbers of distinguishing of contrast, correct accuracy of identification is 91.7%, experiment shows that it is effective that the video frame image profile attributes is differentiated algorithm.

Claims (1)

1. single pig side view Frame Properties recognition methods in a video-frequency band, is characterized in that determining side view Frame Properties value according to single pig profile diagram of pig, and concrete grammar is as follows:
If the profile of pig can be expressed as a coordinate sequence: x (n), y (n): n=0,1 ..., N-1}, formula (1) and (2) are seen in its discrete Fourier transformation (DFT).
Z ( n ) = Σ k = 0 N - 1 Z ( k ) exp [ j 2 πkn N ] , 0≤n≤N-1(1)
Z ( k ) = 1 N Σ n = 0 N - 1 Z ( n ) exp [ j 2 πkn N ] , 0≤n≤N-1(2)
Redefine the Fourier descriptor of pig profile, see formula (3).Fourier coefficient is made standardization processing, in pig contour shape proper vector
Figure FSA000008252140000115
Value.
Fd ( k ) = 0 , k = 0 | Z ( k ) | | Z ( 1 ) | , k = - 1 , . . . , - M 2 - 1 | Z ( k ) | | Z ( 1 ) | , k = 1 , . . . , M 2 - - - ( 4 )
Structure pig contour shape feature vector, X, namely
Figure FSA000008252140000116
, in vector, each element is scalar, wherein, and x 1Be the high long ratio of the normalization of pig profile boundary rectangle, 1 is the unitary Fourier descriptor coefficient of a group.If G is M *+ 1 dimension pig contour shape proper vector is overall, and its distribution mean vector and covariance matrix calculate sees formula (4).
μ = μ 1 μ 2 . . . μ M * + 1 , Σ = σ 11 σ 12 . . . σ 1 M * + 1 σ 21 σ 22 . . . σ 2 M * + 1 . . . . . . . . . σ 1 M * + 1 σ 2 M * + 1 . . . σ [ M * + 1 [ M * + 1 ] ] - - - ( 4 )
If
Figure FSA000008252140000118
For taking from the sample of overall G, definition X sees formula (5) to square mahalanobis distance of overall G, supposes ∑>0 (∑ is positive definite matrix).
d 2(X,G)=(X-μ)′∑ -1(X-μ) (5)
Set training set, near the frame sample the positive side view of pig a priori is made as the overall G of desirable side view 1, other be made as the overall G of imperfect side view 2, the mean vector of distribution is respectively μ 1, μ 2, covariance matrix is respectively ∑ 1>0, ∑ 2>0.Need carry out
Figure FSA00000825214000016
Estimate:
μ ^ 1 = X ‾ 1 , μ ^ 2 = X ‾ 2 , Σ ^ 1 = S 1 , Σ ^ 2 = S 2 - - - ( 6 )
The sample X of an existing unknown classification *, formula (7) is seen in the estimation of its mahalanobis distance,
Figure FSA000008252140000111
Be quadric discriminant function, see formula (8).
Figure FSA000008252140000112
i=1,2 (7)
J ^ ( X * ) = d ^ 2 ( X * , G 1 ) - d ^ 2 ( X * , G 2 ) - - - ( 8 )
Judgement X *Ownership, the correction decision rule is:
Figure FSA000008252140000114
Belong to G 1The sample frame property value be 1, represent that in this frame, pig is desirable side view; The Frame Properties value of other samples is 0, represents that in this frame, pig is imperfect side view.
CN2012105490559A 2012-12-05 2012-12-05 Recognition method of single-pig side view frame property in video-frequency band Pending CN103106407A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2012105490559A CN103106407A (en) 2012-12-05 2012-12-05 Recognition method of single-pig side view frame property in video-frequency band

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2012105490559A CN103106407A (en) 2012-12-05 2012-12-05 Recognition method of single-pig side view frame property in video-frequency band

Publications (1)

Publication Number Publication Date
CN103106407A true CN103106407A (en) 2013-05-15

Family

ID=48314255

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2012105490559A Pending CN103106407A (en) 2012-12-05 2012-12-05 Recognition method of single-pig side view frame property in video-frequency band

Country Status (1)

Country Link
CN (1) CN103106407A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103488941A (en) * 2013-09-18 2014-01-01 工业和信息化部电子第五研究所 Hardware Trojan horse detection method and hardware Trojan horse detection system
CN106203476A (en) * 2016-06-24 2016-12-07 浙江大学 A kind of pig's head tail wheel exterior feature recognition methods based on arest neighbors classification with fuzzy algorithmic approach
CN109598226A (en) * 2018-11-29 2019-04-09 安徽工业大学 Based on Kinect colour and depth information online testing cheating judgment method
CN113449638A (en) * 2021-06-29 2021-09-28 西藏新好科技有限公司 Pig image ideal frame screening method based on machine vision technology

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102509085A (en) * 2011-11-19 2012-06-20 江苏大学 Pig walking posture identification system and method based on outline invariant moment features
CN102521563A (en) * 2011-11-19 2012-06-27 江苏大学 Method for indentifying pig walking postures based on ellipse fitting

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102509085A (en) * 2011-11-19 2012-06-20 江苏大学 Pig walking posture identification system and method based on outline invariant moment features
CN102521563A (en) * 2011-11-19 2012-06-27 江苏大学 Method for indentifying pig walking postures based on ellipse fitting

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
纪滨: "基于机器视觉的猪只腹式呼吸建模", 《万方数据》 *

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103488941A (en) * 2013-09-18 2014-01-01 工业和信息化部电子第五研究所 Hardware Trojan horse detection method and hardware Trojan horse detection system
CN103488941B (en) * 2013-09-18 2016-09-14 工业和信息化部电子第五研究所 Hardware Trojan horse detection method and system
CN106203476A (en) * 2016-06-24 2016-12-07 浙江大学 A kind of pig's head tail wheel exterior feature recognition methods based on arest neighbors classification with fuzzy algorithmic approach
CN106203476B (en) * 2016-06-24 2019-03-29 浙江大学 A kind of pig's head tail wheel exterior feature recognition methods based on arest neighbors classification and fuzzy algorithmic approach
CN109598226A (en) * 2018-11-29 2019-04-09 安徽工业大学 Based on Kinect colour and depth information online testing cheating judgment method
CN109598226B (en) * 2018-11-29 2022-09-13 安徽工业大学 Online examination cheating judgment method based on Kinect color and depth information
CN113449638A (en) * 2021-06-29 2021-09-28 西藏新好科技有限公司 Pig image ideal frame screening method based on machine vision technology
CN113449638B (en) * 2021-06-29 2023-04-21 北京新希望六和生物科技产业集团有限公司 Pig image ideal frame screening method based on machine vision technology

Similar Documents

Publication Publication Date Title
Wang et al. A deep learning approach incorporating YOLO v5 and attention mechanisms for field real-time detection of the invasive weed Solanum rostratum Dunal seedlings
Aquino et al. A new methodology for estimating the grapevine-berry number per cluster using image analysis
WO2021047232A1 (en) Interaction behavior recognition method, apparatus, computer device, and storage medium
CN101179713A (en) Method of detecting single moving target under complex background
CN103942577A (en) Identity identification method based on self-established sample library and composite characters in video monitoring
CN104166841A (en) Rapid detection identification method for specified pedestrian or vehicle in video monitoring network
CN106384345B (en) A kind of image detection and flow statistical method based on RCNN
CN102915446A (en) Plant disease and pest detection method based on SVM (support vector machine) learning
Liu et al. Tracking objects using shape context matching
CN103034860A (en) Scale-invariant feature transform (SIFT) based illegal building detection method
CN102509085A (en) Pig walking posture identification system and method based on outline invariant moment features
CN105512618B (en) Video tracing method
CN108491807B (en) Real-time monitoring method and system for oestrus of dairy cows
CN104598871A (en) Correlation regression based face age calculating method
CN102194114A (en) Method for recognizing iris based on edge gradient direction pyramid histogram
CN106023151A (en) Traditional Chinese medicine tongue manifestation object detection method in open environment
CN105488541A (en) Natural feature point identification method based on machine learning in augmented reality system
CN104700412A (en) Calculating method of visual salience drawing
CN103810707B (en) A kind of image vision significance detection method based on moving-vision focus
CN106529441B (en) Depth motion figure Human bodys' response method based on smeared out boundary fragment
CN103106407A (en) Recognition method of single-pig side view frame property in video-frequency band
CN106548131A (en) A kind of workmen's safety helmet real-time detection method based on pedestrian detection
CN107292299A (en) Side face identification method based on kernel specification correlation analysis
Xu et al. Real-time object detection method of melon leaf diseases under complex background in greenhouse
CN114550212A (en) Goat face detection and identification method based on lightweight model

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C02 Deemed withdrawal of patent application after publication (patent law 2001)
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20130515