DeepAI
Log In Sign Up

Quantum algorithms for group convolution, cross-correlation, and equivariant transformations

09/23/2021
by   Grecia Castelazo, et al.
0

Group convolutions and cross-correlations, which are equivariant to the actions of group elements, are commonly used in mathematics to analyze or take advantage of symmetries inherent in a given problem setting. Here, we provide efficient quantum algorithms for performing linear group convolutions and cross-correlations on data stored as quantum states. Runtimes for our algorithms are logarithmic in the dimension of the group thus offering an exponential speedup compared to classical algorithms when input data is provided as a quantum state and linear operations are well conditioned. Motivated by the rich literature on quantum algorithms for solving algebraic problems, our theoretical framework opens a path for quantizing many algorithms in machine learning and numerical methods that employ group operations.

READ FULL TEXT VIEW PDF

page 1

page 2

page 3

page 4

11/06/2017

An efficient quantum algorithm for generative machine learning

A central task in the field of quantum computing is to find applications...
01/27/2020

How symmetric is too symmetric for large quantum speedups?

Suppose a Boolean function f is symmetric under a group action G acting ...
12/01/2021

Discriminating Quantum States with Quantum Machine Learning

Quantum machine learning (QML) algorithms have obtained great relevance ...
12/14/2021

Speeding up Learning Quantum States through Group Equivariant Convolutional Quantum Ansätze

We develop a theoretical framework for S_n-equivariant quantum convoluti...
12/21/2018

Quantum Equivalence of the DLP and CDHP for Group Actions

In this short note we give a polynomial-time quantum reduction from the ...
04/22/2020

Fast Quantum Algorithm for Learning with Optimized Random Features

Kernel methods augmented with random features give scalable algorithms f...
12/02/2019

The supersingular isogeny problem in genus 2 and beyond

Let A/F_p and A'/F_p be supersingular principally polarized abelian vari...

1 Introduction

Symmetry and invariance are properties of functions that have central importance in mathematics and physics. In machine learning, for example, many successful algorithms exploit inherent symmetries in a problem to guide or bias an algorithm towards special classes of functions which are suitable for that problem. Notably, convolutional neural networks (CNNs) exploit the translationally invariant structures within images (say if a cat moves sideways in an image, the features of that cat move with it)

[albawi2017understanding, goodfellow2016deep]

. Convolutional neural networks seek to take advantage of translational invariance; however, symmetries arise through countless other group actions which each correspond to different invariance properties. More recent literature has focused on generalizing the results of convolutional neural networks to a broader class of group actions via the analysis of equivariance

[cohen2016group, kondor2018generalization]. Informally, a function is equivariant if it transfers symmetries from the function’s input space into its output space. There is a rich connection between equivariance and convolution and cross-correlation in mathematics. For group convolutional neural networks, previous work has shown that equivariant functions are precisely those that implement some form of group convolution or cross-correlation [kondor2018generalization, ravanbakhsh2017equivariance, maron2019universality].

In this study, we overview the group equivariant transformations of group convolution and cross-correlation and provide quantum algorithms to perform these linear group operations on data stored as quantum states. Our algorithms can output quantum states storing the output of a group convolution or cross-correlation operation with runtimes that scale polynomially with the condition number of the linear operation and logarithmically with the dimension of the group. Though we briefly discuss some applications of our work, we primarily aim to contribute a theoretical framework for quantizing existing classical algorithms or designing new quantum algorithms in the group theoretic setting.

Before outlining our algorithms, we first provide a brief review of salient group theoretic concepts. Let and be functions which map group elements to complex or real numbers. A convolution over a group is defined as

(1)

Similarly, cross-correlation is defined as

(2)

As an example, let us consider as the cyclic group . Then the group operation is isomorphic to addition modulus . For example, if and are two elements of the groups corresponding to integers and as well (abusing notation), then we note that the operation is equivalent to and is equivalent to . Hence, for the cyclic group, the convolution corresponds to the typical case for one dimensional functions:

(3)

where indices above are taken mod .

Note, that the equations above hold for finite groups, which are the focus of this study. For general groups, performing group convolution would require integration over Haar measures [kondor2018generalization, haarconvs]. Though classical algorithms exist for approximately performing equivariant transformations over infinite dimensional groups [finzi2020generalizing, kondor2018clebsch, perraudin2019deepsphere, cohen2018spherical], we leave this more general case to future work.

1.1 Background in representation theory and group Fourier transforms

In this section, we will discuss how to perform a group Fourier transform via the irreducible representations of a group. For the discussion here, we restrict ourselves to finite groups where the exposition of representations and group Fourier transforms is simpler.

