Skip to content

Unsupervised learning of Particle Image Velocimetry. (ISC 2020)

Notifications You must be signed in to change notification settings

acse-wz19/UnLiteFlowNet-PIV

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Unsupervised learning of Particle Image Velocimetry

This repository contains materials for ISC workshop paper Unsupervised learning of Particle Image Velocimetry.

Introduction

Particle Image Velocimetry (PIV) is a classical flow estimation problem which is widely considered and utilised, especially as a diagnostic tool in experimental fluid dynamics and the remote sensing of environmental flows. We present here what we believe to be the first work which takes an unsupervised learning based approach to tackle PIV problems. The proposed approach is inspired by classic optical flow methods. Instead of using ground truth data, we make use of photometric loss between two consecutive image frames, consistency loss in bidirectional flow estimates and spatial smoothness loss to construct the total unsupervised loss function. The approach shows significant potential and advantages for fluid flow estimation. Results presented here demonstrate that is outputs competitive results compared with classical PIV methods as well as supervised learning based methods for a broad PIV dataset, and even outperforms these existing approaches in some difficult flow cases.

Sample results

Syethetic data: samples from PIV dataset

  • Backstep flow


  • Surface Quasi Geostrophic (SQG) flow


Real experimental data: particle Images from PIV challenge

  • Jet Flow


From left to right: Particle images, UnLiteFlowNet-PIV(trained by full integrated loss) output, PIV-LiteNetFlow output

Unsupervised Loss


Dataset

The dataset used in this work is obtained from the work below:

Shengze Cai, Shichao Zhou, Chao Xu, Qi Gao. 
Dense motion estimation of particle images via a convolutional neural network, Exp Fluids, 2019
Y. Li, E. Perlman, M. Wan, Y. Yang, R. Burns, C. Meneveau, R. Burns, S. Chen, A. Szalay & G. Eyink. 
A public turbulence database cluster and applications to study Lagrangian evolution of velocity increments in turbulence. Journal of Turbulence 9, No. 31, 2008.

Prerequisite

  • cuda (v10.1)

  • pytorch (v1.5.0)

  • sklearn (v0.22.2)

  • livelossplot

    pip install livelossplot

  • flowiz

    Library to visualize .flo files

    pip install flowiz -U

  • GPUtil

    pip install GPUtil

Training

To train from scratch:

  1. Download the PIV dataset, remove the current data in the folder sample_data and extract new data into it.

  2. Run the scripts with --train argument:

    python main.py --train

  3. Trained model will be saved in the same folder. (A checkpoint is generated every 5 epochs in default during training)

Trained model

The trained model UnsupervisedLiteFlowNet_pretrained.pt is available in the folder models.

Testing

The data samples for test use are in the folder sample_data.

Test and visualize the sample data results with the pretrained model using:

python main.py --test

Citation

About

Unsupervised learning of Particle Image Velocimetry. (ISC 2020)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%