Computing gradients in TF backend

Hello! I’ve been trying to play with the ‘tf’ backend of the strawberry fields. I tried to compute the gradients of a circuit but it is giving gradient=0 and I need help to understand why?

The question is why in this case the gradient is 0? Any insight or help is much appreciated thanks

Hi @Pranav_Chandarana,

I think the gradient is simply 0 for that circuit. If you add another gate such as Dgate(alpha ** 2) | q[0] you will notice that the gradient stops being 0.