Representation

Representations of a group aim to translate the action of groups onto matrix operations. A representation of a group is a matrix valued function such that for all [fulton2013representation], where is the dimension of the representation. As an example, we have the trivial representation for all .

Representations of a group can arise when associating a basis vector to each element of a group. Let

be a vector space of dimension with basis , then the left (right) action of any is a permutation: (). This gives rise to a representation consisting of permutation matrices of size which are called the left and right regular representations, denoted and respectively for . These matrices permute the basis elements according to the left and right actions of the group: and [fulton2013representation]. For example, the cyclic group has the following regular representation matrices (since this group is abelian, for all group elements):

(4)

A representation is unitary if

is a unitary matrix for all

. A representation is irreducible if it contains no proper invariant subspaces with respect to the action of the group. For finite groups, unitary irreducible representations always exist. On the contrary, a representation is reducible if it decomposes as a direct sum of irreducible subrepresentations. For example, if a representation can be decomposed into the direct sum of two other representations and as below,

(5)

where

is an invertible matrix, then it is reducible. Importantly, for compact groups, any representation

can be decomposed as above into a direct sum of irreducible representations:

(6)

For abelian groups, the irreducible representations all have dimension equal to one. For non-abelian groups, there is at least one irreducible representation which has dimension greater than one.

Group Fourier transform

Given any function which maps group elements to scalars, the group Fourier transform of is a function which maps irreducible representations to matrices whose output is denoted by and is defined as (for finite groups)

(7)

As a corollary to the conventional Fourier transform, convolution in the Fourier regime of the group corresponds to matrix multiplication over irreducible representations. Namely, for convolutions we have

(8)

Similarly for cross-correlations we have

(9)

Note that throughout this text, we will use to indicate convolution and to indicate cross-correlation.

Equivariance

Equivariance is the property of a function that translates symmetries of a function from its domain to codomain (input to output domain). A function is equivariant when the action of the group commutes with the function.

Definition 1.1 (Paraphrased from [kondor2018generalization]).

Let be a group and be two sets with corresponding G-actions

(10)

Let and be vector spaces with basis elements labeled by elements of and respectively, and let () be the set of functions mapping () to (). Let and be the induced actions of group elements onto and respectively (i.e., permute vector elements). A map is equivariant if

(11)

For example, circular or cyclic convolutional layers (i.e., filters or kernels wrap around to perform convolution) in a convolution neural network are equivariant to cyclic permutations – applying a cyclic permutation to the pixels before or after the layer results in equivalent outputs [ravanbakhsh2017equivariance].

The property of equivariance can be visualized as a commutative diagram:

(12)

Convolutions and cross-correlations are examples of functions which are equivariant to the actions of a group (see Appendix C

for more details). These operations are studied in deep learning under the topic of equivariant neural networks

[kondor2018generalization, ravanbakhsh2017equivariance]. [kondor2018generalization] proves that a feedforward neural network layer is equivariant to the action of a group if and only if each layer of the neural network performs a generalized form of convolution or cross-correlation.

2 Related works

Motivation for this work derives from the study of algebraic problems in quantum computing and implementations of equivariant transformations in deep learning especially in the context of group convolutional neural networks. Much of the prior work related to group theoretic problems in quantum computing stems from quantum algorithms aimed at solving the hidden subgroup problem [childs2010quantum]. [van2006quantum] proposed an algorithm for solving the hidden shift problem which employed group deconvolution on quantum states storing a superposition of queried function values. These ideas were expanded in [roetteler2016quantum, rotteler2010quantum]. [moore2006generic] provides an algorithm to perform generic group Fourier transforms on a quantum computer which forms the basis for many of the transformations performed in this work. In the broader context of quantum circuit analysis, group convolution has been used to analyze rates of convergence of ensembles of unitaries [emerson2005convergence, dankert2009exact].

In the past few years, many algorithms for equivariant neural networks have been proposed and analyzed [kondor2018generalization, keriven2019universal, cohen2016group, ravanbakhsh2017equivariance]. These algorithms employ and analyze weight sharing schemes that are inherent in equivariant transformations. This work has motivated a long line of research aiming to take advantage of symmetries in data [zaheer2017deep, dieleman2016exploiting, worrall2017harmonic] with applications particularly in physics and chemistry [bogatskiy2020lorentz, thomas2018tensor, kondor2018clebsch, cohen2019gauge].

