SearcharxivSearch

arXiv subjects

Shahnawaz Ahmed

Publications and source records attributed to Shahnawaz Ahmed.

At least 19 recordsLinked to original sources

FlashHead: Efficient Drop-In Replacement for the Classification Head in Language Model Inference

Language models are increasingly adopting smaller architectures optimized for consumer devices. In this setting, inference efficiency is the primary constraint. Meanwhile, vocabulary sizes continue to grow rapidly, making the classification head a critical bottleneck that accounts for up to 60\% of model parameters, and 50\% of inference compute. We introduce FlashHead, the first efficient drop-in replacement for the dense classification head that is training-free and hardware-friendly. FlashHead builds on principles from information retrieval, reframing that computation at the output head as a retrieval problem rather than a dense classification over the full vocabulary. FlashHead introduces four key innovations: (1) a balanced clustering scheme that structures vocabulary partitions into compact hardware-efficient tensors, (2) extending multiprobe retrieval to language model heads, enabling thousands of clusters to be scored in parallel, (3) a novel inference-time sampling mechanism that extends retrieval beyond top tokens, enabling probabilistic sampling across the full vocabulary, and (4) selective quantization, enabling effective low-bit computation in the head. Experiments on Llama-3.2, Gemma-3, and Qwen-3 show that FlashHead delivers model-level inference speedups of up to \textbf{1.75x} which maintaining output accuracy compared to the original head. By overcoming the classification head bottleneck, FlashHead establishes a new benchmark for efficient inference and removes a key barrier to developing smaller, capable models for consumer hardware.

cs.LG

Train on classical, deploy on quantum: scaling generative quantum machine learning to a thousand qubits

We propose an approach to generative quantum machine learning that overcomes the fundamental scaling issues of variational quantum circuits. The core idea is to use a class of generative models based on instantaneous quantum polynomial circuits, which we show can be trained efficiently on classical hardware. Although training is classically efficient, sampling from these circuits is widely believed to be classically hard, and so computational advantages are possible when sampling from the trained model on quantum hardware. By combining our approach with a data-dependent parameter initialisation strategy, we do not encounter issues of barren plateaus and successfully circumvent the poor scaling of gradient estimation that plagues traditional approaches to quantum circuit optimisation. We investigate and evaluate our approach on a number of real and synthetic datasets, training models with up to one thousand qubits and hundreds of thousands of parameters. We find that the quantum models can successfully learn from high dimensional data, and perform surprisingly well compared to simple energy-based classical generative models trained with a similar amount of hyperparameter optimisation. Overall, our work demonstrates that a path to scalable quantum generative machine learning exists and can be investigated today at large scales.

quant-ph

QuTiP 5: The Quantum Toolbox in Python

QuTiP, the Quantum Toolbox in Python, has been at the forefront of open-source quantum software for the past 13 years. It is used as a research, teaching, and industrial tool, and has been downloaded millions of times by users around the world. Here we introduce the latest developments in QuTiP v5, which are set to have a large impact on the future of QuTiP and enable it to be a modern, continuously developed and popular tool for another decade and more. We summarize the code design and fundamental data layer changes as well as efficiency improvements, new solvers, applications to quantum circuits with QuTiP-QIP, and new quantum control tools with QuTiP-QOC. Additional flexibility in the data layer underlying all ``quantum objects'' in QuTiP allows us to harness the power of state-of-the-art data formats and packages like JAX, CuPy, and more. We explain these new features with a series of both well-known and new examples. The code for these examples is available in a static form on GitHub and as continuously updated and documented notebooks in the qutip-tutorials package.

quant-ph

Gradient-descent methods for fast quantum state tomography

