Command Line#

The moldenViz CLI offers a fast way to inspect Molden files and explore bundled examples. Run moldenViz -h for a full option list; the tables and recipes below summarise each capability.

Primary Options#

Flag / Argument

Description

Default

FILE

Positional argument; path to a Molden file to visualise.

None (required unless --example is used)

-e, --example

Load a bundled example molecule (co, o2, co2, h2o, benzene, prismane, pyridine, furan, acrolein).

None

-m, --only-molecule

Skip orbital surfaces and render only the nuclear framework.

False

-V, --version

Print the installed moldenViz version and exit without launching the viewer.

—

-v, --verbose

Increase logging to show informative progress messages while loading and rendering data.

False

-d, --debug

Emit detailed debug logs for troubleshooting parsing or rendering issues.

False

-q, --quiet

Suppress non-error log messages for minimal console output.

False

-h, --help

Display inline help and exit.

—

Basic Rendering#

Render molecular orbitals from a Molden file:

moldenViz path/to/file.molden

This launches the standalone PySide6 viewer with both the molecule structure and orbital visualization. The CLI owns the Qt event loop until the window is closed. Its window appears first with a loading indicator while the VTK-backed renderer and molecule meshes initialize, then replaces that placeholder with the interactive viewer.

The interactive window allows you to:

  • Select and view different molecular orbitals

  • Adjust visualization parameters (contour, opacity, colors)

  • Switch between spherical and cartesian grids

  • Export orbital data or visualization images

Show only the molecular structure (skip orbital surfaces):

moldenViz path/to/file.molden -m
Benzene displayed without molecular-orbital surfaces in the moldenViz viewer

Molecule-only mode keeps the structure and appearance controls available while skipping orbital parsing and rendering.#

Bundled Examples#

Use one of the shipped example molecules when you just want to explore the plotting experience:

moldenViz -e co

Available examples include: co, o2, co2, h2o, benzene, prismane, pyridine, furan, acrolein

Tips#

  • Combine -e with -m to explore only the geometry of an example.

  • Use configuration overrides (see details) to change colors, bond lengths, or orbital contours before launching the CLI.

  • Check your installed version quickly without rendering a window:

    moldenViz --version
    
  • Turn on additional logging when diagnosing issues (FILE can be any Molden path):

    moldenViz -v FILE
    
  • Silence informational output if you only care about errors during batch runs:

    moldenViz -q FILE
    

Common recipes#

Use the following patterns as building blocks:

# Only plot the molecule inside my.molden
moldenViz my.molden -m
# Plot only the molecule of one of the examples
moldenViz -e co -m
# Inspect the installed version
moldenViz --version
# Launch with verbose logging to follow parsing progress
moldenViz -v my.molden

For additional Python-based export options, see Exporting Volumetric Data (v1.1+) in the Python API guide.