This repository contains the bilayer simulation extension of the simulation framework SORS (Soft Over Rigid Simulator), referring to the paper:
SORS: A Modular, High-Fidelity Simulator for Soft Robots (Arxiv link).
For Linux distributions, tested on Ubuntu 22.04, we need the following packages installed:
sudo apt-get install imagemagick ffmpeg
Once these are installed, the simulator can be set up using:
git clone --recursive git@github.com:srl-ethz/bilayered_optimization.git
cd bilayered_optimization
conda env create -f python/environment.yml
conda activate sors
pip install -e . -v
Alternatively to the last pip install, you can run ./install.sh instead.
We provide C++ executables that will be compiled if the previous install ran successfully for:
- A single simulation
./cpp/build/bhr_sim- The genetic algorithm optimization
./cpp/build/bhr_GA- The stiffness sweep (geometry sweep can be configured in
cpp/bhr_sweep.cpp)
./cpp/build/bhr_sweepWe also provide the Python interface for running these simulations. For example for rendering a biohybrid bilayer into a video of the contraction, you can run:
python python/bhr_sim.py