NGCM Summer Academy 2017: VTK/Mayavi

NGCM Summer Academy 2017: VTK/Mayavi

During the final two days of the third annual NGCM Summer Academy, students and academics received a two day training course on 3D visualisation using Mayavi and VTK from Prabhu Ramachandran from the Department of Aerospace Engineering at IIT Bombay.

VTK is an open source library providing 3D visualisation and image processing functionality. It is written in C++ and provides wrappers to Python and other languages; enabling visualisation of complex datasets to be scripted in high-level languages.

Mayavi is a Python package that builds on VTK for general purpose 3D visualisation. It, like VTK, is also open source and allows publication-quality data visuals to be created with ease.

The workshop commenced with a brief intro to Mayavi before swiftly allowing particpants to visualise data contained in NumPy arrays in just a few lines of code! A number of different plots were created for both scalar and vector data and participants were provided with a brief introduction to meshes and how to visualise them. The Mayavi pipeline was also introduced and implemented in scripted recording of animations.

The second day focused on datsets and low-level visualisation with VTK. The use of traits in Python were also explored, giving participants knowledge of how VTK works “under the hood”. Finally, participants were invited and helped with exploring their own data using their newly acquired skills in visualisation using Mayavi and VTK.

All the material for the workshop can be downloaded from Dropbox by clicking here.

Written by Daniel Powell