exatomic.widgets.widget module

Universe Notebook Widget

To visualize a universe containing atoms, molecules, orbitals, etc., do the following in a Jupyter notebook environment.

exatomic.UniverseWidget(u)    # type(u) is exatomic.core.universe.Universe
class exatomic.widgets.widget.DemoContainer(**kwargs: Any)[source]

Bases: ExatomicBox

A proof-of-concept mixing GUI controls with a three.js scene.

class exatomic.widgets.widget.TensorContainer(**kwargs: Any)[source]

Bases: ExatomicBox

A simple container to implement cartesian tensor visualization.

Parameters:

file_path (string) – Takes a file path name to pass through the Tensor.from_file function. Default to None.

class exatomic.widgets.widget.DemoUniverse(**kwargs: Any)[source]

Bases: ExatomicBox

A showcase of functional forms used in quantum chemistry.

class exatomic.widgets.widget.UniverseWidget(**kwargs: Any)[source]

Bases: ExatomicBox

Visualize a Universe.

u = exatomic.Universe.load(exatomic.base.resource("adf-lu-valid.hdf5"))
scenekwargs = dict(atomcolors=dict(Lu="black"))
exatomic.UniverseWidget(u, scenekwargs=scenekwargs)    # In Jupyter notebook

scenekwargs = dict(atomcolors=dict(Lu="#f442f1"), atomradii=dict(Lu=1.0))
exatomic.UniverseWidget(u, scenekwargs=scenekwargs)    # In Jupyter notebook
Parameters:
  • uni – The Universe object

  • scenekwargs (dict) – Keyword args to be passed to ExatomicScene