Git Product home page Git Product logo

auto_oo's Introduction

auto_oo: an autodifferentiable framework for molecular orbital-optimized variational quantum algorithms

DOI

Generate orbital optimized cost functions based on electronic structure Hamiltonians in an active space, based on automatic differentation. Powered by PennyLane using either a Pytorch or Jax backend. Molecular structure calculations are performed with PySCF. Supports gradients and hessians of hybrid cost functions based on orbital rotations and parameterized quantum circuits. We use a parameterization of orbitals by rotating the orthogonal atomic orbitals (OAOs). This code was developed as a tool to enable the calculation of Berry phases in molecular systems, see arXiv:2304.06070.

Install

  1. create an anaconda or pip environment.
  2. install PyTorch following the instructions in PyTorch's Get Started. (GPU support is not needed for small active spaces)
  3. Clone the repository git clone [email protected]:EmielKoridon/auto_oo.git and move into the cloned directory cd auto_oo
  4. Install auto_oo and its dependencies with pip install .

Dependencies

Auto_oo requires the following dependencies:

Furthermore in the tutorials, we use cirq to visualize states using Dirac notation.

Tutorials and example

For an extensive tutorial of the code, see the examples section. For the moment, we provide two jupyer notebooks

  1. examples/Tutorial_auto_oo.ipynb - in this introduction to the usage of the code, we implement a orbital-optimized PQC ansatz and optimize it using automatic differentation
  2. examples/Tutorial_Berry_phase.ipynb - in this tutorial we show how to use the orbital-optimized PQC ansatz to detect a conical intersection by calculating the Berry phase with the algorithm described in arXiv:2304.06070.

Code structure

auto_oo
├── README.md
├── pyproject.toml
│
├── examples
│   ├── Tutorial_auto_oo.ipynb
│   └── Tutorial_Berry_phase.ipynb
│
├── src
│   └── auto_oo
│       ├── ansatze
│       │   ├── __init__.py
│       │   ├── kUpCCD.py
│       │   └── uccd.py
│       ├── __init__.py
│       ├── moldata_pyscf.py
│       ├── noisy_oo_pqc.py
│       ├── oo_energy.py
│       ├── oo_pqc.py
│       ├── pqc.py
│       └── utils
│           ├── active_space.py
│           ├── __init__.py
│           ├── miscellaneous.py
│           └── newton_raphson.py
└── test
    └── ...

auto_oo's People

Contributors

emieeel avatar stefanopolla avatar

Stargazers

Johannes Spies avatar  avatar  avatar Clinch Leatherwood avatar Abhigyan Mishra avatar

Watchers

 avatar

Forkers

deba-cyber

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.