One of the goals of the project is to enable researchers to visualize the result of molecular dynamic (MD) simulation easily with ParaView.
- Adapt your dataset for visualization
- Express ellipsoid in vtk format
- Color of particles
- Extract particles by planes
- ParaView GUI commands
- Resources
data
- where input data need to be stored
ParaView_macro
- python macro can be loaded and run in ParaView. Detail on macros is on this page
utils
- contains helper functions to process dataframe, converting vtk file etc
git clone https://github.com/deepflowinc/md-visualisation.git
- adjust arguments in
run.sh
python3 pipeline.py --input_dir <path/to/data/dir/> --input_column_names <variable1 variable2 ... variableN> --cross_section_grad <a b c d> --cross_section_width <w> --cross_section_origin <x0 y0 z0>
where <>
is a placeholder
python3 pipeline.py --input_dir data --input_column_names x y z --cross_section_grad 2 -1 0 1 --cross_section_width 1 --cross_section_origin 0 0 0
-
bash runme.sh
and generate vtk file -
load macro
visualiseVTK.py
on ParaView # For ellipsoid visualisation, usevisualiseVTK_ellipsoid.py
-
press button to run
visualiseVTK.py
on ParaView
input_dir
- path to the directory containing input data
input_column_names
- header of the data file you are processing.
input_skip_first_line
- if specified, skips the first line of the input when loading the input file.
vtk_saved_dir
- path to store output vtk files
save_csv
- If ‘on’, the program saves the processed dataframes into csv file
save_video
- If ‘True’, the program creates a .vtk.series file which combines all the vtk files, which can be animated in ParaView
scale
- Scale determines the radius of particles. This parameter is used unless scale is not specified in dataframe for each particles. Every particle will have the same scale in this way.
ratio
- Ratio determines the shape of particles. The parameter is the ratio of the long and short axis(long/short), which are the length of the eigenvectors. This parameter is used unless ratio is not specified in dataframe for each particles. Every particle will have the same ratio in this way
Plane equation:
more detail on this page
cross_section_grad
- parameter a, b, c, d to define the gradient of the plane
cross_section
- width of 2 planes cutting the 3D particle models. If not defined, it becomes the same as the radius of the particle(scale)
cross_section
- origin of the plane
- numpy
- pandas
This product was originally developed by Yusuke Miyashita as part of his internship in DeepFlow, Inc. This work is published under BSD-3 license, with approval from Prof. Takeshi Kawasaki at Nagoya University, who was the original contractee of this project. The original project is supported by JSPS Kakenhi (22H04472) and JST FOREST program (JPMJFR212T).