Quantum state tomography (QST) is a widely employed technique for characterizing the state of a quantum system. However, it is plagued by two fundamental challenges: computational and experimental complexity grows exponentially with the number of qubits, rendering experimental implementation and data post-processing arduous even for moderately sized systems. Here, we introduce gradient-descent (GD) algorithms for the post-processing step of QST in discrete- and continuous-variable systems. To ensure physically valid state reconstruction at each iteration step of the algorithm, we use various density-matrix parameterizations: Cholesky decomposition, Stiefel manifold, and projective normalization. These parameterizations have the added benefit of enabling a rank-controlled ansatz, which simplifies reconstruction when there is prior information about the system. We benchmark the performance of our GD-QST techniques against state-of-the-art methods, including constrained convex optimization, conditional generative adversarial networks, and iterative maximum likelihood estimation. Our comparison focuses on time complexity, iteration counts, data requirements, state rank, and robustness against noise. We find that rank-controlled ansatzes in our stochastic mini-batch GD-QST algorithms effectively handle noisy and incomplete data sets, yielding significantly higher reconstruction fidelity than other methods. Simulations achieving full-rank seven-qubit QST in under three minutes on a standard laptop, with 18 GB of RAM and no dedicated GPU, highlight that GD-QST is computationally more efficient and outperforms other techniques in most scenarios, offering a promising avenue for characterizing noisy intermediate-scale quantum devices. Our Python code for GD-QST algorithms is publicly available at https://github.com/mstorresh/GD-QST.

quant-ph

Entangling Schrödinger's cat states by bridging discrete- and continuous-variable encoding

In quantum information processing, two primary research directions have emerged: one based on discrete variables (DV) and the other on the structure of quantum states in a continuous-variable (CV) space. Integrating these two approaches could unlock new potentials, overcoming their respective limitations. Here, we show that such a DV-CV hybrid approach, applied to superconducting Kerr parametric oscillators (KPOs), enables us to entangle a pair of Schrödinger's cat states by two methods. The first involves the entanglement-preserving conversion between Bell states in the Fock-state basis (DV encoding) and those in the cat-state basis (CV encoding). The second method implements a $\sqrt{\textrm{iSWAP}}$ gate between two cat states following the procedure for Fock-state encoding. This simple and fast gate operation completes a universal quantum gate set in a KPO system. Our work offers powerful applications of DV-CV hybridization and marks a first step toward developing a multi-qubit platform based on planar KPO systems.

quant-ph

Better than classical? The subtle art of benchmarking quantum machine learning models

Benchmarking models via classical simulations is one of the main ways to judge ideas in quantum machine learning before noise-free hardware is available. However, the huge impact of the experimental design on the results, the small scales within reach today, as well as narratives influenced by the commercialisation of quantum technologies make it difficult to gain robust insights. To facilitate better decision-making we develop an open-source package based on the PennyLane software framework and use it to conduct a large-scale study that systematically tests 12 popular quantum machine learning models on 6 binary classification tasks used to create 160 individual datasets. We find that overall, out-of-the-box classical machine learning models outperform the quantum classifiers. Moreover, removing entanglement from a quantum model often results in as good or better performance, suggesting that "quantumness" may not be the crucial ingredient for the small learning tasks considered here. Our benchmarks also unlock investigations beyond simplistic leaderboard comparisons, and we identify five important questions for quantum model design that follow from our results.

quant-ph

Parameter estimation by learning quantum correlations in continuous photon-counting data using neural networks

We present an inference method utilizing artificial neural networks for parameter estimation of a quantum probe monitored through a single continuous measurement. Unlike existing approaches focusing on the diffusive signals generated by continuous weak measurements, our method harnesses quantum correlations in discrete photon-counting data characterized by quantum jumps. We benchmark the precision of this method against Bayesian inference, which is optimal in the sense of information retrieval. By using numerical experiments on a two-level quantum system, we demonstrate that our approach can achieve a similar optimal performance as Bayesian inference, while drastically reducing computational costs. Additionally, the method exhibits robustness against the presence of imperfections in both measurement and training data. This approach offers a promising and computationally efficient tool for quantum parameter estimation with photon-counting data, relevant for applications such as quantum sensing or quantum imaging, as well as robust calibration tasks in laboratory-based settings.

