PyElastica: Simulation Visualization - Week 1 - 20/06/2022

hamzah
Published: 06/27/2022

Week 1 Status Update - 20/06/2022

Today marks one week since the official start of GSoC 2022 and I thought I should start off the project blog by giving a quick rundown on the proposed project, and the progress made so far in the first week.

Project Overview

PyElastica is an open-source Python library that can be used to assemble cosserat rods into structures and simulate their behaviour. 

As best explained by the PyElastica documentation:

The theory of Cosserat rods is a method of modeling 1D, slender rods accounting for bend, twist, stretch, and shear; allowing all possible modes of deformation to be considered under a wide range of boundary conditions. It models the rod as a deformable curve with attached deformable vectors to characterize its orientation, and evolves the system using a set of coupled second-order, nonlinear partial differential equations.

These cosserat rods can be used to build up complex and dynamic systems, from birds’ nests made of twigs to living creatures made of bones, tendons, fibers and muscles

With the large scale of systems that can be simulated in PyElastica, and the difficulty in understanding the behaviour of these systems from the large amounts of numerical data, visualization tools can be invaluable in helping to debug, understand and improve these simulations.

This Summer, I will be working on the PyElastica library to build a set of visualization tools that can be used to visualize the varying systems that can created and simulated in PyElastica.

What I Did This Week

As my project is quite open in the sense that there has not been much prior work on visualization in PyElastica and that I have a lot of control over the design and features of the visualization tools, it is very important to spend time to explore the different ways of approaching the project.

One important choice is the which visualization library to use. From discussions with my mentors, I am currently exploring two main libraries: VisPy and FURY. Both have their advantages and disadvantages, which are important to understand and evaluate to help decided on which to use going forward. Having spent some time during the community bonding period gaining familiarity with the two libraries, I spent this week working on visualizing some of the different example simulations found in the PyElastica documentation, and exploring some of the different features that could be included into the visualizations such as keyboard interactivity.

What I Plan To Do Next Week

Next week's plan is to continue on the progress made during this week, working on getting a better understanding of the respective visualization libraries. I also plan on making progress towards generalizing the visualization code, so we are able to visualize a variety of different systems through the same functions and tools.

Some consideration will also be given to the design of the visualization functions as we begin to build the general visualization tools for the library, and how we would like for PyElastica users to use the tools to easily and robustly visualize their respective systems with minimal effort.

What Issues I Faced

Fortunately, this week was mostly smooth sailing. I did face some minor issues with dependency issues and installation errors with the visualization libraries, however these were easily fixed. This did however raise a point to be aware of, which is to ensure that installation of the visualization tools and its dependencies are as straightforward as possible for PyElastica users, and will need some consideration as we get closer to release of the visualization tools.

Overall, however, it was a productive and useful first week, and I look forward to continuing the progress and working on the project in the coming weeks :).

DJDT

Versions

Time

Settings from gsoc.settings

Headers

Request

SQL queries from 1 connection

Static files (2312 found, 3 used)

Templates (11 rendered)

Cache calls from 1 backend

Signals

Log messages