Data classification method, quantum convolutional neural network, and associated quantum electronic device

The method of progressive encoding in quantum convolutional neural networks addresses the resource and complexity challenges of conventional networks by allowing more characteristics to be processed efficiently, enhancing accuracy and reducing complexity.

FR3161050A1Pending Publication Date: 2025-10-10ORANGE SA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
FR2024003552
Authority / Receiving Office
FR · FR
Patent Type
Applications
Current Assignee / Owner
Filing Date
2024-04-05
Publication Date
2025-10-10

AI Technical Summary

Technical Problem

Conventional quantum convolutional neural networks require significant resources and complexity to process data with numerous characteristics, necessitating large network sizes and increased processing time.

Method used

A method for classifying data using a quantum convolutional neural network with progressive encoding of characteristics across multiple layers, allowing more characteristics to be processed without increasing the network size or qubit count, utilizing techniques like principal component analysis and cross-entropy minimization.

Benefits of technology

This approach enhances the accuracy of the neural network by enabling it to handle more features without expanding its size, reducing processing complexity and time, and improving classification performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

Method for classifying data, quantum convolutional neural network, and associated quantum electronic device The invention relates to a method for classifying data implemented by a quantum electronic device and comprising: obtaining a set of characteristics describing the data to be classified; and, classifying the data by a quantum convolutional neural network comprising a plurality of successive processing layers, said classification comprising progressive encoding of the characteristics of the set by several encoding layers of said network. Figure for abstract: Fig. 2A.
Need to check novelty before this filing date? Find Prior Art

Description

Title of the invention: Method for classifying data, quantum convolutional neural network, and associated quantum electronic device Technical field

[0001] The present invention belongs to the general field of quantum computing. It relates more particularly to a method for classifying data. It also relates to a quantum electronic device configured to implement such a method, and a quantum convolutional neural network. Prior art

[0002] Quantum machine learning (QML) is a growing field of study that combines machine learning techniques and the principles of quantum computing to solve complex problems more efficiently than conventional computing. Quantum machine learning refers in particular to the analysis, by quantum computers, of data encoded in the form of bits (and referred to as "classical data" hereinafter) or quantum data.

[0003] The motivation behind quantum machine learning is to integrate the concepts of quantum computing and classical machine learning to open the way to new learning programs. Quantum neural networks apply this principle by combining neural networks and parameterized quantum circuits. Quantum neural networks offer the advantage of exponentially increasing the computing power and degrees of freedom of a computer, compared to conventional techniques, and have computing capabilities that allow for a reduction in the number of steps and computation times.These models are configured to take classical data encoded in a quantum state as input, and to perform processing using quantum gates dependent on parameters whose values ​​are determined during a training phase.

[0004] Quantum Convolutional Neural Networks (QCNN) are quantum neural networks that have the ability to determine particular characteristics and patterns of an input data such as an image. More precisely, the input data is used (in an encoding layer) to encode a feature map in a circuit quantum system, then alternative layers of convolution and pooling are applied, until a single qubit is obtained. A qubit is generally defined as a two-level quantum system, which represents the smallest unit of quantum information storage. This single qubit is then measured, in order to determine the class to associate with the input data.

[0005] The fact remains that when one wishes to process data having numerous characteristics, at a rate of one characteristic per input of the neural network, it is necessary to use a quantum convolutional neural network of significant size (e.g., comprising a large number of sets of convolution and pooling layers), and which consequently also comprises a significant number of parameters to be optimized. This complexity requires the use of significant resources in terms of data processing, whether during the learning or inference phase of the quantum neural network.

[0006] Generally speaking, to process data having 2” characteristics a conventional quantum convolutional neural network must comprise n convolution layers and n pooling layers. Statement of the invention

[0007] The present invention aims to remedy all or part of the drawbacks of the prior art, in particular those set out above, by proposing a solution which makes it possible to increase the number of characteristics at the input of a quantum convolutional neural network, without increasing the size of said network.

[0008] To this end, and according to a first aspect, the invention relates to a method for classifying data implemented by a quantum electronic device and comprising:

[0009] - obtaining a set of characteristics describing the data to be classified; and,

[0010] - a classification of data by a quantum convolutional neural network comprising a plurality of successive processing layers, said classification comprising a progressive encoding of at least part of the characteristics of the set by several encoding layers of said network.

[0011] Encoding the input characteristics of the neural network in several encoding layers makes it possible to use more characteristics in the neural network without increasing the number of qubits used by the network (and therefore the number of layers of the network) and therefore limiting the associated complexity and processing time.

[0012] According to the embodiments, different training criteria may be considered during the training phase of the neural network, such as the method least squares and / or cross-entropy minimization.

[0013] Furthermore, no limitation is attached to the type or modality of the data processed by the neural network. Thus, in a particular example of implementation, the input samples of the neural network include images (or features extracted from raw images), sound data (or features extracted from raw sound data) synchronized with images, or physiological signals (or features extracted from physiological signals) which may also be synchronized with other input data.

