Challenges
Datasets
Workspaces
Papers
Discussions
Leaderboard
Log inSign up
Challenges
Datasets
Workspaces
Papers
Discussions
Leaderboard
Blog
Job Board
Q3AS

© 2026 Aqora Quantum S.A.S.

TermsPrivacyLegal Notice

arXiv:2102.04394 · Quantum Machine Intelligence

Learning with density matrices and random features

Fabio Augusto Gonzalez, Joseph A. Gallego-Mejia, Santiago Toledo-Cortés, Vladimir Vargas-Calderón

Published Aug 25, 2022• 27 citations
arXivHTMLPDF

Abstract

Abstract A density matrix describes the statistical state of a quantum system. It is a powerful formalism to represent both the quantum and classical uncertainty of quantum systems and to express different statistical operations such as measurement, system combination and expectations as linear algebra operations. This paper explores how density matrices can be used as a building block for machine learning models exploiting their ability to straightforwardly combine linear algebra and probability. One of the main results of the paper is to show that density matrices coupled with random Fourier features could approximate arbitrary probability distributions over $$\mathbb {R}^{n}$$ R n . Based on this finding the paper builds different models for density estimation, classification and regression. These models are differentiable, so it is possible to integrate them with other differentiable components, such as deep learning architectures and to learn their parameters using gradient-based optimization. In addition, the paper presents optimization-less training strategies based on estimation and model averaging. The models are evaluated in benchmark tasks and the results are reported and discussed.

DOI
10.1007/s42484-022-00079-9

Related papers

DEMANDE: Density Matrix Neural Density Estimation

Joseph A. Gallego-Mejia, Fabio Augusto Gonzalez

Density estimation is a fundamental task in statistics and machine learning that aims to estimate, from a set of samples, the probability density function of the distribution that generated them. There are different methods for addressing this problem but recently deep-neural density estimation methods have emerged as a powerful alternative. This paper presents a novel method for neural density estimation based on density matrices and adaptive Fourier features. Density matrices are commonly used in quantum mechanics to represent the quantum state of a physical system. In this work, they are used to estimate probability densities using an operation called quantum measurement. The proposed method can be trained without optimization using an averaging operation over the samples of the training dataset. It can also be integrated with deep learning architectures and trained using gradient descent. The performance of the proposed method was evaluated on a range of synthetic and real datasets and compared with fast kernel density estimation and state-of-the-art neural density estimation methods. The results demonstrate that the proposed method achieves competitive performance while being faster and more efficient than existing methods.

IEEE Access•Jan 1, 2023•3 citations

Quantum Adaptive Fourier Features for Neural Density Estimation

Joseph A. Gallego-Mejia, Fabio Augusto Gonzalez

Density estimation is a fundamental task in statistics and machine learning applications. Kernel density estimation is a powerful tool for non-parametric density estimation in low dimensions; however, its performance is poor in higher dimensions. Moreover, its prediction complexity scale linearly with more training data points. This paper presents a method for neural density estimation that can be seen as a type of kernel density estimation, but without the high prediction computational complexity. The method is based on density matrices, a formalism used in quantum mechanics, and adaptive Fourier features. The method can be trained without optimization, but it could be also integrated with deep learning architectures and trained using gradient descent. Thus, it could be seen as a form of neural density estimation method. The method was evaluated in different synthetic and real datasets, and its performance compared against state-of-the-art neural density estimation methods, obtaining competitive results.

arXiv:2208.00564•Aug 1, 2022•7 citations

Quantum density estimation with density matrices: Application to quantum anomaly detection

Diego H. Useche, Oscar A. Bustos-Brinez, Joseph A. Gallego-Mejia +1 more