Prior work in quantum computing has proposed methods and algorithms for efficiently performing matrix multiplication or solving linear systems of equations for dense matrices. The most related papers are those for applying circulant or Toeplitz matrices [wan2018asymptotic, zhou2017efficient, mahasinghe2016efficient]. Circulant matrices are a specific instance of the more general form of group cross-correlation matrices studied here. From a more applied perspective, other related work focuses on pre-conditioning matrices using circulant matrices or solving Green’s functions by taking advantage of symmetries in a problem [tong2020fast, shao2018quantum]. Many quantum algorithms have converted machine learning algorithms into quantum algorithms that are related to convolutions. For example, [kerenidis2019quantum] construct a quantum algorithm that mimics the operation of a classical convolutional neural network (e.g., for image recognition). Quantum versions of convolutional neural networks which parameterize convolutions as quantum gates have also been proposed [cong2019quantum, liu2019hybrid, pesah2020absence].

3 Converting group convolution to a linear algebraic formulation

Since convolutions and cross-correlations are linear operations, one can convert them into a matrix formulation. One simple way to do so is to vectorize the two input functions into the transformation and represent the action of the transformation via a matrix. Given two functions that map group elements to complex numbers, , we vectorize these functions over group elements by associating every group element to a basis of the vector space and denote the vectors of dimension as (filter) and (input). Any convolution or cross-correlation can be converted into a matrix weighted sum of the left or right regular representations and respectively.

Lemma 3.1 (Group operations as matrices).

Given a group , let and be the filter and input for a group operation. Then, group convolutions and cross-correlations correspond to matrix weighted sums of the left or right regular representations (all proofs deferred to Appendix A).

(13)

For each of the operations above, we also have a corresponding convolution theorem which applies the operation in the Fourier domain of the group.

Lemma 3.2 (Convolution theorems [fulton2013representation]).

Given a group , let and be the filter and input for a group operation. Let and indicate the value of the Fourier transform of the filter and input for irreducible representation . Then, one can perform group operations in the Fourier regime by applying the corresponding convolution theorem.

(14)

We defer proofs of the above to Appendix A and provide examples of these concepts in Appendix B.

The above shows that there are two methods by which one can perform group convolution or cross-correlation on a quantum computer. The first is to apply the matrices described in Lemma 3.1 as a weighted sum of unitaries [kothari2014efficient]. The second is to apply Fourier transforms to inputs and perform convolution in the Fourier regime as described in Lemma 3.2. This method takes advantage of the fact that many group Fourier transforms are efficiently performable on a quantum computer [childs2010quantum, moore2006generic].

Throughout this study, we employ the block encoding framework to implement linear transformations on a quantum computer

[low2019hamiltonian]. In this framework, a desired linear but not necessarily unitary transformation bounded in the spectral norm by is encoded in a unitary operator with

ancilla qubits such that the top left block of

is precisely .

(15)

where is the identity operation on the qubits encoding . In other words, applying the unitary to a quantum state and post-selecting on the measurement outcome on the ancilla qubits is equivalent to applying the operation on .

(16)

where is a garbage state that is orthogonal to the subspace (i.e.,

). The probability of successfully post-selecting

is thus equal to .

4 Quantum implementation as sum of unitaries

Previous quantum algorithms have proposed efficient means to block encode and apply certain matrices as a sum of unitary matrices, each of which can be efficiently performed via quantum operations [berry2015simulating, kothari2014efficient]. This framework can be applied to the form of the operations shown in Lemma 3.1 where convolution and cross-correlation operations are a weighted sum of the left or right regular (and unitary) representations.

Let indicate the number of qubits needed to block encode a given group operation. In the quantum case, we assume that we have access to either of the below oracles, or , which provide values of the convolution filter as -bit descriptions or amplitudes of a quantum state:

(17)

If entries scale independently with the size of the group, one can efficiently convert oracle to (and vice-versa up to phase factors) via algorithms for quantum digital-to-analog conversion [mitarai2019quantum], which we detail in subsection A.3 of the appendix. We note that from the oracle , one can also extract the phase of , a fact which will become useful in block encoding the operations properly.

From here, we apply quantum algorithms for linear combinations of unitary matrices to perform group convolutions and cross-correlations.

Lemma 4.1 (Linear combination of unitaries, paraphrased from Lemma 2.1 of [kothari2014efficient]).

Let be a linear combination of unitary matrices with . Let be a unitary matrix that maps to where . Let , then satisfies for any state

(18)

where and the unnormalized state (depending on ) satisfies .

In other words, Lemma 4.1 shows that is a block encoding of the matrix [gilyen2019quantum]. Performing group convolution or cross-correlation is a direct application of the above Lemma.

Lemma 4.2 (Block encoding of group convolution or cross-correlation).