quant-ph

Measuring the quantum state of photoelectrons

A photoelectron, emitted due to the absorption of light quanta as described by the photoelectric effect, is often characterized experimentally by a classical quantity, its momentum. However, since the photoelectron is a quantum object, its rigorous characterization requires the reconstruction of the complete quantum state, the photoelectron's density matrix. Here, we use quantum state tomography to fully characterize photoelectrons emitted from helium and argon atoms upon absorption of ultrashort, extreme ultraviolet light pulses. While in helium we measure a pure photoelectronic state, in argon, spin-orbit interaction induces entanglement between the ion and the photoelectron, leading to a reduced purity of the photoelectron state. Our work shows how state tomography gives new insights into the fundamental quantum aspects of light-induced electronic processes in matter, bridging the fields of photoelectron spectroscopy and quantum information, and offering new spectroscopic possibilities for quantum technology.

quant-ph

Quantum process tomography of continuous-variable gates using coherent states

Encoding quantum information into superpositions of multiple Fock states of a harmonic oscillator can provide protection against errors, but it comes with the cost of requiring more complex quantum gates that need to address multiple Fock states simultaneously. Therefore, characterizing the quantum process fidelity of these gates also becomes more challenging. Here, we demonstrate the use of coherent-state quantum process tomography (csQPT) for a bosonic-mode superconducting circuit. CsQPT uses coherent states as input probes for the quantum process in order to completely characterize the quantum operation for an arbitrary input state. We show results for this method by characterizing a logical quantum gate constructed using displacement and SNAP operations on an encoded qubit. With csQPT, we are able to reconstruct the Kraus operators for the larger Hilbert space rather than being limited to the logical subspace. This allows for a more accurate determination of the different error mechanisms that lead to the gate infidelity.

quant-ph

QuTiP-BoFiN: A bosonic and fermionic numerical hierarchical-equations-of-motion library with applications in light-harvesting, quantum control, and single-molecule electronics

The "hierarchical equations of motion" (HEOM) method is a powerful exact numerical approach to solve the dynamics and find the steady-state of a quantum system coupled to a non-Markovian and non-perturbative environment. Originally developed in the context of physical chemistry, it has also been extended and applied to problems in solid-state physics, optics, single-molecule electronics, and biological physics. Here we present a numerical library in Python, integrated with the powerful QuTiP platform, which implements the HEOM for both bosonic and fermionic environments. We demonstrate its utility with a series of examples. For the bosonic case, we include demonstrations of fitting arbitrary spectral densities, and an example of the dynamics of energy transfer in the Fenna-Matthews-Olson photosynthetic complex, showing how a suitable non-Markovian environment can protect against pure dephasing. We also demonstrate how the HEOM can be used to benchmark different strategies for dynamical decoupling of a spin from its environment, and show that the Uhrig pulse-spacing scheme is less optimal than equally spaced pulses when the environment's spectral density is very broad. For the fermionic case, we present an integrable single-impurity example, used as a benchmark of the code, and a more complex example of an impurity strongly coupled to a single vibronic mode, with applications to single-molecule electronics.

quant-ph

Implicit differentiation of variational quantum algorithms

Several quantities important in condensed matter physics, quantum information, and quantum chemistry, as well as quantities required in meta-optimization of machine learning algorithms, can be expressed as gradients of implicitly defined functions of the parameters characterizing the system. Here, we show how to leverage implicit differentiation for gradient computation through variational quantum algorithms and explore applications in condensed matter physics, quantum machine learning, and quantum information. A function defined implicitly as the solution of a quantum algorithm, e.g., a variationally obtained ground- or steady-state, can be automatically differentiated using implicit differentiation while being agnostic to how the solution is computed. We apply this notion to the evaluation of physical quantities in condensed matter physics such as generalized susceptibilities studied through a variational quantum algorithm. Moreover, we develop two additional applications of implicit differentiation -- hyperparameter optimization in a quantum machine learning algorithm, and the variational construction of entangled quantum states based on a gradient-based maximization of a geometric measure of entanglement. Our work ties together several types of gradient calculations that can be computed using variational quantum circuits in a general way without relying on tedious analytic derivations, or approximate finite-difference methods.

