37 instantiations of ReadOnlyTensorSpan
System.Numerics.Tensors (37)
System\Numerics\Tensors\netcore\ReadOnlyTensorDimensionSpan_1.cs (1)
55
return new
ReadOnlyTensorSpan
<T>(ref Unsafe.Add(ref _tensor._reference, linearOffset), _sliceShape);
System\Numerics\Tensors\netcore\ReadOnlyTensorSpan_1.cs (5)
316
public static implicit operator ReadOnlyTensorSpan<T>(T[]? array) => new
ReadOnlyTensorSpan
<T>(array);
326
return new
ReadOnlyTensorSpan
<T>(
389
return new
ReadOnlyTensorSpan
<T>(
399
return new
ReadOnlyTensorSpan
<T>(
409
return new
ReadOnlyTensorSpan
<T>(
System\Numerics\Tensors\netcore\Tensor.cs (16)
18
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[])" />
20
=> new
ReadOnlyTensorSpan
<T>(array);
22
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], ReadOnlySpan{nint})" />
24
=> new
ReadOnlyTensorSpan
<T>(array, lengths);
26
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
28
=> new
ReadOnlyTensorSpan
<T>(array, lengths, strides);
30
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], int, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
32
=> new
ReadOnlyTensorSpan
<T>(array, start, lengths, strides);
305
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[])" />
310
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], ReadOnlySpan{nint})" />
315
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
320
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], int, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
1623
ReadOnlyTensorSpan<T> output = new
ReadOnlyTensorSpan
<T>(ref tensor._reference, tensor._shape.LinearLength, newLengths, strides, tensor.IsPinned);
2065
ReadOnlyTensorSpan<T> output = new
ReadOnlyTensorSpan
<T>(ref tensor._reference, tensor._shape.LinearLength, lengths[..rank], strides[..rank], tensor.IsPinned);
2202
ReadOnlyTensorSpan<T> tmpTensor = new
ReadOnlyTensorSpan
<T>(ref Unsafe.Add(ref tensor._reference, i * tensor.Strides[0]), tmpShape);
2428
ReadOnlyTensorSpan<T> output = new
ReadOnlyTensorSpan
<T>(ref tensor._reference, tensor._shape.LinearLength, newLengths, newStrides, tensor.IsPinned);
System\Numerics\Tensors\netcore\Tensor_1.cs (1)
137
public ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan() => new
ReadOnlyTensorSpan
<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_values), _start), in _shape);
System\Numerics\Tensors\netcore\TensorSpan_1.cs (14)
35
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[])" />
47
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], ReadOnlySpan{nint})" />
52
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
64
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T[], int, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
76
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(ReadOnlySpan{T})" />
84
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(ReadOnlySpan{T}, ReadOnlySpan{nint})" />
88
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(ReadOnlySpan{T}, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
96
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(Array)"/>
108
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(Array, ReadOnlySpan{int}, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
120
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T*, nint)" />
128
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T*, nint, ReadOnlySpan{nint})" />
133
/// <inheritdoc cref="ReadOnlyTensorSpan{T}.
ReadOnlyTensorSpan
(T*, nint, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
215
new
ReadOnlyTensorSpan
<T>(ref tensor._reference, tensor._shape);
218
public ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan() => new
ReadOnlyTensorSpan
<T>(ref _reference, in _shape);
905 references to ReadOnlyTensorSpan
System.Numerics.Tensors (905)
System\Numerics\Tensors\netcore\IReadOnlyTensor_1.cs (4)
38
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan();
43
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<nint> startIndexes);
46
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NIndex> startIndexes);
51
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NRange> ranges);
System\Numerics\Tensors\netcore\ReadOnlyTensorDimensionSpan_1.cs (5)
17
private readonly
ReadOnlyTensorSpan
<T> _tensor;
22
internal ReadOnlyTensorDimensionSpan(
ReadOnlyTensorSpan
<T> tensor, int dimension)
45
public
ReadOnlyTensorSpan
<T> this[nint index]
65
: IEnumerator<
ReadOnlyTensorSpan
<T>>
78
public readonly
ReadOnlyTensorSpan
<T> Current => _span[_index];
System\Numerics\Tensors\netcore\ReadOnlyTensorSpan_1.cs (26)
26
: IReadOnlyTensor<
ReadOnlyTensorSpan
<T>, T>
30
public static
ReadOnlyTensorSpan
<T> Empty => default;
266
public
ReadOnlyTensorSpan
<T> this[params scoped ReadOnlySpan<NRange> ranges]
302
public static bool operator ==(in
ReadOnlyTensorSpan
<T> left, in
ReadOnlyTensorSpan
<T> right)
311
public static bool operator !=(in
ReadOnlyTensorSpan
<T> left, in
ReadOnlyTensorSpan
<T> right) => !(left == right);
316
public static implicit operator
ReadOnlyTensorSpan
<T>(T[]? array) => new ReadOnlyTensorSpan<T>(array);
323
public static
ReadOnlyTensorSpan
<T> CastUp<TDerived>(in
ReadOnlyTensorSpan
<TDerived> items)
386
public
ReadOnlyTensorSpan
<T> Slice(params scoped ReadOnlySpan<nint> startIndexes)
396
public
ReadOnlyTensorSpan
<T> Slice(params scoped ReadOnlySpan<NIndex> startIndexes)
406
public
ReadOnlyTensorSpan
<T> Slice(params scoped ReadOnlySpan<NRange> ranges)
454
ReadOnlyTensorSpan
<T> IReadOnlyTensor<
ReadOnlyTensorSpan
<T>, T>.AsReadOnlyTensorSpan() => this;
456
ReadOnlyTensorSpan
<T> IReadOnlyTensor<
ReadOnlyTensorSpan
<T>, T>.AsReadOnlyTensorSpan(params scoped ReadOnlySpan<nint> startIndexes) => Slice(startIndexes);
458
ReadOnlyTensorSpan
<T> IReadOnlyTensor<
ReadOnlyTensorSpan
<T>, T>.AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NIndex> startIndexes) => Slice(startIndexes);
460
ReadOnlyTensorSpan
<T> IReadOnlyTensor<
ReadOnlyTensorSpan
<T>, T>.AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NRange> ranges) => Slice(ranges);
462
ReadOnlyTensorSpan
<T> IReadOnlyTensor<
ReadOnlyTensorSpan
<T>, T>.ToDenseTensor()
464
ReadOnlyTensorSpan
<T> result = this;
480
private readonly
ReadOnlyTensorSpan
<T> _span;
485
internal Enumerator(
ReadOnlyTensorSpan
<T> span)
System\Numerics\Tensors\netcore\Tensor.cs (810)
18
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[])" />
19
public static
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan<T>(this T[]? array)
22
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], ReadOnlySpan{nint})" />
23
public static
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan<T>(this T[]? array, scoped ReadOnlySpan<nint> lengths)
26
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
27
public static
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan<T>(this T[]? array, scoped ReadOnlySpan<nint> lengths, scoped ReadOnlySpan<nint> strides)
30
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], int, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
31
public static
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan<T>(this T[]? array, int start, scoped ReadOnlySpan<nint> lengths, scoped ReadOnlySpan<nint> strides)
56
public static Tensor<T> Broadcast<T>(scoped in
ReadOnlyTensorSpan
<T> source, scoped in
ReadOnlyTensorSpan
<T> lengthsSource)
68
public static Tensor<T> Broadcast<T>(scoped in
ReadOnlyTensorSpan
<T> source, scoped ReadOnlySpan<nint> lengths)
105
public static void BroadcastTo<T>(in this
ReadOnlyTensorSpan
<T> source, in TensorSpan<T> destination)
305
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[])" />
310
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], ReadOnlySpan{nint})" />
315
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
320
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], int, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
472
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> for equality. If the shapes are not the same, the tensors are broadcasted to the smallest broadcastable size
475
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
476
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
478
public static Tensor<bool> Equals<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
487
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> for equality. If the shapes are not the same, the tensors are broadcasted to the smallest broadcastable size
490
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
491
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
494
public static ref readonly TensorSpan<bool> Equals<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
503
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> for equality. If the shapes are not the same, the tensors are broadcasted to the smallest broadcastable size
506
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
509
public static Tensor<bool> Equals<T>(in
ReadOnlyTensorSpan
<T> x, T y)
518
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> for equality. If the shapes are not the same, the tensors are broadcasted to the smallest broadcastable size
521
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
525
public static ref readonly TensorSpan<bool> Equals<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<bool> destination)
536
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are equal to <paramref name="y"/>.
540
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
541
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
543
public static bool EqualsAll<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
551
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are equal to <paramref name="y"/>.
555
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
556
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
558
public static bool EqualsAll<T>(in
ReadOnlyTensorSpan
<T> x, T y)
564
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are equal to <paramref name="y"/>.
568
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
569
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
571
public static bool EqualsAny<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
583
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are equal to <paramref name="y"/>.
587
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
590
public static bool EqualsAny<T>(in
ReadOnlyTensorSpan
<T> x, T y)
601
public static ref readonly TensorSpan<T> FilteredUpdate<T>(in this TensorSpan<T> tensor, scoped in
ReadOnlyTensorSpan
<bool> filter, T value)
615
public static ref readonly TensorSpan<T> FilteredUpdate<T>(in this TensorSpan<T> tensor, scoped in
ReadOnlyTensorSpan
<bool> filter, scoped in
ReadOnlyTensorSpan
<T> values)
625
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are greater than <paramref name="y"/>.
630
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
631
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
634
public static Tensor<bool> GreaterThan<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
643
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are greater than <paramref name="y"/>.
648
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
649
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
653
public static ref readonly TensorSpan<bool> GreaterThan<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
662
/// Compares the elements of a <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements are greater than <paramref name="y"/>.
666
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
670
public static Tensor<bool> GreaterThan<T>(in
ReadOnlyTensorSpan
<T> x, T y)
679
/// Compares the elements of a <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements are greater than <paramref name="y"/>.
683
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
688
public static ref readonly TensorSpan<bool> GreaterThan<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<bool> destination)
701
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
705
public static Tensor<bool> GreaterThan<T>(T x, in
ReadOnlyTensorSpan
<T> y)
713
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
718
public static ref readonly TensorSpan<bool> GreaterThan<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
724
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are greater than <paramref name="y"/>.
728
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
729
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
731
public static bool GreaterThanAll<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
739
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are greater than <paramref name="y"/>.
743
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
744
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
746
public static bool GreaterThanAll<T>(in
ReadOnlyTensorSpan
<T> x, T y)
750
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="y"/> are greater than <paramref name="y"/>.
754
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
755
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
757
public static bool GreaterThanAll<T>(T x, in
ReadOnlyTensorSpan
<T> y)
763
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are greater than <paramref name="y"/>.
767
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
768
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
770
public static bool GreaterThanAny<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
782
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are greater than <paramref name="y"/>.
786
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
789
public static bool GreaterThanAny<T>(in
ReadOnlyTensorSpan
<T> x, T y)
793
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="y"/> are greater than <paramref name="x"/>.
797
/// <param name="y">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
800
public static bool GreaterThanAny<T>(T x, in
ReadOnlyTensorSpan
<T> y)
806
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are greater than or equal to <paramref name="y"/>.
811
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
812
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
815
public static Tensor<bool> GreaterThanOrEqual<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
824
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are greater than or equal to <paramref name="y"/>.
829
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
830
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
834
public static ref readonly TensorSpan<bool> GreaterThanOrEqual<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
843
/// Compares the elements of a <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements are greater than or equal to <paramref name="y"/>.
847
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
851
public static Tensor<bool> GreaterThanOrEqual<T>(in
ReadOnlyTensorSpan
<T> x, T y)
860
/// Compares the elements of a <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements are greater than or equal to <paramref name="y"/>.
864
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
869
public static ref readonly TensorSpan<bool> GreaterThanOrEqual<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<bool> destination)
882
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
886
public static Tensor<bool> GreaterThanOrEqual<T>(T x, in
ReadOnlyTensorSpan
<T> y)
894
/// <param name="x"><see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
899
public static ref readonly TensorSpan<bool> GreaterThanOrEqual<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
905
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are greater than <paramref name="y"/>.
909
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
910
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
912
public static bool GreaterThanOrEqualAll<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
920
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are greater than <paramref name="y"/>.
924
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
925
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
927
public static bool GreaterThanOrEqualAll<T>(in
ReadOnlyTensorSpan
<T> x, T y)
931
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="y"/> are greater than <paramref name="y"/>.
935
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
936
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
938
public static bool GreaterThanOrEqualAll<T>(T x, in
ReadOnlyTensorSpan
<T> y)
944
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are greater than <paramref name="y"/>.
948
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
949
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
951
public static bool GreaterThanOrEqualAny<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
963
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are greater than <paramref name="y"/>.
967
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
970
public static bool GreaterThanOrEqualAny<T>(in
ReadOnlyTensorSpan
<T> x, T y)
974
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="y"/> are greater than <paramref name="x"/>.
978
/// <param name="y">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
981
public static bool GreaterThanOrEqualAny<T>(T x, in
ReadOnlyTensorSpan
<T> y)
987
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are less than <paramref name="y"/>.
992
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
993
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
996
public static Tensor<bool> LessThan<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
1005
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are less than <paramref name="y"/>.
1010
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1011
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1015
public static ref readonly TensorSpan<bool> LessThan<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
1032
public static Tensor<bool> LessThan<T>(in
ReadOnlyTensorSpan
<T> x, T y)
1050
public static ref readonly TensorSpan<bool> LessThan<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<bool> destination)
1067
public static Tensor<bool> LessThan<T>(T x, in
ReadOnlyTensorSpan
<T> y)
1080
public static ref readonly TensorSpan<bool> LessThan<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
1086
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are less than <paramref name="y"/>.
1090
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1091
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
1093
public static bool LessThanAll<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
1101
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are less than <paramref name="y"/>.
1105
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1108
public static bool LessThanAll<T>(in
ReadOnlyTensorSpan
<T> x, T y)
1112
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="y"/> are less than <paramref name="x"/>.
1119
public static bool LessThanAll<T>(T x, in
ReadOnlyTensorSpan
<T> y)
1125
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are less than <paramref name="y"/>.
1129
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1130
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
1132
public static bool LessThanAny<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
1144
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are less than <paramref name="y"/>.
1148
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1151
public static bool LessThanAny<T>(in
ReadOnlyTensorSpan
<T> x, T y)
1155
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="y"/> are less than <paramref name="y"/>.
1162
public static bool LessThanAny<T>(T x, in
ReadOnlyTensorSpan
<T> y)
1168
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are less than <paramref name="y"/>.
1173
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1174
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1177
public static Tensor<bool> LessThanOrEqual<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
1186
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see which elements of <paramref name="x"/> are less than <paramref name="y"/>.
1191
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1192
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1196
public static ref readonly TensorSpan<bool> LessThanOrEqual<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
1213
public static Tensor<bool> LessThanOrEqual<T>(in
ReadOnlyTensorSpan
<T> x, T y)
1231
public static ref readonly TensorSpan<bool> LessThanOrEqual<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<bool> destination)
1248
public static Tensor<bool> LessThanOrEqual<T>(T x, in
ReadOnlyTensorSpan
<T> y)
1261
public static ref readonly TensorSpan<bool> LessThanOrEqual<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<bool> destination)
1267
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are less than <paramref name="y"/>.
1271
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1272
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
1274
public static bool LessThanOrEqualAll<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
1282
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="x"/> are less than <paramref name="y"/>.
1286
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1289
public static bool LessThanOrEqualAll<T>(in
ReadOnlyTensorSpan
<T> x, T y)
1293
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if all elements of <paramref name="y"/> are less than <paramref name="x"/>.
1300
public static bool LessThanOrEqualAll<T>(T x, in
ReadOnlyTensorSpan
<T> y)
1306
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are less than <paramref name="y"/>.
1310
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1311
/// <param name="y">Second <see cref="
ReadOnlyTensorSpan
{T}"/> to compare against.</param>
1313
public static bool LessThanOrEqualAny<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
1325
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="x"/> are less than <paramref name="y"/>.
1329
/// <param name="x">First <see cref="
ReadOnlyTensorSpan
{T}"/> to compare.</param>
1332
public static bool LessThanOrEqualAny<T>(in
ReadOnlyTensorSpan
<T> x, T y)
1336
/// Compares the elements of two <see cref="
ReadOnlyTensorSpan
{T}"/> to see if any elements of <paramref name="y"/> are less than <paramref name="y"/>.
1343
public static bool LessThanOrEqualAny<T>(T x, in
ReadOnlyTensorSpan
<T> y)
1559
public static
ReadOnlyTensorSpan
<T> Reshape<T>(this scoped in
ReadOnlyTensorSpan
<T> tensor, scoped ReadOnlySpan<nint> lengths)
1623
ReadOnlyTensorSpan
<T> output = new ReadOnlyTensorSpan<T>(ref tensor._reference, tensor._shape.LinearLength, newLengths, strides, tensor.IsPinned);
1676
/// <param name="tensor">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
1678
public static void ResizeTo<T>(scoped in
ReadOnlyTensorSpan
<T> tensor, in TensorSpan<T> destination)
1694
public static Tensor<T> Reverse<T>(in
ReadOnlyTensorSpan
<T> tensor)
1708
public static Tensor<T> ReverseDimension<T>(in
ReadOnlyTensorSpan
<T> tensor, int dimension)
1721
public static ref readonly TensorSpan<T> Reverse<T>(scoped in
ReadOnlyTensorSpan
<T> tensor, in TensorSpan<T> destination)
1733
public static ref readonly TensorSpan<T> ReverseDimension<T>(scoped in
ReadOnlyTensorSpan
<T> tensor, in TensorSpan<T> destination, int dimension)
1772
public static bool SequenceEqual<T>(this scoped in TensorSpan<T> tensor, scoped in
ReadOnlyTensorSpan
<T> other)
1784
public static bool SequenceEqual<T>(this scoped in
ReadOnlyTensorSpan
<T> tensor, scoped in
ReadOnlyTensorSpan
<T> other)
1801
public static Tensor<T> SetSlice<T>(this Tensor<T> tensor, in
ReadOnlyTensorSpan
<T> values, params ReadOnlySpan<NRange> ranges)
1813
public static ref readonly TensorSpan<T> SetSlice<T>(this in TensorSpan<T> tensor, scoped in
ReadOnlyTensorSpan
<T> values, params scoped ReadOnlySpan<NRange> ranges)
1835
public static Tensor<T>[] Split<T>(scoped in
ReadOnlyTensorSpan
<T> tensor, int splitCount, nint dimension)
2009
/// <param name="tensor">The <see cref="
ReadOnlyTensorSpan
{T}"/> to remove all dimensions of length 1.</param>
2010
public static
ReadOnlyTensorSpan
<T> Squeeze<T>(this scoped in
ReadOnlyTensorSpan
<T> tensor)
2019
/// <param name="tensor">The <see cref="
ReadOnlyTensorSpan
{T}"/> to remove dimension of length 1.</param>
2021
public static
ReadOnlyTensorSpan
<T> SqueezeDimension<T>(this scoped in
ReadOnlyTensorSpan
<T> tensor, int dimension)
2065
ReadOnlyTensorSpan
<T> output = new ReadOnlyTensorSpan<T>(ref tensor._reference, tensor._shape.LinearLength, lengths[..rank], strides[..rank], tensor.IsPinned);
2165
/// Creates a <see cref="string"/> representation of the <see cref="
ReadOnlyTensorSpan
{T}"/>."/>
2168
/// <param name="tensor">The <see cref="
ReadOnlyTensorSpan
{T}"/> you want to represent as a string.</param>
2170
public static string ToString<T>(this in
ReadOnlyTensorSpan
<T> tensor, ReadOnlySpan<nint> maximumLengths)
2182
internal static void ToString<T>(in
ReadOnlyTensorSpan
<T> tensor, ReadOnlySpan<nint> maximumLengths, StringBuilder sb, int indentLevel = 0)
2202
ReadOnlyTensorSpan
<T> tmpTensor = new ReadOnlyTensorSpan<T>(ref Unsafe.Add(ref tensor._reference, i * tensor.Strides[0]), tmpShape);
2309
/// <param name="tensor">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2311
public static bool TryBroadcastTo<T>(in this
ReadOnlyTensorSpan
<T> tensor, in TensorSpan<T> destination)
2400
/// <param name="tensor">The <see cref="
ReadOnlyTensorSpan
{T}"/> to add a dimension of length 1.</param>
2402
public static
ReadOnlyTensorSpan
<T> Unsqueeze<T>(this scoped in
ReadOnlyTensorSpan
<T> tensor, int dimension)
2428
ReadOnlyTensorSpan
<T> output = new ReadOnlyTensorSpan<T>(ref tensor._reference, tensor._shape.LinearLength, newLengths, newStrides, tensor.IsPinned);
2440
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the abs of.</param>
2441
public static Tensor<T> Abs<T>(in
ReadOnlyTensorSpan
<T> x)
2450
/// Takes the absolute value of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2454
public static ref readonly TensorSpan<T> Abs<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2467
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2468
public static Tensor<T> Acos<T>(in
ReadOnlyTensorSpan
<T> x)
2481
public static ref readonly TensorSpan<T> Acos<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2492
/// Takes the inverse hyperbolic cosine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2494
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2495
public static Tensor<T> Acosh<T>(in
ReadOnlyTensorSpan
<T> x)
2508
public static ref readonly TensorSpan<T> Acosh<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2521
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2522
public static Tensor<T> AcosPi<T>(in
ReadOnlyTensorSpan
<T> x)
2533
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2535
public static ref readonly TensorSpan<T> AcosPi<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2548
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> of values to add.</param>
2549
/// <param name="y">The second <see cref="
ReadOnlyTensorSpan
{T}"/> of values to add.</param>
2550
public static Tensor<T> Add<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
2561
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> of values to add.</param>
2563
public static Tensor<T> Add<T>(in
ReadOnlyTensorSpan
<T> x, T y)
2572
/// Adds each element of <paramref name="x"/> to each element of <paramref name="y"/> and returns a new <see cref="
ReadOnlyTensorSpan
{T}"/> with the result.
2574
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> of values to add.</param>
2575
/// <param name="y">The second <see cref="
ReadOnlyTensorSpan
{T}"/> of values to add.</param>
2577
public static ref readonly TensorSpan<T> Add<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
2588
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> of values to add.</param>
2591
public static ref readonly TensorSpan<T> Add<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
2602
/// Takes the inverse sin of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2604
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2605
public static Tensor<T> Asin<T>(in
ReadOnlyTensorSpan
<T> x)
2614
/// Takes the inverse sin of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2616
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2618
public static ref readonly TensorSpan<T> Asin<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2629
/// Takes the inverse hyperbolic sine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2631
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2632
public static Tensor<T> Asinh<T>(in
ReadOnlyTensorSpan
<T> x)
2641
/// Takes the inverse hyperbolic sine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2643
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2645
public static ref readonly TensorSpan<T> Asinh<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2656
/// Takes the inverse hyperbolic sine divided by pi of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2658
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2659
public static Tensor<T> AsinPi<T>(in
ReadOnlyTensorSpan
<T> x)
2668
/// Takes the inverse hyperbolic sine divided by pi of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2670
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
2672
public static ref readonly TensorSpan<T> AsinPi<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2683
/// Takes the arc tangent of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2685
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
2686
public static Tensor<T> Atan<T>(in
ReadOnlyTensorSpan
<T> x)
2695
/// Takes the arc tangent of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2697
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
2699
public static ref readonly TensorSpan<T> Atan<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2710
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2712
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2713
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2714
public static Tensor<T> Atan2<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
2723
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2725
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2726
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2728
public static ref readonly TensorSpan<T> Atan2<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
2737
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2739
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2740
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2741
public static Tensor<T> Atan2<T>(in
ReadOnlyTensorSpan
<T> x, T y)
2750
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2752
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2753
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2755
public static ref readonly TensorSpan<T> Atan2<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
2764
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2766
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2767
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2768
public static Tensor<T> Atan2<T>(T x, in
ReadOnlyTensorSpan
<T> y)
2777
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2779
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2780
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2782
public static ref readonly TensorSpan<T> Atan2<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
2793
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/>, divides each element by pi, and returns a new <see cref="Tensor{T}"/> with the result.
2795
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2796
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2797
public static Tensor<T> Atan2Pi<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
2806
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/>, divides each element by pi, and returns a new <see cref="TensorSpan{T}"/> with the result.
2808
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2809
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2811
public static ref readonly TensorSpan<T> Atan2Pi<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
2820
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/>, divides each element by pi, and returns a new <see cref="TensorSpan{T}"/> with the result.
2822
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2823
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2824
public static Tensor<T> Atan2Pi<T>(in
ReadOnlyTensorSpan
<T> x, T y)
2833
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/>, divides each element by pi, and returns a new <see cref="TensorSpan{T}"/> with the result.
2835
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2836
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2838
public static ref readonly TensorSpan<T> Atan2Pi<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
2847
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/>, divides each element by pi, and returns a new <see cref="TensorSpan{T}"/> with the result.
2849
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2850
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2851
public static Tensor<T> Atan2Pi<T>(T x, in
ReadOnlyTensorSpan
<T> y)
2860
/// Takes the arc tangent of the two input <see cref="
ReadOnlyTensorSpan
{T}"/>, divides each element by pi, and returns a new <see cref="TensorSpan{T}"/> with the result.
2862
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2863
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2865
public static ref readonly TensorSpan<T> Atan2Pi<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
2876
/// Takes the inverse hyperbolic tangent of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2878
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2879
public static Tensor<T> Atanh<T>(in
ReadOnlyTensorSpan
<T> x)
2888
/// Takes the inverse hyperbolic tangent of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2890
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2892
public static ref readonly TensorSpan<T> Atanh<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2903
/// Takes the inverse hyperbolic tangent divided by pi of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2905
/// <param name="x">The input<see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2906
public static Tensor<T> AtanPi<T>(in
ReadOnlyTensorSpan
<T> x)
2915
/// Takes the inverse hyperbolic tangent divided by pi of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2917
/// <param name="x">The input<see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2919
public static ref readonly TensorSpan<T> AtanPi<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
2934
public static T Average<T>(scoped in
ReadOnlyTensorSpan
<T> x)
2947
/// Computes the element-wise bitwise and of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2949
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2950
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2951
public static Tensor<T> BitwiseAnd<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
2960
/// Computes the element-wise bitwise and of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2962
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2963
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2965
public static ref readonly TensorSpan<T> BitwiseAnd<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
2974
/// Computes the element-wise bitwise and of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
2976
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2978
public static Tensor<T> BitwiseAnd<T>(in
ReadOnlyTensorSpan
<T> x, T y)
2987
/// Computes the element-wise bitwise and of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
2989
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
2992
public static ref readonly TensorSpan<T> BitwiseAnd<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
3003
/// Computes the element-wise bitwise of of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3005
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3006
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3007
public static Tensor<T> BitwiseOr<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3016
/// Computes the element-wise bitwise of of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3018
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3019
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3021
public static ref readonly TensorSpan<T> BitwiseOr<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3030
/// Computes the element-wise bitwise or of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3032
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3034
public static Tensor<T> BitwiseOr<T>(in
ReadOnlyTensorSpan
<T> x, T y)
3043
/// Computes the element-wise bitwise or of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3045
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3048
public static ref readonly TensorSpan<T> BitwiseOr<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
3059
/// Computes the element-wise cube root of the input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3061
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3062
public static Tensor<T> Cbrt<T>(in
ReadOnlyTensorSpan
<T> x)
3071
/// Computes the element-wise cube root of the input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3073
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3075
public static ref readonly TensorSpan<T> Cbrt<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3086
/// Computes the element-wise ceiling of the input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3088
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3089
public static Tensor<T> Ceiling<T>(in
ReadOnlyTensorSpan
<T> x)
3098
/// Computes the element-wise ceiling of the input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3100
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3102
public static ref readonly TensorSpan<T> Ceiling<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3113
/// Copies <paramref name="source"/> to a new <see cref="
ReadOnlyTensorSpan
{TTO}"/> converting each <typeparamref name="TFrom"/>
3116
/// <param name="source">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3117
public static Tensor<TTo> ConvertChecked<TFrom, TTo>(in
ReadOnlyTensorSpan
<TFrom> source)
3132
public static ref readonly TensorSpan<TTo> ConvertChecked<TFrom, TTo>(scoped in
ReadOnlyTensorSpan
<TFrom> source, in TensorSpan<TTo> destination)
3144
/// Copies <paramref name="source"/> to a new <see cref="
ReadOnlyTensorSpan
{TTO}"/> converting each <typeparamref name="TFrom"/>
3147
/// <param name="source">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3148
public static Tensor<TTo> ConvertSaturating<TFrom, TTo>(in
ReadOnlyTensorSpan
<TFrom> source)
3163
public static ref readonly TensorSpan<TTo> ConvertSaturating<TFrom, TTo>(scoped in
ReadOnlyTensorSpan
<TFrom> source, in TensorSpan<TTo> destination)
3175
/// Copies <paramref name="source"/> to a new <see cref="
ReadOnlyTensorSpan
{TTO}"/> converting each <typeparamref name="TFrom"/>
3178
/// <param name="source">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3179
public static Tensor<TTo> ConvertTruncating<TFrom, TTo>(in
ReadOnlyTensorSpan
<TFrom> source)
3194
public static ref readonly TensorSpan<TTo> ConvertTruncating<TFrom, TTo>(scoped in
ReadOnlyTensorSpan
<TFrom> source, in TensorSpan<TTo> destination)
3208
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3210
public static Tensor<T> CopySign<T>(in
ReadOnlyTensorSpan
<T> x, T sign)
3221
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3222
/// <param name="sign">The <see cref="
ReadOnlyTensorSpan
{T}"/> with the associated signs.</param>
3223
public static Tensor<T> CopySign<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> sign)
3234
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3237
public static ref readonly TensorSpan<T> CopySign<T>(scoped in
ReadOnlyTensorSpan
<T> x, T sign, in TensorSpan<T> destination)
3248
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3249
/// <param name="sign">The <see cref="
ReadOnlyTensorSpan
{T}"/> with the associated signs.</param>
3251
public static ref readonly TensorSpan<T> CopySign<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> sign, in TensorSpan<T> destination)
3262
/// Takes the cosine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3264
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the cosine of.</param>
3265
public static Tensor<T> Cos<T>(in
ReadOnlyTensorSpan
<T> x)
3274
/// Takes the cosine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3276
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the cosine of.</param>
3278
public static ref readonly TensorSpan<T> Cos<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3289
/// Takes the hyperbolic cosine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3291
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the cosine of.</param>
3292
public static Tensor<T> Cosh<T>(in
ReadOnlyTensorSpan
<T> x)
3301
/// Takes the hyperbolic cosine of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3303
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the cosine of.</param>
3305
public static ref readonly TensorSpan<T> Cosh<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3318
/// <param name="x">The first <see cref="
ReadOnlyTensorSpan
{T}"/></param>
3319
/// <param name="y">The second <see cref="
ReadOnlyTensorSpan
{T}"/></param>
3320
public static T CosineSimilarity<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3332
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
3345
public static Tensor<T> CosPi<T>(in
ReadOnlyTensorSpan
<T> x)
3354
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
3368
public static ref readonly TensorSpan<T> CosPi<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3381
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3382
public static Tensor<T> DegreesToRadians<T>(in
ReadOnlyTensorSpan
<T> x)
3393
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3395
public static ref readonly TensorSpan<T> DegreesToRadians<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3408
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3409
/// <param name="y">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3410
public static T Distance<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y)
3424
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3426
public static Tensor<T> Divide<T>(in
ReadOnlyTensorSpan
<T> x, T y)
3438
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> divisor.</param>
3439
public static Tensor<T> Divide<T>(T x, in
ReadOnlyTensorSpan
<T> y)
3449
/// a new <see cref="
ReadOnlyTensorSpan
{T}"/> with the result.
3451
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to be divided.</param>
3452
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> divisor.</param>
3453
public static Tensor<T> Divide<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3464
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3467
public static ref readonly TensorSpan<T> Divide<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
3479
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> divisor.</param>
3481
public static ref readonly TensorSpan<T> Divide<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3493
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to be divided.</param>
3494
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> divisor.</param>
3496
public static ref readonly TensorSpan<T> Divide<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3509
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3510
/// <param name="y">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3511
public static T Dot<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3525
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3526
public static Tensor<T> Exp<T>(in
ReadOnlyTensorSpan
<T> x)
3537
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3539
public static ref readonly TensorSpan<T> Exp<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3552
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3553
public static Tensor<T> Exp10<T>(in
ReadOnlyTensorSpan
<T> x)
3564
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3566
public static ref readonly TensorSpan<T> Exp10<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3577
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3578
public static Tensor<T> Exp10M1<T>(in
ReadOnlyTensorSpan
<T> x)
3587
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3589
public static ref readonly TensorSpan<T> Exp10M1<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3600
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3601
public static Tensor<T> Exp2<T>(in
ReadOnlyTensorSpan
<T> x)
3610
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3612
public static ref readonly TensorSpan<T> Exp2<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3623
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3624
public static Tensor<T> Exp2M1<T>(in
ReadOnlyTensorSpan
<T> x)
3633
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3635
public static ref readonly TensorSpan<T> Exp2M1<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3646
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3647
public static Tensor<T> ExpM1<T>(in
ReadOnlyTensorSpan
<T> x)
3656
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3658
public static ref readonly TensorSpan<T> ExpM1<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3669
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3670
public static Tensor<T> Floor<T>(in
ReadOnlyTensorSpan
<T> x)
3679
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3681
public static ref readonly TensorSpan<T> Floor<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3695
/// <param name="x">Left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3696
/// <param name="y">Right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3697
public static Tensor<T> Hypot<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3709
/// <param name="x">Left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3710
/// <param name="y">Right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3712
public static ref readonly TensorSpan<T> Hypot<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3724
/// <param name="x">Left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3725
/// <param name="y">Right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3726
public static Tensor<T> Ieee754Remainder<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3736
/// <param name="x">Left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3737
/// <param name="y">Right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3739
public static ref readonly TensorSpan<T> Ieee754Remainder<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3748
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3749
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3750
public static Tensor<T> Ieee754Remainder<T>(in
ReadOnlyTensorSpan
<T> x, T y)
3759
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3760
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3762
public static ref readonly TensorSpan<T> Ieee754Remainder<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
3771
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3772
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3773
public static Tensor<T> Ieee754Remainder<T>(T x, in
ReadOnlyTensorSpan
<T> y)
3782
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3783
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3785
public static ref readonly TensorSpan<T> Ieee754Remainder<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3796
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3797
public static Tensor<int> ILogB<T>(in
ReadOnlyTensorSpan
<T> x)
3806
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3808
public static ref readonly TensorSpan<int> ILogB<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<int> destination)
3819
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3820
public static nint IndexOfMax<T>(scoped in
ReadOnlyTensorSpan
<T> x)
3831
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3832
public static nint IndexOfMaxMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x)
3842
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3843
public static nint IndexOfMin<T>(scoped in
ReadOnlyTensorSpan
<T> x)
3855
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3856
public static nint IndexOfMinMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x)
3868
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3869
public static Tensor<T> LeadingZeroCount<T>(in
ReadOnlyTensorSpan
<T> x)
3880
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
3882
public static ref readonly TensorSpan<T> LeadingZeroCount<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3893
/// Takes the natural logarithm of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3895
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the natural logarithm of.</param>
3896
public static Tensor<T> Log<T>(in
ReadOnlyTensorSpan
<T> x)
3905
/// Takes the natural logarithm of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3907
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the natural logarithm of.</param>
3909
public static ref readonly TensorSpan<T> Log<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3920
public static Tensor<T> Log<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
3932
public static ref readonly TensorSpan<T> Log<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
3943
public static Tensor<T> Log<T>(in
ReadOnlyTensorSpan
<T> x, T y)
3955
public static ref readonly TensorSpan<T> Log<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
3966
/// Takes the base 10 logarithm of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3968
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 10 logarithm of.</param>
3969
public static Tensor<T> Log10<T>(in
ReadOnlyTensorSpan
<T> x)
3978
/// Takes the base 10 logarithm of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
3980
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 10 logarithm of.</param>
3982
public static ref readonly TensorSpan<T> Log10<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
3993
/// Takes the base 10 logarithm plus 1 of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
3995
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 10 logarithm of.</param>
3996
public static Tensor<T> Log10P1<T>(in
ReadOnlyTensorSpan
<T> x)
4005
/// Takes the base 10 logarithm plus 1 of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
4007
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 10 logarithm of.</param>
4009
public static ref readonly TensorSpan<T> Log10P1<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4020
/// Takes the base 2 logarithm of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
4022
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 2 logarithm of.</param>
4023
public static Tensor<T> Log2<T>(in
ReadOnlyTensorSpan
<T> x)
4032
/// Takes the base 2 logarithm of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
4034
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 2 logarithm of.</param>
4036
public static ref readonly TensorSpan<T> Log2<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4047
/// Takes the base 2 logarithm plus 1 of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
4049
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 2 logarithm of.</param>
4050
public static Tensor<T> Log2P1<T>(in
ReadOnlyTensorSpan
<T> x)
4059
/// Takes the base 2 logarithm plus 1 of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
4061
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the base 2 logarithm of.</param>
4063
public static ref readonly TensorSpan<T> Log2P1<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4074
/// Takes the natural logarithm plus 1 of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
4076
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the natural logarithm of.</param>
4077
public static Tensor<T> LogP1<T>(in
ReadOnlyTensorSpan
<T> x)
4086
/// Takes the natural logarithm plus 1 of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
4088
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the natural logarithm of.</param>
4090
public static ref readonly TensorSpan<T> LogP1<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4101
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4102
public static T Max<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4118
public static Tensor<T> Max<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4130
public static ref readonly TensorSpan<T> Max<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4141
public static Tensor<T> Max<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4153
public static ref readonly TensorSpan<T> Max<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4164
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4165
public static T MaxMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4181
public static Tensor<T> MaxMagnitude<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4193
public static ref readonly TensorSpan<T> MaxMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4204
public static Tensor<T> MaxMagnitude<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4216
public static ref readonly TensorSpan<T> MaxMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4227
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4228
public static T MaxMagnitudeNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4244
public static Tensor<T> MaxMagnitudeNumber<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4256
public static ref readonly TensorSpan<T> MaxMagnitudeNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4267
public static Tensor<T> MaxMagnitudeNumber<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4279
public static ref readonly TensorSpan<T> MaxMagnitudeNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4290
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4291
public static T MaxNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4307
public static Tensor<T> MaxNumber<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4319
public static ref readonly TensorSpan<T> MaxNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4330
public static Tensor<T> MaxNumber<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4342
public static ref readonly TensorSpan<T> MaxNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4353
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4354
public static T Min<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4370
public static Tensor<T> Min<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4382
public static ref readonly TensorSpan<T> Min<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4393
public static Tensor<T> Min<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4405
public static ref readonly TensorSpan<T> Min<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4416
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4417
public static T MinMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4433
public static Tensor<T> MinMagnitude<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4445
public static ref readonly TensorSpan<T> MinMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4456
public static Tensor<T> MinMagnitude<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4468
public static ref readonly TensorSpan<T> MinMagnitude<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4479
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4480
public static T MinMagnitudeNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4496
public static Tensor<T> MinMagnitudeNumber<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4508
public static ref readonly TensorSpan<T> MinMagnitudeNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4519
public static Tensor<T> MinMagnitudeNumber<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4531
public static ref readonly TensorSpan<T> MinMagnitudeNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4542
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4543
public static T MinNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4559
public static Tensor<T> MinNumber<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4571
public static ref readonly TensorSpan<T> MinNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4582
public static Tensor<T> MinNumber<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4594
public static ref readonly TensorSpan<T> MinNumber<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4607
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4609
public static Tensor<T> Multiply<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4621
/// <param name="x">Left <see cref="
ReadOnlyTensorSpan
{T}"/> for multiplication.</param>
4622
/// <param name="y">Right <see cref="
ReadOnlyTensorSpan
{T}"/> for multiplication.</param>
4623
public static Tensor<T> Multiply<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4634
/// <param name="x">Input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4637
public static ref readonly TensorSpan<T> Multiply<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4649
/// <param name="x">Left <see cref="
ReadOnlyTensorSpan
{T}"/> for multiplication.</param>
4650
/// <param name="y">Right <see cref="
ReadOnlyTensorSpan
{T}"/> for multiplication.</param>
4652
public static ref readonly TensorSpan<T> Multiply<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4663
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4664
public static Tensor<T> Negate<T>(in
ReadOnlyTensorSpan
<T> x)
4673
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4675
public static ref readonly TensorSpan<T> Negate<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4686
/// Takes the norm of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns the result.
4688
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the norm of.</param>
4689
public static T Norm<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4700
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4701
public static Tensor<T> OnesComplement<T>(in
ReadOnlyTensorSpan
<T> x)
4710
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4712
public static ref readonly TensorSpan<T> OnesComplement<T>(scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4723
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4724
public static Tensor<T> PopCount<T>(in
ReadOnlyTensorSpan
<T> x)
4733
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4735
public static ref readonly TensorSpan<T> PopCount<T>(scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4746
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4747
/// <param name="y">The second input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4748
public static Tensor<T> Pow<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
4757
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4758
/// <param name="y">The second input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4760
public static ref readonly TensorSpan<T> Pow<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4769
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4771
public static Tensor<T> Pow<T>(in
ReadOnlyTensorSpan
<T> x, T y)
4780
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4781
/// <param name="y">The second input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4783
public static ref readonly TensorSpan<T> Pow<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
4792
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4794
public static Tensor<T> Pow<T>(T x, in
ReadOnlyTensorSpan
<T> y)
4803
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4804
/// <param name="y">The second input <see cref="
ReadOnlyTensorSpan
{T}"/></param>
4806
public static ref readonly TensorSpan<T> Pow<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
4817
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4818
public static T Product<T>(scoped in
ReadOnlyTensorSpan
<T> x)
4829
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4830
public static Tensor<T> RadiansToDegrees<T>(in
ReadOnlyTensorSpan
<T> x)
4839
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4841
public static ref readonly TensorSpan<T> RadiansToDegrees<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4852
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4853
public static Tensor<T> Reciprocal<T>(in
ReadOnlyTensorSpan
<T> x)
4862
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4864
public static ref readonly TensorSpan<T> Reciprocal<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4877
public static Tensor<T> RootN<T>(in
ReadOnlyTensorSpan
<T> x, int n)
4889
public static ref readonly TensorSpan<T> RootN<T>(scoped in
ReadOnlyTensorSpan
<T> x, int n, in TensorSpan<T> destination)
4903
public static Tensor<T> RotateLeft<T>(in
ReadOnlyTensorSpan
<T> x, int rotateAmount)
4916
public static ref readonly TensorSpan<T> RotateLeft<T>(scoped in
ReadOnlyTensorSpan
<T> x, int rotateAmount, in TensorSpan<T> destination)
4930
public static Tensor<T> RotateRight<T>(in
ReadOnlyTensorSpan
<T> x, int rotateAmount)
4943
public static ref readonly TensorSpan<T> RotateRight<T>(scoped in
ReadOnlyTensorSpan
<T> x, int rotateAmount, in TensorSpan<T> destination)
4954
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4955
public static Tensor<T> Round<T>(in
ReadOnlyTensorSpan
<T> x)
4964
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4966
public static ref readonly TensorSpan<T> Round<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
4975
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4978
public static Tensor<T> Round<T>(in
ReadOnlyTensorSpan
<T> x, int digits, MidpointRounding mode)
4987
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
4991
public static ref readonly TensorSpan<T> Round<T>(scoped in
ReadOnlyTensorSpan
<T> x, int digits, MidpointRounding mode, in TensorSpan<T> destination)
5000
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5002
public static Tensor<T> Round<T>(in
ReadOnlyTensorSpan
<T> x, int digits)
5011
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5014
public static ref readonly TensorSpan<T> Round<T>(scoped in
ReadOnlyTensorSpan
<T> x, int digits, in TensorSpan<T> destination)
5023
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5025
public static Tensor<T> Round<T>(in
ReadOnlyTensorSpan
<T> x, MidpointRounding mode)
5034
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5037
public static ref readonly TensorSpan<T> Round<T>(scoped in
ReadOnlyTensorSpan
<T> x, MidpointRounding mode, in TensorSpan<T> destination)
5048
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5049
public static Tensor<T> Sigmoid<T>(in
ReadOnlyTensorSpan
<T> x)
5058
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5060
public static ref readonly TensorSpan<T> Sigmoid<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5071
/// Takes the sin of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
5073
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5074
public static Tensor<T> Sin<T>(in
ReadOnlyTensorSpan
<T> x)
5083
/// Takes the sin of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
5085
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5087
public static ref readonly TensorSpan<T> Sin<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5098
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5099
public static Tensor<T> Sinh<T>(in
ReadOnlyTensorSpan
<T> x)
5108
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5110
public static ref readonly TensorSpan<T> Sinh<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5121
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5122
public static Tensor<T> SinPi<T>(in
ReadOnlyTensorSpan
<T> x)
5131
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5133
public static ref readonly TensorSpan<T> SinPi<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5144
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5145
public static Tensor<T> SoftMax<T>(in
ReadOnlyTensorSpan
<T> x)
5157
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5159
public static ref readonly TensorSpan<T> SoftMax<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5173
/// Takes the square root of each element of the <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
5175
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the square root of.</param>
5176
public static Tensor<T> Sqrt<T>(in
ReadOnlyTensorSpan
<T> x)
5187
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the square root of.</param>
5189
public static ref readonly TensorSpan<T> Sqrt<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5204
public static T StdDev<T>(in
ReadOnlyTensorSpan
<T> x)
5220
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5222
public static Tensor<T> Subtract<T>(in
ReadOnlyTensorSpan
<T> x, T y)
5234
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> of values to subtract.</param>
5235
public static Tensor<T> Subtract<T>(T x, in
ReadOnlyTensorSpan
<T> y)
5246
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> with values to be subtracted from.</param>
5247
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> with values to subtract.</param>
5248
public static Tensor<T> Subtract<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
5259
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> with values to be subtracted from.</param>
5262
public static ref readonly TensorSpan<T> Subtract<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
5274
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/> values to subtract.</param>
5276
public static ref readonly TensorSpan<T> Subtract<T>(T x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
5287
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> of values to be subtracted from.</param>
5288
/// <param name="y">The <see cref="
ReadOnlyTensorSpan
{T}"/>of values to subtract.</param>
5290
public static ref readonly TensorSpan<T> Subtract<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
5305
public static T Sum<T>(scoped in
ReadOnlyTensorSpan
<T> x)
5320
internal static T SumOfSquares<T>(scoped in
ReadOnlyTensorSpan
<T> x)
5331
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5332
public static Tensor<T> Tan<T>(in
ReadOnlyTensorSpan
<T> x)
5341
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5343
public static ref readonly TensorSpan<T> Tan<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5354
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5355
public static Tensor<T> Tanh<T>(in
ReadOnlyTensorSpan
<T> x)
5364
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5366
public static ref readonly TensorSpan<T> Tanh<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5377
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5378
public static Tensor<T> TanPi<T>(in
ReadOnlyTensorSpan
<T> x)
5387
/// <param name="x">The <see cref="
ReadOnlyTensorSpan
{T}"/> to take the sin of.</param>
5389
public static ref readonly TensorSpan<T> TanPi<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5400
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5401
public static Tensor<T> TrailingZeroCount<T>(in
ReadOnlyTensorSpan
<T> x)
5410
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5412
public static ref readonly TensorSpan<T> TrailingZeroCount<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5423
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5424
public static Tensor<T> Truncate<T>(in
ReadOnlyTensorSpan
<T> x)
5433
/// <param name="x">The input <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5435
public static ref readonly TensorSpan<T> Truncate<T>(scoped in
ReadOnlyTensorSpan
<T> x, in TensorSpan<T> destination)
5446
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5447
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5448
public static Tensor<T> Xor<T>(in
ReadOnlyTensorSpan
<T> x, in
ReadOnlyTensorSpan
<T> y)
5457
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5458
/// <param name="y">The right <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5460
public static ref readonly TensorSpan<T> Xor<T>(scoped in
ReadOnlyTensorSpan
<T> x, scoped in
ReadOnlyTensorSpan
<T> y, in TensorSpan<T> destination)
5469
/// Computes the element-wise Xor of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="Tensor{T}"/> with the result.
5471
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5473
public static Tensor<T> Xor<T>(in
ReadOnlyTensorSpan
<T> x, T y)
5482
/// Computes the element-wise Xor of the two input <see cref="
ReadOnlyTensorSpan
{T}"/> and returns a new <see cref="TensorSpan{T}"/> with the result.
5484
/// <param name="x">The left <see cref="
ReadOnlyTensorSpan
{T}"/>.</param>
5487
public static ref readonly TensorSpan<T> Xor<T>(scoped in
ReadOnlyTensorSpan
<T> x, T y, in TensorSpan<T> destination)
System\Numerics\Tensors\netcore\Tensor_1.cs (6)
133
/// <inheritdoc cref="TensorSpan{T}.implicit operator
ReadOnlyTensorSpan
{T}(in TensorSpan{T})" />
134
public static implicit operator
ReadOnlyTensorSpan
<T>(Tensor<T> tensor) => tensor.AsReadOnlyTensorSpan();
137
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan() => new ReadOnlyTensorSpan<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_values), _start), in _shape);
140
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<nint> startIndexes) => AsReadOnlyTensorSpan().Slice(startIndexes);
143
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NIndex> startIndexes) => AsReadOnlyTensorSpan().Slice(startIndexes);
146
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NRange> ranges) => AsReadOnlyTensorSpan().Slice(ranges);
System\Numerics\Tensors\netcore\TensorOperation.cs (27)
29
public static bool Invoke<TOperation, TArg>(in
ReadOnlyTensorSpan
<TArg> x, in
ReadOnlyTensorSpan
<TArg> y)
61
public static bool Invoke<TOperation, TArg>(in
ReadOnlyTensorSpan
<TArg> x, TArg y)
106
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in TensorSpan<TResult> destination)
127
public static void ReverseInvoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in TensorSpan<TResult> destination)
156
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in Span<TResult> destination)
176
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, ref TResult destination)
194
public static void Invoke<TOperation, TArg1, TArg2, TResult>(in
ReadOnlyTensorSpan
<TArg1> x, in
ReadOnlyTensorSpan
<TArg2> y, in TensorSpan<TResult> destination)
219
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in
ReadOnlyTensorSpan
<TArg> y, in TensorSpan<TResult> destination)
223
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in
ReadOnlyTensorSpan
<TArg> y, ref TResult result)
248
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, TArg y, in TensorSpan<TResult> destination)
252
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, int y, in TensorSpan<TResult> destination)
255
public static void Invoke<TOperation, TArg1, TArg2, TResult>(in
ReadOnlyTensorSpan
<TArg1> x, TArg2 y, in TensorSpan<TResult> destination)
277
public static void Invoke<TOperation, TArg, TResult>(TArg x, in
ReadOnlyTensorSpan
<TArg> y, in TensorSpan<TResult> destination)
299
public static void Invoke<TOperation, TArg1, TArg2, TResult>(in
ReadOnlyTensorSpan
<TArg1> x, TArg2 y, ref TResult result)
318
public static void Invoke<TOperation, TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, TArg y, ref TResult result)
321
public static void ValidateCompatibility<TArg>(in
ReadOnlyTensorSpan
<TArg> x, in ReadOnlySpan<nint> lengths)
328
public static void ValidateCompatibility<TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in
ReadOnlyTensorSpan
<TResult> y)
335
public static void ValidateCompatibility<TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in TensorSpan<TResult> destination)
342
public static void ValidateCompatibility<TArg1, TArg2, TResult>(in
ReadOnlyTensorSpan
<TArg1> x, in
ReadOnlyTensorSpan
<TArg2> y, in TensorSpan<TResult> destination)
359
public static void ValidateCompatibility<TArg, TResult>(in
ReadOnlyTensorSpan
<TArg> x, in
ReadOnlyTensorSpan
<TArg> y, out Tensor<TResult> destination)
System\Numerics\Tensors\netcore\TensorSpan_1.cs (26)
35
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[])" />
47
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], ReadOnlySpan{nint})" />
52
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
64
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T[], int, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
76
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(ReadOnlySpan{T})" />
84
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(ReadOnlySpan{T}, ReadOnlySpan{nint})" />
88
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(ReadOnlySpan{T}, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
96
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(Array)"/>
108
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(Array, ReadOnlySpan{int}, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
120
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T*, nint)" />
128
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T*, nint, ReadOnlySpan{nint})" />
133
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ReadOnlyTensorSpan(T*, nint, ReadOnlySpan{nint}, ReadOnlySpan{nint})" />
198
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.operator ==(in
ReadOnlyTensorSpan
{T}, in
ReadOnlyTensorSpan
{T})" />
203
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.operator !=(in
ReadOnlyTensorSpan
{T}, in
ReadOnlyTensorSpan
{T})" />
214
public static implicit operator
ReadOnlyTensorSpan
<T>(scoped in TensorSpan<T> tensor) =>
218
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan() => new ReadOnlyTensorSpan<T>(ref _reference, in _shape);
221
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<nint> startIndexes) => AsReadOnlyTensorSpan().Slice(startIndexes);
224
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NIndex> startIndexes) => AsReadOnlyTensorSpan().Slice(startIndexes);
227
public
ReadOnlyTensorSpan
<T> AsReadOnlyTensorSpan(params scoped ReadOnlySpan<NRange> ranges) => AsReadOnlyTensorSpan().Slice(ranges);
241
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.Equals(object?)" />
265
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.GetHashCode" />
311
/// <inheritdoc cref="
ReadOnlyTensorSpan
{T}.ToString" />
System\Numerics\Tensors\netcore\TensorSpanDebugView.cs (1)
19
public TensorSpanDebugView(
ReadOnlyTensorSpan
<T> span)