diff --git a/csharp/src/Microsoft.ML.OnnxRuntime/Tensors/Tensor.cs b/csharp/src/Microsoft.ML.OnnxRuntime/Tensors/Tensor.cs index 21613a2fab5f6..9dc3c256ce886 100644 --- a/csharp/src/Microsoft.ML.OnnxRuntime/Tensors/Tensor.cs +++ b/csharp/src/Microsoft.ML.OnnxRuntime/Tensors/Tensor.cs @@ -922,6 +922,12 @@ public Tensor GetUpperTriangle(int offset) return GetTriangle(offset, upper: true); } + /// + /// Implementation method for GetTriangle, GetLowerTriangle, GetUpperTriangle + /// + /// Offset of diagonal to set in returned tensor. + /// true for upper triangular and false otherwise + /// public Tensor GetTriangle(int offset, bool upper) { if (Rank < 2) @@ -1158,8 +1164,16 @@ object IList.this[int index] } } + /// + /// Always fixed size Tensor + /// + /// always true public bool IsFixedSize => true; + /// + /// Tensor is not readonly + /// + /// always false public bool IsReadOnly => false; int IList.Add(object value) @@ -1566,6 +1580,11 @@ public virtual DenseTensor ToDenseTensor() #endregion + /// + /// Get a string representation of Tensor + /// + /// + /// public string GetArrayString(bool includeWhitespace = true) { var builder = new StringBuilder();