BINOCULAR-VISION-BASED METHOD FOR TRACKING FRUIT SPACE ATTITUDE AND FRUIT SPACE MOTION

Information

  • Patent Application
  • 20220005209
  • Publication Number
    20220005209
  • Date Filed
    January 23, 2020
    4 years ago
  • Date Published
    January 06, 2022
    2 years ago
Abstract
A binocular-vision-based method for tracking fruit space attitude and fruit space motion, the method comprising: establishing a connected base coordinate system by taking a junction of a fruit and a fruit stem as an origin; statically photographing a feature point on the surface of the fruit and a point of the connected base coordinate system established at the junction of the fruit and the fruit stem; storing a photographed image; acquiring an inherent relationship between the feature point and the connected base coordinate system; photographing dynamic motion of the fruit; acquiring absolute coordinates of the feature point on the surface of the fruit; calculating, according to the inherent relationship between the feature point and the connected base coordinate system, absolute coordinates of a point of the connected base coordinate system at each moment corresponding to each frame of image; and respectively calculating the displacement, instantaneous speed and instantaneous acceleration of the fruit, calculating swing angular displacement and swing angular acceleration of the fruit, and calculating a fruit torsion angular speed and a fruit torsion angular acceleration at the moment t. The study of a fruit motion state in the field of forest fruit harvest through vibration is performed, so that the motion of fruits can be better tracked.
Description
FIELD OF THE INVENTION

The present invention belongs to the field of fruit tree harvesting in agriculture and forestry, and specifically relates to a binocular-vision-based method for tracking fruit space attitude and fruit space motion, which is used in the study of fruit motion states in the field of fruit vibration harvesting.


BACKGROUND OF THE INVENTION

Fruit harvesting is the most time-consuming and laborious part of fruit production. For dried fruits such as red dates, walnuts, and ginkgo, the most effective harvesting method is mechanical vibration harvesting. The harvesting effect of its vibration harvesting machinery is related to many factors, including the growth characteristics of fruit trees and the working parameters of mechanical vibration. The research on the vibratory harvesting of forest fruits is more about viewing the tree itself as a second-order system, detecting the relationship between excitation and response, and measuring the overall stiffness and damping ratio of the tree. In recent years, more detailed research has been carried out in China and a simplified mechanical model of tree trunk and branch vibration has been established. Through experiments and theoretical calculations, it is believed that the cantilever straight beam model is more accurate, which provides a theoretical basis for the research of vibratory harvesting machinery. However, there are still gaps in the research on the movement of fruits during the vibration harvesting process, in order to explain the principle of vibratory fruit dropping in more detail, it is necessary to study the movement of fruits.


SUMMARY OF THE INVENTION

The technical problem to be solved by the present invention is to provide a binocular-vision-based method for tracking fruit space attitude and fruit space motion in response to the above-mentioned shortcomings of the prior art. This binocular-vision-based method for tracking fruit space attitude and fruit space motion method is aimed at the research of fruit movement state in the field of forest fruit vibration harvesting, which can better track the movement of fruit.


In order to achieve the above-mentioned technical objectives, the technical solutions adopted by the present invention are:


a binocular-vision-based method for tracking fruit space attitude and fruit space motion, comprising:


(1) marking three feature points custom-charactercustom-characterC3 on a surface of a fruit;


(2) establishing a connected base coordinate system by taking a junction of the fruit and a fruit stem as an origin, a X axis, a Y axis, and a Z axis of the connected base coordinate system are marked as a X connected-axis, a Y connected-axis and a Z connected-axis, respectively, and the origin of the connected base coordinate system is marked as O1, an end point of the unit vector in a positive direction of the X connected-axis is marked as X1, an end point of the unit vector in a positive direction of the Y connected-axis is marked as Y1, an end point of the unit vector in a positive direction of the Z connected-axis is marked as Z1;


(3) establishing a public reference base coordinate system;


(4) statically photographing the three feature points on the surface of the fruit and connected base coordinate system points custom-charactercustom-charactercustom-characterZ1 established at the junction of the fruit and the fruit stem, using Phantom software to store the photographed images, and using TEMA software to process the feature points and connected base coordinate system points custom-charactercustom-charactercustom-characterZ1 in the images, acquiring a absolute coordinate of the feature points custom-charactercustom-characterC3 and the connected base coordinate system points custom-charactercustom-charactercustom-characterZ1, and then acquiring an inherit relationship between the feature points and the connected base coordinate system;


(5) photographing the fruit dynamic motion, using Phantom software to store each frame of the image in the photographed video, using TEMA software to process the feature points in the images to acquiring the absolute coordinate of the feature points on the fruit surface, according to an inherent relationship between the feature points and the connected base coordinate system, the absolute coordinate of each frame of image corresponding to the connected base coordinate system points custom-charactercustom-charactercustom-characterZ1 at each moment being calculated by inverse rotation transformation, and calculating an angle between the vector {right arrow over (O1Z1)} at each moment and the Z axis in the public reference base coordinate system through the space vector angle formula, and the angle representing a swing posture of the fruit;


