stk.MoleculeDejsonizer

class stk.MoleculeDejsonizer[source]

Bases: object

Abstract base class for creating molecules from JSONs.

Notes

You might notice that the public methods of this abstract base class are implemented. These are just default implementations, which can be safely ignored or overridden, when implementing subclasses. However, the default implementation can be used directly, if it suits your needs.

Methods

from_json

Get a Molecule from a JSON.

from_json(json)[source]

Get a Molecule from a JSON.

Parameters:

json (dict) – A JSON representation of a molecule.

Returns:

The molecule held in json.

Return type:

Molecule