Density estimation is a central task in statistics and machine learning. This problem aims to determine the underlying probability density function that best aligns with an observed dataset. Some of its applications include statistical inference, unsupervised learning, and anomaly detection. Despite its relevance, few works have explored the application of quantum computing to density estimation. In this article, we present a quantum-classical density-matrix density estimation model, called Q-DEMDE, based on the expected values of density matrices and a quantum embedding called quantum Fourier features. The method uses quantum hardware to build probability distributions of training data via mixed quantum states. As a core subroutine, we propose an algorithm to estimate the expected value of a mixed density matrix from its spectral decomposition on a quantum computer. In addition, we present an application of the method for quantum-classical anomaly detection. We evaluated the density estimation model with quantum random and quantum adaptive Fourier features on different datasets on a quantum simulator and a real quantum computer. An important result of this work is to show that it is possible to perform density estimation and anomaly detection with high performance on present-day quantum computers.

arXiv:2201.10006•Physical Review A•Mar 19, 2024•9 citations

Quantum Algorithms for Matrix Problems and Machine Learning

Sathyawageeswar Subramanian

This dissertation presents a study of quantum algorithms for problems that can be posed as matrix function tasks. In Chapter 1 we demonstrate a simple unifying framework for implementing of smooth functions of matrices on a quantum computer. This framework captures a variety of problems that can be solved by evaluating properties of some function of a matrix, and we identify speedups over classical algorithms for some problem classes. The analysis combines ideas from the classical theory of function approximation with the quantum algorithmic primitive of implementing linear combinations of unitary operators. In Chapter 2 we continue this study by looking at the role of sparsity of input matrices in constructing efficient quantum algorithms. We show that classically pre-processing an input matrix by spectral sparsification can be profitable for quantum Hamiltonian simulation algorithms, without compromising the simulation error or complexity. Such preprocessing incurs a one time cost linear in the size of the matrix, but can be exploited to exponentially speed up subsequent subroutines such as inversion. In Chapter 3, we give an application of this theory of matrix functions to the problem of estimating the Renyi entropy of an unknown quantum state. We combine matrix function techniques with mixed state quantum computation in the one-clean qubit model, and are able to bound of the expected runtime of our algorithm in terms of the unknown target quantity. In addition to the theme of analysing the complexity of our algorithms, we also identify instances that are of practical relevance, leading us to some problems of machine learning. In Chapter 4 we investigate kernel based learning methods using random features. We work with the QRAM input model suitable for big data, and show how matrix functions and the quantum Fourier transform can be used to devise a quantum algorithm for sampling random features that are optimised for given input data and choice of kernel. We obtain a potential exponential speedup over the best known classical algorithm even without explicit assumptions of sparsity or low rank. Finally in Chapter 5 we consider the technique of beamsearch decoding used in natural language processing. We work in the query model, and show how quantum search with advice can be used to construct a quantum search decoder that can find the optimal parse (which may for instance be a best translation, or text-to-speech transcript) at least quadratically faster than the best known classical algorithms, and obtain super-quadratic speedups in the expected runtime.

•Jul 24, 2020•0 citations

Inferring the quantum density matrix with machine learning

Kyle Stuart Cranmer, Siavash Golkar, Duccio Pappadopulo

We introduce two methods for estimating the density matrix for a quantum system: Quantum Maximum Likelihood and Quantum Variational Inference. In these methods, we construct a variational family to model the density matrix of a mixed quantum state. We also introduce quantum flows, the quantum analog of normalizing flows, which can be used to increase the expressivity of this variational family. The eigenstates and eigenvalues of interest are then derived by optimizing an appropriate loss function. The approach is qualitatively different than traditional lattice techniques that rely on the time dependence of correlation functions that summarize the lattice configurations. The resulting estimate of the density matrix can then be used to evaluate the expectation of an arbitrary operator, which opens the door to new possibilities.

arXiv:1904.05903•Apr 11, 2019•13 citations

Learning quantum models from quantum or classical data

Hilbert J. Kappen

