Python Interface

The generation of temporary files and calls to Blender are handled by a python module ascii_phonons.

ascii_phonons.call_blender(**options)[source]

Generate a temporary script file and call Blender

Typically Blender is called in batch mode to render one or a series of .png image files.

ascii_phonons.montage_anim(**options)[source]

Render animations for all phonon modes and present as array

ascii_phonons.montage_static(**options)[source]

Render images for all phonon modes and present as array

ascii_phonons.parse_tuple(tuple_string, value_type=<type 'float'>)[source]

Get a tuple back from string representation

Three representations are recognised: ‘[1,2,3]’ : JSON-style ‘1 2 3’ : Simple space-separated ‘1,2,3’: Simple comma-separated

Parameters:
  • tuple_string (str) – Serialised tuple
  • value_type (type) – Type to cast values to