The PyRETIS library

This is the documentation for the PyRETIS library and usage of the application programming interface (API). An overview of the main classes and routines are given in the introduction to the library in the user guide. It might also be a good idea to have a look at the developer guide before making changes or reading through the API docs.

The PyRETIS package

The PyRETIS library contains methods and classes that handle the different parts of simulations. These are further grouped into sub-packages:

The PyRETIS library can be imported by:

import pyretis

Or you can just import specific functions and classes from the sub-packages:

from pyretis.core import create_box
from import generate_lattice
from import write_xyz_file

xyz, size = generate_lattice('diamond', [2, 2, 2], lcon=3.567)
write_xyz_file('', xyz, names=['C']*len(xyz))

xyz, size = generate_lattice('diamond', [10, 10, 10], lcon=3.567)
write_xyz_file('', xyz, names=['C']*len(xyz))

low = [i[0] for i in size]
high = [i[1] for i in size]
box = create_box(low=low, high=high)

The usage of these sub-packages are described in the following:

Contents: The PyRETIS sub-packages

In addition PyRETIS has the following submodules:

List of submodules

There are also some submodules with information about PyRETIS. These are: module

This module just contains some info for PyRETIS.

Here we define the name of the program and some other relevant info.

This file is generated by PyRETIS (

pyretis.version module

Version information for PyRETIS.

This file is generated by PyRETIS (

PyRETIS executables

The main PyRETIS executables can be found in: