Skip to main content
QUICK REVIEW

[Paper Review] VQNet: Library for a Quantum-Classical Hybrid Neural Network

Zhaoyun Chen, Cheng Xue|arXiv (Cornell University)|Jan 26, 2019
Quantum Computing Algorithms and Architecture4 citations
TL;DR

VQNet is a quantum-classical hybrid neural network framework that enables end-to-end differentiable training of variational quantum circuits within classical deep learning pipelines. By integrating quantum operations (qop and qop_pmeasure) with automatic differentiation and backpropagation, VQNet supports gradient-based optimization, demonstrating successful implementation of quantum machine learning tasks like quantum circuit learning, VQE, QAOA, and quantum classification with high accuracy on nonlinear function approximation.

ABSTRACT

Deep learning is a modern approach to realize artificial intelligence. Many frameworks exist to implement the machine learning task; however, performance is limited by computing resources. Using a quantum computer to accelerate training is a promising approach. The variational quantum circuit (VQC) has gained a great deal of attention because it can be run on near-term quantum computers. In this paper, we establish a new framework that merges traditional machine learning tasks with the VQC. Users can implement a trainable quantum operation into a neural network. This framework enables the training of a quantum-classical hybrid task and may lead to a new area of quantum machine learning.

Motivation & Objective

  • To bridge classical deep learning frameworks with variational quantum circuits for hybrid quantum-classical machine learning.
  • To enable automatic differentiation and backpropagation through quantum operations in a classical deep learning environment.
  • To provide a scalable, extensible platform for prototyping and testing quantum machine learning algorithms on near-term quantum hardware.
  • To demonstrate the feasibility of training quantum circuits as trainable layers within neural networks using standard optimization techniques.
  • To lay the foundation for a TensorFlow-like ecosystem in quantum machine learning by supporting common components, optimizers, and future hardware acceleration.

Proposed method

  • Introduces two core quantum operations: qop (for expectation value computation) and qop_pmeasure (for probability measurement), both differentiable via parameter shift rules.
  • Embeds quantum circuits as differentiable operators within a classical computational graph, enabling forward and backward passes across classical and quantum components.
  • Uses parameterized quantum circuits (ansatzes) with trainable parameters optimized via gradient-based methods such as Adam and momentum optimizer.
  • Computes gradients of the loss function with respect to quantum circuit parameters using the parameter-shift rule, enabling backpropagation through quantum circuits.
  • Constructs hybrid models where quantum circuits are treated as layers in a neural network, with classical layers and quantum layers jointly trained.
  • Employs a modular design allowing integration of various quantum algorithms (e.g., VQE, QAOA, quantum classifier, quantum circuit learning) within a unified framework.

Experimental results

Research questions

  • RQ1Can variational quantum circuits be seamlessly integrated into classical deep learning frameworks with full support for automatic differentiation?
  • RQ2Can quantum operations be made differentiable and trainable using standard gradient-based optimizers in a hybrid neural network setting?
  • RQ3Can VQNet effectively train quantum circuits to approximate complex nonlinear functions such as x², eˣ, sin(πx), and |x|?
  • RQ4Can the framework support multiple quantum machine learning algorithms (e.g., VQE, QAOA, quantum classification) with consistent and extensible interfaces?
  • RQ5How does the performance of VQNet compare to classical deep neural networks in hybrid learning tasks on near-term quantum hardware?

Key findings

  • VQNet successfully implements differentiable quantum operations (qop and qop_pmeasure) that support forward and backward propagation, enabling end-to-end training of hybrid models.
  • The framework demonstrates accurate training of quantum circuits to approximate nonlinear functions, achieving near-perfect fit for y = x², y = eˣ, y = sin(πx), and y = |x| as shown in loss and prediction plots.
  • Cost functions converge steadily over 200 training steps in all tested function approximation tasks, indicating stable optimization with momentum optimizer.
  • VQNet supports the implementation of diverse quantum machine learning algorithms, including VQE, QAOA, quantum classification, and quantum circuit learning, with consistent and reusable code structure.
  • The framework enables joint optimization of classical weights (coef) and quantum circuit parameters (theta), proving the feasibility of hybrid parameter updates in a single training loop.
  • VQNet is extensible and designed for future integration with noisy quantum simulators, distributed computing (GPU/TPU), and high-level components like custom loss functions and optimizers.

Better researchstarts right now

From reading papers to final review, dramatically reduce your research time.

No credit card · Free plan available

This review was created by AI and reviewed by human editors.