Function cos

  • Plot of cos and its gradient

    Calculates:

    output = cos(input)
    

    Gradient:

    inputGrad = -outputGrad * sin(input)
    

    Parameters

    • input: Tensor

      the input tensor of any shape

    Returns Tensor

    the output tensor

Generated using TypeDoc