Which coordinate system you prefer for the PIV processing?

81 views
Skip to first unread message

alex.l...@gmail.com

unread,
Dec 19, 2020, 5:49:15 AM12/19/20
to openpiv-users
HI All, 

Could you please help us with an answer on a simple question - what coordinate system do you prefer to be used in OpenPIV output : 
a) image coordinate system with 0,0 at the top left corner and x-> to the right, y to the bottom

or

b) physical coordinate system with 0,0 at the bottom left corner, x to the right, y upwards ?

Of course both can be easily transformed one into another, and even display_vector_field can now which way it's done, but just for the general overview on this minor issue, please respond. 

Thanks
Alex

Peter Vennemann

unread,
Dec 21, 2020, 8:34:32 AM12/21/20
to openpiv-users
Dear Alex,
I vote for a) because this is the most common coordinate system in image processing. Most – if not all – image processing tools and libraries use this coordinate system. It probably would be confusing to use a physical system.
Regards!
Peter

alex.l...@gmail.com

unread,
Dec 21, 2020, 9:13:11 AM12/21/20
to openpiv-users
It's a good reason. Anyone else? 

alex.l...@gmail.com

unread,
Dec 21, 2020, 1:32:32 PM12/21/20
to openpiv-users
Dear Peter, 

I forgot to ask another important question - if y is from top to bottom and we preserve the image coordinate system, how do we define the positive vertical velocity? in the image coordinate system, positive displacement is also when the row number increases, i.e. from top to bottom. But for all practical reasons when I think about positive velocity I imagine something moving upward in the image, i.e. negative in the image coordinate system. 

So, shell we choose: 

a) 0,0 top left corner and u left->right, v top-> bottom (self-consistent and maybe confusing)
b) 0,0 top left corner, u left-> right, but v bottom->up (not self-consistent v is not parallel to y, but maybe less confusing?)
c) 0,0 bottom left corner u left->right, v bottom->up (self consistent, physically valid, right-hand rule, not image based)

What do you think? 


On Monday, December 21, 2020 at 3:34:32 PM UTC+2 Peter Vennemann wrote:

alex.l...@gmail.com

unread,
Dec 22, 2020, 3:54:36 AM12/22/20
to openpiv-users
I would like to discuss it with a reference. I guess we can trust PIV Challenge group on a consensus. 

In the attached published result of the PIV Challenge case B is a negative vorticity vortex (clockwise in the image and in the result). 

So the vortex in case B is presented in the arrow field with 0,0 at the bottom and x,y axis are "regular" ones (right-hand rule) and the vortex is clock-wise, so it's consistent with negative vorticity. This is also a "visual" direction of the vortex, i.e. if we'll add an image on the background, that's how frame B is distorted in respect to frame A- clockwise.  

I believe we all could agree that whatever internal OpenPIV orientation and coordinate system is, we stick to this physically relevant representation, i.e. vertical velocity on the left side of the vortex (small x) is positive and vertical velocity on the right side of the vortex (large x) is negative. 

Looking forward to your comments :)



Screenshot from 2020-12-22 10-47-54.png
Screenshot from 2020-12-22 10-47-09.png

Main_results_of_the_first_International_PIV_Challe.pdf

Peter Vennemann

unread,
Dec 22, 2020, 4:10:27 AM12/22/20
to openpiv-users
In DaVis – as far as I understand – there is an »image coordinate system« (origin top left, velocities and position positive to the right and to the bottom) and – after calibration – a physical coordinate system. In the physical coordinate system, the user selects origin and positive direction of the axes.

Peter Vennemann

unread,
Dec 22, 2020, 4:26:58 AM12/22/20
to openpiv-users
... velocities and axes directions are consistent in both cases.

Peter Vennemann

unread,
Dec 22, 2020, 4:30:20 AM12/22/20
to openpiv-users
In JPIV I use the »image coordinate system« (0,0 top left x→, y↓) and simple factors for converting velocities and axes into a physical system. I use the factors just for plotting and do not even change the original pixel data.

alex.l...@gmail.com

unread,
Dec 22, 2020, 5:26:12 AM12/22/20
to openpiv-users
I think that we could keep the same idea - using “non-physical” and “not-right-hand” coordinate system through the image processing parts, BUT to present things in plots in the consistent way and store the data in the physically consistent way - I.e. the right-hand system. This is important so the post-processing software and graphics inside OpenPIV will be in the same. 

So 
1) the vortex of arrows on the image background would rotate clockwise
2) the vortex of arrows on the image without image background would have 0,0 at the top left and also rotate clockwise
3) if we estimate vorticity in the software, it’s negative 
4) if we store the values of velocity for the post-processing (the .txt, data frames, etc.) we store it in the way a simple quiver and simple contour plots will render “correctly”, I.e. like the in the attached publication: 0,0 bottom left, x,y to right and upwards (right-hand) and the vorticity is still negative when rotation visual direction is clockwise. 

Agreed? 

jorge.sa...@upr.edu

unread,
Feb 5, 2021, 10:29:27 AM2/5/21
to openpiv-users
What is the current display?

Is 0,0 on the bottom left? 

I am currently having trouble with my resulting velocity profiles they seem to be flipped (upside down)  in the y axis.
Best,

Jorge X. Santiago

alex.l...@gmail.com

unread,
Feb 6, 2021, 4:38:59 AM2/6/21
to openpiv-users
No, extended_search_piv ( ) function does not change the coordinate system, so it remains the image coordinate system: top left is the origin and positive column-wise displacement from left to right and positive row-wise displacement is from top to bottom (as in in images)

We added this function to transform before saving : 


# 0,0 shall be bottom left, positive rotation rate is counterclockwise 
x, y, u3, v3 = tools.transform_coordinates(x, y, u3, v3)

Reply all
Reply to author
Forward
0 new messages