CN109141248A - Pig weight measuring method and system based on image - Google Patents

Pig weight measuring method and system based on image Download PDF

Info

Publication number
CN109141248A
CN109141248A CN201810835051.4A CN201810835051A CN109141248A CN 109141248 A CN109141248 A CN 109141248A CN 201810835051 A CN201810835051 A CN 201810835051A CN 109141248 A CN109141248 A CN 109141248A
Authority
CN
China
Prior art keywords
pig
ear tag
image
weight
pig body
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.)
Granted
Application number
CN201810835051.4A
Other languages
Chinese (zh)
Other versions
CN109141248B (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 Shenzhi Hengji Technology Co ltd
Original Assignee
Shenzhen Yuan Heng Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Yuan Heng Technology Co Ltd filed Critical Shenzhen Yuan Heng Technology Co Ltd
Priority to CN201810835051.4A priority Critical patent/CN109141248B/en
Publication of CN109141248A publication Critical patent/CN109141248A/en
Application granted granted Critical
Publication of CN109141248B publication Critical patent/CN109141248B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B11/00Measuring arrangements characterised by the use of optical techniques
    • G01B11/02Measuring arrangements characterised by the use of optical techniques for measuring length, width or thickness
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B11/00Measuring arrangements characterised by the use of optical techniques
    • G01B11/24Measuring arrangements characterised by the use of optical techniques for measuring contours or curvatures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes
    • G06T7/62Analysis of geometric attributes of area, perimeter, diameter or volume
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image

Abstract

The invention discloses a kind of pig weight measuring method and system based on image, wherein pig weight measuring method include: in sample image pig body position and ear tag position and pig body contour point and ear tag profile point be labeled;According to pig body position and ear tag position training characteristics detection model;According to pig body contour point and ear tag profile point training profile point regression model;Determine the pig body position in the long measuring and calculating image of body and ear tag position;Determine the calibration profile point position and ear tag profile point position in the long measuring and calculating image of body;Calculate the length in pixels of pig body and ear tag;The practical body for calculating pig body is long;Establish pig weight regression model;Pig weight is obtained using pig weight regression model.According to the technical solution of the present invention, the safety and hygiene and health that ensure that survey crew improve the efficiency for obtaining pig weight data, and cost substantially reduces.

Description

Pig weight measuring method and system based on image
Technical field
The present invention relates to image identification technical field more particularly to a kind of pig weight measuring methods and one kind based on image Pig weight calculating system based on image.
Background technique
In the breeding process of pig, the weight of pig is to react the important indicator of pig upgrowth situation, monitors the weight of pig in time Index has great importance for the breeding production of pig, disease surveillance.
In settlement of insurance claim according to dead pig weight Claims Resolution be a kind of common Claims Resolution mode, but during Claims Resolution exist to The case where artificial modes for increasing pig weight such as dead pig body water filling carry out insurance fraud.
Weight mainly passes through title and measures in traditional mode of production, needs for pig fixation to be placed on when measuring live hog weight It deserves to be called, this measurement method needs take a substantial amount of time and manpower, inefficiency, and scaring may be caused to influence on pig Its growth and development.Many dead pig bodies have infected germ or have rotted during settlement of insurance claim, claim on the dead pig of manual handling The mode weighed can generate more serious hygienic issues.
In the prior art, there is research using the object by placing fixed size at pig back, using being placed on pig house The camera acquisition pig of surface and the image of object of reference carry out weight measuring and calculating, this process needs the intervention of people, can not solve The problem of safety and health, and due to object of reference can not seek unity of standard and be easy to be replaced also can not be with for settlement of insurance claim rank Section.There are also a set of weight and body weight calculating systems that can use in pig house, but need to set up two fixed images of distance and adopt Collect equipment, since its usage scenario is fixed with significant limitations in position.In addition, the existing weight measuring method based on image, The requirement all with higher such as quantity, angle to image capture device, or the object of reference of fixed placement is needed, limit it Usage scenario.
Summary of the invention
At least one of regarding to the issue above, the present invention provides a kind of pig weight measuring method based on image and it is System, using the detection model to pig body and ear tag demarcated of the sample image training based on deep learning, according to detection mould Type determines the position and profile of pig body and ear tag in the long measuring and calculating image of body, to calculate the body of pig body according to ear tag size Long and body is wide, to establish pig weight regression model, determines pig weight according to pig weight regression model, to realize according to image The weight for estimating pig body does not need same pig and is contacted, and ensure that the safety and hygiene and health of survey crew, greatly The convenience and efficiency for obtaining pig weight data are improved, and cost substantially reduces.
To achieve the above object, the present invention provides a kind of pig weight measuring method based on image, comprising: collecting sample Image and weight calculate image, in the sample image and weight measuring and calculating image pig body position and ear tag position with And pig body contour point, ear tag profile point and figure are labeled;The sample image and weight measuring and calculating image are carried out Pretreatment and normalized;According to the pig body position of the sample image and the ear tag position training pig body and The feature detection model of ear tag;According to the pig body contour point of the sample image and ear tag profile point training The profile point regression model of pig body and the ear tag;It is determined in the weight measuring and calculating image using the feature detection model Pig body position and ear tag position;The calibration profile point in the weight measuring and calculating image is determined using the profile point regression model Position and ear tag profile point position;The length in pixels that the pig body is calculated according to the calibration profile point position, according to described Ear tag profile point position calculates the length in pixels of the ear tag;According to the pixel of the Pixel Dimensions of the pig body, the ear tag Size and the actual size of the ear tag calculate the actual size predicted value of the pig body;According to the reality of the pig body Pig weight regression model is established with corresponding pig weight in size prediction value, the calibration profile point position;According to the pig weight The corresponding pig weight of the weight measuring and calculating image is calculated in regression model.
In the above-mentioned technical solutions, it is preferable that described according to the pig body position of the sample image and the ear The feature detection model of cursor position training pig body and ear tag specifically includes: obtaining pig body described in the sample image and institute State the candidate region of ear tag;The feature of the candidate region is extracted using multilayer convolutional neural networks;It will according to the feature of extraction The candidate region is classified as pig body candidate region and ear tag candidate region;It is candidate to pig body candidate region and ear tag Region is utilized respectively non-maximum restraining method and merges, and obtains the pig body region and ear tag region in the sample image.
In the above-mentioned technical solutions, it is preferable that the pig body contour point according to the sample image and described The profile point regression model of the ear tag profile point training pig body and the ear tag specifically includes: utilizing convolutional neural networks pair The pig body image and the ear tag image carry out feature extraction, obtain profile key point information and the convolutional neural networks The corresponding contour point information of prediction;Using convolutional neural networks in image pig body contour and ear tag profile return it is pre- It surveys.
In the above-mentioned technical solutions, it is preferable that the pig body contour point according to the sample image and described The profile point regression model of the ear tag profile point training pig body and the ear tag specifically includes: utilizing convolutional neural networks pair The pig body image and the ear tag image carry out feature extraction, obtain profile key point information and the convolutional neural networks The corresponding contour point information of prediction;It is optimized by formula (1) with the Euclidean distance loss function of L2 regularization term,
Wherein, m is the key point number on pig body contour or ear tag profile, PiIt is corresponding for manually mark i-th Profile coordinate, f (x)iPass through i-th of profile coordinate of convolutional neural networks prediction, w for input picturetFor convolutional neural networks Weight parameter;Using convolutional neural networks to the pig body contour and ear tag profile progress regression forecasting in image.
In the above-mentioned technical solutions, it is preferable that the pixel ruler of the Pixel Dimensions according to the pig body, the ear tag The actual size predicted value that the actual size of the very little and described ear tag calculates the pig body specifically includes: the selection pig basal part of the ear and pig Root of the tail calculates the Euclidean between the calibration profile point as the calibration profile point in the pig body contour point, according to formula (2) Length in pixels of the distance as the pig body in weight measuring and calculating image,
Wherein, (x1, y1), (x2, y2) it is that the pig basal part of the ear point and the pigtail root point are calculated in image in the weight Coordinate position;Length in pixels d of the ear tag in weight measuring and calculating image is calculated according to ear tag profile point position2;According to Formula (3) calculates the long l of practical body of the pig bodypig,
lpig=d1/d2*ltag (3)
Wherein, ltagFor the physical length of ear tag;The wide W of practical body of the pig body is calculated according to same methodpig;Root Pig bust statistical model C is established according to the pig bust length of the pig bodypig=σ * Wpig, wherein CpigFor pig bust length, σ is The coefficient obtained according to statistical information.
In the above-mentioned technical solutions, it is preferable that the pig weight regression model specifically: Weightpig=f (Cpig, lpig, K1...Ki), wherein WeightpigFor pig weight, KiTo return i-th obtained of pig body contour point position.
In the above-mentioned technical solutions, it is preferable that the mark to the figure of pig includes " thin ", " normal " and " fat " three kinds of bodies Type.
The present invention also proposes a kind of pig weight calculating system based on image, using described in any one of above-mentioned technical proposal The pig weight measuring method based on image, comprising: image capture module calculates image for capturing sample image and weight, To the pig body position and ear tag position and pig body contour point, ear tag in the sample image and weight measuring and calculating image Profile point and figure are labeled;Preprocessing module, for being located in advance to the sample image and weight measuring and calculating image Reason and normalized;Feature detection model training module, for according to the pig body position of the sample image and institute State the feature detection model of ear tag position training pig body and ear tag;Profile point regression model training module, for according to The profile point of the pig body contour point of sample image and the ear tag profile point training pig body and the ear tag is returned Return model;Feature detection module, for determining the pig body position in the weight measuring and calculating image using the feature detection model It sets and ear tag position;Profile point detection module, for being determined in the weight measuring and calculating image using the profile point regression model Calibration profile point position and ear tag profile point position;Length in pixels computing module, for according to the calibration profile point position The length in pixels for calculating the pig body calculates the length in pixels of the ear tag according to ear tag profile point position;Size is pre- Module is surveyed, for the actual size according to the Pixel Dimensions of the pig body, the Pixel Dimensions of the ear tag and the ear tag Calculate the actual size predicted value of the pig body;Pig weight regression model training module, for the reality according to the pig body Pig weight regression model is established with corresponding pig weight in border size prediction value, the calibration profile point position;Weight regression block, For the corresponding pig weight of the weight measuring and calculating image to be calculated according to the pig weight regression model.
Compared with prior art, the invention has the benefit that using sample image training based on deep learning to pig The detection model that body and ear tag are demarcated determines the position of pig body and ear tag in the long measuring and calculating image of body according to detection model And profile, thus it is long wide with body according to the body that ear tag size calculates pig body, so that pig weight regression model is established, according to pig Weight regression model determines pig weight, to realize the weight for estimating pig body according to image, does not need same pig and is contacted, The safety and hygiene and health that ensure that survey crew greatly improve the convenience and efficiency for obtaining pig weight data, and Cost substantially reduces.
Detailed description of the invention
Fig. 1 is the flow diagram of the pig weight measuring method based on image disclosed in an embodiment of the present invention;
Fig. 2 is the disclosed flow diagram using model prediction pig weight of an embodiment of the present invention;
Fig. 3 is the disclosed schematic diagram that position mark is carried out to sample image of an embodiment of the present invention;
Fig. 4 is the disclosed schematic diagram that profile point mark is carried out to sample image of an embodiment of the present invention;
Fig. 5 is the schematic block diagram of the pig weight calculating system based on image disclosed in an embodiment of the present invention.
Corresponding relationship in figure, between each component and appended drawing reference are as follows:
11. pig body, 12. ear tags, 13. pig body contour points, 14. ear tag profile points, the 20. pig weight based on image are surveyed Calculation system, 21. image capture modules, 22. preprocessing modules, 23. feature detection model training modules, 24. profile points return mould Type training module, 25. feature detection modules, 26. profile point detection modules, 27. length in pixels computing modules, 28. size predictions Module, 29. pig weight regression model training modules, 30. weight regression blocks.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is A part of the embodiments of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, ordinary skill people Member's every other embodiment obtained without making creative work, shall fall within the protection scope of the present invention.
The present invention is described in further detail with reference to the accompanying drawing:
As shown in Figures 1 to 4, a kind of pig weight measuring method based on image provided according to the present invention, comprising: step S101, capturing sample image and weight calculate image, to the pig body position and ear tag in sample image and weight measuring and calculating image Position and pig body contour point 13, ear tag profile point 14 and figure are labeled;Step S102 surveys sample image and weight Nomogram picture carries out pretreatment and normalized;Step S103, according to the pig body position of sample image and the training of ear tag position The feature detection model of pig body 11 and ear tag 12;Step S104, according to the pig body contour point 13 and ear tag wheel of sample image The profile point regression model of exterior feature point 14 training pig body 11 and ear tag 12;Step S105 determines weight using feature detection model Calculate the pig body position in image and ear tag position;Step S106 determines that weight calculates image using profile point regression model In calibration profile point position and ear tag profile point position;Step S107 calculates pig body 11 according to calibration profile point position Length in pixels calculates the length in pixels of ear tag 12 according to 14 position of ear tag profile point;Step S108, according to the pixel of pig body 11 The actual size of size, the Pixel Dimensions of ear tag 12 and ear tag 12 calculates the actual size predicted value of pig body 11;Step S109 establishes pig weight with corresponding pig weight and returns according to the actual size predicted value of pig body 11, calibration profile point position Model;The corresponding pig weight of weight measuring and calculating image is calculated according to pig weight regression model in step S110.
Specifically, the image of pig in a certain number of farms is collected as sample image, and pig body is carried out to sample image The calibration of body position 13 and ear tag position 14, and the calibration of pig body contour point and ear tag profile point is carried out to sample image, In addition, including " thin ", " normal " and " fat " three kinds of figures to the mark of the figure of pig.Pig body image uses in figs. 3 and 4 Lines description is sample during actual practice in order to which the calibration situation to pig body 11 and ear tag 12 is clearly illustrated The long measuring and calculating image of image and body is collected include pig body 11 and ear tag 12 image.It is completed acquiring and demarcating Afterwards, need to carry out original image pretreatment and normalized.Specifically, the pixel value of each pixel is in original image The pixel value of each pixel is normalized to the floating number between 0-1 by method for normalizing by the integer between 0-255.
Specifically, using sample image training detection model, detection model is recycled to calculate the long detection image of body Process depth learning technology is utilized.Deep learning method can extract the height for including in image according to the mission requirements of feature The characteristics of image of identification achieves huge advance in computer vision field, the object detection algorithms based on deep learning It can be applied to production environment, it is quite high to the accuracy rate of object detection.In addition, in the above embodiment, it is preferable that the long survey of body Nomogram picture carries out pretreatment and normalized before input feature vector detection model and profile point regression model, to guarantee to body The accuracy of long measuring and calculating image prediction.
In the above-mentioned technical solutions, it is preferable that according to the pig body position of sample image and ear tag position training pig body 11 and the feature detection model of ear tag 12 specifically include: obtain the candidate region of pig body 11 and ear tag 12 in sample image, In, the mode that the candidate region of pig body 11 and ear tag 12 generates is using selection search (selective search) or area Suggest network (RPN) in domain;Using multilayer convolutional neural networks extract candidate region feature, the extraction of feature can be used vgg, Resnet etc. different network structures;Candidate region is classified as pig body candidate region according to the feature of extraction and ear tag is candidate Background area in region and sample image;Non- very big suppression is utilized respectively to pig body candidate region and ear tag candidate region Method processed merges, and obtains the pig body region and ear tag region in sample image.For being examined using the object of deep learning Surveying any detector, the technologies such as device selection faster-rcnn, ssd, yolo is the prior art, and details are not described herein.
In the above embodiment, it is preferable that pig body position 13 and ear tag position 14 are indicated using rectangle frame position coordinates, Rectangle frame position coordinates include rectangle upper left corner X-coordinate, rectangle upper left corner Y coordinate, rectangle lower right corner X-coordinate and the rectangle lower right corner Y coordinate determines pig body position 13 and ear tag position 14 using four coordinate values in rectangle frame position coordinates, thus by pig The image interception in 12 region of 11 region of body and ear tag comes out, then using profile point regression model to the profile point of pig body 11 It is accurately positioned with the profile point of ear tag 12.
In the above-mentioned technical solutions, it is preferable that instructed according to the pig body contour point 13 and ear tag profile point 14 of sample image The profile point regression model for practicing pig body 11 and ear tag 12 specifically includes: using convolutional neural networks to pig body image and ear tag Image carries out feature extraction, obtains the corresponding contour point information of profile key point information and convolutional neural networks prediction;Utilize volume Product neural network is to the pig body contour point 13 and the progress regression forecasting of ear tag profile point 14 in image.It is optimal pre- in order to reach Effect is surveyed, also can be selected and optimized by formula (1) with the Euclidean distance loss function of L2 regularization term,
Wherein, m is the key point number on pig body contour or ear tag profile, PiIt is corresponding for manually mark i-th Profile coordinate, f (x)iPass through i-th of profile coordinate of convolutional neural networks prediction, w for input picturetFor convolutional neural networks Weight parameter;Using convolutional neural networks to the pig body contour and ear tag profile progress regression forecasting in image.In the implementation Example in, the selection of convolutional neural networks can be selected according to actual, as VGG, ResNet, MobileNet, Shufflenet etc., according to the structure and parameter amount of the requirement of performance and accuracy rate adjustment network model appropriate, the present invention couple The structure of convolutional neural networks is with no restrictions.
In the above-mentioned technical solutions, it is preferable that according to the Pixel Dimensions of pig body 11, the Pixel Dimensions and ear of ear tag 12 The actual size predicted value that the actual size of mark 12 calculates pig body 11 specifically includes:
1) length in pixels of pig body in the picture is calculated, common calculation is to calculate pig basal part of the ear point to pigtail root two Pixel distance d between a point in the picture1, the calculation of length can select different wheels according to the needs of actual conditions Wide key point is calculated, and the present invention is with no restrictions.Select the pig basal part of the ear and pigtail root as the calibration in pig body contour point 13 Profile point calculates picture of the Euclidean distance between calibration profile point as pig body 11 in weight measuring and calculating image according to formula (2) Plain length,
Wherein, (x1, y1), (x2, y2) it is the coordinate position of pig basal part of the ear point and pigtail root point in weight measuring and calculating image;
2) length in pixels d of the ear tag 12 in weight measuring and calculating image is calculated according to 14 position of ear tag profile point2, ear tag length Calculating can by least square method according to ear tag outline position information return produce agaric target elliptic region, obtain the length of ear tag Axis and short axle length in pixels:
Wherein 1 is elliptical long axis length in pixels, and s is elliptical short axle length in pixels;
3) the long l of practical body of pig body 11 is calculated according to formula (3)pig,
lpig=d1/d2*ltag (3)
Wherein, ltagFor the physical length of ear tag 12;
4) the wide W of practical body of pig body 11 is calculated according to same methodpig
5) pig bust statistical model C is established according to the pig bust length of pig body 11pig=σ * Wpig, wherein CpigFor pig chest Girth degree, σ are the coefficient obtained according to statistical information.
In the above-mentioned technical solutions, it is preferable that pig weight is established according to the weight of the profile information of pig and pig, body long message Regression model, then pig weight regression model specifically: Weightpig=f (Cpig, lpig, K1...Ki), wherein WeightpigFor Pig weight, KiTo return i-th obtained of pig body contour point position.
As shown in figure 5, the present invention also proposes a kind of pig weight calculating system 20 based on image, using above-mentioned technical proposal Any one of the pig weight measuring method based on image, comprising: image capture module 21, be used for capturing sample image and weight Calculate image, in sample image and weight measuring and calculating image pig body position and ear tag position and pig body contour point 13, Ear tag profile point 14 and figure are labeled;Preprocessing module 22, for being located in advance to sample image and weight measuring and calculating image Reason and normalized;Feature detection model training module 23, for according to sample image pig body position and ear tag position The feature detection model of training pig body 11 and ear tag 12;Profile point regression model training module 24, for according to sample image Pig body contour point 13 and ear tag profile point 14 training pig body 11 and ear tag 12 profile point regression model;Feature detects mould Block 25, for determining pig body position and ear tag position in weight measuring and calculating image using feature detection model;Profile point detection Module 26, for determining calibration profile point position and ear tag profile point 14 in weight measuring and calculating image using profile point regression model Position;Length in pixels computing module 27, for calculating the length in pixels of pig body 11 according to calibration profile point position, according to ear tag The length in pixels of 14 position of profile point calculating ear tag 12;Size prediction module 28, for Pixel Dimensions, the ear according to pig body 11 The Pixel Dimensions of mark 12 and the actual size of ear tag 12 calculate the actual size predicted value of pig body 11;Pig weight regression model Training module 29, for being established according to the actual size predicted value of pig body 11, calibration profile point position with corresponding pig weight Pig weight regression model;Weight regression block 30, it is corresponding for weight measuring and calculating image to be calculated according to pig weight regression model Pig weight.
When being calculated using the pig weight calculating system 20 based on image to the pig weight in weight measuring and calculating image, specifically Method pig weight measuring method based on image referring to disclosed in above-described embodiment, details are not described herein.
The above is embodiments of the present invention, the pig weight measuring method based on image proposed according to the present invention and System, using the detection model to pig body and ear tag demarcated of the sample image training based on deep learning, according to detection Model determines the position and profile of pig body and ear tag in the long measuring and calculating image of body, to calculate pig body according to ear tag size Body is long and body is wide, to establish pig weight regression model, determines pig weight according to pig weight regression model, to realize according to figure Weight as estimating pig body, does not need same pig and is contacted, ensure that the safety and hygiene and health of survey crew, improves Obtain the efficiency of pig weight data.In fields such as settlements of insurance claim, uses weight to avoid raiser as Claims Resolution index and pass through The modes such as water filling gain the behavior of premium by cheating, so that Claims Resolution process is more just.Furthermore, it is not necessary that the ginseng of fixed position size is arranged According to object, also not needing to set up has complicated desired image capture device, has lower use cost.
These are only the preferred embodiment of the present invention, is not intended to restrict the invention, for those skilled in the art For member, the invention may be variously modified and varied.All within the spirits and principles of the present invention, it is made it is any modification, Equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.

