From efa286b497e63e29042fb285a067b794f3de5593 Mon Sep 17 00:00:00 2001 From: Sebastien Lemaire Date: Tue, 24 Sep 2024 16:54:01 +0100 Subject: [PATCH] add page on blender --- docs/data-tools/blender.md | 59 ++++++++++++++++++++++++++++++++++++++ docs/data-tools/index.md | 1 + 2 files changed, 60 insertions(+) create mode 100644 docs/data-tools/blender.md diff --git a/docs/data-tools/blender.md b/docs/data-tools/blender.md new file mode 100644 index 000000000..3fce2b9e1 --- /dev/null +++ b/docs/data-tools/blender.md @@ -0,0 +1,59 @@ +# Blender + +[Blender](https://www.blender.org) is a 3D rendering and package tool primarily used for 3D animation and VFX but increasingly also for scientific visualisation. By being an artist tool first as opposed to a scientific visualisation package, it allows for a great versatility and a complete control over every aspect of the final image. + + +## Useful links + + - [Blender homepage](https://www.blender.org) + - [Introduction to Scientific Visualization with Blender, course by surf](https://surf-visualization.github.io/blender-course/) + - [EPCC Webinar on the use of Blender for Scientific Visualisation](https://www.archer2.ac.uk/training/courses/240214-visualisation-vt) + + +## Using Blender on ARCHER2 + +Blender is available through the `blender` module. + +``` +module load blender +``` + +Once the module has been loaded, the Blender executable will be available. + +### Running blender jobs + + +Even though blender is single node only, each frame being independent makes the render of animations an embarrassingly parallel problem. Here is an example job for running blender to export frames 1 to 100 from the blend file `scene.blend`. Submitting an other job with a different frame range will use a 2nd node etc. + +```bash +#!/bin/bash + +# Slurm job options (job-name, compute nodes, job time) +#SBATCH --job-name=example_blender_job +#SBATCH --time=0:20:00 +#SBATCH --nodes=1 +#SBATCH --ntasks-per-node=1 +#SBATCH --cpus-per-task=1 + +# Replace [budget code] below with your budget code (e.g. t01) +#SBATCH --account=[budget code] +#SBATCH --partition=standard +#SBATCH --qos=standard + +module load blender + +export BLENDER_USER_RESOURCES=${HOME/home/work}/.blender + +blender -b scene.blend --render-output //render_ -noaudio -f 1-100 -- --cycles-device CPU + +``` + +The full list of command line arguments can be found in [Blender's documentation](https://docs.blender.org/manual/en/4.2/advanced/command_line/arguments.html). Note that with blender, the order of the arguments is important. + +To automatise this process addons like the one available in [blender4science](https://github.com/EPCCed/blender4science/) are helpful as they allow to submit multiple identical jobs and handles the parallelisation to render each frame only once. + +!!! note Blender doesn't work on ARCHER2 GPU nodes at the moment due to incompatibilities with the rocm version available + + + + diff --git a/docs/data-tools/index.md b/docs/data-tools/index.md index b4ba38bd4..33b41ce1a 100644 --- a/docs/data-tools/index.md +++ b/docs/data-tools/index.md @@ -14,6 +14,7 @@ OpenMP or pthreads mutli-threaded applications (and also hydrid MPI/OpenMP) - [Globus](globus): Data transfer tool - [Julia(\*)](julia.md): The julia language - [ParaView](paraview.md): A data visualisation and analysis package +- [Blender](blender.md): A generalist 3D software that can be used for scientific visualisations - [R](cray-r.md): The R statistical language - [VisiData](visidata.md): An interactive multitool for tabular data - [VMD](vmd.md): A visualisation and analysis program for Molecular Dynamics