CN109141256A - A kind of crops Size Measuring System and method - Google Patents

A kind of crops Size Measuring System and method Download PDF

Info

Publication number
CN109141256A
CN109141256A CN201811233383.1A CN201811233383A CN109141256A CN 109141256 A CN109141256 A CN 109141256A CN 201811233383 A CN201811233383 A CN 201811233383A CN 109141256 A CN109141256 A CN 109141256A
Authority
CN
China
Prior art keywords
image
seed
crops
diode
mounting table
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
CN201811233383.1A
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 Agricultural University AHAU
Original Assignee
Anhui Agricultural University AHAU
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 Agricultural University AHAU filed Critical Anhui Agricultural University AHAU
Priority to CN201811233383.1A priority Critical patent/CN109141256A/en
Publication of CN109141256A publication Critical patent/CN109141256A/en
Pending legal-status Critical Current

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
    • G01B11/022Measuring arrangements characterised by the use of optical techniques for measuring length, width or thickness by means of tv-camera scanning

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Length Measuring Devices By Optical Means (AREA)

Abstract

The invention discloses a kind of crops Size Measuring System, system includes: image collecting device, mounting table is rotated, in the viewfinder range of image collecting device;Processing unit is connected with image collecting device;Rotation mounting table includes: that fixing seat is connected with the first end of second support respectively, the first end of first support is connected, and the bottom of fixing seat is fixedly connected with pedestal;Irradiation equipment is connected with the second end of second support respectively, the second end of first support is connected, and the bottom of irradiation equipment is fixedly connected with fixing seat;Mounting table is oppositely arranged with image collecting device, and crops to be tested are placed on the object disposing platform of mounting table;Image collecting device is connect with fixing seat;The object disposing platform of mounting table rotates under driving device driving.And a kind of crops dimension measurement method is provided, using the embodiment of the present invention, realize the size of automatic measurement measurement crops, and structure is simple, detachably, is easy to carry about with one, installation cost is cheap.

Description