[0014] Generally speaking, it is considered that the steps of a method should not be interpreted as being linked to a notion of temporal succession.

[0015] In particular embodiments, the classification method may further comprise one or more of the following characteristics, taken in isolation or in all technically possible combinations.

[0016] In particular embodiments, progressive encoding comprises:

[0017] - an encoding of a first subset of the set of characteristics via a first encoding layer of the quantum convolutional neural network; and,

[0018] - an encoding of at least a second subset of the feature set via at least a second layer of said network located downstream of the first layer in said network.

[0019] In particular embodiments, said at least one second subset includes a characteristic present in said first subset.

[0020] In particular embodiments, the method further comprises:

[0021] - a weighting of at least part of the characteristics of the set; and,

[0022] - an association of at least one weighted characteristic with the first and / or the second subset, based on said weighting.

[0023] In particular embodiments, said data corresponds to a file, the method further comprises a conversion of the file into an image; obtaining a set of characteristics comprising a determination of characteristics of said image; and the classification aims to determine whether said file is a benign or malicious file.

[0024] In this case, a classification of the file is for example implemented in one of the following classes: "benign", "malicious" depending on a search result for specific pattern(s) in the data provided as input.

[0025] When a file is considered to have benign behavior (which can still be called "normal behavior" in the literature), reference is made to the fact that said file is not considered to be likely to be used to carry out a computer attack. It is then understood that the notion of "benign behavior" is defined as the opposite of that of "malicious behavior".

[0026] In particular modes of implementation, the input file is in "portable executable" format.

[0027] In particular modes of implementation, the image resulting from the conversion of the file is in gray levels and of predetermined dimension.

[0028] In particular embodiments, the characteristics of the image are determined by applying a principal component analysis to said image.

[0029] Principal component analysis is a method in the data analysis family that consists of transforming variables that are linked together - and called "correlated" in statistics - into new variables that are decorrelated from each other. These new variables are called "principal components" or "principal axes". Such an analysis makes it possible to summarize information by reducing the number of variables.

[0030] According to a second aspect, the invention relates to a quantum convolutional neural network comprising a first set of layers and at least one second set of layers linked to the first set, each of the first and second sets including an encoding layer, in which the encoding layers of the first and second sets progressively encode at least a portion of input characteristics of said network.

[0031] Thus, when a conventional quantum convolutional neural network takes n features as input, the quantum convolutional neural network according to the invention can take up to 2 (n - 1) features as input for the same number of qubits (and a similar number of layers).

[0032] Also, this quantum convolutional neural network architecture is advantageous since it allows more features to be provided as input to the neural network, thus helping to improve the accuracy of the neural network, without significantly increasing its size.

[0033] In particular embodiments, the encoding layer of the second set takes a number of inputs less than the number of inputs of the encoding layer of the first set.

[0034] In particular embodiments, each of the first and second sets further includes a quantum convolutional layer linked to the encoding layer and a quantum pooling layer linked to the quantum convolutional layer.

[0035] According to a third aspect, the invention relates to a quantum electronic device configured to implement the classification method mentioned above.

[0036] According to a fourth aspect, the invention relates to a computer program comprising instructions for implementing a classification method, when said program is executed by a processor.

[0037] This program may use any programming language, and be in the form of source code, object code, or code intermediate between source code and object code, such as in a partially compiled form, or in any other desirable form.

[0038] According to a fifth aspect, the invention relates to a computer-readable recording medium on which the computer program according to the invention is recorded.

[0039] The information or recording medium may be any entity or device capable of storing the program. For example, the medium may comprise a storage means, such as a ROM, for example a CD ROM or a microelectronic circuit ROM, or a magnetic recording means, for example a hard disk.

[0040] On the other hand, the information or recording medium may be a transmissible medium such as an electrical or optical signal, which may be conveyed via an electrical or optical cable, by radio or by other means. The program according to the invention may in particular be downloaded from a network such as the Internet.

[0041] Alternatively, the information or recording medium may be an integrated circuit in which the program is incorporated, the circuit being adapted to execute or to be used in the execution of the method in question. Brief description of the drawings

[0042] Other characteristics and advantages of the present invention will emerge from the description given below, with reference to the appended drawings which illustrate an exemplary embodiment thereof without any limiting character. In the figures:

[0043] [Fig-1] [Fig.l] is a representation of a quantum convolutional neural network conventional;

[0044] [Fig.2A] [Fig.2A] is a representation of a quantum convolutional neural network as proposed, according to a first example of implementation of the invention;

[0045] [Fig.2B] [Fig.2B] is a representation of a quantum convolutional neural network as proposed, according to a second exemplary implementation of the invention;

[0046] [Fig.3A] [Fig.3A] schematically represents a quantum architecture of a quantum pooling layer taking two qubits as input, according to an exemplary implementation;

[0047] [Fig.3B] [Fig.3B] schematically represents a quantum architecture of a quantum convolution layer taking two qubits as input, according to an example of implementation;