Claims (8)

1. a kind of pig weight measuring method based on image characterized by comprising
Capturing sample image and weight calculate image, to the pig body position in the sample image and weight measuring and calculating image It is labeled with ear tag position and pig body contour point, ear tag profile point and figure;
Pretreatment and normalized are carried out to the sample image and weight measuring and calculating image;
According to the feature detection of the pig body position of the sample image and ear tag position training pig body and ear tag Model;
According to the pig body contour point of the sample image and the ear tag profile point training pig body and the ear Target profile point regression model;
Pig body position and the ear tag position in the weight measuring and calculating image are determined using the feature detection model;
Calibration profile point position and the ear tag profile point in the weight measuring and calculating image are determined using the profile point regression model Position;
The length in pixels that the pig body is calculated according to the calibration profile point position, calculates according to ear tag profile point position The length in pixels of the ear tag;
According to the calculating of the actual size of the Pixel Dimensions of the pig body, the Pixel Dimensions of the ear tag and the ear tag The actual size predicted value of pig body;
Pig weight is established with corresponding pig weight according to the actual size predicted value of the pig body, the calibration profile point position Regression model;
The corresponding pig weight of the weight measuring and calculating image is calculated according to the pig weight regression model.
2. the pig weight measuring method according to claim 1 based on image, which is characterized in that described according to the sample The feature detection model of the pig body position of image and ear tag position training pig body and ear tag specifically includes:
Obtain the candidate region of pig body and the ear tag described in the sample image;
The feature of the candidate region is extracted using multilayer convolutional neural networks;
The candidate region is classified as pig body candidate region and ear tag candidate region according to the feature of extraction;
Non-maximum restraining method is utilized respectively to pig body candidate region and ear tag candidate region to merge, and is obtained described Pig body region and ear tag region in sample image.
3. the pig weight measuring method according to claim 1 based on image, which is characterized in that described according to the sample The profile point of the pig body contour point of image and the ear tag profile point training pig body and the ear tag returns mould Type specifically includes:
Feature extraction is carried out to the pig body image and the ear tag image using convolutional neural networks, obtains profile key point The corresponding contour point information of information and convolutional neural networks prediction;
Using convolutional neural networks to the pig body contour and ear tag profile progress regression forecasting in image.
4. the pig weight measuring method according to claim 1 based on image, which is characterized in that described according to the sample The profile point of the pig body contour point of image and the ear tag profile point training pig body and the ear tag returns mould Type specifically includes:
Feature extraction is carried out to the pig body image and the ear tag image using convolutional neural networks, obtains profile key point The corresponding contour point information of information and convolutional neural networks prediction;
It is optimized by formula (1) with the Euclidean distance loss function of L2 regularization term,
Wherein, m is the key point number on pig body contour or ear tag profile, PiI-th of corresponding profile manually to mark is sat Mark, f (x)iPass through i-th of profile coordinate of convolutional neural networks prediction, w for input picturetJoin for the weight of convolutional neural networks Number;
Using convolutional neural networks to the pig body contour and ear tag profile progress regression forecasting in image.
5. the pig weight measuring method according to claim 1 based on image, which is characterized in that described according to the pig body The actual size of the Pixel Dimensions of body, the Pixel Dimensions of the ear tag and the ear tag calculates the actual size of the pig body Predicted value specifically includes:
It selects the pig basal part of the ear and pigtail root as the calibration profile point in the pig body contour point, calculates the mark according to formula (2) Determine length in pixels of the Euclidean distance as the pig body in weight measuring and calculating image between profile point,
Wherein, (x1,y1), (x2,y2) it is the coordinate of the pig basal part of the ear point and the pigtail root point in weight measuring and calculating image Position;
Length in pixels d of the ear tag in weight measuring and calculating image is calculated according to ear tag profile point position2
The long l of practical body of the pig body is calculated according to formula (3)pig,
lpig=d1/d2*ltag (3)
Wherein, ltagFor the physical length of ear tag;
The wide W of practical body of the pig body is calculated according to same methodpig
Pig bust statistical model C is established according to the pig bust length of the pig bodypig=σ * Wpig, wherein CpigIt is long for pig bust Degree, σ is the coefficient obtained according to statistical information.
6. the pig weight measuring method according to claim 1 based on image, which is characterized in that the pig weight returns mould Type specifically: Weightpig=f (Cpig,lpig,K1…Ki), wherein
WeightpigFor pig weight, KiTo return i-th obtained of pig body contour point position.
7. the pig weight measuring method according to claim 1 based on image, which is characterized in that the mark of the figure of pig Including " thin ", " normal " and " fat " three kinds of figures.
8. a kind of pig weight calculating system based on image, using described in any one of claims 1 to 7 based on the pig of image Weight measuring method characterized by comprising
Image capture module is calculated image for capturing sample image and weight, is calculated to the sample image and the weight Pig body position and ear tag position and pig body contour point, ear tag profile point and figure in image are labeled;
Preprocessing module, for carrying out pretreatment and normalized to the sample image and weight measuring and calculating image;
Feature detection model training module, for according to the pig body position of the sample image and ear tag position instruction Practice the feature detection model of pig body and ear tag;
Profile point regression model training module, for according to the pig body contour point of the sample image and the ear tag wheel Exterior feature puts the profile point regression model of training the pig body and the ear tag;
Feature detection module, for determined using the feature detection model pig body position in weight measuring and calculating image and Ear tag position;
Profile point detection module, for determining the calibration profile in the weight measuring and calculating image using the profile point regression model Point position and ear tag profile point position;
Length in pixels computing module, for calculating the length in pixels of the pig body according to the calibration profile point position, according to Ear tag profile point position calculates the length in pixels of the ear tag;
Size prediction module, for according to the Pixel Dimensions of the pig body, the Pixel Dimensions of the ear tag and the ear tag Actual size calculate the actual size predicted value of the pig body;
Pig weight regression model training module, for actual size predicted value, the calibration profile point according to the pig body Pig weight regression model is established with corresponding pig weight in position;
Weight regression block, for the corresponding pig body of the weight measuring and calculating image to be calculated according to the pig weight regression model Weight.
CN201810835051.4A 2018-07-26 2018-07-26 Pig weight measuring and calculating method and system based on image Active CN109141248B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810835051.4A CN109141248B (en) 2018-07-26 2018-07-26 Pig weight measuring and calculating method and system based on image

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810835051.4A CN109141248B (en) 2018-07-26 2018-07-26 Pig weight measuring and calculating method and system based on image

