All Projects → XanaduAI → Quantum Neural Networks

XanaduAI / Quantum Neural Networks

Licence: apache-2.0
This repository contains the source code used to produce the results presented in the paper "Continuous-variable quantum neural networks". Due to subsequent interface upgrades, these scripts will work only with Strawberry Fields version <= 0.10.0.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Quantum Neural Networks

Pennylane
PennyLane is a cross-platform Python library for differentiable programming of quantum computers. Train a quantum computer the same way as a neural network.
Stars: ✭ 800 (+286.47%)
Mutual labels:  quantum-computing, quantum, optimization
Quantum Learning
This repository contains the source code used to produce the results presented in the paper "Machine learning method for state preparation and gate synthesis on photonic quantum computers".
Stars: ✭ 89 (-57%)
Mutual labels:  quantum-computing, quantum, optimization
Qmlt
The Quantum Machine Learning Toolbox (QMLT) is a Strawberry Fields application that simplifies the optimization of variational quantum circuits (also known as parametrized quantum circuits).
Stars: ✭ 106 (-48.79%)
Mutual labels:  quantum-computing, quantum, optimization
Pyepr
Powerful, automated analysis and design of quantum microwave chips & devices [Energy-Participation Ratio and more]
Stars: ✭ 81 (-60.87%)
Mutual labels:  quantum-computing, quantum
Quantum Benchmarks
benchmarking quantum circuit emulators for your daily research usage
Stars: ✭ 70 (-66.18%)
Mutual labels:  quantum-computing, quantum
Qrack
Comprehensive, GPU accelerated framework for developing universal virtual quantum processors
Stars: ✭ 79 (-61.84%)
Mutual labels:  quantum-computing, quantum
Strawberryfields
Strawberry Fields is a full-stack Python library for designing, simulating, and optimizing continuous variable (CV) quantum optical circuits.
Stars: ✭ 505 (+143.96%)
Mutual labels:  quantum-computing, quantum
Awesome Quantum Computing
A curated list of awesome quantum computing learning and developing resources.
Stars: ✭ 1,350 (+552.17%)
Mutual labels:  quantum-computing, quantum
Q
Quantum Computation Simulator written in golang
Stars: ✭ 99 (-52.17%)
Mutual labels:  quantum-computing, quantum
Teach Me Quantum
⚛ 10 week Practical Course on Quantum Information Science and Quantum Computing - with Qiskit and IBMQX
Stars: ✭ 118 (-43%)
Mutual labels:  quantum-computing, quantum
Awesome Quantum Machine Learning
Here you can get all the Quantum Machine learning Basics, Algorithms ,Study Materials ,Projects and the descriptions of the projects around the web
Stars: ✭ 1,940 (+837.2%)
Mutual labels:  quantum-computing, quantum
Qpga
Simulations of photonic quantum programmable gate arrays
Stars: ✭ 68 (-67.15%)
Mutual labels:  quantum-computing, quantum
Qutip
QuTiP: Quantum Toolbox in Python
Stars: ✭ 985 (+375.85%)
Mutual labels:  quantum-computing, quantum
Qpanda 2
QPanda 2 is an open source quantum computing framework developed by OriginQC that can be used to build, run, and optimize quantum algorithms.
Stars: ✭ 128 (-38.16%)
Mutual labels:  quantum-computing, quantum
Learnquantum
Repo of resources to help learn about quantum computing.
Stars: ✭ 143 (-30.92%)
Mutual labels:  quantum-computing, quantum
Q.js
Quantum computing in your browser.
Stars: ✭ 158 (-23.67%)
Mutual labels:  quantum-computing, quantum
Qcgpu
High Performance Tools for Quantum Computing
Stars: ✭ 380 (+83.57%)
Mutual labels:  quantum-computing, quantum
Quantumcomputingbook
Companion site for the textbook Quantum Computing: An Applied Approach
Stars: ✭ 386 (+86.47%)
Mutual labels:  quantum-computing, quantum
Quantum Nc
Microsoft Quantum Computing Libraries for noncommercial use
Stars: ✭ 126 (-39.13%)
Mutual labels:  quantum-computing, quantum
Quantum Circuit
Quantum Circuit Simulator implemented in JavaScript
Stars: ✭ 157 (-24.15%)
Mutual labels:  quantum-computing, quantum

Continuous-variable quantum neural networks

This repository contains the source code used to produce the results presented in "Continuous-variable quantum neural networks".


Requirements

To construct and optimize the variational quantum circuits, these scripts and notebooks use the TensorFlow backend of Strawberry Fields. In addition, matplotlib is required for generating output plots.

Due to subsequent interface upgrades, these scripts will work only with the following configuration

  • Strawberry Fields version 0.10.0
  • TensorFlow version 1.3
  • Python version 3.5 or 3.6

Your version of Python can be checked by running python --version. The correct versions of StrawberryFields and TensorFlow can be installed by running pip install -r requirements.txt from the main directory of this repository.

Contents

  • Function fitting: The folder function_fitting contains the Python script function_fitting.py, which automates the process of fitting classical functions using continuous-variable (CV) variational quantum circuits. Simply specify the function you would like to fit, along with other hyperparameters, and this script automatically constructs and optimizes the CV quantum neural network. In addition, training data is also provided.

  • Quantum autoencoder: coming soon.

  • Quantum fraud detection: The folder fraud_detection contains the Python script fraud_detection.py, which builds and trains a hybrid classical/quantum model for fraud detection. Additional scripts are provided for visualizing the results.

  • Tetrominos learning: The folder tetrominos_learning contains the Python script tetrominos_learning.py, which trains a continuous-variable (CV) quantum neural network. The task of the network is to encode 7 different 4X4 images, representing the (L,O,T,I,S,J,Z) tetrominos, in the photon number distribution of two light modes. Once the training phase is completed, the script plot_images.py can be executed in order to generate a .png figure representing the final results.

Using the scripts

To use the scripts, simply set the input data, output data, and hyperparametersby modifying the scripts directly - and then enter the subdirectory and run the script using Python 3:

python3 script_name.py

The outputs of the simulations will be saved in the subdirectory.

To access any saved data, the file can be loaded using NumPy:

results = np.load('simulation_results.npz')

Authors

Nathan Killoran, Thomas R. Bromley, Juan Miguel Arrazola, Maria Schuld, Nicolás Quesada, and Seth Lloyd.

If you are doing any research using this source code and Strawberry Fields, please cite the following two papers:

Nathan Killoran, Thomas R. Bromley, Juan Miguel Arrazola, Maria Schuld, Nicolás Quesada, and Seth Lloyd. Continuous-variable quantum neural networks. Physical Review Research, 1(3), 033063 (2019).

Nathan Killoran, Josh Izaac, Nicolás Quesada, Ville Bergholm, Matthew Amy, and Christian Weedbrook. Strawberry Fields: A Software Platform for Photonic Quantum Computing. arXiv, 2018. Quantum, 3, 129 (2019).

License

This source code is free and open source, released under the Apache License, Version 2.0.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].