Given oracle access to a filter where is normalized such that , one can block encode the matrix corresponding to group convolution or cross-correlation (see Lemma 3.1 for the proper choice of ). This requires two calls to the oracle , one call to the oracle , and efficient (classical) circuits for performing permutations based on group operations ().

Proof.

Based on which operation we would like to perform, we choose to be either or (or their inverses) as given in Lemma 3.1. These permutaiton operations typically can be efficiently performed classically. Furthermore, we make a call to and apply a phase transformation to proportional to the phase of . Finally, we use Lemma 4.1, setting in Lemma 4.1 to and to the chosen permutation operation (including the possible phase), and directly apply the results of Lemma 4.1. ∎

Remark.

The normalization

is set to ensure that the largest singular value of the linear operation is no greater than 1. This bound can be easily obtained via the triangle inequality, e.g., for convolution

. This is required for block encoding a matrix within a larger unitary matrix.

Proposition 4.3 (Applying group operations to an input state).

Given a quantum state containing the input state normalized such that and oracle access to the convolution filter , one can construct a state which is equal to the normalized output of where corresponds to one of the group operations delineated in Lemma 3.1. This operation has a runtime that scales as where is the runtime of the block encoding of Lemma 4.1.

Proof.

Let the matrix correspond to the linear operator where for a given group operation. Applying the block encoding of Lemma 4.1, we obtain the state

(19)

where is the “garbage” projected into the perpendicular subspace. The operation is successful after measuring the first register and obtaining the outcome . The probability of success for this measurement is equal to . By using amplitude amplification, this probability can be improved to [brassard2002quantum, ambainis2012variable]. ∎

Remark.

The term can be bounded by the condition number of the matrix corresponding to the group operation (see creftypecap 5.5). These matrices are diagonalized (abelian groups) or block diagonalized (non-abelian groups) by the group Fourier transform as discussed in the next section. This provides a convenient method to calculate the condition number of any given linear operation.

Note, that if the group is a cyclic group of order , then the cross-correlation operation over the group produces a circulant matrix and we recover results similar to prior quantum algorithms for performing quantum matrix operations for circulant matrices [zhou2017efficient, wan2018asymptotic].

5 Quantum implementation via convolution theorems

In this section, we consider quantum implementations of group operations when one is given oracle access to the convolutional filter

in the Fourier regime. Such settings are possible when for example one has access to the generating function of a kernel or can approximate the eigenvalues of the convolution matrix by analytically calculating a corresponding integral (see example provided later)

[wan2018asymptotic]. When performing group operations in the Fourier regime, there is an important distinction between abelian and non-abelian groups that arises from the property of the irreducible representations of each class of groups. Namely, abelian groups have the nice property that all of their irreducible representations are scalars. Furthermore, the Fourier transform for an abelian group can be easily obtained given the fact that any finite abelian group is a direct product of cyclic groups.

Theorem 5.1 (Fundamental theorem of finite abelian groups [dummit2004abstract]).

Every finite abelian group is a direct product of cyclic groups whose orders are prime powers uniquely determined by the group.

Given this convenient theorem, the algorithm for performing abelian group operations is rather simple and we consider that case first. Then, we will generalize to the case of non-abelian groups which requires more detail.

5.1 Block encoding for abelian groups

Based on the fundamental theorem of finite abelian groups, one can form the Fourier transform for a finite abelian group by taking tensor products over the corresponding Fourier transform (DFT matrix) for the groups in the direct product. For example, if an abelian group

is isomorphic to cyclic groups of dimension respectively, then

(20)

where is the discrete Fourier transform matrix of dimension

. This provides a direct means for diagonalizing convolutions and cross-correlations. For example, for convolution over an abelian group, we can form a matrix with the corresponding eigenvalues and eigenvectors.

(21)

where the is entry-wise multiplication. This implies that

(22)

where the eigenvalues of are the entries of and the eigenvectors are the columns of . Note, that in the above, we assume the are normalized to be unitary and hence we have the additional factor of not typically seen in the convolution theorem. Since outputs are quantum states, this additional factor will be removed due to the normalization of the state.

Assume we are given access to an oracle which returns entries of in a separate register:

(23)

Any finite abelian group of size is isomorphic to a direct product of cyclic groups of dimension . Therefore, the Fourier transform for a finite abelian group is simply where is the standard unitary discrete Fourier transform matrix of dimension . To apply a convolution matrix, we need to apply the Fourier transform, a diagonal matrix, and an inverse Fourier transform (see Equation 22). The applications of the Fourier transform and inverse Fourier transform, at least for the abelian case, are applications of the corresponding qFFT in the appropriate dimensions of the cyclic group decomposition.