A kind of crops Size Measuring System and method
Technical field
The present invention relates to crops size measurement technique field more particularly to a kind of crops Size Measuring System and sides Method.
Background technique
In China's agricultural production, wheat and rice occupy most of national Grain Development, and China is since 20 generation The 50's of recording have introduced cereal tune and broadcast machine, cotton planter etc..Seeding machinery is guaranteeing increases in grain production, is pushing plant production development In advance in agricultural science and technology, there is extremely important status and effect.Present more and more agricultural mechanization persons draw Traditional cultivated method, and modern farming technique and mechanization means are combined, a collection of seeding machinery is had developed, successively in order to meet The production and improvement of accurate Agricultural Machinery Equipment, have to accurately measure for the various aspects physical characteristic of crop seeds.For example, The determination of row's grain mouth size of wheat seeder has to the size according to selected good seed, could protect in this way The accuracy for demonstrate,proving sowing, can improve grain-production efficiency, improve the germination percentage of seed, promote the grain quality of harvest, full Requirement of the sufficient people to grain quality.Seeding machinery aspect of performance is being improved, the measurement of the physical characteristic of crop kernels is especially It is important, especially in terms of rice size measurement.Currently, the most common method of measurement seed sizes, is surveyed using vernier caliper Amount.There are following deficiencies for this measurement method: contact type measurement is easily-deformable.Seed and slide calliper rule contact site are easily-deformable, produce Raw measurement error;Measurement position inaccuracy, seed sizes are smaller or in irregular shape, and three axial positions are difficult to determine;People The big measurement of work fluctuation of service, especially fine grain seed is easy fatigue, generates error;Speed is slow.Use vernier caliper Crop seeds size is measured, accuracy is relatively low, error is relatively large, measuring speed is slow.
Summary of the invention
The embodiment of the present invention is designed to provide a kind of crops Size Measuring System and method, it is intended to which realization passes through rotation Turn the rotation of mounting table, automatic measurement measures the size of crops, and structure is simple, detachably, is easy to carry about with one, installation cost It is cheap.Specific technical solution is as follows:
In order to achieve the above objectives, the embodiment of the invention provides a kind of crops Size Measuring System, the system comprises:
Image collecting device,
Mounting table is rotated, in the viewfinder range of described image acquisition device;
Processing unit is connected with described image acquisition device;
Wherein, the rotation mounting table includes: pedestal, mounting table, irradiation equipment, first support, second support, fixation Seat, motor driver;
The fixing seat is connected with the first end of the second support respectively, the first end of the first support is connected, institute The bottom for stating fixing seat is fixedly connected with the base;
The irradiation equipment is connected with the second end of the second support respectively, the second end of the first support is connected, And the bottom of the irradiation equipment is fixedly connected with the fixing seat;
The mounting table is oppositely arranged with described image acquisition device, and crops to be tested are placed in the glove of the mounting table On platform, the bottom of mounting table is fixedly connected with the fixing seat;
Described image acquisition device is connect with the fixing seat;The object disposing platform of the mounting table is under driving device driving Rotation.
In a kind of implementation of the invention, the mounting table includes: the object disposing platform, at least one rotation axis, often Gear is installed in one rotation axis, and is intermeshed movement between gear, the object disposing platform is placed in the top of rotation axis.
In a kind of implementation of the invention, the upper end of the transmission shaft connects the plane disc, the gear and institute Driving device is stated to be connected.
In a kind of implementation of the invention, the driving device includes: low profile gear motor, motor-drive circuit;Institute Geared sleeve is stated in the low profile gear motor, the low profile gear motor is connected with the motor-drive circuit.
In a kind of implementation of the invention, the motor-drive circuit, comprising:
Motor drive ic, the first light emitting diode, the second light emitting diode, resistance;
First output end of the motor drive ic is connected with one end of the first resistor, the first resistor it is another One end is connected with the cathode of the anode of first light emitting diode, second light emitting diode, the motor drive ic Second output terminal be connected with the anode of the cathode of first light emitting diode, second light emitting diode, the motor The first output end and second output terminal of driving chip are connected with low profile gear motor.
In a kind of implementation of the invention, the motor driver further include: first diode, the second diode, Third diode, the 4th diode;
First output end of the motor drive ic and the anode of the first diode and the third diode Cathode is connected;
The anode and the 4th diode of the second output terminal of the motor drive ic and second diode Cathode is connected;
The cathode connection operating voltage VCC of the first diode, second diode, the third diode, institute State the plus earth of the 4th diode.
It further include start-up circuit in a kind of implementation of the invention, the start-up circuit includes: pressure sensor, AD Converter, first comparator, the second comparator, photoelectrical coupler, second resistance, 3rd resistor, the 4th resistance, the 5th resistance, Voltage VCC, described and door;
The pressure sensor is connected with the AD converter, and the AD converter and the forward direction of the first comparator are defeated Enter end to be connected, the reverse input end of the first comparator is connected to the sliding end of the second resistance, the second resistance One end ground connection, the other end connect the voltage VCC;
The first input end of the photoelectrical coupler is connected with the operating voltage, another input of the photoelectrical coupler End is grounded by 3rd resistor, and the output end of the photoelectrical coupler is connected, simultaneously with the positive input of second comparator It is filtered and is grounded by the 4th resistance, the sliding end phase of the reverse input end of second comparator and the 5th resistance Even, one end ground connection of the 5th resistance, the other end connect the voltage VCC;
The output end of the first comparator is connected to an input terminal with door, the output of second comparator End is connected to described another input terminal with door, the output end and motor drive ic supply voltage end with door It is connected;And the pressure sensor is arranged on the plane disc.
In addition, the present invention also provides a kind of crops dimension measurement methods, which comprises
From collected seed video image, the video frame images of seed are obtained;
Detection zone is extracted from each video frame images, is converted to colored frame image using greyscale transformation operator Gray level image;
According to camera imaging model, the coordinate of gridiron pattern calibrated and calculated camera is utilized;
The bianry image for calculating each gray level image primarily determines seed region, obtains the bianry image in seed region;
The bianry image in the seed region is traversed using connection Filtering Template, obtains connected region;
Minimum extraneous rectangle fitting is carried out to each connected domain, four apex coordinates of each rectangle is obtained, calculates The length and width of rectangle out calculate the length data of each rectangle, width data and altitude information in the video frame images;
In conjunction with the coordinate of length data, width data and the altitude information and camera that calculate, Pixel Dimensions are turned Actual physical size is turned to, target length data, target width data and object height data are obtained.
In a kind of implementation of the invention, the bianry image for calculating each gray level image primarily determines seed Region, the step of obtaining the bianry image in seed region, comprising:
Before placing seed, the preceding N frame image I of continuous acquisition video sequence1, I2..., IN, by the N frame image Effective coverage in respective pixel gray value grey scale pixel value of the average value as background frames image, calculation formula is as follows:
Wherein, B (x, y) indicates the corresponding grey scale pixel value of pixel (x, y) in background frames image, It(x, y) indicates the N T frame image is in the corresponding grey scale pixel value of pixel (x, y) in frame image;
Calculate the standard deviation sigma of the grey scale pixel value of all pixels point in the background frames image B (x, y);
By the t frame image I of seedt(x, y) and background frames image B (x, y) subtract each other to obtain error image, to error image Threshold segmentation is carried out, threshold value is set as 3 σ, if current pixel value is greater than the threshold value of setting, which is candidate seed picture Vegetarian refreshments is set as 255, is otherwise background pixel point, is set as 0, obtains bianry image Ft(x, y),
Noise is filtered out according to morphological operation, the pseudo- seed in seed region is eliminated using the area features of image, obtains seed Grain bianry image region.
It is described that minimum extraneous rectangle fitting is carried out to each connected domain in a kind of implementation of the invention, it obtains every Four apex coordinates of one rectangle, calculate the length and width of rectangle, calculate the length of each rectangle in the video frame images The step of data, width data and altitude information, comprising:
Each connected region is marked;
According to flag sequence, minimum extraneous rectangle fitting is carried out to each connected domain one by one, writes down square clockwise Three apex coordinates of shape, then the length data of rectangle and width data are respectively as follows:
Wherein, three apex coordinates of rectangle are respectively (x1,y1)、(x2,y2)、(x3,y3), L is length data, and W is width Degree evidence;
Length data and width data in continuous statistics M frame image, extract the maximum value and minimum value in L, maximum value The major axis dimension of corresponding seed, minimum value correspond to the minor axis dimension of seed, extract in the width data in M frame image continuous The constant width data of multiframe is then altitude information;
According to the camera calibration matrix of acquisition, by major axis dimension, minor axis dimension and high turn in the image coordinate system of seed It is changed to actual three shaft size under world coordinate system.
Using the automatic automatic measurement system of crops size provided by the invention and method, realize:
1, by rotating the rotation of mounting table, automatic measurement measures the size of crops, and structure is simple, detachably, easily In carrying, installation cost is cheap;
2, by the irradiation equipment improving image quality of setting, the measurement accuracy of seed is improved;
3, automatic detection is given in the case where light intensity is sufficient and detects that the object disposing platform for rotating mounting table has glove Motor drive ic power supply, carries out motor rotation, otherwise rotates without motor, can be into while realizing automatic measurement The energy conservation of one step;
4, a kind of automatic rice size acquisition methods are provided, the video frame images got by image collecting device into Row automatically analyzes, and exports the collected size signal of institute.
Detailed description of the invention
Fig. 1 is a kind of structure chart of crops Size Measuring System in the embodiment of the present invention;
Fig. 2 is another mechanism map of crops Size Measuring System in the embodiment of the present invention;
Fig. 3 is a kind of circuit diagram of crops Size Measuring System in the embodiment of the present invention;
Fig. 4 is another circuit diagram of crops Size Measuring System in the embodiment of the present invention;
Fig. 5 is a kind of flow diagram of crops dimension measurement method in the embodiment of the present invention;
Fig. 6 is a kind of effect diagram of crops dimension measurement method in the embodiment of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts it is all its His embodiment, shall fall within the protection scope of the present invention.
The embodiment of the present invention is directed to the dimensional measurement of fine grain, for example, peanut, soybean, corn, red bean, mung bean, pea The crops such as beans, glutinous millet carry out dimensional measurement.Application range is suitable for carrying out the ruler before the sampling observation of crops, scientific experiment application The fields such as very little detection.
Three shaft size of crop kernels of a variety of small sizes may be implemented in crops Size Measuring System provided by the invention Automatic measurement, the foundation of design, for example, seed of the machinery such as sowing, seeding can be provided for various agricultural machinery sizes Outlet provides size design foundation, for manufacture agricultural machinery cutting, threshing, clean and arrange grain etc. finely machine provide it is more acurrate Ground seed data are supported.
As shown in Figure 1, a kind of crops Size Measuring System provided by the invention, the system comprises: image collector 2 are set, mounting table 3 is rotated, in the viewfinder range of described image acquisition device 2;Processing unit 1 is acquired with described image and is filled 2 are set to be connected;
Wherein, the rotation mounting table 3 includes: pedestal 31, mounting table 32, irradiation equipment 33, first support 34, second Bracket 35, fixing seat 36, motor driver;
The fixing seat 36 is connected with the first end of the second support 35 respectively, the first end phase of the first support 34 Even, the bottom of the fixing seat 36 is fixedly connected with the pedestal 31;The irradiation equipment 33 respectively with the second support 35 Second end be connected, the second end of the first support 34 is connected, and the bottom of the irradiation equipment 33 and the fixing seat 36 It is fixedly connected;The mounting table 32 is oppositely arranged with described image acquisition device 2, and crops to be tested are placed in the mounting table On 32 object disposing platform 13, the bottom of mounting table 32 is fixedly connected with the fixing seat 36;Described image acquisition device 2 and institute State the connection of fixing seat 36;The object disposing platform 13 of the mounting table 32 rotates under driving device driving.
It is understood that illuminated to the crops being placed on mounting table 32 by irradiation equipment 33, avoid due to Light is too weak to cause 2 acquired image effects of image collecting device too poor, so that the treatment effect of processing unit 1 It is bad.
It should be noted that the rotation of mounting table 32 is driven by motor driver, so that image collecting device 2 acquires Multiple angle pictures of crops on to mounting table 32.Specifically, image processing process is not protection point of the invention, this hair It is bright using existing processing unit for realizing image processing process, therefore, the solution of the present invention do not include software realization Image procossing.
Therefore, by driving mounting table 32, irradiation equipment 33, first support 34, second support 35, fixing seat 36, motor Dynamic device fixation is placed on pedestal 31, and it is simple to be capable of forming structure, detachably, is easy to carry about with one, the cheap crops of installation cost Size Measuring System.
In a kind of implementation of the invention, the mounting table 32 includes: the object disposing platform 13, at least one rotation axis 12, gear is installed in each rotation axis 12, and movement is intermeshed between gear, the object disposing platform 13 is placed in rotation The top of axis 12.
As shown in Fig. 2, by being intermeshed movement between gear 7, to drive the rotation of object disposing platform 13.In addition, every The corresponding circular plane of one rotation axis 12, so that object disposing platform 13 is constituted, in addition, also can connect in rotation axis 12 One complete platform plane constitutes object disposing platform 13.
In a kind of implementation of the invention in, the upper end of the transmission shaft 12 connect the plane disc 13, it is described Gear is connected with the driving device.Specifically, the driving device includes: low profile gear motor 6, motor-drive circuit;Institute Geared sleeve is stated in the low profile gear motor 6, the low profile gear motor 6 is connected with the motor-drive circuit.
The rotation of low profile gear motor 6 is driven by motor-drive circuit, to drive the rotation of gear, drive is entirely set The rotation of object platform 13.
In a kind of implementation of the invention, the motor-drive circuit, comprising: motor drive ic U1, first shine Diode L1, the second light emitting diode L2, resistance R1;The first output end OUT1 of the motor drive ic U1 and described the One end of one resistance R1 is connected, the anode of the other end of the first resistor R1 and the first light emitting diode L1, described the The cathode of two light emitting diode L2 is connected, the second output terminal OUT2 of the motor drive ic U1 and described first luminous two The cathode of pole pipe L1, the anode of the second light emitting diode L2 are connected, the first output end of the motor drive ic U1 OUT1 and second output terminal OUT2 are connected with low profile gear motor 6.
Specifically, the input terminal of motor drive ic U1 can be connected with processing unit 1, transmitted by receiving and processing device 1 Instruction, the rotation direction and its operating condition of driving motor, since the part can be achieved by the prior art, at this Invention does not illustrate.
Motor drive ic U1 model L298N, L298N are dedicated drive integrated circults, belong to dual H-bridge integrated circuit, The driving plate can drive two-way direct current generator, when the ENA high level of enable end, at low profile gear motor 6 (motor connected) In enabled state, if IN1 meets 5V, IN2 ground connection at this time, low profile gear motor 6 is rotated forward, if IN1 is grounded at this time, IN2 meets 5V, small Type decelerating motor 6 inverts.Since P1 interface connects low profile gear motor 6, then passing through the first light emitting diode L1, the second hair Optical diode L2, which can be respectively indicated, is connected to each output end, and to show the state of doing of current motor, circuit realizes letter It is single.
In a kind of implementation of the invention, the motor driver further include: first diode D1, the second diode D2, third diode D3, the 4th diode D4;The first output end OUT1 and the described 1st of the motor drive ic U1 The anode of pole pipe D1 is connected with the cathode of the third diode D3;The second output terminal OUT2 of the motor drive ic U1 It is connected with the cathode of the anode of the second diode D2 and the 4th diode D4;The first diode D1, described The cathode of two diode D2 connects operating voltage VCC, the plus earth of the third diode D3, the 4th diode D4.
By D1-D4, this 4 diodes are known as freewheeling diode, prevent voltage and current to be mutated, play the work of smooth electric current With guaranteeing that the fluctuation of the driving current of motor is smaller.
It further include start-up circuit in a kind of implementation of the invention, the start-up circuit includes: pressure sensor, AD Converter, first comparator U11A, the second comparator U11B, photoelectrical coupler U13, second resistance R2,3rd resistor R3, Four resistance R4, the 5th resistance R5, voltage VCC, described and door U12;The pressure sensor is connected with the AD converter, institute It states AD converter to be connected with the positive input of the first comparator U11A, the reversed input of the first comparator U11A End is connected to the sliding end of the second resistance R2, and one end ground connection of the second resistance R2, the other end connect the voltage VCC;The first input end of the photoelectrical coupler U13 is connected with the operating voltage, and the photoelectrical coupler U13's is another End is grounded by 3rd resistor R3, and the output end of the photoelectrical coupler U13 and the positive of the second comparator U11B input End is connected and by the 4th resistance R4 filtering ground connection, the reverse input end and the described 5th of the second comparator U11B The sliding end of resistance R5 is connected, and one end ground connection of the 5th resistance R5, the other end connect the voltage VCC;First ratio Output end compared with device U11A is connected to an input terminal with door U12, the output end connection of the second comparator U11B To described and another input terminal of door U12, the output end and the motor drive ic U1 supply voltage with door U12 VSS is held to be connected;And the pressure sensor is arranged on the plane disc 13.
When plane disc 13 is provided with pressure sensor, pressure can be collected by being placed on plane disc 13 in crops Signal be converted by AD converter the positive input that digital signal is sent to first comparator U11A, and first compares Device U11A reverse input end is input to the adjusting by second resistance R2 and changes, to improve flexible device.
It is understood that assuming that plane disc 13 is provided with pressure sensor, the forward direction of first comparator U11A is defeated Enter and hold input high level, first comparator U11A reverse input end input low level, then the output end of first comparator U11A is defeated High level out.
The light intensity that photoelectrical coupler U13 is received is different, causes the output valve of photoelectrical coupler U13 different, such as Photoelectrical coupler U13 receive intensity of illumination it is larger when, photoelectrical coupler U13 export high level to the second comparator U11B's Positive input, it is assumed that the partial pressure of the 5th resistance R5 sliding end is less than photoelectrical coupler U13 output valve at this time, then the second ratio Output compared with device U11B is high level.
It is understood that when light intensity is higher while having crops to be applied to plane disc 13 again, then necessarily needing Image Acquisition is carried out, the measurement of crops is then carried out.So needing to drive the rotation of plane disc 13 at this time, then just It needs that motor drive ic U1 is driven to work.
As shown in figure 3, the voltage of the work of the chip operating voltage VSS pin of motor drive ic U1 is 5V, so In the case that the output of first comparator U11A, the second comparator U11B are high level, the output with door U12 is similarly high Level, then start-up circuit can be passed through by being connected with door U12 with the chip operating voltage VSS pin of motor drive ic U1 Output control motor drive ic U1 work whether.
In a kind of implementation, it can be realized when in use using following process:
The first step on computers by the USB line connection of camera opens LED flat plate light source.
The start button on program interface is clicked at second step, opening program interface, and pop-up camera has turned on window, and journey Shooting picture is shown on sequence interface, i.e., correctly opens camera.
Third step presses the unlatching platform spin button on device, clicks and starts shooting button on program interface, and pop-up is clapped At the end of taking the photograph, LED flat plate light source and platform spin button can be closed.
4th step is clicked image procossing, is waited several seconds for, and window is completed in pop-up processing, and click data the Show Button can both be seen See that screen is display data, clicks and save data, can save the data in xls file.Data analysis button can incite somebody to action Data are shown with the pattern of statistical chart.
As shown in figure 5, a kind of crops dimension measurement method, which comprises
S501 obtains the video frame images of seed from collected seed video image.
It should be noted that the video image of specific region can be obtained using image capture device, when specific region is wrapped When containing seed, then the video image obtained is the seed video image comprising seed region.Video image is continuous Image when carrying out image analysis, needs to analyze image one by one, so carrying out video frame images acquisition from video.
Specifically, obtaining the mode that video frame images can use from the video of a period of time, to be syncopated as multiple figures As coming, using each image as a video frame images.
S502 extracts detection zone from each video frame images, using greyscale transformation operator by colored frame image Be converted to gray level image.
It should be noted that obtaining the video frame images of seed after the acquisition of progress seed video image, it is possible to understand that Be place seed region be it is fixed, according to the detection environment of practical seed placement region, extracted on current frame image Four points carry out straight line fitting calculating to extracted point, merge quadrangularly, as the interest region detected in quadrangle, I.e. effective detection zone.It can be further reduced the efficiency and speed that detection is improved to the detection on entire video frame images in this way Degree.
S503 utilizes the coordinate of gridiron pattern calibrated and calculated camera according to camera imaging model.
It is understood that the position of camera is fixed, so its coordinate is fixed.Then according to camera imaging mould Type and principle demarcate the transformation for realizing the photo coordinate system and world coordinate system of video camera using gridiron pattern.
S504 calculates the bianry image of each gray level image, primarily determines seed region, obtains the two-value in seed region Image.
Specifically, the realization process of step S504 can use following steps:
Background frames extract: before placing seed, illustratively, the preceding 30 frame image I of continuous acquisition video sequence1, I2..., I30, using the average value of respective pixel gray value in the effective coverage of the 30 frame image as the picture of background frames image Plain gray value, calculation formula are as follows:
Wherein, B (x, y) indicates the corresponding grey scale pixel value of pixel (x, y) in background frames image, It(x, y) is indicated should T frame image is in the corresponding grey scale pixel value of pixel (x, y) in 30 frame images.After obtaining background frames image B (x, y), calculate The standard deviation sigma of the grey scale pixel value of all pixels point, calculation formula are as follows in background frames;
Wherein, Num is all pixels number in background frames B (x, y) image, Bi(x, y) is i-th of picture in background frames image The gray value of element.
Seed region detection: a seed will be placed on each platform, by the frame image I of seedt(x, y) and background frames figure Picture B (x, y) subtracts each other to obtain error image, carries out Threshold segmentation to error image, threshold value is set as 3 σ, if current pixel value is big In the threshold value of setting, then the pixel is candidate seed pixel, is set as 255, is otherwise background pixel point, is set as 0, obtains Bianry image Ft(x, y) is shown below,
S505 traverses the bianry image in the seed region using connection Filtering Template, obtains connected region.
Then, it recycles morphological operation to filter out noise, the pseudo- seed in seed region is eliminated using the area features of image, The bianry image in seed region is traversed using 4 connection Filtering Templates, obtains connected region, and carry out to connected region Different numeral marks, the connected domain area minimum by calculating seed is greater than 2000, therefore deletes pixel point areas less than 2000 Connected domain, pseudo- seed can be effectively removed, obtain the bianry image in seed region.
S506 carries out minimum extraneous rectangle fitting to each connected domain, obtains four apex coordinates of each rectangle, The length and width for calculating rectangle calculate the length data of each rectangle in the video frame images, width data and high degree According to.
Specifically, the realization of step S506 can use:
Each connected region is marked;
It should be noted that multiple connected domains can be obtained after being filtered using connection Filtering Template, in order to improve Processing speed is not omitted and improved to Connected area disposal$, each connected region is marked, for example, connected region Number 50, then the number of 1-50 can be carried out, then 1-50 connected region is handled, specific processing sequence is not It limits.
According to flag sequence, minimum extraneous rectangle fitting is carried out to each connected domain one by one, writes down square clockwise Three apex coordinates of shape, then the length data of rectangle and width data are respectively as follows:
Wherein, three apex coordinates of rectangle are respectively (x1,y1)、(x2,y2)、(x3,y3), L is length data, and W is width Degree evidence;
Length data and width data in continuous statistics M frame image, extract the maximum value and minimum value in L, maximum value The major axis dimension of corresponding seed, minimum value correspond to the minor axis dimension of seed, extract in the width data in M frame image continuous The constant width data of multiframe is then altitude information;
According to the camera calibration matrix of acquisition, by major axis dimension, minor axis dimension and high turn in the image coordinate system of seed It is changed to actual three shaft size under world coordinate system.
It is assumed that target measurement seed 5 is shared in each image of acquisition, according to the revolving speed of motor, this 5 seed rotations 45 frame images can be acquired by turning around, and to this 45 frame image, repeat S504-S507, amounted to and executed 45 times, by continuous 45 frame Rectangular aspect data are remembered in imageWithExtract the maximum value and minimum in L Value, maximum value correspond to the major axis dimension of seed, and minimum value corresponds to the minor axis dimension of seed, and it is constant that continuous multiple frames are extracted in W Data, the data are the height of seed;It recycles camera calibration data to convert actual physical size for Pixel Dimensions, and carries out Graphical interfaces shows that interface display is as shown in Figure 6.
Minimum extraneous rectangle fitting is carried out to each connected domain, four apex coordinates of each rectangle is obtained, calculates The length and width of rectangle out count the length and width data of rectangle in continuous multiple frames seed image, with maximum in the rectangular aspect data of multiframe Value is length, and minimum value is width, and the constant data of multiframe are height, and camera calibration data is recycled to convert reality for Pixel Dimensions Physical size, and carry out graphical interfaces and show.
S507, in conjunction with the coordinate of length data, width data and the altitude information and camera that calculate, by pixel ruler It is very little to be converted into actual physical size, obtain target length data, target width data and object height data.
Specifically, according to the seed length data, width data and the altitude information that calculate, and according to image at As the coordinate of principle and camera, the realistic objective length data, target width data and object height data of seed are obtained, it should Process is to carry out the conversion process again of coordinate, does not do for the prior art and excessively repeats.
Therefore, using present invention embodiment shown in fig. 5, a kind of automatic rice size acquisition methods is provided, figure is passed through The video frame images got as acquisition device are automatically analyzed, and export the collected size signal of institute.
It is displayed data furthermore it is also possible to be arranged by screen.
1) present invention devises seed and places rotating mechanism, and the multi-party bitmap of seed can be realized using fixed monocular camera The acquisition of picture;
2) three shaft sizes that mature image processing techniques is used for small size crop kernels are measured in the present invention, collection figure As acquisition, image procossing, measurement data are shown, data storage is analyzed and one, easy to operate, reliable and stable;
3) measuring device of the invention reduces measurement mistake from light source point, physical mechanism and image processing algorithm etc. are many-sided Difference improves the measurement accuracy and measurement efficiency of seed.
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the scope of the present invention.It is all Any modification, equivalent replacement, improvement and so within the spirit and principles in the present invention are all contained in protection model of the invention In enclosing.

