Installing OpenFermion requires pip. Make sure that you are using an up-to-date version of it. For information about getting started beyond what is provided below please see our Intro to OpenFermion tutorial.
Currently, OpenFermion is only tested on Mac and Linux for the reason that both electronic structure plugins are only compatible with Mac and Linux. However, for those who would like to use Windows, or for anyone having other difficulties with installing OpenFermion or its plugins, we have provided a Docker image and usage instructions in the docker folder. The Docker image provides a virtual environment with OpenFermion and select plugins pre-installed. The Docker installation should run on any operating system.
You might also want to explore the alpha release of the OpenFermion Cloud Library where users can share and download precomputed molecular benchmark files.
Check out other projects and papers using OpenFermion for inspiration, and let us know if you've been using OpenFermion!
To install the latest version of OpenFermion (in development mode):
git clone https://github.com/quantumlib/OpenFermion cd OpenFermion python3 -m pip install -e .
To install the latest PyPI release as a library (in user mode):
python3 -m pip install --user openfermion
Build the docs
The guides and tutorials are built from the
docs/ directory. Preview Markdown
files directly in GitHub. Notebooks can be loaded, viewed, and executed in Colab
by passing the GitHub location in the URL, for example:
See the TensorFlow docs style guide for Markdown and MathJax usage.
The API reference is generated from docstrings in the OpenFermion package using the latest stable release in PyPI. See the API reference style guide for examples of docstrings and testable code snippets.
To build the Markdown files from your local repo (to preview or for archive),
tensorflow-docs package to use the
API docs generator
python3 -m pip install -U --user git+https://github.com/tensorflow/docs
Run the OpenFermion docs build script to generate the Markdown files. These can be previewed in GitHub:
python3 dev_tools/docs/build_api_docs.py --output_dir=docs/api_docs