arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2202.13239quant-phcs.ARcs.CVcs.LG
收藏

QOC:基于参数移位和梯度剪枝的量子片上训练

QOC: Quantum On-Chip Training with Parameter Shift and Gradient Pruning

Massachusetts Institute of Technology(麻省理工学院);University of California, Los Angeles(加州大学洛杉矶分校);Carnegie Mellon University(卡内基梅隆大学);Cornell University(康奈尔大学);Arizona State University(亚利桑那州立大学);University of Texas at Austin(德克萨斯大学奥斯汀分校)

Hanrui Wang, Zirui Li, Jiaqi Gu, Yongshan Ding, David Z. Pan, Song Han

AI总结:

提出QOC,首次实现基于参数移位的实用量子片上训练,并引入概率梯度剪枝以缓解真实量子机器噪声导致的梯度低保真度问题,在多个分类任务上显著提升训练精度与可扩展性。

摘要:

参数化量子电路(PQC)正引起越来越多的研究兴趣,这得益于其在近期含噪中等规模量子(NISQ)硬件上实现量子优势的潜力。为了实现可扩展的PQC学习,训练过程需要卸载到真实的量子机器上,而不是使用指数级成本的经典模拟器。获取PQC梯度的一种常见方法是参数移位,其成本随量子比特数量线性扩展。我们提出了QOC,这是首次对使用参数移位进行实用片上PQC训练的实验演示。然而,我们发现由于真实机器上存在显著的量子误差(噪声),从简单的参数移位获得的梯度保真度较低,从而降低了训练精度。为此,我们进一步提出概率梯度剪枝,首先识别具有潜在大误差的梯度,然后将其移除。具体而言,小梯度比大梯度具有更大的相对误差,因此被剪枝的概率更高。我们使用量子神经网络(QNN)基准在5个分类任务上使用5台真实量子机器进行了广泛实验。结果表明,我们的片上训练在2类和4类图像分类任务上分别实现了超过90%和60%的准确率。概率梯度剪枝相比不剪枝带来了高达7%的PQC准确率提升。总体而言,我们成功获得了与无噪声模拟相似的片上训练精度,但具有更好的训练可扩展性。QOC代码可在TorchQuantum库中获取。

英文摘要:

Parameterized Quantum Circuits (PQC) are drawing increasing research interest thanks to its potential to achieve quantum advantages on near-term Noisy Intermediate Scale Quantum (NISQ) hardware. In order to achieve scalable PQC learning, the training process needs to be offloaded to real quantum machines instead of using exponential-cost classical simulators. One common approach to obtain PQC gradients is parameter shift whose cost scales linearly with the number of qubits. We present QOC, the first experimental demonstration of practical on-chip PQC training with parameter shift. Nevertheless, we find that due to the significant quantum errors (noises) on real machines, gradients obtained from naive parameter shift have low fidelity and thus degrading the training accuracy. To this end, we further propose probabilistic gradient pruning to firstly identify gradients with potentially large errors and then remove them. Specifically, small gradients have larger relative errors than large ones, thus having a higher probability to be pruned. We perform extensive experiments with the Quantum Neural Network (QNN) benchmarks on 5 classification tasks using 5 real quantum machines. The results demonstrate that our on-chip training achieves over 90% and 60% accuracy for 2-class and 4-class image classification tasks. The probabilistic gradient pruning brings up to 7% PQC accuracy improvements over no pruning. Overall, we successfully obtain similar on-chip training accuracy compared with noise-free simulation but have much better training scalability. The QOC code is available in the TorchQuantum library.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