Claims (10)

1. a kind of crops Size Measuring System, which is characterized in that the system comprises:
Image collecting device (2),
It rotates mounting table (3), is located in the viewfinder range of described image acquisition device (2);
Processing unit (1) is connected with described image acquisition device (2);
Wherein, the rotation mounting table (3) include: pedestal (31), mounting table (32), irradiation equipment (33), first support (34), Second support (35), fixing seat (36), motor driver;
The fixing seat (36) is connected with the first end of the second support (35) respectively, the first end of the first support (34) It is connected, the bottom of the fixing seat (36) is fixedly connected with the pedestal (31);
The irradiation equipment (33) be connected with the second end of the second support (35) respectively, the first support (34) second End is connected, and the bottom of the irradiation equipment (33) is fixedly connected with the fixing seat (36);
The mounting table (32) is oppositely arranged with described image acquisition device (2), and crops to be tested are placed in the mounting table (32) on object disposing platform (13), the bottom of mounting table (32) is fixedly connected with the fixing seat (36);
Described image acquisition device (2) is connect with the fixing seat (36);The object disposing platform (13) of the mounting table (32) is driving The dynamic lower rotation of device driving.
2. a kind of crops Size Measuring System according to claim 1, which is characterized in that mounting table (32) packet Include: the object disposing platform (13), at least one rotation axis (12) are equipped with gear in each rotation axis (12), and gear it Between be intermeshed movement, the object disposing platform (13) is placed in the top of rotation axis (12).
3. a kind of crops Size Measuring System according to claim 2, which is characterized in that the transmission shaft (12) Upper end connects the plane disc (13), and the gear is connected with the driving device.
4. a kind of crops Size Measuring System according to claim 2 or 3, which is characterized in that the driving device packet It includes: low profile gear motor (6), motor-drive circuit;The geared sleeve is described small-sized to subtract on the low profile gear motor (6) Speed motor (6) is connected with the motor-drive circuit.
5. a kind of crops Size Measuring System according to claim 1, which is characterized in that the motor-drive circuit, Include:
Motor drive ic (U1), the first light emitting diode (L1), the second light emitting diode (L2), resistance (R1);
The first output end (OUT1) of the motor drive ic (U1) is connected with one end of the first resistor (R1), and described The cathode of the other end of one resistance (R1) and the anode of first light emitting diode (L1), second light emitting diode (L2) It is connected, the cathode of the second output terminal (OUT2) of the motor drive ic (U1) and first light emitting diode (L1), institute The anode for stating the second light emitting diode (L2) is connected, the first output end (OUT1) and second of the motor drive ic (U1) Output end (OUT2) is connected with low profile gear motor (6).
6. a kind of crops Size Measuring System according to claim 5, which is characterized in that the motor driver is also It include: first diode (D1), the second diode (D2), third diode (D3), the 4th diode (D4);
The first output end (OUT1) of the motor drive ic (U1) and the anode of the first diode (D1) and described the The cathode of three diodes (D3) is connected;
The anode of the second output terminal (OUT2) of the motor drive ic (U1) and second diode (D2) and described the The cathode of four diodes (D4) is connected;
Cathode connection operating voltage (VCC) of the first diode (D1), second diode (D2), the three or two pole Manage the plus earth of (D3), the 4th diode (D4).
7. a kind of crops Size Measuring System according to claim 5 or 6, which is characterized in that it further include start-up circuit, The start-up circuit includes: pressure sensor, AD converter, first comparator (U11A), the second comparator (U11B), photoelectricity coupling Clutch (U13), second resistance (R2), 3rd resistor (R3), the 4th resistance (R4), the 5th resistance (R5), voltage VCC and door (U12);
The pressure sensor is connected with the AD converter, the forward direction of the AD converter and the first comparator (U11A) Input terminal is connected, and the reverse input end of the first comparator (U11A) is connected to the sliding end of the second resistance (R2), institute State one end ground connection of second resistance (R2), the other end connects the voltage VCC;
The first input end of the photoelectrical coupler (U13) is connected with the operating voltage, the photoelectrical coupler (U13) it is another One input terminal is grounded by 3rd resistor (R3), the output end and second comparator of the photoelectrical coupler (U13) (U11B) positive input is connected and passes through the 4th resistance (R4) the filtering ground connection, second comparator (U11B) Reverse input end is connected with the sliding end of the 5th resistance (R5), and one end ground connection of the 5th resistance (R5), the other end connect Meet the voltage VCC;
The output end of the first comparator (U11A) is connected to an input terminal with door (U12), and described second compares The output end of device (U11B) is connected to described another input terminal with door (U12), the output end with door (U12) with it is described Motor drive ic (U1) supply voltage end (VSS) is connected;
And the pressure sensor is arranged on the plane disc (13).
8. a kind of crops dimension measurement method, which is characterized in that the described method includes:
From collected seed video image, the video frame images of seed are obtained;
Detection zone is extracted from each video frame images, colored frame image is converted into gray scale using greyscale transformation operator Image;
According to camera imaging model, the coordinate of gridiron pattern calibrated and calculated camera is utilized;
The bianry image for calculating each gray level image primarily determines seed region, obtains the bianry image in seed region;
The bianry image in the seed region is traversed using connection Filtering Template, obtains connected region;
Minimum extraneous rectangle fitting is carried out to each connected domain, four apex coordinates of each rectangle is obtained, calculates square The length and width of shape calculate the length data of each rectangle, width data and altitude information in the video frame images;
In conjunction with the coordinate of length data, width data and the altitude information and camera that calculate, convert Pixel Dimensions to Actual physical size obtains target length data, target width data and object height data.
9. a kind of crops dimension measurement method according to claim 8, which is characterized in that described each gray scale of calculating The step of bianry image of image primarily determines seed region, obtains the bianry image in seed region, comprising:
Before placing seed, the preceding N frame image I of continuous acquisition video sequence1, I2..., IN, by having for the N frame image Grey scale pixel value of the average value of respective pixel gray value in region as background frames image is imitated, calculation formula is as follows:
Wherein, B (x, y) indicates the corresponding grey scale pixel value of pixel (x, y) in background frames image, It(x, y) indicates the N frame figure T frame image is in the corresponding grey scale pixel value of pixel (x, y) as in;
Calculate the standard deviation sigma of the grey scale pixel value of all pixels point in the background frames image B (x, y);
By the t frame image I of seedt(x, y) and background frames image B (x, y) subtract each other to obtain error image, carry out to error image Threshold segmentation, threshold value are set as 3 σ, if current pixel value is greater than the threshold value of setting, which is candidate seed pixel, 255 are set as, is otherwise background pixel point, is set as 0, obtain bianry image Ft(x, y),
Noise is filtered out according to morphological operation, the pseudo- seed in seed region is eliminated using the area features of image, obtains seed two It is worth image-region.
10. a kind of crops dimension measurement method according to claim 8 or claim 9, which is characterized in that described to each company Logical domain carries out minimum extraneous rectangle fitting, obtains four apex coordinates of each rectangle, calculates the length and width of rectangle, calculates institute The step of stating the length data of each rectangle, width data and altitude information in video frame images, comprising:
Each connected region is marked;
According to flag sequence, minimum extraneous rectangle fitting is carried out to each connected domain one by one, writes down rectangle clockwise Three apex coordinates, then the length data of rectangle and width data are respectively as follows:
Wherein, three apex coordinates of rectangle are respectively (x1,y1)、(x2,y2)、(x3,y3), L is length data, and W is width number According to;
Length data and width data in continuous statistics M frame image, extract the maximum value and minimum value in L, maximum value is corresponding The major axis dimension of seed, minimum value correspond to the minor axis dimension of seed, extract continuous multiple frames not in the width data in M frame image The width data of change is then altitude information;
According to the camera calibration matrix of acquisition, major axis dimension, minor axis dimension and height in the image coordinate system of seed are converted to Actual three shaft size under world coordinate system.
CN201811233383.1A 2018-10-23 2018-10-23 A kind of crops Size Measuring System and method Pending CN109141256A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811233383.1A CN109141256A (en) 2018-10-23 2018-10-23 A kind of crops Size Measuring System and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811233383.1A CN109141256A (en) 2018-10-23 2018-10-23 A kind of crops Size Measuring System and method