(6) rotating the {right arrow over (O1Z1)} at each moment to a position that coincides with the Z axis in the public reference base coordinate system, and calculating an angle between the rotated {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, the angle representing a twisting posture of the fruit; and


(7) setting moments corresponding to two adjacent frames to t+1 moment and t moment, and calculating a displacement of the point O1 along the X axis, Y axis and Z axis of the public reference base coordinate system at t+1 moment and t moment respectively, calculating an instantaneous speed along the X axis, an instantaneous speed along the Y axis, and an instantaneous speed along the Z axis of the fruit at t moment according to the displacement, calculating an instantaneous acceleration along the X axis, an instantaneous acceleration along the Y axis and an instantaneous acceleration along the Z axis of the fruit at t moment according to the instantaneous speed, calculating a swing angular displacement of the fruit in a time interval between the two adjacent frames of images, sequentially calculating a swing angular speed of the fruit at t moment and a swing angular acceleration of the fruit at t moment via the swing angular displacement, and calculating a torsion angular speed of the fruit at t moment and a torsion angular acceleration of the fruit at t moment according to the torsion angular degree from t moment to t+1 moment.


As a further improved technical solution for the present invention, the step (2) includes:


establishing the connected base coordinate system by taking a junction of the fruit and the fruit stem as the origin, and taking a line between the junction of the fruit and the fruit stem and a center point of the fruit as a center line, the center line being the Z axis of the connected base coordinate system, which being marked as the Z connected-axis, taking a direction from the central point pointing to the joining point as the positive direction of the Z connected-axis, establishing the X axis and Y axis of the connected base coordinate system on a plane perpendicular to the Z axis of the connected base coordinate system, and marking them as X connected-axis and Y connected-axis respectively; marking the origin of the connected base coordinate system as O1, marking the end point of the unit vector in the positive direction of the X connected-axis as X1, marking the end point of the unit vector in the positive direction of the Y1 connected-axis as Y1, and marking the end point of the unit vector in the positive direction of the Z connected-axis as Z1.


As a further improved technical solution for the present invention, the absolute coordinates are spatial coordinates in the public reference base coordinate system, and the unit vectors of the coordinate axis of the public reference base coordinate system are:



custom-character
custom-character Z=(0 0 1)T.


As a further improved technical solution for the present invention, the step (4) includes:


(A) under static conditions, using two high-speed cameras to statically photograph the three feature points on the surface of the fruit and the points custom-charactercustom-charactercustom-character Z1 of the connected base coordinate system established at the junction of the fruit and the fruit stem, using Phantom software to store the photographed images, and using TEMA software to process the feature points custom-charactercustom-character C3 and the connected base coordinate system points custom-charactercustom-charactercustom-character Z1 in the images, acquiring the absolute coordinate of the feature points custom-charactercustom-character C3 and the absolute coordinate of the connected base coordinate system points custom-charactercustom-charactercustom-character Z1;


(b) creating vectors {right arrow over (C1C2)} and {right arrow over (C1C3)} via absolute coordinate, unitizing {right arrow over (C1C2)} and {right arrow over (C1C3)}, creating vector custom-character vector custom-character vector {right arrow over (C1Y1)} and vector {right arrow over (C1Z1)};


(c) doing a vector product of unitized {right arrow over (C1C2)} and {right arrow over (C1C3)} to get: {right arrow over (Y)}={right arrow over (C1C2)}×{right arrow over (C1C3)}, doing a vector product of {right arrow over (X)}={right arrow over (C1C2)} and {right arrow over (Y)} to get: {right arrow over (Z)}={right arrow over (X)}× {right arrow over (Y)}, thus, establishing a coordinate system Cxyz by taking feature point C1 as an origin, the coordinate axis vector of the coordinate system Cxyz is: {right arrow over (XCxyz)}=custom-character{right arrow over (YCxyz)}=custom-character{right arrow over (ZCxyz)}=custom-character


calculating angles custom-charactercustom-character γx between the vector {right arrow over (XCxyz)} and the X axis, Y axis and Z axis of the public reference base coordinate system through the calculation formula of the space vector angle,


calculating angles custom-charactercustom-character γy between the vector {right arrow over (YCxyz)} and the X axis, Y axis and Z axis of the public reference base coordinate system,


calculating angles custom-charactercustom-character γz between the vector {right arrow over (ZCxyz)} and the X-axis, Y-axis and Z-axis of the public reference base coordinate system, then the coordinate conversion matrix is:










A
=

(




cos






α
x





cos






β
x





cos






γ
x







cos






α
y





cos






β
y





cos






γ
z







cos






α
z





cos






β
z





cos






γ
z





)


;




(
1
)







the coordinates of point O1 under the coordinate system Cxyz are obtained by formula (2):











O

1

C
xyz



=


A
*



C
1



O
1





=



(




cos






α
x





cos






β
x





cos






γ
x







cos






α
y





cos






β
y





cos






γ
z







cos






α
z





cos






β
z





cos






γ
z





)



(




x

o
1








y

o
1








z

o
1






)


=

(




x

O

1

C
xyz









y

O

1

C
xyz









z

O

1

C
xyz







)




;




(
2
)







wherein, {right arrow over (C1O1)}=(xO1′ yO1′ zO1′)T, and obtained from (b) in step (4);


similarly,










X

1

C
xyz



=


A
*





C
1



X
1
























Y

1

C
xyz



=



A
*





C
1



X
1









and






Z

1

C
xyz




=


A
*





C
1



Z
1










can be obtained, wherein the coordinates of










X

1

C
xyz







Y

1

C
xyz






Z

1

C
xyz















are the coordinates of points custom-charactercustom-character Z1 under the coordinate system Cxyz;


the coordinates of







O

1

C
xyz






X

1

C
xyz






Y

1

C
xyz






Z

1

C
xyz







are the coordinates of points custom-charactercustom-charactercustom-character Z1 under the coordinate system Cxyz, that is, representing the inherent relationship between the feature point and the connected base coordinate system.


As a further improved technical solution for the present invention, the step (5) includes:


(a) using two high-speed cameras to photograph the fruit dynamic motion, using Phantom software to store each frame of image of the photographed video, using TEMA software to process the feature points in the images, and obtaining the absolute coordinate of the feature points on the surface of the fruit;


(b) calculating angles custom-charactercustom-character γxt between the vector







X

C

xyz
t








and the X axis, Y axis, and Z axis of the public reference base coordinate system at t moment through the calculation formula of the space vector angle, calculating angles custom-charactercustom-character γyt, between the vector







Y

C

xyz
t








and me x axis, Y axis and Z axis of the public reference base coordinate system, calculating angles custom-charactercustom-character γzt between the vector







Z

C

xyz
t








and the X axis, Y axis and Z axis of the public reference base coordinate system, wherein,








X

C

xyz
t









Y

C

xyz
t









Z

C

xyz
t









are the coordinate axis vector of the coordinate system Cxyz established by taking the feature point C1 in one frame of image corresponding to the t moment as an origin, then the coordinate conversion matrix is:











A
1

=

(




cos






α

x
t






cos







β
x

t





cos






γ

x
t








cos







α
y

t





cos






β

y
t






cos






γ

z
t








cos






α

z
t






cos






β

z
t






cos






γ

z
t






)


;




(
3
)







the coordinates of point O1 in the public reference base coordinate system, that is, the absolute coordinate is:











(




x

O
1







y

O
1







z

O
1





)





=


(




x

C
1







y

C
1







z

C
1





)

+


A
i

-
1


*

(




x

O

1

C
xyz









y

O

1

C
xyz









z

O

1

C
xyz







)




;




(
4
)







wherein (custom-charactercustom-character ZO1) are the absolute coordinate of the point O1 under t moment, (custom-charactercustom-character zO1) are the absolute coordinate of the point C1 under t moment,






(


x


O

1

C
xyz








y


O

1

C
xyz








z

O

1

C
xyz





)




are the coordinate of point O1 in the coordinate system Cxyz; similarly, calculating the absolute coordinate of the points X1, Y1, Z1 under t moment;


each frame of image is independent of each other, and corresponds to a moment respectively, and solves the absolute coordinates of the points custom-charactercustom-charactercustom-character Z1 of the connected base coordinate system frame by frame;


calculating the angle θ between the vector {right arrow over (O1Z1)} at each moment and the Z axis in the public reference base coordinate system through the space vector angle formula:










θ
=

arccos
(






x

z
1




x
z


+


y

z
1




y
z


+


z

z
1




z
z









x

z
1

2

+

y

z
1

2

+

z

z
1

2



×



x
z
2

+

y
z
2

+

z
z
2





)


;




(
5
)







wherein {right arrow over (O1Z1)}=(xz1 yz1 Zz1)T, custom-character is the unit vector of the Z axis in the public reference base coordinate system, the angle θ between the vector {right arrow over (O1Z1)} and the Z axis in the public reference base coordinate system represents a swing posture of the fruit.


As a further improved technical solution for the present invention, the step (6) includes:


(a) using the axis rotation matrix to rotate {right arrow over (O1Z1)} at the moment corresponding to a certain frame of image to a position that coincides with the Z axis in the public reference base coordinate system, calculating the angle between the rotated {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, the angle represents a twisting posture of the fruit at the moment corresponding to the frame image, detail as follows:


the Z connected-axis direction vector of the frame of image is: custom-character={right arrow over (O1Z1)}=(xz1 yz1 zz1)T, |{right arrow over (O1Z1)}|=√{square root over (xZ12+yZ12+zZ12)}, calculating the angle φ between the Z connected-axis and the Z axis in the public reference base coordinate system:










φ
=

arccos


(


Z

Z
1







O
1



Z
1


_




)



;




(
6
)







calculating the angle ψ between the projection of the Z connected-axis in the X axis and Y axis of the public reference base coordinate system and the Y axis of the public reference base coordinate system:










ψ
=

arccos
(


y

Z
1





y

Z
1

2

+

x

Z
1

2




)


;




(
7
)







calculating the axis rotation matrix:











T
1

=

(




cos





φ



0



sin





φ





0


0


0






-
sin






φ



0



cos





φ




)


;




(
8
)








T
2

=

(




cos





ψ





-
sin






ψ



0





sin





ψ




cos





ψ



0




0


0


1



)


;




(
9
)







the absolute coordinate of the rotated point X1 is consistent with the coordinate of the rotated vector {right arrow over (O1X1)}, and the rotated vector {right arrow over (O1X1)} is:











(





x

X
1










y

X
1










z

X
1







)

=


T
2

-
1


*


T
1

-

1
*





(




x

x
1







y

X
1







z

X
1





)




;




(
10
)







wherein, custom-character is the vector {right arrow over (O1X1)} before the {right arrow over (O1Z1)} of the frame of image is rotated;


the torsion angular degree is:










ϕ
=

arccos






(







x

X
1






x
X


+



y

X
1






y
X


+



z

X
1






z
X










x

X
1



,
2


+


y

X
1



,
2


+


z

x
1



,
2




×




x
X

2

+


y
X

2

+


z
X

2





)



;




(
11
)







the torsion angular degree is the angle between the rotated vector {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, which represents the torsion posture of the fruit at the moment corresponding to the frame image,


wherein custom-character is the unit vector of the X axis in the public reference base coordinate system;


(b) Similarly, in (a) of step (6), calculating the twisting posture of the fruit at each moment corresponding to each frame image; and


As a further improved technical solution for the present invention, the step (7) includes:


(a) setting moments corresponding to two adjacent frames of images to t+1 moment and t moment, based on the point O1 of the connected base coordinate system in adjacent two frames of images, and calculating the displacement of the point O1 along the X axis of the public reference base coordinate system at t+1 moment and t moment respectively:






S
x
=x
O

t+1

−x
O

1
  (12);


wherein custom-character xO1 are the coordinates x of the point O1 under the public reference base coordinate system at t+1 moment and t moment; similarly, calculating the displacement Sy along the Y axis and the displacement S, along the Z axis of the point O1 of the public reference base coordinate system at t+1 moment and t moment, and the combined displacement is:






S=√{square root over (Sx2+Sy2+Sz2)}  (13);


(b) using the average speed of the point O1 moving along the X axis of the public reference base coordinate system from t moment to t+1 moment to express the instantaneous speed vx(t) of the fruit along the X axis at t moment:











v

x


(
t
)



=


S
x


Δ





t



;




(
14
)







wherein Δt is the interval time between two frames of images; similarly, the instantaneous speed vy (t) of the fruit along the Y axis of the public reference base coordinate system at t moment and the instantaneous speed vz (t) of the fruit along the Z axis of the public reference base coordinate system at t moment can be obtained, then the combined speed of the fruit at t moment is:






v=√{square root over (vx (t)2+Vy (t)2+vz (t)2)}  (15);


(c) using the acceleration of the point O1 moving along the X axis of the public reference base coordinate system from t moment to t+1 moment to express the instantaneous acceleration ax(t) of the fruit along the X axis at the t moment:











a

x


(
t
)



=



v

x


(

t
+
1

)



-

v

x


(
t
)





Δ

t



;




(
16
)







wherein vx (t+1) is the instantaneous speed of the fruit along the X axis at t+1 moment, and vx(t) is the instantaneous speed of the fruit along the X axis at t moment; similarly, the instantaneous acceleration ay (t) of the fruit along the Y axis of the public reference base coordinate system at t moment and the instantaneous acceleration az (t) of the fruit along the Z axis of the public reference base coordinate system at t moment can be obtained; then the combined acceleration of the fruit at t moment is:






a=√{square root over (ax (t)2+ay (t)2+az (t)2)}  (17);


(d) using the angle from the Z connected-axis at t moment to the Z connected-axis at t+1 moment to represent the swing angular displacement of the fruit in Δt:











Δ

θ

=

arccos


(






x

Z

1

t
+
1






x

Z

1
t




+


y

Z

1

t
+
1






y

Z

1
t




+


z

Z

1

t
+
1






z

Z

1
t












x

Z

1

t
+
1




2

+


y

Z

1

t
+
1




2

+


z

Z

1

t
+
1




2



×




x

Z

1
t



2

+


y

Z

1
t



2

+


z

Z

1
t



2





)



;




(
18
)







wherein







(


x

Z

1
t






y

Z

1
t






z

Z

1
t




)

T




is the direction vector of Z connected-axis at t moment, that is t moment vector {right arrow over (O1Z1)};







(


x

Z

1

t
+
1







y

Z

1

t
+
1







z

Z

1

t
+
1





)

T




is the direction vector of Z connected-axis at t+1 moment, that is t+1 moment vector {right arrow over (O1Z1)};


(e) using the average swing angular speed from t moment to t+1 moment to express the t swing angular speed ωθt of the fruit at t moment:











ω

θ
t


=

Δθ

Δ





t



;




(
19
)







(f) using the amount of change of the swing angular speed from t moment to t+1 moment to express the swing angular acceleration aθt of the fruit at t moment:











a

θ
t


=



ω

θ

t
+
1



-

ω

θ
t




Δ





t



;




(
20
)







(g) using the axis rotation matrix to rotate the Z connected-axis at t moment and the Z connected-axis at t+1 moment to the position that coincides with the Z connected-axis in the public reference base coordinate system, using formula (6) to formula (10) in step (a) in step (6) to calculate the rotated vector {right arrow over (O1X1)} at t moment and the rotated vector {right arrow over (O1X1)} at t+1 moment, then the torsion angular degree from t moment to t+1 moment is:










Δϕ
=

arccos
(







x

X

1

t
+
1




,



x

X
t



+



y

X

1

t
+
1




,



y

X
t



+



z

X

1

t
+
1




,



z

X
t











x

X

1

t
+
1





,
2


+



y

X

1

t
+
1





,
2





z

X

1

t
+
1





,
2





×




x

X
t


2

+


y

X
t


2

+


z

X
t


2





)


;




(
21
)







wherein










(



x

X

1
t









y

X

1
t









z

X

1
t






)

T












is the rotated vector {right arrow over (O1X1)} at t moment,







(



x

X

1

t
+
1










y

X

1

t
+
1










z

X

1

t
+
1







)

T




is the rotated vector {right arrow over (O1X1)} at t+1 moment;


the torsion angular speed of the fruit at t moment is:











ω

ϕ
t


=

Δϕ

Δ





t



;




(
22
)







and


the torsion angular acceleration of the fruit at t moment is:










a

ϕ
t


=




ω

ϕ

t
-
1



-

ω

ϕ
t




Δ





t


.





(
23







The beneficial effect of the present invention is: when the inertial force generated by the vibration of vibrating fruit picking exceeds the separation force between the fruit and the fruit stem, the fruit is separated from the fruit branch or the fruit stem at the weakest connection point to complete the picking. The effect of fruit separation ultimately depends on the maximum inertial force generated when the fruit vibrates. Inertial force comes from acceleration, so acceleration response is one of the most important characteristics in fruit tree dynamics. This method can construct the trajectory of the fruit in the vibration process through the relationship between the conjoined base at the junction of the fruit stem and the fruit, and then solve the displacement, speed and acceleration of fruit at each moment, which is beneficial to explore the law of fruit movement. And the present invention can also obtain the swing posture and the torsion posture in the process of fruit vibration. This method is aimed at the study of fruit movement status in the field of fruit vibration harvesting, and can better track the movement of fruits.





BRIEF DESCRIPTION OF THE DRAWINGS

Various other features and attendant advantages of the present invention will be more fully appreciated from the following detailed description when considered in connection with the accompanying drawings in which like reference characters designate like or corresponding parts throughout the several views, and wherein:



FIG. 1 shows a flowchart of the method;



FIG. 2 shows a relationship diagram of a coordinate system in a fruit space;



FIG. 3 shows a coordinate curve of a feature point x;



FIG. 4 shows a coordinate curve of a feature point y;



FIG. 5 shows a coordinate curve of a feature point z;



FIG. 6 shows a schematic diagram of a fruit space motion;



FIG. 7 shows a translation trajectory of a fruit spatial;



FIG. 8 shows a position diagram of a conjoined base coordinate of two adjacent moments; and



FIG. 9 shows a schematic diagram of torsion angular.





DETAILED DESCRIPTION OF THE ILLUSTRATED EMBODIMENT

The following further describes the specific implementation of the present invention based on FIGS. 1 to 9.


This embodiment provides a binocular-vision-based method for tracking fruit space attitude and fruit space motion. FIG. 1 is an application step diagram of this embodiment. The content of FIG. 1 will be expanded in detail below.


Mark three feature points custom-charactercustom-character C3 on the surface of the fruit.


Establish a method for setting the fruit posture in space. The fruit is regarded as a rigid body, which does not deform in any state, and the fruit is regarded as a standard rotating body. establishing the connected base coordinate system by taking a junction of the fruit and the fruit stem as the origin, and taking a line between the junction of the fruit and the fruit stem and a center point of the fruit as a center line, the center line being the Z axis of the connected base coordinate system, which being marked as the Z connected-axis, taking a direction from the central point pointing to the joining point as the positive direction of the Z connected-axis, establishing the X-axis and Y-axis of the connected base coordinate system on a plane perpendicular to the Z-axis of the connected base coordinate system, and marking them as X connected-axis and Y connected-axis respectively; marking the origin of the connected base coordinate system as O1, marking the end point of the unit vector in the positive direction of the X connected-axis as X1, marking the end point of the unit vector in the positive direction of the Y connected-axis as Y1, and marking the end point of the unit vector in the positive direction of the Z connected-axis as Z1. Using this method, the movement of the fruit in space can be decomposed into translation, swinging around the junction of the fruit stem and the fruit, and twisting around the centerline. Using this method, the movement of the fruit in space can be decomposed into translation, swinging around the junction of the fruit stem and the fruit, and twisting around the centerline. Using this method, the movement of the fruit in space can be decomposed into translation, swinging around the junction of the fruit stem and the fruit, and torsion movement around the centerline.


Establish a public reference base coordinate system, the unit vector of the coordinate axis of the public reference base coordinate system is:



custom-character
custom-character Z=(0 0 1)T.


The absolute coordinates described in this article are all spatial coordinates in the public reference base coordinate system. The vectors described in this article are all vectors in the public reference base coordinate system.


Since the feature points on the fruit surface tracked by the binocular camera cannot directly reflect the spatial posture of the fruit, this embodiment invented a method for creating a fixed relationship between the conjoined base and the feature points on the fruit surface. First, using two high-speed cameras 1-1 (M310, VEO 410) to statically photograph the three feature points on the surface of the fruit and the points custom-charactercustom-charactercustom-character Z1 of the connected base coordinate system established at the junction of the fruit and the fruit stem, using Phantom software to store the photographed images, and using TEMA software to process the feature points and the connected base coordinate system points custom-charactercustom-charactercustom-character Z1 in the images, export the spatial absolute coordinate of the feature points custom-charactercustom-character C3 and the points custom-charactercustom-charactercustom-character Z1 of the connected base coordinate system and then establish an inherent relationship between the feature points and the connected base coordinate system. Referring to FIG. 2, this embodiment uses two high-speed cameras 1-1 to photograph the fruit 2-1. Two high-speed cameras 1-1 can obtain depth information by binocular visual tracking, and obtain the spatial coordinates of the fruit 2-1. Reference numeral 1-1 in FIG. 2 represents a high-speed camera, reference numeral 2-1 represents a fruit, X, Y, and Z in FIG. 2 represent a public reference base coordinate system, and X connected-axis, Y connected-axis, Z connected-axis represent a connected base coordinate system, Xcxyz, Ycxyz, Zcxyz represent coordinate system Cxyz. Specifically, it includes the following steps:


(a) under static conditions, using two high-speed cameras (M310, VEO 410) to statically photograph the three feature points custom-charactercustom-character C3 on the surface of the fruit and the points custom-charactercustom-charactercustom-character Z1 of the connected base coordinate system established at the junction of the fruit and the fruit stem, using Phantom software to store the photographed images, and using TEMA software to process the feature points custom-charactercustom-character C3 and the connected base coordinate system points custom-charactercustom-charactercustom-character Z1 in the images, acquiring the absolute coordinate of the feature points custom-charactercustom-character C3 and the absolute coordinate of the connected base coordinate system points custom-charactercustom-charactercustom-character Z1; the absolute coordinate of feature point C2 is (custom-charactercustom-character zC2)T, the absolute coordinate of feature point C1 is (custom-charactercustom-character zC1)T, the


absolute coordinate of feature point C3 is (custom-charactercustom-character zC3)T;


(b) creating vectors {right arrow over (C1C2)} and {right arrow over (C1C3)} via absolute coordinate, unitizing {right arrow over (C1C2)} and {right arrow over (C1C3)}, {right arrow over (C1C2)} and {right arrow over (C1C3)} are:


{right arrow over (C1C2)}=(XC2custom-character yC2custom-character zC2−ZC1)T, {right arrow over (C1C3)}=(xC3custom-character yC3custom-character zC3−zC1)T; establish vector {right arrow over (C1O1)}, {right arrow over (C1O1)}=(xO1custom-character yO1custom-character zO1−zC1)T=(xO1′ yO1′ zO1′)T;



custom-characteris the coordinate of the point O1 of the connected base coordinate system in the public reference base coordinate system; and use the same method to create vector custom-character vector {right arrow over (C1Y1)} and vector {right arrow over (C1Z1)};


(c) doing a vector product of unitized {right arrow over (C1C2)} and {right arrow over (C1C3)} to get: {right arrow over (Y)}={right arrow over (C1C2)}× {right arrow over (C1C3)}, doing a vector product of {right arrow over (X)}={right arrow over (C1C2)} and {right arrow over (Y)} to get: {right arrow over (Z)}={right arrow over (X)}×{right arrow over (Y)}, thus, establishing a coordinate system Cxyz by taking feature point C1 as an origin, the coordinate axis vector of the coordinate system Cxyz is: XCxyz=custom-character=custom-character=(custom-charactercustom-character zCz)T, calculating angles custom-charactercustom-character γx between the vector {right arrow over (XCxyz)} and the X axis, Y axis and Z axis of the public reference base coordinate system through the calculation formula of the space vector angle, calculating angles custom-charactercustom-character γy between the vector YCxyz and the X axis, Y axis and Z axis of the public reference base coordinate system, calculating angles custom-charactercustom-character γz between the vector {right arrow over (ZCxyz )} and the X axis, Y axis and Z axis of the public reference base coordinate system; wherein the calculation formula for the angle of the space vector is:








cos





φ

=






m
1



m
2


+


n
1



n
2


+


p
1



p
2









m
1
2

+

n
1
2

+

p
1
2



×



m
2
2

+

n
2
2

+

p
2
2






;




wherein custom-charactercustom-charactercustom-charactercustom-charactercustom-character p2 respectively correspond to the X coordinate, Y coordinate, and Z coordinate of the space vector;


the coordinate conversion matrix is:










A
=

(




cos






α
x





cos






β
x





cos






γ
x







cos






α
y





cos






β
y





cos






γ
z







cos






α
z





cos






β
z





cos






γ
z





)


;




(
1
)







the coordinates of point O1 under the coordinate system Cxyz are obtained by formula (2):











O

1

C
xyz



=



A
*





C
1



O
1





=



(




cos






α
x





cos






β
x





cos






γ
x







cos






α
y





cos






β
y





cos






γ
z







cos






α
z





cos






β
z





cos






γ
z





)



(





x

o
I















y

o
1















z

o
1












)


=

(




x

O

1


C
xy









y

O

IC
xyz








z

O

1


C
xyz







)




;




(
2
)







wherein, {right arrow over (C1O1)}=(xO1′ yO1′ zO1′)T, and obtained from step (b);


similarly,








X

1

C
xyz



=


A
*






C
1


X



1



,




Y

1

C
xyz




=



A
*





C
1



Y
1









and






Z

1

C
xyz




=


A
*





C
1



Z
1







,




wherein the coordinates corresponding to







X

1

C
xyz



,

Y

1

C
xyz



,

Z

1

C
xyz







are the coordinates of points X1, custom-character Z1 under the coordinate system Cxyz; the vector {right arrow over (C1X1)}, the vector {right arrow over (C1Y1)}, and the vector {right arrow over (C1Z1)} are all obtained from the above-mentioned step (b); the coordinates corresponding to







O


1

C
xyz








X

1

C
xyz






Y

1

C
xyz






Z

1

C
xyz







are use coordinates of points custom-charactercustom-charactercustom-character Z1 under the feature point coordinate system Cxyz, that is, it represents the inherent relationship between the feature point and the connected base coordinate system. The inherent relationship in this embodiment is:







S
e

=


(


O

1

C
xyz






X

1

C
xyz






Y

1

C
xyz






Z

1

C
xyz




)

=


(





8
.
3


5

8

0





7
.
3


7

8

2





8
.
3


5

3

4





8
.
2


7

4

0







-
1



2
.
4


3

2

4




-
12.3469




-
12.4959





-
1



3
.
4


2

6

7







-

2
.
3



0

4

6





-

2
.
3



0

5

4





-

3
.
2



8

6

0





-

2
.
2



4

2

0




)








The fruit space motion process is divided into translation, swing and torsion, and the motion process is shown in FIG. 6. The binocular-vision-based method of tracking fruit space attitude first uses two high-speed cameras 1-1 (M310, VEO 410) to photograph the fruit dynamic motion, and the movement of the fruit under a certain frequency of excitation. Use Phantom software to store each frame of image in the photographed video, and use TEMA software to process the feature points in each frame of image, export the absolute coordinate of the feature point on the fruit surface of each frame of image in the video, as shown in FIGS. 3 to 5, FIG. 3 is the x-coordinate diagram of the feature point C1, FIG. 4 is the y-coordinate diagram of the feature point C1, and FIG. 5 is the z-coordinate diagram of the feature point C1, which represents the feature point motion curve in the video. The abscissas in FIGS. 3 to 5 represent each moment corresponding to each frame of image. According to the inherent relationship between the feature points and the connected base coordinate system, the absolute coordinate of each frame of image corresponding to the connected base coordinate system points custom-charactercustom-charactercustom-character Z1 at each moment being calculated by the inverse rotation transformation, and calculating an angle between the vector {right arrow over (O1Z1)} at each moment and the Z axis in the public reference base coordinate system through the space vector angle formula, and the angle representing the swing posture of the fruit. Rotate the {right arrow over (O1Z1)} at each moment to a position that coincides with the Z axis in the public reference base coordinate system, and calculating an angle between the rotated {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, the angle representing the twisting posture of the fruit, details as follows:


(a1) Use two high-speed cameras 1-1 to photograph fruit dynamic motion, use Phantom software to store each frame of image of the photographed video, use TEMA software to process the feature point in the image, and export the absolute coordinate of the feature point on the fruit surface frame by frame;


(b1) Follow the above-mentioned steps (b) and (c) to establish a coordinate system Cxyz by taking the feature point C1 in one frame of image corresponding to t moment as an origin;









X

C

xyz
t









Y

C

xyz
t






,




Z

C

xyz
t










are the coordinate axis vector of the coordinate system Cxyz established by taking the feature point C1 in one frame of image corresponding to t moment as an origin;


calculating angles custom-charactercustom-character γxt between the vector







X

C

xyz
t








and the X axis, Y axis, and Z axis of the public reference base coordinate system at t moment through the calculation formula of the space vector angle, calculating angles custom-charactercustom-character γyt between the vector







Y

C

xyz
t








and the X axis, Y axis and Z axis of the public reference base coordinate system, calculating angles custom-charactercustom-character γzt between the vector







Z

C

xyz
t








and the X axis, Y axis and Z axis of the public reference base coordinate system, then the coordinate conversion matrix at t moment is:











A
t

=

(




cos






α
xt





cos






β
xt





cos






γ
xt







cos






α
yt





cos






β
yt





cos






γ
yt







cos






α
zt





cos






β
zt





cos






γ
zt





)


;




(
3
)







the coordinates of point O1 in the public reference base coordinate system, that is, the absolute coordinate is:











(




x

O
1







y

O
1







z

O
1





)

=


(




x

C
1







y

C
1







z

C
1





)

+


A
t


-
1

*




(




x

O

1


C
xyz









y

O

1


C
xyz









z

O

1


C
xyz







)




;




(
4
)







wherein (custom-charactercustom-character zO1) are the absolute coordinate of the point O1 under t moment, (custom-charactercustom-character ZO1) are the absolute coordinate of the point C1 under t moment,






(


x

O

1


C
xyz







y

O

1


C
xyz







z

O

1


C
xyz





)




are the coordinate of point O1 in the coordinate system Cxyz; similarly, calculating the absolute coordinate of the points custom-charactercustom-character Z1 under t moment;


wherein, the vector corresponding to the absolute coordinate of point X1 at t moment is equal to the vector corresponding to the absolute coordinate of point C1 at t moment plus the vector of At−1 multiplied by the coordinates of point X1 under the coordinate system Cxyz; the absolute coordinate calculation method of point Y1 and point Z1 can be deduced by analogy;


each frame of image is independent of each other, and corresponds to a moment respectively, and solves the absolute coordinates of the points custom-charactercustom-charactercustom-character Z1 of the connected base coordinate system at each moment frame by frame; calculate the angle θ between the vector {right arrow over (O1Z1)} at each moment and the Z axis in the public reference base coordinate system through the space vector angle formula:










θ
=

arccos


(






x

Z
1




x
Z


+


y

Z
1




y
Z


+


z

Z
1




z
Z









x

Z
1

2

+

y

Z
1

2

+

z

Z
1

2



×



x
Z
2

+

y
Z
2

+

z
Z
2





)



;




(
5
)







wherein {right arrow over (O1Z1)}=(xz1 yz1 zz1)T, custom-character is the unit vector of the Z axis in the public reference base coordinate system, the angle θ between the vector {right arrow over (O1Z1)} and the Z axis in the public reference, base coordinate system represents a swing posture of the fruit.


(c1) using the axis rotation matrix to rotate {right arrow over (O1Z1)} (that is, Z connected-axis) at the moment corresponding to a certain frame of image to a position that coincides with the Z axis in the public reference base coordinate system, calculating the angle between the rotated {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, the angle represents a twisting posture of the fruit at the moment corresponding to the frame image, detail as follows:


the Z connected-axis direction vector of the frame of image is: custom-character={right arrow over (O1Z1)}=(xz1 yz1 zz1)T, |{right arrow over (O1Z1)}|=√{square root over (xZ12+yZ12+zZ12)}, calculating the angle φ between the Z connected-axis and the Z axis in the public reference base coordinate system:










φ
=

arccos






(


Z

Z
1







O
1



Z
1







)



;




(
6
)







calculating the angle ψ between the projection of {right arrow over (O1Z1)} (that is, Z connected-axis) in the X axis and Y axis of the public reference base coordinate system and the Y axis of the public reference base coordinate system:










ψ
=

arccos


(


y

Z
1





y

Z
1

2

+

x

Z
1

2




)



;




(
7
)







calculating the axis rotation matrix:











T
1

=

(




cos





φ



0



sin





φ





0


1


0






-
sin






φ



0



cos





φ




)


;




(
8
)
















T
2

=

(




cos





ψ





-
sin






ψ



0





sin





ψ




cos





ψ



0




0


0


1



)


;




(
9
)







the absolute coordinate of the rotated point X1 is consistent with the coordinate of the rotated vector {right arrow over (O1X1)}, and the rotated vector {right arrow over (O1X1)} is:











(




x

X
1








y

X
1








z

X
1






)

=


T
2


-
1

*





T
1


-
1

*




(




x

X
1







y

X
1







z

X
1





)




;




(
10
)







wherein, custom-character is the vector {right arrow over (O1X1)} before the {right arrow over (O1Z1)} of the frame of image is rotated;


the torsion angular degree is:










ϕ
=

arccos
(






x

X
1





x
X


+


y

X
1





y
X


+


z

X
1





z
X









x

X
1







2



+

y

X
1







2



+

z

X
1
′2




×



x

X
2


+

y

X
2


+

z

X
2






)


;




(
11
)







the torsion angular degree is the angle between the rotated vector {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, which represents the torsion posture of the fruit at the moment corresponding to the frame image, wherein custom-character is the unit vector of the X axis in the public reference base coordinate system.


(d1) Similarly, in step (c1), calculating the twisting posture of the fruit at each moment corresponding to each frame image.


A study method of fruit space motion, the space motion of fruit needs to use public reference base coordinates to express its absolute motion. Setting the moments corresponding to two adjacent frames of images to t+1 moment and t moment, based on the point O1 of the connected base coordinate system in adjacent two frames of images, and calculating the displacement of point O1 along the X axis, Y axis and Z axis of the public reference base coordinate system at t+1 moment and t moment respectively. calculating an instantaneous speed along the X axis, an instantaneous speed along the Y axis, and an instantaneous speed along the Z axis of the fruit at t moment according to the displacement, calculating an instantaneous acceleration along the X axis, an instantaneous acceleration along the Y axis and an instantaneous acceleration along the Z axis of the fruit at t moment according to the instantaneous speed, calculating a swing angular displacement of the fruit in the time interval between two adjacent frames of images, sequentially calculating a swing angular speed of the fruit at t moment and a swing angular acceleration of the fruit at t moment via the swing angular displacement, and calculating the torsion angular speed of the fruit at t moment and the torsion angular acceleration of the fruit at t moment according to the torsion angular degree from t moment to t+1 moment. The fruit space motion process is divided into translation, swing and torsion, and the motion process is shown in FIG. 6. The movement of the point O1 along the X Y Z axis represents the translation of the fruit, the swing around the junction of the fruit stem and the fruit represents the swing of the fruit, and the twisting movement around the centerline (that is, Z connected-axis) represents the twist of the fruit. FIG. 7 shows the spatial translation trajectory of fruit, and the curve in FIG. 7 shows the movement of the point O1 in the space coordinates of the public reference base coordinate system.


Wherein, the instantaneous speed moving along the X Y Z axis, the instantaneous acceleration moving along the X Y Z axis, the swing angular displacement, the swing angular speed, and the swing angular acceleration within the frame time interval, the torsion angular degree, the torsion angular speed, and the torsion angular acceleration within the frame time interval all indicate the tracked fruit space motion status. The specific calculation method is as follows:


(a2) setting moments corresponding to two adjacent frames of images to t+1 moment and t moment, based on the point O1 of the connected base coordinate system in adjacent two frames of images, and calculating the displacement of the point O1 along the X axis of the public reference base coordinate system at t+1 moment and t moment respectively:






S
x
=x
O

t+1

−x
O

1
  (12);

    • wherein custom-character xO1 are the coordinates x of the point O1 under the public reference base coordinate system at t+1 moment and t moment; similarly, calculating the displacement Sy along the Y axis and the displacement Sz along the Z axis of the point O1 of the public reference base coordinate system at t+1 moment and t moment, and the combined displacement is:






S=√{square root over (Sx2+Sy2+Sz2)}  (13);


(b2) using the average speed of the point O1 moving along the X axis of the public reference base coordinate system from t moment to t+1 moment to express the instantaneous speed vx(t) of the fruit along the X axis at t moment:











v

x


(
t
)



=


S
x


Δ

t



;




(
14
)







wherein Δt is the interval time between two frames of images; similarly, the instantaneous speed vy (t) of the fruit along the Y axis of the public reference base coordinate system at t moment and the instantaneous speed vz (t) of the fruit along the Z axis at t moment can be obtained, then the combined speed of the fruit at t moment is:






v=√{square root over (vx (t)2+Vy (t)2+vz (t)2)}  (15);


(c2) using the acceleration of the point O1 moving along the X axis of the public reference base coordinate system from t moment to t+1 moment to express the instantaneous acceleration ax(t) of the fruit along the X axis at the t moment:











a

x


(
t
)



=



v

x


(

t
+
1

)



-

v

x


(
t
)





Δ

t



;




(
l6
)







wherein vx (t+1) is the instantaneous speed of the fruit along the X axis at t+1 moment, and vx(t) is the instantaneous speed of the fruit along the X axis at t moment; similarly, the instantaneous acceleration ay (t) of the fruit along the Y axis of the public reference base coordinate system at t moment and the instantaneous acceleration az (t) of the fruit along the Z axis of the public reference base coordinate system at t moment can be obtained; then the combined acceleration of the fruit at t moment is:






a=√{square root over (ax (t)2+ay (t)2+az (t)2)}  (17);


(d2) since there are too many solving moments, this embodiment lists the positions of the connected base coordinate system of adjacent t+1 moment and t moment corresponding to two adjacent frames of images to indicate the swing and twist of the fruit. For convenience of representation, the origins of the conjoined base coordinates of two adjacent moments are overlapped, as shown in FIG. 8, the angle Δθ in FIG. 8 is the angle from t moment Z connected-axis to t+1 moment Z connected-axis, and Δθ represents the swing angular displacement of the fruit in Δt:











Δ

θ

=

arccos
(






x

Z

1

t
+
1






x

Z

1
t




+


y

Z

1

t
+
1






y

Z

1
t




+


z

Z

1

t
+
1






z

Z

1
t











x

Z

1

t
+
1



2

+

y

Z

z

t
+
1



2

+

z

Z

1

t
+
1



2



×



x

Z

1
t


2

+

y

Z

1
t


2

+

z

Z

1
t


2





)


;




(
18
)







wherein







(


x

Z

1
t














y

Z

1
t














z

Z

1
t




)

T




is the direction vector of Z connected-axis at t moment, that is t moment vector {right arrow over (O1Z1)};







(


x

Z

1

t
+
1















y

Z

1

t
+
1















z

Z

1

t
+
1





)

T




is the direction vector of Z connected-axis at t+1 moment, that is t+1 moment vector {right arrow over (O1Z1)};


(e2) using the average swing angular speed from t moment to t+1 moment to express the t swing angular speed ωθt of the fruit at t moment:











ω

θ
t


=


Δ

θ


Δ

t



;




(
19
)







(f2) using the amount of change of the swing angular speed from t moment to t+1 moment to express the swing angular acceleration aθt of the fruit at t moment:











a

θ
t


=



ω

θ

t
+
1



-

ω

θ
t




Δ

t



;




(
20
)







(g2) FIG. 8 is a schematic diagram of the overlapping conjoined base coordinate origins of two adjacent moments. The angle Δθ between the Z connected-axis of t moment and t+1 moment in FIG. 8 represents the swing angular displacement of the fruit in Δt. However, the angle between the X connected-axis of t moment and t+1 moment, and the angle between the Y connected-axis of t moment and t+1 moment in FIG. 8 are not the torsion angular. Therefore, it is necessary to rotate the Z connected-axis of t moment (also expressed as {right arrow over (O1Z1)}) and the Z connected-axis of t+1 moment to the position that coincides with the Z connected-axis in the public reference base coordinate system through the axis rotation matrix. As shown in FIG. 9, the two Z connected-axes in this FIG. 9 coincide with the Z axis in the public reference base coordinate system. The angle between the two X connected-axis at this time is the torsion angular degree from t moment to t+1 moment, and the calculation method is: use the formula (6) to formula (10) in the above-mentioned step (c1) respectively calculate the rotated vector {right arrow over (O1X1)} at t moment and the rotated vector {right arrow over (O1X1)} at t+1 moment.


similarly, in formula (10) of step (c1), the vector {right arrow over (O1X1)} rotated at t moment is:











(




x

X

1
t









y

X

1
t









z

X

1
t







)

=


T

2
t


-
1


*

T

1
t


-
1


*

(




x

X

1
t








y

X

1
t








z

X

1
t






)



;




(
21
)







wherein







(


x

X

1
t




















y

X

1
t














z

X

1
t




)

T




is the vector {right arrow over (O1X1)} before the Z connected-axis rotation at t moment;







(


x

X

1
t





















y

X

1
t















z

X

1
t





)

T




is the vector {right arrow over (O1X1)} after the Z connected-axis rotation at t moment; T2t−1 and T1t−1 are the axis rotation matrices under t moment;


the torsion angular speed degree of the fruit from t moment to t+1 moment is:











Δ

ϕ

=

arccos
(






x

X

1

t
+
1







x

X
t



+


y

X

1

t
+
1







y

X
t



+


z

X

1

t
+
1







z

X
t










x

X

1

t
+
1









2



+

y

X

1

t
+
1









2



+

z

X

1

t
+
1









2





×



x

X
t
2


+

y

X
t
2


+

z

X
t
2






)


;




(
22
)







wherein







(


x

X

1
t





















y

X

1
t















z

X

1
t





)

T




is the rotated vector {right arrow over (O1X1)} at t moment,







(


x

X

1

t
+
1






















y

X

1

t
+
1
















z

X

1

t
+
1






)

T




is the rotated vector {right arrow over (O1X1)} at t+1 moment;


the torsion angular speed of the fruit at t moment is:











ω

ϕ
t


=


Δ

ϕ


Δ

t



;




(
23
)







the torsion angular acceleration of the fruit at t moment is:










a

ϕ
t


=




ω

ϕ

t
+
1



-

ω

ϕ
t




Δ





t


.





(
24
)







When the inertial force generated by the vibration of vibrating fruit picking exceeds the separation force between the fruit and the fruit stem, the fruit is separated from the fruit branch or the fruit stem at the weakest connection point to complete the picking. The effect of fruit separation ultimately depends on the maximum inertial force generated when the fruit vibrates. Inertial force comes from acceleration, so acceleration response is one of the most important characteristics in fruit tree dynamics. This method can construct the trajectory of the fruit in the vibration process through the relationship between the conjoined base at the junction of the fruit stem and the fruit, and then solve the displacement, speed and acceleration of fruit at each moment, which is beneficial to explore the law of fruit movement. The binocular-vision-based method for tracking fruit space attitude and fruit space motion, the system and analysis software for taking fruit vibration photography belong to the prior art, such as binocular cameras and spatial position synthesis software.


The scope of protection of the present invention includes, but is not limited to, the above-mentioned embodiments. The scope of protection of the present invention is subject to the claims. Any substitutions, modifications, and improvements that can be easily conceived by those skilled in the art made to the present invention fall within the scope of protection of the present invention.

Claims
  • 1. A binocular-vision-based method for tracking fruit space attitude and fruit space motion, comprising: (1) marking three feature points C3 on a surface of a fruit;(2) establishing a connected base coordinate system by taking a junction of the fruit and a fruit stem as an origin, a X axis, a Y axis, and a Z axis of the connected base coordinate system are marked as a X connected-axis, a Y connected-axis and a Z connected-axis, respectively, and the origin of the connected base coordinate system is marked as O1, an end point of the unit vector in a positive direction of the X connected-axis is marked as X1, an end point of the unit vector in a positive direction of the Y connected-axis is marked as Y1, an end point of the unit vector in a positive direction of the Z connected-axis is marked as Z1;(3) establishing a public reference base coordinate system;(4) statically photographing the three feature points on the surface of the fruit and connected base coordinate system points C established at the junction of the fruit and the fruit stem, using Phantom software to store the photographed images, and using TEMA software to process the feature points and connected base coordinate system points Z1 in the images, acquiring a absolute coordinate of the feature points C3 and the connected base coordinate system points Z1 and then acquiring an inherit relationship between the feature points and the connected base coordinate system;(5) photographing the fruit dynamic motion, using Phantom software to store each frame of the image in the photographed video, using TEMA software to process the feature points in the images to acquiring the absolute coordinate of the feature points on the fruit surface, according to an inherent relationship between the feature points and the connected base coordinate system, the absolute coordinate of each frame of image corresponding to the connected base coordinate system points Z1 at each moment being calculated by inverse rotation transformation, and calculating an angle between the vector {right arrow over (O1Z1)} at each moment and the Z axis in the public reference base coordinate system through the space vector angle formula, and the angle representing a swing posture of the fruit;(6) rotating the {right arrow over (O1Z1)} at each moment to a position that coincides with the Z axis in the public reference base coordinate system, and calculating an angle between the rotated {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, the angle representing a twisting posture of the fruit; and(7) setting moments corresponding to two adjacent frames to t+1 moment and t moment, and calculating a displacement of the point O1 along the X axis, Y axis and Z axis of the public reference base coordinate system at t+1 moment and t moment respectively, calculating an instantaneous speed along the X axis, an instantaneous speed along the Y axis, and an instantaneous speed along the Z axis of the fruit at t moment according to the displacement, calculating an instantaneous acceleration along the X axis, an instantaneous acceleration along the Y axis and an instantaneous acceleration along the Z axis of the fruit at t moment according to the instantaneous speed, calculating a swing angular displacement of the fruit in a time interval between the two adjacent frames of images, sequentially calculating a swing angular speed of the fruit at t moment and a swing angular acceleration of the fruit at t moment via the swing angular displacement, and calculating a torsion angular speed of the fruit at t moment and a torsion angular acceleration of the fruit at t moment according to the torsion angular degree from t moment to t+1 moment.
  • 2. The binocular-vision-based method for tracking fruit space attitude and fruit space motion according to claim 1, wherein: the step (2) includes:establishing the connected base coordinate system by taking a junction of the fruit and the fruit stem as the origin, and taking a line between the junction of the fruit and the fruit stem and a center point of the fruit as a center line, the center line being the Z axis of the connected base coordinate system, which being marked as the Z connected-axis, taking a direction from the central point pointing to the joining point as the positive direction of the Z connected-axis, establishing the X axis and Y axis of the connected base coordinate system on a plane perpendicular to the Z axis of the connected base coordinate system, and marking them as X connected-axis and Y connected-axis respectively; marking the origin of the connected base coordinate system as O1, marking the end point of the unit vector in the positive direction of the X connected-axis as X1, marking the end point of the unit vector in the positive direction of the Y1 connected-axis as Y1, and marking the end point of the unit vector in the positive direction of the Z connected-axis as Z1.
  • 3. The binocular-vision-based method for tracking fruit space attitude and fruit space motion according to claim 2, wherein: the absolute coordinates are spatial coordinates in the public reference base coordinate system, and the unit vectors of the coordinate axis of the public reference base coordinate system are: Z=(0 0 1)T.
  • 4. The binocular-vision-based method for tracking fruit space attitude and fruit space motion according to claim 3, wherein: the step (4) includes:
  • 5. The binocular-vision-based method for tracking fruit space attitude and fruit space motion according to claim 4, wherein: the step (5) includes:(a) using two high-speed cameras to photograph the fruit dynamic motion, using Phantom software to store each frame of image of the photographed video, using TEMA software to process the feature points in the images, and obtaining the absolute coordinate of the feature points on the surface of the fruit;(a) under static conditions, using two high-speed cameras to statically photograph the three feature points on the surface of the fruit and the points Z1 of the connected base coordinate system established at the junction of the fruit and the fruit stem, using Phantom software to store the photographed images, and using TEMA software to process the feature points C3 and the connected base coordinate system points Z1 in the images, acquiring the absolute coordinate of the feature points C3 and the absolute coordinate of the connected base coordinate system points Z1;(b) creating vectors {right arrow over (C1C2)} and {right arrow over (C1C3)} via absolute coordinate, unitizing {right arrow over (C1C2)} and {right arrow over (C1C3)}, creating vector vector vector {right arrow over (C1Y1)} and vector {right arrow over (C1Z1)};c) doing a vector product of unitized {right arrow over (C1C2)} and {right arrow over (C1C3)} to get: {right arrow over (Y)}={right arrow over (C1C2)}×{right arrow over (C1C3)}, doing a vector product of {right arrow over (X)}={right arrow over (C1C2)} and {right arrow over (Y)} to get: {right arrow over (Z)}={right arrow over (X)}×{right arrow over (Y)}, thus, establishing a coordinate system Cxyz by taking feature point C1 as an origin, the coordinate axis vector of the coordinate system Cxyz is:{right arrow over (XCxyz)}={right arrow over (TCxyz)}={right arrow over (ZCxyz)}=calculating angles γx between the vector {right arrow over (XCxyz)} and the X axis, Y axis and Z axis of the public reference base coordinate system through the calculation formula of the space vector angle,calculating angles γy between the vector {right arrow over (YCxyz)} and the X axis, Y axis and Z axis of the public reference base coordinate system,calculating angles γz between the vector {right arrow over (ZCxyz)} and the X-axis, Y-axis and Z-axis of the public reference base coordinate system, then the coordinate conversion matrix is:(b) calculating angles γxt between the vector
  • 6. The binocular-vision-based method for tracking fruit space attitude and fruit space motion according to claim 5, wherein: the step (6) includes:(a) using the axis rotation matrix to rotate {right arrow over (O1Z1)} at the moment corresponding to a certain frame of image to a position that coincides with the Z axis in the public reference base coordinate system, calculating the angle between the rotated {right arrow over (O1X1)} and the X axis in the public reference base coordinate system, the angle represents an twisting posture of the fruit at the moment corresponding to the frame image, detail as follows:the Z connected-axis direction vector of the frame of image is: ={right arrow over (O1Z1)}=(xz1 yz1 zz1)T, |{right arrow over (O1Z1)}|=√{square root over (xZ12+yZ12+zZ12)}, calculating the angle φ between the Z connected-axis and the Z axis in the public reference base coordinate system:
  • 7. The binocular-vision-based method for tracking fruit space attitude and fruit space motion according to claim 6, wherein the step (7) includes:(a) setting moments corresponding to two adjacent frames of images to t+1 moment and t moment, based on the point O1 of the connected base coordinate system in adjacent two frames of images, and calculating the displacement of the point O1 along the X axis of the public reference base coordinate system at t+1 moment and t moment respectively: Sx=xOt+1−xO1  (12);wherein xO1 are the coordinates x of the point O1 under the public reference base coordinate system at t+1 moment and t moment; similarly, calculating the displacement Sy along the Y axis and the displacement Sz along the Z axis of the point O1 of the public reference base coordinate system at t+1 moment and t moment, and the combined displacement is: S=√{square root over (Sx2+Sy2+Sz2)}  (13);(b) using the average speed of the point O1 moving along the X axis of the public reference base coordinate system from t moment to t+1 moment to express the instantaneous speed vx(t) of the fruit along the X axis at t moment:
Priority Claims (1)
Number Date Country Kind
201811438358.7 Nov 2018 CN national
PCT Information
Filing Document Filing Date Country Kind
PCT/CN2020/074017 1/23/2020 WO 00