To perform the diagonal matrix operation , we can use a block encoding as below. Alternatively, we can directly apply theorems from [tong2020fast] which provide a method for performing the inverse of a diagonal matrix.

Lemma 5.2 (Block encoding of diagonal matrix, adapted from Lemma 48 of [gilyen2019quantum]).

Let be a diagonal matrix and each entry of has absolute value of at most 1. Given access to the oracle such that

(24)

where is a -bit binary description of diagonal element , then we can implement a unitary block encoding such that with gates and two calls to .

The block encoding for a given group operation is a simple application of the proper Fourier transforms and the lemma above.

Lemma 5.3 (Fourier block encoding of abelian group convolution or cross-correlation).

For an abelian group , let . Assume we are given oracle access to the convolution filter in the Fourier regime as described earlier. Furthermore, assume the filter is normalized so that for all entries. Then, one can obtain a unitary operator that is a block encoding of the group operation, e.g., for convolution , with additional gates and application of the group Fourier transform, the inverse group Fourier transform, and two calls to the oracle .

Proof.

Let us consider the case of group convolution. Other group operations are equivalent up to simple transformations in the elements of the diagonal transformation.

For group convolution, one must perform the three operations given in Equation 22 copied below in unnormalized form:

(25)

The operation and are implementations of the proper qFFT for the dimensions of the group. To perform diagonal matrix multiplication of matrix , we block encode into using oracle and Lemma 5.2. Thus, we apply the above operations in the order described to obtain the given block encoding. ∎

5.2 Block encoding for non-abelian groups

For non-abelian groups, irreducible representations are matrices, and convolution applied in the Fourier regime requires matrix multiplication over the irreducible representation. In this setting, we now assume access to an oracle which provides matrix entries of the Fourier transform of a convolution filter in a given irreducible representation,

(26)

where indexes the irreducible representations and is the -th entry of the matrix . Note, that this oracle can be simplified for abelian groups by simply removing the indexing since all irreducible representations are scalars.

Quantum algorithms efficiently perform group Fourier transforms over many non-abelian groups (e.g., dihedral and symmetric groups) [moore2006generic, childs2010quantum]. The quantum group Fourier transform for a group returns a state containing a weighted superposition over irreducible representations [childs2010quantum]:

(27)

where is the group Fourier transform of a given basis vector and is the set of irreducible representations of . The factor included above enforces as unitary. also has the convenient property that it block diagonalizes the left and right regular representations into the irreducible representations [childs2010quantum], e.g., for the left regular representation, we have that [childs2010quantum, Eq. 118].

(28)

Since convolutions and cross-correlations over non-abelian groups require matrix multiplication over irreducible representations, we cannot simply diagonalize the state written above as in the abelian case. Here, to convolve with , we need to apply a matrix of the form below.

(29)

where is the Fourier transformed matrix for irrep with dimensionality .

Lemma 5.4 (Fourier block encoding of general group convolution or cross-correlation).

For a group of dimension which has irreducible representations of dimension no greater than , let . Assume we are given oracle access to the convolution filter in the Fourier regime as described earlier. Furthermore, assume the filter is normalized so that for all entries. Then, one can obtain a unitary operator that is a block encoding of the group operation – e.g., for convolution – with one application of the group Fourier transform and its inverse, two calls to the oracle , and additional gates.

Proof.

Let us consider the case of group convolution. Other group operations are equivalent up to simple transformations in the elements of the block diagonal transformation. For group convolution, one must perform the three operations given in Equation 29 copied below:

(30)

The operations and are implementations of the group Fourier transform and its inverse [moore2006generic]. Let so we can encode the data in qubits. To form the block encoding we follow methods in [gilyen2019quantum]. For our block encoding, we construct a data register of qubits and ancillary registers of qubits where the measurement in this register corresponds to the location of the block encoding. We first apply the group Fourier transform to the data register. The middle operation is a block diagonal matrix which we block encode using Lemma 48 of [gilyen2019quantum]. Each row or column of the matrix is at most sparse. Note, this lemma also requires oracles that provide the locations of each sparse entry in a given row or column of the matrix; in our case, since matrices are block diagonal, locating these entries is easy. Applying this operation up to error in operator norm requires two calls to the oracle and additional gates [gilyen2019quantum]. Finally, one applies an inverse group Fourier transform to the data register to obtain the given encoding. ∎

Remark.

corresponds to the maximum sparsity of any row or column of the block diagonal matrix in our block encoding. The number of irreducible representations of a group is equal to the number of conjugacy classes of the group, so groups with many conjugacy classes tend to have lower dimensional irreducible representations. For all abelian groups, is trivially equal to . For many non-abelian groups, is also strictly bounded, e.g., for dihedral groups for all [childs2010quantum].