[0048] [Fig.3C] [Fig.3C] schematically represents a quantum architecture of a quantum convolution layer taking four qubits as input, according to an example implementation;

[0049] [Fig.4] [Fig.4] represents modules embedded in a quantum electronic device according to an exemplary implementation of the invention;

[0050] [Fig.5] [Fig.5] schematically represents an example of hardware architecture of a quantum electronic device; and,

[0051] [Fig.6] [Fig.6] represents, in the form of a flowchart, a particular mode of implementation of a classification method, for example executed by the quantum electronic device of [Fig.4]. Description of the embodiments

[0052] [Fig.l] is a representation of a conventional quantum convolutional neural network.

[0053] In the field of machine learning, neural networks are architectures that consist of layers of nodes (or neurons), and more precisely of an input layer, one or more intermediate layers and an output layer.

[0054] Convolutional neural networks are a type of artificial neural network particularly suited to image processing, and in particular to pattern recognition within an image. A convolutional neural network is made up of convolution layers, pooling layers, and a so-called "fully connected" layer corresponding to the output layer of the network. Each convolution layer is based on a kernel and determines the characteristics and patterns of a particular input data. Each pooling layer, for its part, focuses on reducing the dimension of the data it takes as input (for example, dividing it by 2), so as to limit the number of learning parameters to be optimized, and a fortiori the cost in terms of processing.

[0055] Quantum convolutional neural networks have an architecture close to that of conventional convolutional neural networks. Figure 1 illustrates an example of a quantum convolutional neural network 100 taking as input four features referenced / 0, / p / 2 and / p. These features / 0, / p / 2 and / 3 are for example derived from processing an image and are provided in an input layer of the quantum convolutional neural network 100 corresponding to an encoding layer. This U# encoding layer is configured to encode the features / 0, / p / 2 and f3 in a quantum circuit using a feature map. Different feature maps exist that can be used, such as the "Pauli-FeatureMap", "ZFeatureMap" or "ZZFeatureMap" maps offered by the Qiskit development environment (registered trademark).

[0056] The result of the encoding provides four qubits referenced ^o, Q}, C1 and Qy It is important at this stage to recall that the qubit, by analogy with the classical bit, is the basic unit of quantum computing. While a classical bit is in a "0" or "1" state, the state of a qubit corresponds to a unit vector in a two-dimensional Hilbert space. In the remainder of this description, the Dirac notation "ket" | ) and "bra" ( | is used to represent the state of a qubit.

[0057] In the illustrated example, the quantum convolutional neural network 100 further comprises a first convolution layer CL^, a first pooling layer PL] connected to the first convolution layer CLU, a second convolution layer CL2 connected to the first pooling layer PL^, and a second pooling layer PL^ connected to the second convolution layer CL2. Each of the previously mentioned layers contains parameter-dependent quantum gates. As discussed in more detail below, this quantum convolutional neural network is trained before it can be used operationally (inference), so as to determine optimal values ​​of these parameters that minimize a cost function.

[0058] Generally speaking, a quantum gate is formally defined as a linear transformation that can act on a qubit or a register of qubits. Thus, a quantum gate makes it possible in particular to modify the state of a qubit or a register of qubits by changing its amplitudes.

[0059] As illustrated in Figure 1, the first convolution layer CLY consists of two quantum gates GCLW and GCLX j of arity 2, which recognize and / or determine the relationships between its input qubits. The outputs of the convolution layer CL} are then provided as input to the first pooling layer PL}. This first pooling layer PL} consists of two quantum gates GPLW and GPL}} of arity 2, and makes it possible to reduce the dimensionality of the network, here from 4 to 2 qubits.

[0060] As illustrated in Figure 1, the outputs of the first pooling layer PL} are provided as input to the second convolution layer CL2 which consists of a single quantum gate GCL2 of arity 2. Then the outputs of this second convolution layer CL2 are provided as input to the second pooling layer pl2 which also comprises only a single quantum gate GPL2 of arity 2. This second pooling layer PL2 generates as output a single qubit clout. which is then "measured". This measurement is represented, in this [Fig.l], by a pointer quadrant.

[0061] Generally speaking, a measurement converts quantum information into information that can be processed by a conventional computer, e.g., into bits. In the remainder of this document, the probabilistic expectation of a measurement, i.e. the weighted average of the results measures, is noted ( • ).