quant-ph

Transmon qubit readout fidelity at the threshold for quantum error correction without a quantum-limited amplifier

High-fidelity and rapid readout of a qubit state is key to quantum computing and communication, and it is a prerequisite for quantum error correction. We present a readout scheme for superconducting qubits that combines two microwave techniques: applying a shelving technique to the qubit that effectively increases the energy-relaxation time, and a two-tone excitation of the readout resonator to distinguish among qubit populations in higher energy levels. Using a machine-learning algorithm to post-process the two-tone measurement results further improves the qubit-state assignment fidelity. We perform single-shot frequency-multiplexed qubit readout, with a 140ns readout time, and demonstrate 99.5% assignment fidelity for two-state readout and 96.9% for three-state readout - without using a quantum-limited amplifier.

quant-ph

Gradient-descent quantum process tomography by learning Kraus operators

We perform quantum process tomography (QPT) for both discrete- and continuous-variable quantum systems by learning a process representation using Kraus operators. The Kraus form ensures that the reconstructed process is completely positive. To make the process trace-preserving, we use a constrained gradient-descent (GD) approach on the so-called Stiefel manifold during optimization to obtain the Kraus operators. Our ansatz uses a few Kraus operators to avoid direct estimation of large process matrices, e.g., the Choi matrix, for low-rank quantum processes. The GD-QPT matches the performance of both compressed-sensing (CS) and projected least-squares (PLS) QPT in benchmarks with two-qubit random processes, but shines by combining the best features of these two methods. Similar to CS (but unlike PLS), GD-QPT can reconstruct a process from just a small number of random measurements, and similar to PLS (but unlike CS) it also works for larger system sizes, up to at least five qubits. We envisage that the data-driven approach of GD-QPT can become a practical tool that greatly reduces the cost and computational effort for QPT in intermediate-scale quantum systems.

quant-ph

PennyLane: Automatic differentiation of hybrid quantum-classical computations

PennyLane is a Python 3 software framework for differentiable programming of quantum computers. The library provides a unified architecture for near-term quantum computing devices, supporting both qubit and continuous-variable paradigms. PennyLane's core feature is the ability to compute gradients of variational quantum circuits in a way that is compatible with classical techniques such as backpropagation. PennyLane thus extends the automatic differentiation algorithms common in optimization and machine learning to include quantum and hybrid computations. A plugin system makes the framework compatible with any gate-based quantum simulator or hardware. We provide plugins for hardware providers including the Xanadu Cloud, Amazon Braket, and IBM Quantum, allowing PennyLane optimizations to be run on publicly accessible quantum devices. On the classical front, PennyLane interfaces with accelerated machine learning libraries such as TensorFlow, PyTorch, JAX, and Autograd. PennyLane can be used for the optimization of variational quantum eigensolvers, quantum approximate optimization, quantum machine learning models, and many other applications.

quant-ph

Extensive characterization of a family of efficient three-qubit gates at the coherence limit

While all quantum algorithms can be expressed in terms of single-qubit and two-qubit gates, more expressive gate sets can help reduce the algorithmic depth. This is important in the presence of gate errors, especially those due to decoherence. Using superconducting qubits, we have implemented a three-qubit gate by simultaneously applying two-qubit operations, thereby realizing a three-body interaction. This method straightforwardly extends to other quantum hardware architectures, requires only a "firmware" upgrade to implement, and is faster than its constituent two-qubit gates. The three-qubit gate represents an entire family of operations, creating flexibility in quantum-circuit compilation. We demonstrate a gate fidelity of $97.90\%$, which is near the coherence limit of our device. We then generate two classes of entangled states, the GHZ and W states, by applying the new gate only once; in comparison, decompositions into the standard gate set would have a two-qubit gate depth of two and three, respectively. Finally, we combine characterization methods and analyze the experimental and statistical errors on the fidelity of the gates and of the target states.