5.3 Performing group operations on quantum states

With the block encodings described above, we can apply linear group operations to an input state . Here, we consider the case of group convolution, and note that other group operations can be performed by simple changes to the steps below. First, we show how to perform group convolution directly on an input state.

Proposition 5.5 (Applying group convolution to ).

For a group of dimension which has irreducible representations of dimension no greater than , assume we are given oracle access to the convolution filter to form block encodings described in Lemma 5.3 or Lemma 5.4. Furthermore, assume the filter is normalized so that for all entries. Given a quantum state containing the input state normalized such that , one can construct a state which is -close to the true normalized output , i.e., where corresponds to one of the group operations delineated in Lemma 3.1. This operation has a runtime that scales as where is the runtime of the block encoding (which includes the dependence on ) of Lemma 5.3 or Lemma 5.4, is the operator norm of , and is the condition number of .

Proof.

One first applies the block encoding of Lemma 5.3 or Lemma 5.4 to a state with the data encoded in the data register. After applying the block encoding, we obtain success when ancillary registers are measured in the basis. The minimum singular value of the linear operation is and the block encoding is such that it has a normalization factor of . Therefore, this has a worst-case success probability of . By using amplitude amplification, this probability can be improved to [brassard2002quantum, ambainis2012variable]. ∎

Remark.

The condition number can be calculated by analyzing the norms of the diagonal or block diagonal matrices in the block encoding. For example, for abelian groups,

(31)

For non-abelian groups, we analyze the singular values of the Fourier transform over its irreducible representations. Let and be the smallest and largest singular values of a matrix , then for non-abelian groups,

(32)

6 Inverse group operations or deconvolution

Given group operations as block encodings, we can conveniently perform polynomial transformations to the singular values of the block encoded matrix [gilyen2019quantum]. This consequentially provides a straightforward means to apply inverse convolutions or cross-correlations, also commonly termed deconvolution. In this setting, one is provided with the output as a quantum state where corresponds to convolution or cross-correlation. Given information about the filter , one hopes to reconstruct the input to the group operation as a quantum state .

Here, we provide an algorithm to perform deconvolution given the block encoding using oracle described in Lemma 4.2. Similar steps can be followed to apply deconvolution for other block encodings.

Proposition 6.1 (Applying inverse group convolution or cross-correlation (deconvolution)).

For a group of dimension , assume we are given oracle to access the convolution filter as described in Lemma 4.2. Given a quantum state containing the output of normalized such that , one can construct a state which is -close to the true normalized input , where corresponds to one of the group operations delineated in Lemma 3.1. This operation has a runtime that scales as where is the runtime of the block encoding (which includes the dependence on ) of Lemma 4.2 and is the condition number of the linear group operation .

Proof.

Follow the steps of creftypecap 4.3, but instead of directly applying the block encoding, apply a singular value transformation with polynomial approximations of the inverse function instead. In this setting, we start with a unitary that block encodes as in Lemma 4.2. Let

be the singular value decomposition of

where is a diagonal matrix and and are unitary matrices. Using the quantum singular value transformation, with applications of the block encoding and its inverse, one can apply polynomial transformations of up to degree to the diagonal entries of , i.e., [gilyen2019quantum]. Therefore, one must simply apply a polynomial approximating the inverse function as shown in Lemma 40 of [gilyen2019quantum] and described below.

On the domain , there exists an -degree polynomial function that is -close to the inverse function [gilyen2019quantum]. Using this polynomial transformation of the singular values, one can obtain an -close block encoding of the deconvolution operation using applications of the unitary block encoding and its inverse. See Lemma 40 and Theorem 41 of [gilyen2019quantum]. Upon application of this singular value transformation, the probability of successfully obtaining the state is since the normalization factor of the inverse block encoding in Theorem 41 of [gilyen2019quantum] is equal to the smallest eigenvalue of , which is , and the smallest eigenvalue of the inverse operation (deconvolution) is equal to . By using amplitude amplification, this probability can be improved to [brassard2002quantum, ambainis2012variable]. ∎

Remark.

Alternatively, when performing deconvolution in the Fourier regime using the block encoding in Lemma 5.4, the operation has a runtime that scales as , where is the runtime of Lemma 5.4. We defer the proof and formal statement to Section A.4.

7 Example application for integral equations

One particular application of the group convolution algorithms written above is in solving linear integral equations over domains that contain a certain symmetry. The example we consider here is solving a linear integral equation defined over the surface of an -dimensional Torus which is the -fold product of the circle .

