I am trying to calculate the armijo step length for the steepest descent direction of 2 loss functions of the generator and the discriminator.

I am unable to calculate the armijo step length for the same. How to calculate the f(x+tv) where x is the current iteration and t is the learning rate and v is the direction of steepest descent respectively. I have the values of x and v but how to call the loss function? Considering the loss function I am using as nn.BCELoss(), how can I calculate the value of the function at some point in pytorch?