[0062] The output qubit is for example measured using the Pauli matrix ^z. In a Hilbert space of dimension 2, the Pauli matrix °z is expressed as (J / 1 0 \ \0 -1 / The Pauli matrix ^z then defines the basis in which the measure is performed. More precisely, the output qubit is measured by evaluating the probabilistic expectation of the product between the output qubit and the Pauli matrix ^z. This involves determining the average number of times the qubit ^oui.is in the eigenstate of the matrix ^z, based on the coefficients of the qubit state vector quûut.

[0063] This measurement makes it possible to obtain a value (eg, "0", "1") representative of a result of using this quantum convolutional neural network 100. Thus, if this quantum convolutional neural network 100 is used to determine the presence or absence of a cat in an image (provided as input to said network), this value makes it possible to determine whether this image includes a cat or not (eg "0" indicates the presence of a cat, "1" the absence of a cat).

[0064] Through this example of a conventional quantum convolutional neural network 100, it can therefore be observed that a conventional quantum convolutional neural network, such as the quantum convolutional neural network 100, comprising two convolution layers and two pooling layers makes it possible to process data comprising four characteristics, at a rate of one characteristic per network input. And a fortiori, a conventional quantum convolutional neural network comprising three convolution layers and three pooling layers makes it possible to process data comprising eight characteristics.

[0065] Figure 2A is a representation of a quantum convolutional neural network as proposed, according to a first example. This quantum convolutional neural network 200A comprises a first set of layers E1 including an encoding layer U (pi, a quantum convolutional layer CL{ linked to the encoding layer U and a quantum pooling layer PL^ linked to the quantum convolutional layer CL{.

[0066] It also comprises a second set of layers E2 connected to the first set E} and including an encoding layer U cp2,, a quantum convolutional layer CL2 linked to the encoding layer P&2 and a quantum pooling layer PL2 linked to the quantum convolutional layer CL2.

[0067] The characteristics / 0, / pfy fy f 4 and f5 mentioned below are for example derived from processing of image-type data, such as a principal component analysis (PCA). These characteristics correspond for example to gray level measurements. They are provided as input to the quantum convolutional neural network 200A.

[0068] In this example, the encoding layer U takes as input a first sub- set of four characteristics referenced fQ, fv and / 3. This layer encoding U is configured to encode the features / 0, fp and / 3 in a quantum circuit using a feature map, and generate four qubits referenced ¢0 A ^2 and #3.

[0069] These four qubits Qq, #2 and ^3 are provided as input to the quantum convolutional layer CL} which modifies the state of these four qubits. In the rest of the description, we denote q'o, g? q3, and q3 the result of the application of the quantum convolutional layer CL} on the qubits ^0, 9 and 63. These four qubits qQ, q^ q\, and q3 are then supplied as input to the pooling layer PL^ which modifies the state of two of the four qubits qff g? q? and q3 supplied as input to this pooling layer PL[. In the rest of the description, we denote q'o and q} the result of the application of the pooling layer PLt on the qubits qQ, q'Ÿ qr and q'3.

[0070] As illustrated in Figure 2A, the qubits q^ and q"v are encoded in the encoding layer U<^2 using a second subset of two features / 4 and / 5 of the image. In this example, the subsets of features used in the two encoding layers perform a partition of the features of the input data (i.e., they are disjoint subsets whose union corresponds to the set of features of the input data). In other embodiments (for example, when some features are more important than others as explained below), the subsets of features of the encoding layers may include common features.

[0071] The results q^ and q^ of the encoding, by the encoding layer Us are provided as input to the quantum convolutional layer CL2. In the rest of the description, we denote q^' and q”" the result of the application of the quantum convolutional layer CL2 on the qubits q^ and q"^.

[0072] These qubits q'”' and q^' are provided as input to the quantum pooling layer PL2, which then generates as output a single qubit cl,nit which is then "measured".

[0073] U1 and U encoding layers

[0074] In particular embodiments, the input data jg R” are projected onto p) 2. j”, and the encoding layers U&i and implement a feature map which is expressed as follows: [°°75] ® (cos( / .)|0) + sin( / .)|l) )

[0076] with the tensor product repeated n times, with n here the number of characteristics used by the encoding layer considered (therefore n = 4 for the Uet layer n— 2 for the U02 layer in the examples above).

[0077] It is important at this stage to recall that Dirac's notation is equivalent to the notation vector. Thus, + sin( / J 1)

[0078] In other words, the probability that the qubit representative of the characteristic f. is in a state p} is encoded by y J and the probability that the qubit representative of the feature / . is in a state |] ) is encoded by sin( / .)

[0079] Quantum pooling layers

[0080] As mentioned above, quantum pooling layers aim to reduce the dimension of the data they take as input (eg, the number of qubits), so as to reduce the number of learning parameters to be optimized, and a fortiori the cost in terms of processing. To do this, the pooling layers Quantum entanglement entangles the qubits as input - this is called quantum entanglement - and calculates a measurement or partial trace ("trace out" in English terminology) of a state.

[0081] Figure 3A schematically represents an example of quantum architecture of a quantum pooling layer taking two qubits as input and according to an example of implementation of the invention.

[0082] A quantum architecture can be represented by a two-dimensional "grid", which is composed of "horizontal wires" through which qubits circulate, and "vertical portions" containing quantum gates which act on the qubits of the horizontal wires.