Publications (1)

Publication Number Publication Date
CN109141256A true CN109141256A (en) 2019-01-04

Family

ID=64809386

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811233383.1A Pending CN109141256A (en) 2018-10-23 2018-10-23 A kind of crops Size Measuring System and method

Country Status (1)

Country Link
CN (1) CN109141256A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050074146A1 (en) * 2003-09-17 2005-04-07 Advanta Technology, Ltd. Method and apparatus for analyzing quality traits of grain or seed
CN203772216U (en) * 2014-02-26 2014-08-13 北京大恒图像视觉有限公司 Die checking apparatus
CN107300360A (en) * 2017-08-10 2017-10-27 山西农业大学 A kind of shaft size fast algorithm of detecting of rain fed crops seed three
CN107860316A (en) * 2017-10-30 2018-03-30 重庆师范大学 Corn kernel three-dimensional parameter measurement apparatus and its measuring method
CN207516234U (en) * 2017-12-12 2018-06-19 佛山科学技术学院 A kind of device of optical projection tomography
CN208887574U (en) * 2018-10-23 2019-05-21 安徽农业大学 A kind of crops Size Measuring System

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050074146A1 (en) * 2003-09-17 2005-04-07 Advanta Technology, Ltd. Method and apparatus for analyzing quality traits of grain or seed
CN203772216U (en) * 2014-02-26 2014-08-13 北京大恒图像视觉有限公司 Die checking apparatus
CN107300360A (en) * 2017-08-10 2017-10-27 山西农业大学 A kind of shaft size fast algorithm of detecting of rain fed crops seed three
CN107860316A (en) * 2017-10-30 2018-03-30 重庆师范大学 Corn kernel three-dimensional parameter measurement apparatus and its measuring method
CN207516234U (en) * 2017-12-12 2018-06-19 佛山科学技术学院 A kind of device of optical projection tomography
CN208887574U (en) * 2018-10-23 2019-05-21 安徽农业大学 A kind of crops Size Measuring System

