ARTIFICIAL NEURAL NETWORKS AND THEIR APPLICATIONS TO QUANTUM COMPUTING SEMINAR COURSE IDC601 COURSE INSTRUCTOR: PROF. KAVITA DORAI PRESENTED BY: MATREYEE KANDPAL (PH23022) OUTLINE: • INTRODUCTION • BIOLOGICAL NEURAL NETWORKS • ARTIFICIAL NEURAL NETWORKS HISTORY MODEL OF AN ANN MODEL OF SINGLE NEURON ACTIVATION FUNCTIONS • NEURAL NETWORKS ARCHITECTURE TYPES • LEARNING IN NEURAL NETS • FEEDFORWARDED NEURAL NETWORKS TRAINING FFNN’s BACK PROPAGATION ALGORITHM • • • • FUNDAMENTALS OF QUANTUM COMPUTING APPLICATIONS OF ANN’s TO QC EXAMPLE: QUANTUM STATE TOMOGRAPHY USING NEURAL NETS ADVANTAGES OF COMBINING QC AND ANN’s INTRODUCTION: • Computational models called Artificial Neural Networks (ANNs) are a key element in machine learning's branch known as deep learning and they are modelled after the neurons in the human brain. • Artificial Neural Network (ANN) or Neural Network(NN) has provide an exciting alternative method for solving a variety of problems in different fields of science and engineering. BIOLOGICAL NEURAL NETWORKS: Four parts of a typical nerve cell : • DENDRITES : Accepts the inputs • SOMA: Process the inputs • AXON : Turns the processed inputs into outputs. • SYNAPSES : The electrochemical contact between the neurons. ARTIFICIAL NEURAL NETWORKS: HISTORY: • Human brain has many incredible characteristics such as massive parallelism, computation, learning ability, generalization ability, adaptivity, which seems simple but is really complicated. • ANN models was an effort to apply the same method as human brain uses to solve perceptual problems. • Three periods of development for ANN:- • 1940: Mcculloch and Pitts: Initial works • 1960: Rosenblatt: perceptron convergence theorem. Minsky and Papert : work showing the limitations of a simple perceptron • 1980: Hopfield/Werbos and Rumelhart : Hopfield's energy approach/back-propagation learning algorithm. MODEL OF AN ARTIFICIAL NEURAL NETWORK: (dendrite) X1 X2 X3 Input units (synapse) (axon) (soma) Wa Wb f() Wc Connection weights Summing function computation Y MODEL OF A SINGLE NEURON (PERCEPTRON): • McCulloch and Pitts (1943) proposed the 'integrate and fire' model: Output is given by: φ 𝑛 𝑖=1 𝑤𝑘𝑖 𝑥𝑖 +𝑏𝑘 where, 𝜑 =activation function 𝑤𝑘𝑖 = weights 𝑥𝑖 = inputs 𝑏𝑘 = bias ACTIVATION FUNCTIONS: The activation function decides whether a neuron should be activated or not by calculating the weighted sum and further adding bias to it. • Identity f(x) = x • Binary step f(x) = 1 if x >= q f(x) = 0 otherwise • Binary sigmoid f(x) = 1 / (1 + e-s𝑥) • Bipolar sigmoid f(x) = -1 + 2 / (1 + e-s𝑥) • Hyperbolic tangent f(x) = (ex – e-x) / (ex + e-x) • RELU (Rectified linear unit) f(x) = max(0,x) • Leaky RELU f (x) = max (ax, x), where a is a small constant. NEURAL NETWORK ARCHITECTURE TYPES: Simple perceptron Feedforward NN Deep Feedforward NN Recurrent NN LSTM NN LEARNING IN NEURAL NETWORKS: • Training: It is the process in which the network is taught to change its weight and bias. • Learning: It is the internal process of training where the artificial neural system learns to update/adapt the weights and biases. Supervised Learning: • Learning is performed by presenting pattern with target. • During learning, produced output is compared with the desired output. • The difference between both output is used to modify learning weights according to the learning algorithm. • Recognizing hand-written digits, pattern recognition and etc. • Neural Network models: perceptron, feed-forward, radial basis function, support vector machine. Unsupervised Learning: • Targets are not provided • Appropriate for clustering task. • Find similar groups of documents in the web, content addressable memory, clustering. • Neural Network models: Kohonen, self organizing maps, Hopfield networks. Reinforcement Learning: • Target is provided, but the desired output is absent. • The net is only provided with guidance to determine the produced output is correct or vise versa. • Weights are modified in the units that have errors FEEDFORWARDED NEURAL NETWORKS: • Networks without cycles (feedback loops) are called a feed-forward networks (or perceptron). Their architecture has following layers: • Input layer: Number of neurons in this layer corresponds to the number of inputs to the neuronal network. This layer consists of passive nodes, i.e., which do not take part in the actual signal modification, but only transmits the signal to the following layer. • Hidden layer: This layer has arbitrary number of layers with arbitrary number of neurons. The nodes in this layer take part in the signal modification, hence, they are active. • Output layer: The number of neurons in the output layer corresponds to the number of the output values of the neural network. The nodes in this layer are active ones. Fig: illustration of feedforwarded NN’s TRAINING FEEDFORWARDED NN’s: • Algorithms for training neural networks can be supervised (i.e. with a ‘teacher’) and unsupervised (self-organizing). • Supervised algorithms use a training set — a set of pairs (x, y) of inputs with their corresponding desired outputs. • The process of finding a set of weights such that for a given input the network produces the desired output is called training. • An outline of a supervised learning algorithm: 1. Initially, set all the weights wij to some random values. 2. Repeat (a) Feed the network with an input x from one of the examples in the training set. (b) Compute the network’s output f(x). (c) Change the weights wij of the nodes. 3. Until the error c(y, f(x)) is small. BACK PROPAGATION ALGORITHM: • In a back-propagation neural network, the learning algorithm has two phases. • First, a training input pattern is presented to the network input layer. The network propagates the input pattern from layer to layer until the output pattern is generated by the output layer. • If this pattern is different from the desired output, an error is calculated and then propagated backwards through the network from the output layer to the input layer. The weights are modified as the error is propagated. THREE-LAYER FEED-FORWARD NEURAL NETWORK: ( trained using back-propagation algorithm) Step 1: Initialisation Set all the weights and threshold levels of the network to random numbers uniformly distributed inside a small range. The weight initialisation is done on a neuron-by-neuron basis. Step 2: Activation Activate the back-propagation neural network by applying inputs x1(p), x2(p),…, xn(p) and desired outputs yd,1(p), yd,2(p),…, yd,n(p). (a) Calculate the actual outputs of the neurons in the hidden layer: n y j ( p) sigmoid xi ( p) wij ( p) j i 1 where n is the number of inputs of neuron j in the hidden layer, and sigmoid is the sigmoid activation function. (b) Calculate the actual outputs of the neurons in the output layer: m yk ( p ) sigmoid x jk ( p ) w jk ( p ) k j 1 where m is the number of inputs of neuron k in the output layer Step 3: Weight training Update the weights in the back-propagation network propagating backward the errors associated with output neurons. (a) Calculate the error gradient for the neurons in the output layer: k ( p) yk ( p) 1 yk ( p) ek ( p) where ek ( p) yd ,k ( p) yk ( p) Calculate the weight corrections: w jk ( p) y j ( p) k ( p) Update the weights at the output neurons: w jk ( p 1) w jk ( p) w jk ( p) (b) Calculate the error gradient for the neurons in the hidden layer: l j ( p ) y j ( p ) [1 y j ( p )] k ( p ) w jk ( p ) k 1 Calculate the weight corrections: wij ( p) xi ( p) j ( p) Update the weights at the hidden neurons: wij ( p 1) wij ( p) wij ( p) Step 4: Iteration Increase iteration p by one, go back to Step 2 and repeat the process until the selected error criterion is satisfied. FUNDAMENTALS OF QUANTUM COMPUTING: Common digital computing requires data to be encoded into binary digits (bits), each of which is always in one of two definite states (0 or 1), quantum computation uses quantum bits or QUBITS, which can be in superposition of states. APPLICATIONS OF ANN’s TO QUANTUM COMPUTING: Much recent research has focused on training artificial neural networks to perform several quantum computing and quantum information processing tasks, which include: • Quantum state and process Tomography • Entanglement characterization • Quantum gate optimization • Decoherence mitigation • Investigate quantum contextuality QUANTUM STATE TOMOGRAPHY USING ANN’s: Fig: Flowchart illustrating the FFNN model used to perform QST on two-qubit quantum states generated on an NMR quantum; on the left, 𝝆𝒊𝒏 represents the state which is to be tomographed; IY denotes a tomographic operation, which is followed by signal detection, the set of depicted NMR spectra are those obtained after the tomographic measurement. The FFNN with two hidden layers is represented next, which then uses a reduced data set to reconstruct the final experimental tomographs represented on the right. • A multilayer FFNN architecture can be employed to perform QST. • QST generally refers to the reconstruction of a quantum state and a quantum state is described by a density matrix. An n-qubit density operator ρ can be expressed as a matrix in the product basis by: • The aim of QST is to reconstruct ρ from a set of tomographic measurements. • The FFNN model is trained on a dataset containing randomly generated pure and mixed states. • To perform QST the LeakyReLU (α = 0.5) activation function was used for both the input and the hidden layers of the FFNN: LeakyReLU(x) =x ; x > 0 =αx ; x < 0 • A linear activation function was used for the output layer. • Training of this network can be achieved by minimizing a mean-squared-error cost function, with respect to the network parameters. • The results demonstrated that FFNN architectures are promising methods for performing QST. APPLICATIONS OF COMBINING ANN’s WITH QUANTUM COMPUTING: Combining quantum computing and artificial neural networks holds the potential for several advantages, although it's important to note that practical implementation and realization of these benefits are still areas of active research. Some potential advantages include: Improved Learning Algorithms Quantum Entanglement Parallelism and Superposition Exponential speedup of certain problems REFERENCES: • A. Gaikwad, O. Bihani, Arvind, and K. Dorai, "Neural network assisted quantum state and process tomography using limited data sets," (2023), arXiv: 2304.04167. • Laurene Fausett, “Fundamentals of Neural Networks, Architectures, Algorithms and Applications”, Prentice Hall publications. • Anderson, J. A., 1995, Introduction to Neural Networks (Cambridge, MA:MIT Press). • ResearchGate. • Haykin, S., 1999, Neural Networks: A Comprehensive Foundation, 2nd ed.(Englewood Cliffs, NJ: Prentice-Hall).