This repository contains a five-part PennyLane demo series on GKP-based logical quantum error correction in photonic systems.
This five-part demo series introduces GKP-based quantum error correction in photonic systems from a software perspective using PennyLane. Unlike ordinary qubit-level error correction, where syndrome extraction and recovery act directly on qubits, the GKP framing starts from bosonic oscillator noise and studies how correction appears at the logical-circuit layer as reduced effective logical noise. The series progresses from single-qubit logical coherence under effective noise to channel comparisons, multi-qubit Bell/GHZ behavior, and an interactive playground.
Install project dependencies from the repository root (notebooks + desktop app):
pennylaneandnumpyfor simulationmatplotlibfor plotsipywidgetsfor interactive controls in S05PySide6for the desktop app
pip install -r requirements.txtPhotonic quantum computing spans multiple layers, from continuous-variable physics to high-level quantum algorithms. This project intentionally operates between hardware physics and algorithms, at the logical-qubit abstraction layer.
Physical photonic hardware
└── Continuous-variable states
(squeezing, phase space, homodyne detection)
└── GKP encoding and correction
(bosonic, non-Gaussian processes)
└── Logical qubit with effective noise <- this repo
└── Quantum algorithms
Equation:
Notebook: demos/gkp_qec_demo_01.ipynb
Equation:
Notebook: demos/gkp_qec_demo_02.ipynb
Equation example:
Notebook: demos/gkp_qec_demo_03.ipynb
Equation focus: Bell and GHZ correlations such as
Notebook: demos/gkp_qec_demo_04.ipynb
Equation focus:
Notebook: demos/gkp_qec_demo_05.ipynb
Note: the notebook uses direct numeric inputs (no sliders). For a live GUI, use the desktop app below.
The desktop app mirrors S05 with live plots, data export, and multiple noise models.
Build scripts (offline desktop):
Build instructions: pyqt_gui/README.md
CI workflow: .github/workflows/build-desktop-app.yml
- Simulations use PennyLane
default.mixeddevices for noisy evolution. - Noise channels are inserted explicitly in the circuits.
- Each demo is self-contained and follows a continuous narrative.
- A conceptual framework for photonic logical noise and correction
- Focused on logical qubits, logical operations, and logical noise models
- Architecture-aware, with a photonic-first interpretation
- Designed to support education, documentation, and onboarding
- Structured as a progressive demo series (S01 to S05)
- Not a new quantum software framework
- Not a continuous-variable (CV) gate tutorial
- Not a replacement for PennyLane or Strawberry Fields
- Not a fault-tolerance benchmark or hardware performance study
- Not a physical simulation of GKP state preparation or decoding