Similar Documents

Publication Publication Date Title
CN108323295B (en) A kind of seedling stage crop liquid manure based on multiple dimensioned habitat information detects and controls method and device
CN108830272A (en) Potato image collecting device and bud eye based on RGB-D camera identify and position method
Yang et al. Relationships between yield monitor data and airborne multidate multispectral digital imagery for grain sorghum
CN109765194A (en) Fructus lycii Production area recognition method based on high light spectrum image-forming technology
CN101210876A (en) Rice nutrient information measuring method based on visible/near infrared multispectral imaging
CN102819765B (en) A kind of milk somatic cell method of counting based on computer vision
CN111751376B (en) Rice nitrogen nutrition estimation method based on canopy image feature derivation
CN103808263A (en) High-throughput detection method for grain form parameters
WO2018074171A1 (en) Soil diagnosis method and soil condition improvement method
CN102855485B (en) The automatic testing method of one grow wheat heading
CN106471960A (en) A kind of novel intelligent seed planter
CN107860316A (en) Corn kernel three-dimensional parameter measurement apparatus and its measuring method
CN109827957A (en) A kind of rice leaf SPAD value estimating and measuring method based on computer vision and system
CN101339118A (en) Grain parameter automatic measuring equipment and method
Yuan et al. Diagnosis of nitrogen nutrition of rice based on image processing of visible light
CN105844632A (en) Rice plant identification and positioning method based on machine visual sense
CN110211099A (en) The wheat scab detection method and device of the comprehensive wheat head front and back sides state of an illness
CN114694047A (en) Corn sowing quality evaluation method and device
CN106568730B (en) A kind of rice yin-yang leaf fringe recognition methods based on Hyperspectral imaging near the ground
CN109141256A (en) A kind of crops Size Measuring System and method
CN116862456B (en) Traditional Chinese medicine production monitoring control system and method based on image processing
CN109668857A (en) Tealeaves total plate count detection device and method based on near-infrared hyper-spectral image technique
CN206951597U (en) A kind of Blueberry hierarchical detection system based on machine vision
CN208887574U (en) A kind of crops Size Measuring System
CN202452970U (en) Shot put measuring device based on rules and view field geometric figure calibration technology

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