Find answers to common questions about OpenPIV. Click on any question to expand the answer.

General Questions

It is an optical method for fluid flow measurements. PIV uses laser illumination to visualize particles in a flow and captures their motion using high-speed cameras. By analyzing sequential images, PIV can determine velocity fields across entire flow regions.

Read more on Wikipedia

OpenPIV is a user-friendly software for Particle Image Velocimetry. It contains software in Python, Matlab, and C++ that allows to estimate the velocity fields from images of particles and post-process the fields to obtain important fluid dynamics quantities such as vorticity, rate-of-strain, dissipation and Reynolds stresses in the case of turbulent flows.

The main development focus now is on the Python version.

OpenPIV was originally written in Matlab (tm) in 1998 but switched to Python. OpenPIV is designed to be portable: it runs on all platforms, on mobiles, and on high performance clusters and on virtual machines.

OpenPIV was created in order to combine the know-how of different developers into a single, coherent group developing the next generation of the open source Particle Image Velocimetry software. It is based on the three older packages URAPIV, PyPIV, and URAPIV-C++. We hope that other open source PIV developers will join this initiative.

OpenPIV is good for analysing your PIV images, acquired with frame-straddle or continuous, time-resolved PIV system. It is good to check if your commercial software is not producing any strange results, it is good to use for the images taken not only of fluid, but also solid motion, cell tracking, bees or flies or birds tracking, etc.

Applications include:
  • Fluid dynamics research
  • Aerodynamics testing
  • Microfluidics
  • Biological motion tracking
  • Particle tracking in general

Read the LICENSE files in repositories, we use standard open source licenses. OpenPIV is free to use, modify, and distribute according to the terms of these licenses.

View License Details

If you use the Python version, you can cite all versions by using the DOI:

DOI

If you use another package, please check the Readme files in every package: Matlab, Python, C++ and the toolboxes were created at different times and by different teams.

Full Citation Information

Technical Questions

Scaling or sclt

The Scaling parameter converts the pixel/dt units into meters/second or other physical units. For example, if the time between the two consecutive images is dt = 0.5 seconds and the magnification is such that 1 pixel in the image corresponds to 50 cm, then the value of sclt is estimated as:

sclt = 50 cm/pixels / 0.5 sec/dt = 100 [cm/seconds/pixels]

For example, if a given displacement vector was estimated to be 10 pixels, then the velocity will be:

100 * 10 = 1000 cm/s

Global Filtering

Global filtering supposedly removes the obvious outliers, i.e. the vectors which length is larger than the mean of the flow field plus 3 times its standard deviation. These are global outliers in the statistical sense.

Local Filtering

Local filtering is performed on small neighborhoods of vectors, e.g. 3 x 3 or 5 x 5, in order to find local outliers - the vectors that are dissimilar from the close neighbors. Typically there are about 5 per-cent of erroneous vectors and these are removed and later the missing values are interpolated from the neighbor vector values.

This is also a reason for the Matlab version to generate three lists of files:

  • raw - _noflt.txt
  • filtered (after global and local filters) - _flt.txt
  • final (after filtering and interpolation) - .txt

You might see code like:

ffta = fft2( a2, Nfft, Nfft );
fftb = fft2( b2, Nfft, Nfft );

where the size has been specified as Nfft which is twice the interrogation window size.

In the FFT-based correlation analysis, we have to pad the interrogation window with zeros and get correlation map of the right size and avoid aliasing problem (see Raffel et al. 2007).

You might see:

b2 = b2(end:-1:1,end:-1:1);

Without rotation the result will be convolution. The definition is:

ifft(fft(a)*fft(conj(b)))

So, the operation conj() is replaced by rotation which is identical in the case of real values. It is more computationally efficient.

In the find_displacement(c,s2nm) function for finding peak2, why are neighbourhood pixels around peak1 masked?

These peaks might appear as "false second peak", but they are the part of the same peak. Think about a top of a mountain. You want to remove not only the single point, but cut out the top part in order to search for the second peak.

After the program is executed, the variable vel contains all the parameters for all the velocity vectors. What are the units of u, v? Is it in metres/second?

It is not, the result depends on the sclt variable. If sclt is not used (i.e. equal to 1) then the output is in pixels/dt, where dt is the time interval between the two PIV images.

The outlier filter value is the threshold of the global outlier filter and says how many times the standard deviation of the whole vector field is exceeded before the vector is considered as outlier. See above the discussion on various filters.

What are the fifth and sixth columns in the data *.txt, *flt.txt or *noflt.txt?

  • The fifth column is the value of the Signal-To-Noise (s2n) ratio.
  • The sixth column is a mask of invalid vectors.

Note that the value is different (numerically) if the user chooses Peak-to-Second-Peak ratio as the s2n parameter or Peak-to-Mean ratio as s2n parameter. The value of Peak-to-Second-Peak or Peak-to-Mean ratio is stored for further processing.

Still have questions?

Our community is here to help!