[0083] As illustrated in Figure 3A, the quantum pooling layer PL takes as input two qubits ^jet ^2, and comprises two quantum gates Rz and Rx corresponding to one-parameter rotation quantum gates. The gate Rz depends on parameters W|Ct the gate Rx on parameters ^2, with 0} a first t-tuple of parameters, and ^2 a second t-tuple of parameters. These gates are called "parameterized", and the values ​​of these parameters are determined during a training phase of the quantum convolutional neural network to which they belong.

[0084] The symbol * linking the wire through which qubit 9 circulates, to the gate Rz(6^) means that this gate Rz(3^) is activated only if qubit 9) is in a state |1}. The symbol O linking the wire through which the qubit circulates to the gate R^ ( ) means that this Ry gate ( ) is activated only if the qubit is in a state p) • A partial trace of the state of the qubit at the output of this quantum architecture is then calculated, so as to reduce the dimensionality of the circuit.

[0085] Quantum Convolution Layers

[0086] Convolution layers entangle the qubits they take as input, and to do this they use parameterized quantum gates. As mentioned previously, the values ​​of these parameters (eg, and 62, with i a first t-tuple of parameters, and #2 a second t-tuple of parameters) are determined during a training phase of the quantum convolutional neural network to which they belong.

[0087] Figure 3B schematically represents an example of quantum architecture of a quantum convolution layer CL taking as input two qubits ^jet 9 / according to an example of implementation of the invention.

[0088] As illustrated in Figure 3B, the quantum convolution layer CL comprises three quantum gates Rz, Rx, and NOT. A first qubit is provided as input to a first parameterized quantum gate Ry ( which generates a qubit and a second qubit #2 is provided as input to a second parameterized quantum gate Ry( (L ) which generates a qubit Q2. Then a NOT gate (also named CNOT or cX) taking as input the two qubits / and is applied. More precisely, the NOT operation is applied to qubit #2 when qubit ^^is in a state |1 ), and otherwise leaves it unchanged.

[0089] [Fig.3C] schematically represents an example of quantum architecture of a quantum convolution layer taking four qubits as input, according to an example of implementation of the invention.

[0090] As illustrated in Figure 3B, the quantum convolution layer CL takes as input four qubits ^2, ^3 and 9 / and comprises three quantum gates GLC^ GLC3} and GLC32 which can for example correspond to the gates Rz, Rx, and NOT mentioned with reference to [Fig.3B].

[0091] Measure

[0092] As mentioned previously, the output qubit of the quantum convolutional neural network is measured.

[0093] In particular modes of implementation, this qubit is measured in the Z base, in order to obtain the expectation ( M-* | (j71W ) , with the Pauli matrix in Z base (also sometimes referenced °3 in the literature), and ) a quantum state of this qubit ciout.

[0094] More formally, let U0 be the representative matrix of the quantum convolutional neural network, and O = Z the observable, then

[0095] < >

[0096] with [0( / ) ) an arbitrary quantum state on a qubit, / the transpose matrix and conjugate of U0, and f an input data.

[0097] This expectation value is equivalent to the probability of the qubit being in a state p ) or in a state |1 ). It is then used to calculate a cost function which, during a training phase of this quantum convolutional neural network, is for example minimized. In particular modes of implementation, this cost function C( 0) corresponds to a cross-entropy cost function, and is expressed as follows 100981 [yJog(P(V,<0)= 1)) + (l-jJlogCPm^O))]

[0099] with the class associated with the "i-th" input J p N the number of inputs of the convolutional neural network, P(T;(^) = 1) a probability that the state f. ) ) s°it mcsuæ as being equal to 1 and P( = 0) a probability that the state | j yJ j is measured as being equal to 0.

[0100] A gradient descent-based optimization method may be applied to determine the optimal values ​​of the parameters 6 by adjusting them in the opposite direction of the gradient of the cost function. In quantum machine learning, different optimization methods may be used. For example, in some embodiments, the parameter shifting method described in the article "Evaluating analytic gradients on quantum hardware", Schuld & Al., published in March 2019 in Physical Review A, 99(3) may be used; or the "Simultaneous Perturbation for Stochastic Backpropagation" (SPSB) method described in more detail in the article "Gradient estimation with constant scaling for hybrid quantum machine learning", Hoffmann & Al., published in November 2022.

[0101] It is important to note that depending on the embodiments, different training criteria can be used during the training phase of the neural network, such as for example the least squares method or the minimization of cross entropy.

[0102] Furthermore, the invention has so far been described without making any assumptions about the values ​​of the characteristics / 0, fp / 2, fy f 4, and / 5 (which may for example all be distinct from one another). But the invention nevertheless remains applicable in the case where at least one same characteristic is provided to several inputs of the neural network. This variant proves to be particularly advantageous in the case where this characteristic proves to be more important than other characteristics of the input data in the classification task for which the quantum convolutional neural network is used.

[0103] Also, in the event that it is determined that at least one characteristic turns out to be more important than other features of the input data, this more important feature may be provided, in some embodiments, to multiple inputs of the neural network, so as to be taken into account more in the classification task. As discussed in more detail below with reference to [Fig.6], this relative importance of the input features is for example determined during a specific step of weighting the features of the input data.