Publications (2)

Publication Number Publication Date
CN109141248A true CN109141248A (en) 2019-01-04
CN109141248B CN109141248B (en) 2020-09-08

Family

ID=64798966

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810835051.4A Active CN109141248B (en) 2018-07-26 2018-07-26 Pig weight measuring and calculating method and system based on image

Country Status (1)

Country Link
CN (1) CN109141248B (en)

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110288580A (en) * 2019-06-25 2019-09-27 深圳德里克设备有限公司 Measurement method, measuring device and the readable storage medium storing program for executing of livestock weight
CN110296660A (en) * 2019-06-26 2019-10-01 北京海益同展信息科技有限公司 Livestock body ruler detection method and device
CN110378953A (en) * 2019-07-17 2019-10-25 重庆市畜牧科学院 A kind of method of spatial distribution behavior in intelligent recognition swinery circle
CN110426112A (en) * 2019-07-04 2019-11-08 平安科技(深圳)有限公司 Live pig weight measuring method and device
CN110672189A (en) * 2019-09-27 2020-01-10 北京海益同展信息科技有限公司 Weight estimation method, device, system and storage medium
CN111639777A (en) * 2019-03-01 2020-09-08 北京海益同展信息科技有限公司 Method and device for estimating target weight
CN111860652A (en) * 2020-07-22 2020-10-30 中国平安财产保险股份有限公司 Method, device, equipment and medium for measuring animal body weight based on image detection
CN113068657A (en) * 2021-03-31 2021-07-06 重庆市畜牧技术推广总站 Intelligent efficient pig raising method and system
CN113096178A (en) * 2021-04-25 2021-07-09 中国农业大学 Pig weight estimation method, device, equipment and storage medium
CN113177564A (en) * 2021-05-16 2021-07-27 河南牧原智能科技有限公司 Computer vision pig key point identification method
CN113449638A (en) * 2021-06-29 2021-09-28 西藏新好科技有限公司 Pig image ideal frame screening method based on machine vision technology
WO2023060777A1 (en) * 2021-10-13 2023-04-20 华南农业大学 Pig body size and weight estimation method based on deep learning

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002286421A (en) * 2001-03-28 2002-10-03 Hideo Minagawa Apparatus for measuring weight of animal
CN101144705A (en) * 2007-07-25 2008-03-19 中国农业大学 Method for monitoring pig growth using binocular vision technology
CN103884280A (en) * 2014-03-14 2014-06-25 中国农业大学 Mobile system for monitoring body sizes and weights of pigs in multiple pigsties
WO2015050929A1 (en) * 2013-10-01 2015-04-09 The Children's Hospital Of Philadelphia Image analysis for predicting body weight in humans
CN104657717A (en) * 2015-02-12 2015-05-27 合肥工业大学 Pedestrian detection method based on layered kernel sparse representation
JP2016059300A (en) * 2014-09-17 2016-04-25 国立大学法人広島大学 Cow body diagnostic system and cow body diagnostic method
CN105651776A (en) * 2015-12-30 2016-06-08 中国农业大学 Device and method for automatically grading beef carcass meat yield based on computer vision
CN105784083A (en) * 2016-04-05 2016-07-20 北京农业信息技术研究中心 Cow shape measuring method and cow shape measuring system based on stereo vision technology
CN106296430A (en) * 2015-05-22 2017-01-04 中国农业科学院农业信息研究所 A kind of contactless herding sign information harvester and method
CN106529006A (en) * 2016-11-04 2017-03-22 北京农业信息技术研究中心 Depth image-based broiler growth model fitting method and apparatus
CN106529400A (en) * 2016-09-26 2017-03-22 深圳奥比中光科技有限公司 Mobile terminal and human body monitoring method and device
CN107180438A (en) * 2017-04-26 2017-09-19 清华大学 Estimate yak body chi, the method for body weight and corresponding portable computer device
CN107194987A (en) * 2017-05-12 2017-09-22 西安蒜泥电子科技有限责任公司 The method being predicted to anthropometric data
CN107680130A (en) * 2017-09-30 2018-02-09 深圳市云之梦科技有限公司 One kind is based on the somatometric method and system of image

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002286421A (en) * 2001-03-28 2002-10-03 Hideo Minagawa Apparatus for measuring weight of animal
CN101144705A (en) * 2007-07-25 2008-03-19 中国农业大学 Method for monitoring pig growth using binocular vision technology
WO2015050929A1 (en) * 2013-10-01 2015-04-09 The Children's Hospital Of Philadelphia Image analysis for predicting body weight in humans
CN103884280A (en) * 2014-03-14 2014-06-25 中国农业大学 Mobile system for monitoring body sizes and weights of pigs in multiple pigsties
JP2016059300A (en) * 2014-09-17 2016-04-25 国立大学法人広島大学 Cow body diagnostic system and cow body diagnostic method
CN104657717A (en) * 2015-02-12 2015-05-27 合肥工业大学 Pedestrian detection method based on layered kernel sparse representation
CN106296430A (en) * 2015-05-22 2017-01-04 中国农业科学院农业信息研究所 A kind of contactless herding sign information harvester and method
CN105651776A (en) * 2015-12-30 2016-06-08 中国农业大学 Device and method for automatically grading beef carcass meat yield based on computer vision
CN105784083A (en) * 2016-04-05 2016-07-20 北京农业信息技术研究中心 Cow shape measuring method and cow shape measuring system based on stereo vision technology
CN106529400A (en) * 2016-09-26 2017-03-22 深圳奥比中光科技有限公司 Mobile terminal and human body monitoring method and device
CN106529006A (en) * 2016-11-04 2017-03-22 北京农业信息技术研究中心 Depth image-based broiler growth model fitting method and apparatus
CN107180438A (en) * 2017-04-26 2017-09-19 清华大学 Estimate yak body chi, the method for body weight and corresponding portable computer device
CN107194987A (en) * 2017-05-12 2017-09-22 西安蒜泥电子科技有限责任公司 The method being predicted to anthropometric data
CN107680130A (en) * 2017-09-30 2018-02-09 深圳市云之梦科技有限公司 One kind is based on the somatometric method and system of image

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
SOMAYE AMRAEI: "Application of computer vision and support vector regression for weight prediction of live broiler chicken", 《ENGINEERING IN AGRICULTURE》 *
张凯等: "基于计算机视觉术育肥猪体重分析研究", 《农机化研究》 *
石晨等: "基于LabVIEW的双目立体视觉系统估测猪体重方法", 《中国畜牧兽医学会信息技术分会第十二届学术研讨会论文集》 *
郝雪萍: "基于图像处理的杜泊羊体重估算模型研究", 《中国优秀硕士学位论文全文数据库 信息科技辑》 *

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111639777B (en) * 2019-03-01 2023-09-29 京东科技信息技术有限公司 Method and device for estimating target body weight
CN111639777A (en) * 2019-03-01 2020-09-08 北京海益同展信息科技有限公司 Method and device for estimating target weight
CN110288580A (en) * 2019-06-25 2019-09-27 深圳德里克设备有限公司 Measurement method, measuring device and the readable storage medium storing program for executing of livestock weight
CN110296660A (en) * 2019-06-26 2019-10-01 北京海益同展信息科技有限公司 Livestock body ruler detection method and device
CN110426112A (en) * 2019-07-04 2019-11-08 平安科技(深圳)有限公司 Live pig weight measuring method and device
CN110378953A (en) * 2019-07-17 2019-10-25 重庆市畜牧科学院 A kind of method of spatial distribution behavior in intelligent recognition swinery circle
CN110672189A (en) * 2019-09-27 2020-01-10 北京海益同展信息科技有限公司 Weight estimation method, device, system and storage medium
CN111860652A (en) * 2020-07-22 2020-10-30 中国平安财产保险股份有限公司 Method, device, equipment and medium for measuring animal body weight based on image detection
CN113068657B (en) * 2021-03-31 2022-04-08 重庆市畜牧技术推广总站 Intelligent efficient pig raising method and system
CN113068657A (en) * 2021-03-31 2021-07-06 重庆市畜牧技术推广总站 Intelligent efficient pig raising method and system
CN113096178A (en) * 2021-04-25 2021-07-09 中国农业大学 Pig weight estimation method, device, equipment and storage medium
CN113177564A (en) * 2021-05-16 2021-07-27 河南牧原智能科技有限公司 Computer vision pig key point identification method
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
WO2023060777A1 (en) * 2021-10-13 2023-04-20 华南农业大学 Pig body size and weight estimation method based on deep learning

