Papers
Topics
Authors
Recent
Search
2000 character limit reached

JPEG-Assisted QPIE: Hybrid Quantum Image Encoding

Updated 18 June 2026
  • The paper presents a hybrid classical–quantum protocol that integrates JPEG’s DCT and quantization to reduce quantum gate counts while preserving image fidelity.
  • JQPIE employs truncated 8×8 DCT coefficients for efficient amplitude encoding, achieving up to a 10× reduction in quantum resources compared to direct QPIE.
  • The approach generalizes to both amplitude encoding and gate-based representations, with experimental evaluations confirming near-classical JPEG image quality and improved fidelity in its quantization-free variant.

JPEG-Assisted QPIE (JQPIE) is a hybrid classical–quantum image preparation protocol that leverages JPEG compression principles—most notably, 8×8 block-wise discrete cosine transform (DCT) and quantization—to dramatically reduce quantum resource requirements in quantum pixel information encoding (QPIE). By loading only a chosen subset of quantized (or in a variant, unquantized) DCT coefficients into quantum registers, JQPIE enables the efficient construction of quantum image states with gate counts that are reduced by a large constant factor relative to direct QPIE—while retaining image quality metrics on par with classical JPEG, or exceeding them in its quantization-free variant. The approach generalizes the method to both state-preparation-based (amplitude encoding) QPIE schemes (Boosari, 5 Feb 2026) and gate-based quantum image representations such as GQIR (Wang et al., 2017).

1. Hybrid Classical–Quantum Workflow

The JQPIE protocol decomposes image preparation into a classical preprocessing stage and a quantum loading and decompression stage:

A. Classical Preprocessing

  • The input image II of size H×WH \times W is partitioned into 8×88 \times 8 pixel blocks BjB_j.
  • For each block, the 2D discrete cosine transform (DCT) is applied:

Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)

  • Standard JPEG quantization is performed:

C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)

where Q(u,v)Q(u,v) is the standard 8×8 quantization matrix.

  • A zigzag permutation (standard JPEG order) is applied to the quantized coefficients, and the first 2r2^r coefficients are retained:

Z^j(r)=[C^j(π(0)),,C^j(π(2r1))]\hat{Z}_j^{(r)} = [\hat{C}_j(\pi(0)),\,\ldots,\,\hat{C}_j(\pi(2^r-1))]

with π(k)\pi(k) the zigzag mapping.

B. Quantum Stage

  • A quantum state preparation (QSP) routine loads the truncated coefficient vectors as amplitudes, employing index and data registers for addressing blocks and coefficients.
  • Quantum decompression comprises three steps:
    • Inverse zigzag permutation to restore H×WH \times W0 order.
    • Coherent inverse quantization, implemented via block-encoded diagonal unitaries acting jointly on data and a single ancilla.
    • Inverse quantum DCT (QDCT), implemented as a separable unitary on each block's subspace.
  • Measurement or amplitude amplification post-selects the image state in the ancilla H×WH \times W1 subspace or amplifies its probability as required.

A variant, quantization-free JQPIE (QF-JQPIE), omits quantization and corresponding inverse operations, directly encoding and decompressing the leading DCT coefficients.

2. Circuit Construction and Quantum State Encoding

Registers

  • Index register: H×WH \times W2 qubits select blocks (H×WH \times W3).
  • Data register: 6 qubits address DCT coefficient index H×WH \times W4 within each block.
  • Ancilla qubit (JQPIE only): mediates block-encoded quantization during inverse quantization.

Amplitude Encoding for Truncated Coefficients

State preparation operator H×WH \times W5 exactly loads the H×WH \times W6 non-zero amplitudes:

H×WH \times W7

where H×WH \times W8 and H×WH \times W9 is a normalization constant.

  • The block-encoded unitary for inverse quantization 8×88 \times 80 applies a rescaled diagonal 8×88 \times 81 using 8×88 \times 82-fold uniformly controlled 8×88 \times 83 rotations on the ancilla (8×88 \times 84, 8×88 \times 85 with 8×88 \times 86).

QF-JQPIE: Quantization-Free Pathway

  • After DCT, apply zigzag and truncate; no quantization or ancilla required.
  • The prepared state:

8×88 \times 87

where 8×88 \times 88.

  • Inverse zigzag and only an inverse quantum DCT are required for decompression.

3. Resource Analysis and Quantum Gate Complexity

The main quantum resource cost in JQPIE is set by the QSP stage for truncated block representations, scaling as 8×88 \times 89 entangling gates (CX):

Approach CX gates (32×32, r=3) Circuit depth
Direct QPIE 1024 1024
JQPIE 228 292
QF-JQPIE 164 163
  • JQPIE reduces the QSP gate count to BjB_j0 (12.5% of direct QPIE); end-to-end, the count is BjB_j1 of the direct baseline.
  • QF-JQPIE achieves BjB_j2 of the baseline gate count and even lower depth due to the absence of the block-encoded quantization step.

For large images, the compression factor asymptotes to about a BjB_j3 reduction in the leading-order gate count relative to full-amplitude preparation, due to JPEG's energy compaction in the DCT domain and coefficient truncation (Boosari, 5 Feb 2026, Wang et al., 2017).

4. Image Reconstruction Fidelity and Comparative Evaluation