Consider an integral equation defined as below:

(33)

where is an -dimensional vector indicating the location of a point on the surface of the Torus, is the unknown function (defined on the Torus) we would like to solve for, is a norm which is cyclically invariant (see example in Appendix D), and is a scalar constant.

To solve the given integral equation numerically, one approximates the integral above via a numerical approximation scheme. For example, using the Nyström method [atkinson2009numerical], one can approximate the integral as a weighted sum over discretized points with points evenly spaced along each dimension of . In each dimension , we identify these evenly spaced points as where such that any given discretized point . Here, our approximation would be

(34)

Therefore, to solve the above integral equation, we discretize our numerical solution and solve a linear systems of equations. In our example, we have

(35)

where bold text indicates discretized values of the functions vectorized in lexicographic order and is a matrix. The form of the matrix corresponds to a group cross-correlation over the direct product of the cyclic groups where the filter is equal to the values of the first row of . In other words, moving from one row of to another is equivalent to applying a permutation operation corresponding to one of the group elements of .

Note, that Equation 35 can be solved by inverting the cross-correlation operation via algorithms outlined here. When is provided as a quantum state, such an operation can be performed efficiently. In Appendix D we provide a detailed example of treating integrals over a Torus as group cross-correlation.

8 Discussion

Group convolutions and cross-correlations cover a wide class of equivariant functions commonly studied in machine learning and mathematics. We provide a framework and methodology for performing these equivariant group operations on a quantum computer. In well-conditioned cases, the runtimes of these operations scale logarithmically with the dimension of the group. For applications in machine learning, our algorithms provide a path towards quantizing group convolutional neural networks and exploring whether there exists quantum speed-ups for equivariant neural networks [cohen2016group, kondor2018generalization, ravanbakhsh2017equivariance, maron2019universality]. Furthermore, one can apply our framework in a variational algorithm where a quantum circuit is parameterized and optimized as a convolutional filter [cerezo2020variational]. More generally, our work provides a means to speed up linear operations for kernel matrices in the form of convolutions or cross-correlations commonly found in algorithms for machine learning and numerical methods [rasmussen2003gaussian, dietrich1997fast, atkinson2009numerical]. This generalizes results from previous quantum algorithms for cirulant or Toeplitz matrices [wan2018asymptotic, zhou2017efficient] and calculating Green’s functions [tong2020fast].

Acknowledgements

This work was supported by the NSF, IARPA, DOE, and DARPA. The authors would like to thank Milad Marvian and William Kaminsky for helpful discussions.

Appendix A Deferred proofs

a.1 Linear algebraic formulation (Lemma 3.1)

We would like to prove the equivalences shown in Lemma 3.1 and repeated below.

(36)

We provide a proof for convolution noting that the others require similar steps.

(37)

where the notation indicates the -th component of the vector within the brackets. In the second and third lines above, we re-order the sum over all group elements by transforming and respectively. Converting the above into a vector form over the output, we have the final result:

(38)

a.2 Proofs of convolution theorems (Lemma 3.2)

We would like to prove the equivalences via the various convolution theorems shown in Lemma 3.2 and repeated below.

(39)

For standard convolution, we have:

(40)

Since , then the above argument can be applied to also show that .

For standard cross-correlation, we similarly can show that:

(41)

For right cross-correlation, we have that:

(42)

a.3 Digital to analog oracle conversion

As a reminder, we have analog () and digital oracles () as shown below.

(43)

Given oracle , our goal is to construct . Here, we assume that returns values normalized such that the magnitude of the maximum value of is equal to 1. This is chosen to maximize the success probability of oracle conversion which can be performed by following the steps below.

  1. Beginning with the state , obtain an equal superposition of states in the support of .

    (44)

    where returns the set of basis states in the support of . If the filter has full support, then this is equivalent to applying Hadamard gates to each qubit.

  2. Call oracle and perform (classical) transformations to obtain the magnitude of the filter resulting in

    (45)
  3. Append a qubit and conditionally rotate the qubit by .

    (46)
  4. Measuring the last appended register, the oracle conversion is successful when the outcome of the measurement is . We note, that this register need not be measured right away and can be included in the block encoding to be measured later.

The runtime of this procedure depends on the probability of successfully measuring the state in the last step. This probability is and is equal to the average value of . If values of are and do not decay with the dimension of the group, then this success probability is also . Finally, additional gates are needed to obtain an equal superposition over states in the support of as in step 1. This, in most cases, requires a number of operations that scale poly-logarithmically with the dimension of the state. For example, for filters with support over all states, this is equivalent to applying Hadamard gates to each qubit.

