torch.Tensor.Tensor.minimum
Tensor.minimum<O extends Shape>(other: Tensor<O>): Tensor<DynamicShape, D, Dev>Computes the element-wise minimum of this tensor and another tensor.
This operation supports broadcasting - if the tensors have different shapes, they will be broadcast to a compatible shape.
Parameters
otherTensor<O>- The tensor to compare against
Returns
Tensor<DynamicShape, D, Dev>– A tensor containing the element-wise minimum valuesExamples
const a = torch.tensor([1, 5, 3]);
const b = torch.tensor([2, 4, 6]);
const result = a.minimum(b);
// result: [1, 4, 3]