tril

dragon.vm.torch.tril(
  input,
  diagonal=0,
  out=None
)[source]

Return the lower triangular part of input.

\[\text{out}_{ij} = \begin{cases} 0, & \text{ if } j > i + k \\ \text{input}_{ij}, & \text{ otherwise } \end{cases} \]

Examples:

x = torch.ones(3, 3)
print(torch.tril(x))
Parameters:
Returns:

dragon.vm.torch.Tensor – The output tensor.