Also Published As

Publication number Publication date
CN109141248B (en) 2020-09-08

Similar Documents

Publication Publication Date Title
CN109141248A (en) Pig weight measuring method and system based on image
WO2021000423A1 (en) Pig weight measurement method and apparatus
CN107180438B (en) Method for estimating size and weight of yak and corresponding portable computer device
CN109785337B (en) In-column mammal counting method based on example segmentation algorithm
Yu et al. Segmentation and measurement scheme for fish morphological features based on Mask R-CNN
CN108961330A (en) The long measuring method of pig body and system based on image
KR102062609B1 (en) A portable weighting system for livestock using 3D images
Salau et al. Feasibility of automated body trait determination using the SR4K time-of-flight camera in cow barns
CN108961269B (en) Pig weight measuring and calculating method and system based on image
Xiao et al. Cow identification in free-stall barns based on an improved Mask R-CNN and an SVM
CN113920453A (en) Pig body size weight estimation method based on deep learning
CN111666855B (en) Animal three-dimensional parameter extraction method and system based on unmanned aerial vehicle and electronic equipment
He et al. Automatic weight measurement of pigs based on 3D images and regression network
CN110969654A (en) Corn high-throughput phenotype measurement method and device based on harvester and harvester
CN108830856B (en) GA automatic segmentation method based on time series SD-OCT retina image
CN112016497A (en) Single-view Taijiquan action analysis and assessment system based on artificial intelligence
CN115240087A (en) Tree barrier positioning analysis method and system based on binocular stereo vision and laser point cloud
Shi et al. Automatic estimation of dairy cow body condition score based on attention-guided 3D point cloud feature extraction
CN109344917A (en) A kind of the species discrimination method and identification system of Euproctis insect
CN112907546B (en) Non-contact measuring device and method for beef scale
CN113920138A (en) Cow body size detection device based on RGB-D camera and detection method thereof
CN116739739A (en) Loan amount evaluation method and device, electronic equipment and storage medium
CN113706512B (en) Live pig weight measurement method based on deep learning and depth camera
KR102403791B1 (en) Weight measurement system using livestock photographing device
KR102289640B1 (en) A contactless mobile weighting system for livestock using asymmetric stereo cameras

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP03 Change of name, title or address

Address after: Room 203, Floor 2, Building 6, Qinghe Xisanqi East Road, Haidian District, Beijing 100,089

Patentee after: Beijing Shenzhi Hengji Technology Co.,Ltd.

Address before: 0706-003, 113 Zhichun Road, Haidian District, Beijing 100086

Patentee before: SHENYUAN HENGJI TECHNOLOGY CO.,LTD.

CP03 Change of name, title or address