We present COGNAC, a novel strategy for compiling quantum circuits based on numerical optimization algorithms from scientific computing. Using a simple noise model informed by the duration of entangling gates, our gradient-based method can quickly converge to a local optimum that closely approximates the target unitary. By iteratively and continuously decreasing a gate's duration to zero, we reduce a circuit's gate count without the need for a large number of explicit elimination rewrite rules. We have implemented this technique as a general-purpose Qiskit compiler plugin and compared performance with state-of-the-art optimizers on a variety of standard 4-qubit benchmarks. COGNAC typically outperforms existing optimizers in reducing 2-qubit gate count, sometimes significantly. Running on a low-end laptop, our plugin takes seconds to optimize a small circuit, making it effective and accessible for a typical quantum programmer.
翻译:我们提出COGNAC,一种基于科学计算中数值优化算法进行量子电路编译的新策略。利用由纠缠门持续时间构建的简单噪声模型,基于梯度的方法能够快速收敛至局部最优解,从而高精度逼近目标酉矩阵。通过连续迭代将门持续时间逐步降至零,我们无需大量显式消除重写规则即可减少电路的逻辑门数量。该技术已实现为通用型Qiskit编译器插件,并在多种标准4量子比特基准测试中与现有优化器进行了性能对比。实验表明,COGNAC在减少2量子比特门数量方面通常优于现有优化器,部分情况下优势显著。在低端笔记本电脑上运行时,该插件仅需数秒即可完成小型电路的优化,为典型量子编程人员提供了高效且易用的解决方案。