Abstract In this paper, we address the problem of how to represent a classical data distribution in a quantum system. The proposed method is to learn the quantum Hamiltonian, that is such that its ground state approximates the given classical distribution. We review previous work on the quantum Boltzmann machine (QBM) (Kieferová M and Nathan W 2017 Phys. Rev. A 96 062327, Amin M H et al 2018 Phys. Rev. X 8 021050) and how it can be used to infer quantum Hamiltonians from quantum statistics. We then show how the proposed quantum learning formalism can also be applied to a purely classical data analysis. Representing the data as a rank one density matrix introduces quantum statistics for classical data in addition to the classical statistics. We show that quantum learning yields results that can be significantly more accurate than the classical maximum likelihood approach, both for unsupervised learning and for classification. The data density matrix and the QBM solution show entanglement, quantified by the quantum mutual information I . The classical mutual information in the data I c ⩽ I /2 = C , with C maximal classical correlations obtained by choosing a suitable orthogonal measurement basis. We suggest that the remaining mutual information Q = I /2 is obtained by non orthogonal measurements that may violate the Bell inequality. The excess mutual information I − I c may potentially be used to improve the performance of quantum implementations of machine learning or other statistical methods.

arXiv:1803.11278•Journal of Physics A Mathematical and Theoretical•Mar 9, 2020•33 citations
Abstract A density matrix describes the statistical state of a quantum system. It is a powerful formalism to represent both the quantum and classical uncertainty of quantum systems and to express different statistical operations such as measurement, system combination and expectations as linear algebra operations. This paper explores how density matrices can be used as a building block for machine learning models exploiting their ability to straightforwardly combine linear algebra and probability. One of the main results of the paper is to show that density matrices coupled with random Fourier features could approximate arbitrary probability distributions over Rn\mathbb {R}^{n}Rn R n . Based on this finding the paper builds different models for density estimation, classification and regression. These models are differentiable, so it is possible to integrate them with other differentiable components, such as deep learning architectures and to learn their parameters using gradient-based optimization. In addition, the paper presents optimization-less training strategies based on estimation and model averaging. The models are evaluated in benchmark tasks and the results are reported and discussed.
Density estimation is a fundamental task in statistics and machine learning that aims to estimate, from a set of samples, the probability density function of the distribution that generated them. There are different methods for addressing this problem but recently deep-neural density estimation methods have emerged as a powerful alternative. This paper presents a novel method for neural density estimation based on density matrices and adaptive Fourier features. Density matrices are commonly used in quantum mechanics to represent the quantum state of a physical system. In this work, they are used to estimate probability densities using an operation called quantum measurement. The proposed method can be trained without optimization using an averaging operation over the samples of the training dataset. It can also be integrated with deep learning architectures and trained using gradient descent. The performance of the proposed method was evaluated on a range of synthetic and real datasets and compared with fast kernel density estimation and state-of-the-art neural density estimation methods. The results demonstrate that the proposed method achieves competitive performance while being faster and more efficient than existing methods.
Density estimation is a fundamental task in statistics and machine learning applications. Kernel density estimation is a powerful tool for non-parametric density estimation in low dimensions; however, its performance is poor in higher dimensions. Moreover, its prediction complexity scale linearly with more training data points. This paper presents a method for neural density estimation that can be seen as a type of kernel density estimation, but without the high prediction computational complexity. The method is based on density matrices, a formalism used in quantum mechanics, and adaptive Fourier features. The method can be trained without optimization, but it could be also integrated with deep learning architectures and trained using gradient descent. Thus, it could be seen as a form of neural density estimation method. The method was evaluated in different synthetic and real datasets, and its performance compared against state-of-the-art neural density estimation methods, obtaining competitive results.
Density estimation is a central task in statistics and machine learning. This problem aims to determine the underlying probability density function that best aligns with an observed dataset. Some of its applications include statistical inference, unsupervised learning, and anomaly detection. Despite its relevance, few works have explored the application of quantum computing to density estimation. In this article, we present a quantum-classical density-matrix density estimation model, called Q-DEMDE, based on the expected values of density matrices and a quantum embedding called quantum Fourier features. The method uses quantum hardware to build probability distributions of training data via mixed quantum states. As a core subroutine, we propose an algorithm to estimate the expected value of a mixed density matrix from its spectral decomposition on a quantum computer. In addition, we present an application of the method for quantum-classical anomaly detection. We evaluated the density estimation model with quantum random and quantum adaptive Fourier features on different datasets on a quantum simulator and a real quantum computer. An important result of this work is to show that it is possible to perform density estimation and anomaly detection with high performance on present-day quantum computers.
This dissertation presents a study of quantum algorithms for problems that can be posed as matrix function tasks. In Chapter 1 we demonstrate a simple unifying framework for implementing of smooth functions of matrices on a quantum computer. This framework captures a variety of problems that can be solved by evaluating properties of some function of a matrix, and we identify speedups over classical algorithms for some problem classes. The analysis combines ideas from the classical theory of function approximation with the quantum algorithmic primitive of implementing linear combinations of unitary operators. In Chapter 2 we continue this study by looking at the role of sparsity of input matrices in constructing efficient quantum algorithms. We show that classically pre-processing an input matrix by spectral sparsification can be profitable for quantum Hamiltonian simulation algorithms, without compromising the simulation error or complexity. Such preprocessing incurs a one time cost linear in the size of the matrix, but can be exploited to exponentially speed up subsequent subroutines such as inversion. In Chapter 3, we give an application of this theory of matrix functions to the problem of estimating the Renyi entropy of an unknown quantum state. We combine matrix function techniques with mixed state quantum computation in the one-clean qubit model, and are able to bound of the expected runtime of our algorithm in terms of the unknown target quantity. In addition to the theme of analysing the complexity of our algorithms, we also identify instances that are of practical relevance, leading us to some problems of machine learning. In Chapter 4 we investigate kernel based learning methods using random features. We work with the QRAM input model suitable for big data, and show how matrix functions and the quantum Fourier transform can be used to devise a quantum algorithm for sampling random features that are optimised for given input data and choice of kernel. We obtain a potential exponential speedup over the best known classical algorithm even without explicit assumptions of sparsity or low rank. Finally in Chapter 5 we consider the technique of beamsearch decoding used in natural language processing. We work in the query model, and show how quantum search with advice can be used to construct a quantum search decoder that can find the optimal parse (which may for instance be a best translation, or text-to-speech transcript) at least quadratically faster than the best known classical algorithms, and obtain super-quadratic speedups in the expected runtime.
We introduce two methods for estimating the density matrix for a quantum system: Quantum Maximum Likelihood and Quantum Variational Inference. In these methods, we construct a variational family to model the density matrix of a mixed quantum state. We also introduce quantum flows, the quantum analog of normalizing flows, which can be used to increase the expressivity of this variational family. The eigenstates and eigenvalues of interest are then derived by optimizing an appropriate loss function. The approach is qualitatively different than traditional lattice techniques that rely on the time dependence of correlation functions that summarize the lattice configurations. The resulting estimate of the density matrix can then be used to evaluate the expectation of an arbitrary operator, which opens the door to new possibilities.
Abstract In this paper, we address the problem of how to represent a classical data distribution in a quantum system. The proposed method is to learn the quantum Hamiltonian, that is such that its ground state approximates the given classical distribution. We review previous work on the quantum Boltzmann machine (QBM) (Kieferová M and Nathan W 2017 Phys. Rev. A 96 062327, Amin M H et al 2018 Phys. Rev. X 8 021050) and how it can be used to infer quantum Hamiltonians from quantum statistics. We then show how the proposed quantum learning formalism can also be applied to a purely classical data analysis. Representing the data as a rank one density matrix introduces quantum statistics for classical data in addition to the classical statistics. We show that quantum learning yields results that can be significantly more accurate than the classical maximum likelihood approach, both for unsupervised learning and for classification. The data density matrix and the QBM solution show entanglement, quantified by the quantum mutual information I . The classical mutual information in the data I c ⩽ I /2 = C , with C maximal classical correlations obtained by choosing a suitable orthogonal measurement basis. We suggest that the remaining mutual information Q = I /2 is obtained by non orthogonal measurements that may violate the Bell inequality. The excess mutual information I − I c may potentially be used to improve the performance of quantum implementations of machine learning or other statistical methods.