a.4 Deconvolution in the Fourier regime (creftypecap 6.1)

To perform deconvolution in the Fourier regime, we apply Theorem 41 of [gilyen2019quantum] to perform an inverse block encoding.

Lemma A.1 (Inverse block encoded matrix, adapted from Theorem 41 of [gilyen2019quantum]).

Let be an invertible matrix and . Let be the smallest singular value of and . For , there is an efficient circuit to implement such that

where can be implemented using a single ancilla qubit and gates, which include uses of , , and single-qubit gates.

From here, one can perform deconvolution in the Fourier regime via block encodings described in Lemma 5.3 and Lemma 5.4.

Proposition A.2 (Applying deconvolution in the Fourier regime).

For a group , assume we are given oracle access to the Fourier transformed convolution filter as described in Lemma 5.4. Given a quantum state containing the output of normalized such that , one can construct a state which is -close to the true normalized input , where corresponds to one of the group operations delineated in Lemma 3.1. This operation has a runtime that scales as where is the runtime of the block encoding (which includes the dependence on and ) of Lemma 5.4 and is the condition number of the linear group operation .

Proof.

We take where is the block encoding in Lemma 5.4. The smallest eigenvalue of is . Thus, one can obtain a block encoding of in operations. Upon application of this block encoded inverse, the probability of successfully obtaining the state is since the normalization factor of the block encoding of the inverse is and the smallest singular value of is . By using amplitude amplification [brassard2002quantum, ambainis2012variable], this probability of success can be improved to .

Note, that the assumption , while being natural, can be removed by applying Corollary 69 of [gilyen2019quantum]. Furthermore, the assumption can be fulfilled by rescaling entries of accordingly. ∎

Note, that the runtime of the above algorithm has an additional factor of compared to the runtime shown in creftypecap 6.1.

Appendix B Representation theory of finite groups: example for the dihedral group

In this section we will provide a detailed example that highlights some important concepts of representation theory [reptheory2004springer] focusing on the dihedral groups , and specifically on , which is the non-abelian group having the smallest group order.

Representations

A representation of a finite group on a finite-dimensional complex vector space is a homomorphism -where is the group of invertable linear transformations of the vector space - of to the group of automorphisms of (invertible matrices).

Left and right regular representations

If we associate each element of a group to a basis element in a vector space , then the left and right regular representations, denoted by and , respectively, are matrices that permute the basis elements according to the left and right actions of the group:

Subrepresentations

A subrepresentation of a representation is a vector space of which is invariant under . For compact groups, any representation can be decomposed as a direct sum of subrepresentations which are irreducible,

(47)

where is an invertible matrix and each is irreducible.

Irreducible representations

A representation is irreducible if there is no proper, nontrivial subspace of V that is invariant under the action of G. It is called completely reducible if it decomposes as a direct sum of irreducible subrepresentations. The number of irreducible representations for a finite group is equal to the number of conjugacy classes [fulton2013representation]. A conjugacy class in is a nonempty subset of that is closed under the action of the group on itself by conjugation, i.e.

  • Given any , there exists such that .

  • If and , then .

Furthermore, the sum of the dimensions squared of all the irreducible representation of a group equals group size .

(48)

b.1 Representations of

Dihedral groups

The dihedral group is the group of symmetries of the regular -gon in the plane. The dihedral group is of order and is represented by , with the group law

for and .

The dihedral group with elements is isomorphic to a semidirect product of the cyclic groups and . Let be the generator of and be the generator of , then the dihedral group can be written compactly as

(49)

Irreducible representations of

For even, we have the following 1-dimensional irreducible representations

(50)

For odd, we have and only. The -dimensional irreducible representations are of the form

(51)

for . The sum of the squared dimensions of the irreducible representations is equal to , which is the size of the group:

b.2 Representations of

The dihedral group is obtained by composing the six symmetries of an equilateral triangle. The dihedral group and the cyclic group are the only two groups that have order 6. Unlike (which is abelian), is non-abelian. Products of group elements of are shown in the Cayley table shown in Table 1.

Like all dihedral groups, group elements of are generated by and , where is a rotation by radians about an axis passing through the center and one of the vertices of a regular -gon and is a rotation by about the center of the -gon (see Figure 1).

Figure 1: The dihedral group is the symmetry group of an equilateral triangle, that is, it is the set of all transformations such as reflection, rotation, and combinations of these, that leave the shape and position of this triangle fixed.
1
1 1
1
1
1
Table 1: The Cayley table of .

Left and right regular representations of

The regular representations of are obtained by associating a basis vector to each element of the group .