quant-ph

Robust preparation of Wigner-negative states with optimized SNAP-displacement sequences

Hosting non-classical states of light in three-dimensional microwave cavities has emerged as a promising paradigm for continuous-variable quantum information processing. Here we experimentally demonstrate high-fidelity generation of a range of Wigner-negative states useful for quantum computation, such as Schrödinger-cat states, binomial states, Gottesman-Kitaev-Preskill (GKP) states, as well as cubic phase states. The latter states have been long sought after in quantum optics and were never achieved experimentally before. To do so, we use a sequence of interleaved selective number-dependent arbitrary phase (SNAP) gates and displacements. We optimize the state preparation in two steps. First we use a gradient-descent algorithm to optimize the parameters of the SNAP and displacement gates. Then we optimize the envelope of the pulses implementing the SNAP gates. Our results show that this way of creating highly non-classical states in a harmonic oscillator is robust to fluctuations of the system parameters such as the qubit frequency and the dispersive shift.

quant-ph

Diagnosing quantum chaos with out-of-time-ordered-correlator quasiprobability in the kicked-top model

While classical chaos has been successfully characterized with consistent theories and intuitive techniques, such as with the use of Lyapunov exponents, quantum chaos is still poorly understood, as well as its relation with multi-partite entanglement and information scrambling. We consider a benchmark system, the kicked top model, which displays chaotic behaviour in the classical version, and proceed to characterize the quantum case with a thorough diagnosis of the growth of chaos and entanglement in time. As a novel tool for the characterization of quantum chaos, we introduce for this scope the quasi-probability distribution behind the out-of-time-ordered correlator (OTOC). We calculate the cumulative nonclassicality of this distribution, which has already been shown to outperform the simple use of OTOC as a probe to distinguish between integrable and nonintegrable Hamiltonians. To provide a thorough comparative analysis, we contrast the behavior of the nonclassicality with entanglement measures, such as the tripartite mutual information of the Hamiltonian as well as the entanglement entropy. We find that systems whose initial states would lie in the "sea of chaos" in the classical kicked-top model, exhibit, as they evolve in time, characteristics associated with chaotic behavior and entanglement production in closed quantum systems. We corroborate this indication by capturing it with this novel OTOC-based measure.

quant-ph

Pulse-level noisy quantum circuits with QuTiP

The study of the impact of noise on quantum circuits is especially relevant to guide the progress of Noisy Intermediate-Scale Quantum (NISQ) computing. In this paper, we address the pulse-level simulation of noisy quantum circuits with the Quantum Toolbox in Python (QuTiP). We introduce new tools in qutip-qip, QuTiP's quantum information processing package. These tools simulate quantum circuits at the pulse level, leveraging QuTiP's quantum dynamics solvers and control optimization features. We show how quantum circuits can be compiled on simulated processors, with control pulses acting on a target Hamiltonian that describes the unitary evolution of the physical qubits. Various types of noise can be introduced based on the physical model, e.g., by simulating the Lindblad density-matrix dynamics or Monte Carlo quantum trajectories. In particular, the user can define environment-induced decoherence at the processor level and include noise simulation at the level of control pulses. We illustrate how the Deutsch-Jozsa algorithm is compiled and executed on a superconducting-qubit-based processor, on a spin-chain-based processor and using control optimization algorithms. We also show how to easily reproduce experimental results on cross-talk noise in an ion-based processor, and how a Ramsey experiment can be modeled with Lindblad dynamics. Finally, we illustrate how to integrate these features with other software frameworks.

quant-ph