Backpropagating through a circuit #726
-
Hi, I was wondering whether it were possible to backpropagate through a circuit, @MatteoRobbiati, maybe you could help me figure this out. |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 3 replies
-
Just a quick remark, probably unrelated, if you use the tensorflow backend you should be able to get the analytic expression for all derivatives. Obviously the PSR would be better, because you can run on hardware. |
Beta Was this translation helpful? Give feedback.
-
I was thinking about the same thing @scarrazza says. Tensorflow's I must have a look deeply in literature searching for some hardware-compatible hyper-optimization techinques (of course you can try with Genetic Algos, but I am not sure it will be worth). Do you want to have a meeting for discussing this? |
Beta Was this translation helpful? Give feedback.
I was thinking about the same thing @scarrazza says.
Your problem seems to be an hyper-optimization one. In this case you are not directly derivating with respect to the gates' parameters, but you are searching for an instrument which allows you to calculate the derivative of the circuit's output with respect, e.g. the number of layers , right?
Tensorflow's
GradientTape
module is able to track all the state vector's modification under your assumptions (you must define all your elements inside the Gradient Tape).I must have a look deeply in literature searching for some hardware-compatible hyper-optimization techinques (of course you can try with Genetic Algos, but I am not sure it will b…