[0104] The invention has also been described so far in the case where the quantum convolutional neural network considers six features as input to the network. But the invention nonetheless remains applicable in the case where the quantum convolutional neural network considers a different number of features as input to the network (eg, greater than or less than six).

[0105] Figure 2B is a representation of a quantum convolutional neural network as proposed, according to a second example. This quantum convolutional neural network 200B comprises a first set of layers E^, a second set of layers E2, and a third set of layers E3. Each of these sets includes an encoding layer, U^2, E(p^, a quantum convolutional layer CL^, CL2, CL3 linked to the encoding layer which precedes it, and a quantum pooling layer PE^, PL^ and PL{ linked to the quantum convolutional layer which precedes it. As illustrated by this figure 2B, the neural network 200B has 14 inputs, each of which can be associated with a characteristic fQ, f iy of the input data.

[0106] Of course, as mentioned previously, the same characteristic can be provided to several inputs of the neural network 200B.

[0107] It is also important to note that the architectures of the quantum convolution and pooling layers previously mentioned constitute only non-limiting examples, other configurations being able to be envisaged by a person specialized in the field of quantum machine learning.

[0108] [Fig.4] represents modules embedded in a quantum electronic device according to an exemplary implementation of the invention.

[0109] This quantum electronic device referenced 20 may correspond to a quantum computer or an imperfect intermediate-scale quantum computer ("Noisy In-termediate-Scale Quantum", NISQ, according to the Anglo-Saxon terminology). The latter is less efficient than a quantum computer since it is subject to quantum noise which limits its capacities, and is not capable of correcting quantum errors continuously. In addition, its quantum processor is only capable of processing a limited number of qubits (a few tens to hundreds).

[0110] As illustrated by [Fig.4], the quantum electronic device 20 notably comprises a MOD_OBT module for obtaining a set of characteristics describing data to be classified; and a MOD_CLASS module for classifying the given by the quantum convolutional neural network according to the invention.

[0111] [Fig.5] schematically represents an example of hardware architecture of a quantum electronic device.

[0112] As illustrated by [Fig.5], the quantum electronic device 20 has the hardware architecture of a computer. Thus, the quantum electronic device 20 comprises, in particular, a quantum processor 1, a random access memory 2, a read-only memory 3 and a non-volatile memory 4. In particular embodiments, the quantum electronic device 20 also has communication means 5.

[0113] The read-only memory 3 of the quantum electronic device 20 constitutes a recording medium in accordance with the invention, readable by the quantum processor 1 and on which is recorded a computer program PROG in accordance with the invention, comprising instructions for executing steps of the classification method. The program PROG defines functional modules of the quantum electronic device 20, which rely on or control the hardware elements 1 to 5 of the quantum electronic device 20 cited above. These functional modules are illustrated in [Fig. 4] in a non-limiting manner, and are described in more detail below with reference to different modes of implementation.

[0114] In particular embodiments, the communication means 5 allow in particular the quantum electronic device 20 to exchange data with any other electronic device. For this purpose, the communication means 5 comprise a communication interface, wired or wireless, capable of implementing any communication protocol.

[0115] [Fig.6] represents, in the form of a flowchart, a particular mode of implementation of a classification method, for example executed by the quantum electronic device of [Fig.4].

[0116] In this particular mode of implementation, the classification consists of a classification of a file according to whether it is benign or malicious. As illustrated by [Fig.6], the method comprises a first step S10 during which the file to be classified is obtained, for example using the communication means 5.

[0117] This file is for example of the "portable executable" type ("Portable Executable", PE, according to Anglo-Saxon terminology). This type of file makes it possible to efficiently encapsulate all the information necessary for the Windows boot manager (registered trademark) to load an executable code.

[0118] The classification method further comprises a step S20 during which the obtained file is converted into an image. This file is for example converted into a grayscale image using the conversion method described in the article "Malware images: Visualization and automatic classification", Nataraj & Al., published in 2011 in "Proceedings of the 8th International Symposium on Visualization for Cyber ​​Security". During this step S20, the resulting image is also resized to a fixed (e.g., predetermined) dimension (e.g., to a 64 x 64 pixel image), depending on the QCNN used.

[0119] Then, during a step S30, characteristics of the image obtained during step S20 are determined. This step is for example implemented by the MOD_OBT module of the quantum electronic device 20. In particular modes of implementation, these characteristics are obtained by applying a principal component analysis. Other techniques may also be envisaged, which aim for example to detect contours, lines, objects or patterns, a sudden and local change in intensity, a change in texture, etc.

[0120] In particular modes of implementation, these characteristics can be weighted, so as to select for example only the most relevant characteristics in the context of the classification of the file, or to use in several encoding layers of the QCNN the most relevant characteristics (the same characteristic can be used in several encoding layers for example).

[0121] As illustrated by [Fig.6], the method further comprises a step S40 during which the characteristics determined during step S30 are provided as input to a quantum convolutional neural network, such as the network 200A or 200B of FIGS. 2A or 2B. This step is for example implemented by the module M0D_IN of the quantum electronic device 20.

[0122] In particular modes of implementation, where the characteristics determined in step S30 are weighted, those having the greatest weights can for example be provided to several inputs of the neural network 200A, 200B.

[0123] Finally, the method comprises a step S50 during which a classification of said file is carried out, which characterizes the fact that this file is considered benign or malicious. This step is for example implemented by the MOD_CLASS module of the quantum electronic device 20.

[0124] Results

[0125] The architecture of the quantum convolutional neural network according to the invention ("INV") and a conventional quantum convolutional neural network architecture ("CONV") were compared, in the context of a classification of images comprising "0" and "1" and originating from the MNIST (acronym for "Modified / Mixed National Institute of Standards and Technology) data set.

[0126] Five processing cycles el, e5 - also called "epochs" - were considered for training the neural network, on 10,000 samples. Then the precision measures ("prec") and the "F-score" ("Fl") were calculated considering 4,000 samples.

[0127] Table 1 below summarizes these results.

[0128] [Table 1]

[0129] Table 1: results of the classification of images of "0" and "1" by a neural network according to the invention (INV) and by a conventional neural network (CONV) Number of sets el e2 e3 e4 e5 Results (prec / Fl) 2 INV 0.9695 0.98 0.9819 0.9774 0.9808 0.9837 / 0.9848 CONV 0.9549 0.9795 0.9786 0.9787 0.9783 0.9742 / 0.9762 3 INV 0.9292 0.9701 0.9645 0.97 0.9652 0.983 / 0.9841 CONV 0.8908 0.968 0.9661 0.9757 0.9685 0.97275 / 0.9746 4 INV 0.7102 0.9558 0.96 0.9607 0.9577 0.9795 / 0.9809 CONV 0.7821 0.96 0.9709 0.9737 0.9706 0.97725 / 0.9789

[0130] The results in this table 1 show that the QCNN architecture according to the invention provides, in this experiment, better classification results, whether in terms of precision or FL score. II also illustrates that the performance of the QCNN seems to decrease when the number of sets of layers increases, which tends to confirm that the information included in the input data can be "lost" when the QCNN includes too many parameters.

[0131] Table 2 below illustrates the results of a classification of images of "0" and "8" by a neural network according to the invention (INV) and by a conventional neural network (CONV).

[0132] [Table 2]

[0133] Table 2: results of the classification of images of "0" and "8" by a neural network according to the invention (INV) and by a conventional neural network (CONV) Number of sets el e2 e3 e4 e5 Results (prev / Fl) 2 INV 0.945 0.938 0.953 0.965 0.963 0.9547 / 0.9548 CONV 0.946 0.960 0.934 0.961 0.965 0.9512 / 0.9518 3 INV 0.8992 0.9548 0.9578 0.947 0.9499 0.958 / 0.9579 CONV 0.9138 0.9544 0.9499 0.9469 0.9328 0.9495 / 0.9500 4 INV 0.5265 0.5198 0.7798 0.9454 0.9454 0.926 / 0.928 CONV 0.8264 0.9517 0.9447 0.9596 0.9530 0.944 / 0.9449

[0134] The results in this table 2 show that the QCNN architecture according to the invention provides in this experiment, better results in terms of classification, whether in terms of precision or Fl score.

[0135] The scores of this classification of images of "0" and "8" are lower than those of the classification of "0" and "1". As mentioned previously, this is explained on the one hand by the fact that the "0" and "8" are graphically closer than the "0" and "1", but also by the fact that a low-dimensional principal component analysis (as in this example) tends to blur the image.

[0136] It can be seen that in the experiment, according to Table 2, the QCNN according to the invention comprising four sets of layers is not more efficient than the conventional QCNN. This is explained by the fact that the random initialization of the hyperparameters of the QCNN (those optimized by gradient descent) is not optimal. However, a number of cycles greater than 5 could improve the performance of the QCNN according to the invention, as confirmed by the results in Table 3. Furthermore, this result is explained by the fact that, in this experiment, the number of features considered is not sufficiently large compared to the number of parameters of the QCNN. This assertion is further confirmed by the results in Table 4.

[0137] More specifically, Table 3 shows that the performance of the neural network according to the invention (INV) is much better than that of the conventional neural network (CONV), with a difference (in this example) of 4% in terms of accuracy and FL score.

[0138] [Table 3]

[0139] Table 3: results of image classification of "0" and "8" from the set MNIST, using two neural network architectures having 4 sets of layers. el e2 e3 e4 e5 INV 0.6596 0.9450 0.9427 0.9385 0.9385 CONV 0.7693 0.9218 0.9407 0.9390 0.9480 e6 e7 e8 e9 elO Results (prec / Fl) INV 0.9356 0.9259 0.9356 0.9405 0.9347 0.9625 / 0.9605 CONV 0.9466 0.9387 0.9439 0.9276 0.9478 0.924 / 0.9267

[0140] Table 4 summarizes the results of the classification of images of "0" and "8" from the MNIST set by a conventional neural network having 5 sets of layers, and which takes as input a number of characteristics similar to that considered to obtain the results of the neural network according to the invention (INV) of Table 3, but with a significant number (eg, 114 parameters for the conventional neural network with 5 sets of layers against 60 parameters for the neural network according to the invention with 4 layers) of free parameters. This Table 4 shows that the performances of the conventional neural network are low, which therefore confirms that the performance of the architecture of the neural network according to the invention is linked to the number of characteristics that this neural network can take as input.

[0141] [Table 4]

[0142] Table 4: Results of image classification of "0" and "8" from the MNIST set by a conventional neural network having 5 sets of layers. el e2 e3 e4 e5 Results (prec / Fl) CONV 0.5055 0.5087 0.4984 0.5152 0.4935 0.4817 / 0.6138

[0143] The neural network architecture according to the invention was also tested with sets of images representative of benign and / or malicious files. To do this, two sets of labeled data including files of the "portable executable" type were considered, "BODMAS Malware Dataset" provided by the University of Illinois at Urbana-Champaign (UIUC) and "PE Malware Machine Learning Dataset".

[0144] A principal component analysis, PCA, was then applied to these files, so as to obtain a set of images. The dimension of this analysis was 14 (PCA-14) so ​​as to be able to obtain a relatively fine analysis of the images, without significantly increasing the number of characteristics to be considered as input to the neural network. Table 5 shows the results of the classification of images representative of benign and malicious files by a neural network according to the invention (INV) and a conventional neural network (CONV) having 2 and 3 sets of layers.

[0145] [Table 5]

[0146] Table 5: results of the classification of images representative of benign and malicious files by a neural network according to the invention (INV) and by a conventional neural network (CONV) Number of sets el e2 e3 e4 e5 Score Fl 2 INV 0.6464 0.6798 0.6940 0.7174 0.7036 0.780 CONV 0.6409 0.7063 0.7042 0.6998 0.6996 0.7698 3 INV 0.6195 0.6784 0.6835 0.6528 0.6547 0.785 CONV 0.4525 0.4665 0.5933 0.5294 0.5049 0.5897

[0147] Table 5 shows that the neural network according to the invention offers better results in terms of Fl score: 1% with two sets of layers, and 33% with three sets of layers.

[0148] For the conventional neural network comprising three sets of layers, the values ​​are relatively low. This is due to the excessive number of parameters compared to the number of features provided as input to the neural network, which are not sufficient. This example therefore illustrates well the technical effect and the interest of the neural network architecture as proposed, which improves the efficiency of the training phase, even with a limited number of sets (eg, 3).

Claims

Claims

1. Method for classifying data implemented by a quantum electronic device (20) and comprising: • obtaining (S30) a set of characteristics describing the data to be classified; and, • classifying (S50) the data by a quantum convolutional neural network comprising a plurality of successive processing layers, said classification comprising a progressive encoding of at least part of the characteristics of the set by several encoding layers of said network.

2. A classification method according to claim 1, wherein the progressive encoding comprises: • an encoding of a first subset of the set of characteristics via a first encoding layer of the quantum convolutional neural network; and, • an encoding of at least a second subset of the set of characteristics via at least a second layer of said network located downstream of the first layer in said network.

3. A classification method according to claim 2, wherein said at least one second subset includes a characteristic present in said first subset.

4. Classification method according to claim 2 or 3, further comprising: • a weighting of at least part of the characteristics of the set; and, • an association of at least one weighted characteristic with the first and / or the second subset, according to said weighting.

5. Classification method according to one of claims 1 to 4, in which said data corresponds to a file, the method comprising in in addition to a conversion (S20) of the file into an image; obtaining (S30) a set of characteristics comprising a determination of characteristics of said image; and the classification (S50) aims to determine whether said file is a benign or malicious file.

6. A quantum convolutional neural network (200A, 200B) comprising a first set (El) of layers and at least one second set (E2) of layers linked to the first set, each of the first and second sets including an encoding layer (UU(V2 ), wherein the encoding layers (UU¢2 ) of the first and second sets (El, E2) progressively encode at least a portion of input features of said network.

7. The quantum convolutional neural network (200A, 200B) of claim 6, wherein the encoding layer (U02) of the second set (E2) has a number of inputs less than the number of inputs of the encoding layer) of the first set (El).

8. The quantum convolutional neural network (200A, 200B) of claim 6 or 7, wherein each of the first and second sets further includes a quantum convolutional layer (CL^, CL^ linked to the encoding layer and a quantum pooling layer (PL^ PL^) linked to the quantum convolutional layer.

9. Quantum electronic device (20) configured to implement the classification method according to one of claims 1 to 5.

10. Computer program (PROG) comprising instructions for implementing a classification method according to any one of claims 1 to 5, when said program is executed by a processor.

11. A computer-readable recording medium having a computer program recorded thereon according to claim 9.