Image fidelity is assessed by BjB_j4PSNR and BjB_j5SSIM relative to classical JPEG after quantum decompression:

  • JQPIE (BjB_j6, 32 coeffs/block):
    • BjB_j7 of images have BjB_j8PSNRBjB_j9 dB, Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)0SSIMCj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)1.
    • Mean values: Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)2PSNRCj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)3 dB, Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)4SSIMCj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)5.
  • JQPIE (Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)6, 16 coeffs):
    • Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)7 of images meet Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)8PSNR threshold.
  • QF-JQPIE (Cj(u,v)=α(u)α(v)x,y=07Xj(x,y)cos((2x+1)uπ16)cos((2y+1)vπ16)C_j(u,v) = \alpha(u)\alpha(v)\sum_{x,y=0}^7 X_j(x,y) \cos\left(\frac{(2x+1)u\pi}{16}\right)\cos\left(\frac{(2y+1)v\pi}{16}\right)9):
    • Nearly all images achieve C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)0PSNRC^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)1 and mean C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)2SSIMC^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)3 (improved over JPEG due to absence of quantization noise).
  • QF-JQPIE (C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)4):
    • C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)5 of images maintain or exceed JPEG SSIM.

Experimental evaluations on standard datasets (USC–SIPI, Kodak), show that both JQPIE and QF-JQPIE maintain high perceptual quality, with QF-JQPIE frequently outperforming classical JPEG by eliminating quantization error (Boosari, 5 Feb 2026).

5. Gate-Level Circuits and Operator Sequences

The circuit-level requirements for JQPIE include:

  • State preparation: exact amplitude encoding for the selected blockwise coefficient set.
  • Block-encoded inverse quantization (C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)6): C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)7 CX gates plus C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)8 C^j(u,v)=round(Cj(u,v)Q(u,v))\hat{C}_j(u,v) = \mathrm{round}\left(\frac{C_j(u,v)}{Q(u,v)}\right)9 rotations per block, implemented via a Möttönen-style multiplexed rotation network.
  • Inverse DCT: each Q(u,v)Q(u,v)0 block requires Q(u,v)Q(u,v)1 CX gates (separable over Q(u,v)Q(u,v)2 and Q(u,v)Q(u,v)3 indices).
  • Total depth: sum of QSP, inverse quantization, and inverse DCT layers.
  • In GQIR-based realizations (Wang et al., 2017), the leading gate term is Q(u,v)Q(u,v)4 multi-controlled-NOTs, plus Q(u,v)Q(u,v)5 fixed overhead.

These costs advance prior quantum compression methods, achieving dramatic reductions in both multi-qubit circuit width and entangling gate counts for images at and above Q(u,v)Q(u,v)6 pixels, owing to JPEG’s empirically measured quantum compression ratio of Q(u,v)Q(u,v)7.

6. Limitations, Parameter Choices, and Extensions

Truncation Fidelity: Fixed per-block coefficient truncation parameter Q(u,v)Q(u,v)8 does not exploit local content variation; block misadaptation can reduce quality for high-frequency regions.

Probabilistic Step: JQPIE (quantized path) requires postselection or amplitude amplification on the ancilla Q(u,v)Q(u,v)9 subspace due to block-encoded diagonal quantization.

Scaling Properties: Asymptotic scaling remains 2r2^r0; there is no asymptotic speedup for dense images without further sparsity exploitation.

Potential Enhancements:

  • Adaptive blockwise 2r2^r1 based on local DCT energy distribution.
  • Alternative state-preparation transforms: JPEG2000 (wavelets), PCA/SVD, or learned autoencoders.
  • Integration with near-optimal sparse-state QSP algorithms to exploit further amplitude sparsity.
  • Experimental realization on Noisy Intermediate-Scale Quantum (NISQ) devices, including error mitigation strategies.

A plausible implication is that future methods using adaptive or learned transforms could further reduce gate counts beyond fixed-coefficient truncation.

7. Historical and Comparative Context

The JQPIE scheme generalizes early proposals for quantum image preparation by introducing lossy DCT-based compression and quantum decompression, unlike direct GQIR loading or block encoding schemes without amplitude truncation. Preprocessing times for JQPIE are orders of magnitude faster than block-encoding competitors (e.g., 256×256 images: 2r2^r2s for JQPIE vs. up to 2r2^r3 h for baseline block-encoding), and quantum gate savings are consistently an order of magnitude or better (Wang et al., 2017). JQPIE thus enables feasible quantum state construction for downstream quantum image processing and machine learning algorithms on non-trivial image sizes.

Summary Table: Key JQPIE and QF-JQPIE Characteristics

Feature JQPIE QF-JQPIE
Quantization Standard JPEG None
Ancilla requirement 1 (for block-encoding) None
Inverse quantization Block-encoded unitary Not required
Compression factor (typical) 2r2^r410× 2r2^r510×
Typical 2r2^r6PSNR vs. JPEG 2r2^r70 dB 2r2^r8 dB
Circuit structure Probabilistic + amplitude amp Fully unitary
Applicability to high-frequency data JPEG-matched May underperform without higher 2r2^r9

JQPIE and its quantization-free variant establish the compatibility of robust classical compression (JPEG) with scalable quantum image encoding, serving as a template for future hybrid classical–quantum data-loading protocols (Boosari, 5 Feb 2026, Wang et al., 2017).

Definition Search Book Streamline Icon: https://streamlinehq.com
References (2)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to JPEG-Assisted QPIE (JQPIE).