SciSharp / NumSharp

High Performance Computation for N-D Tensors in .NET, similar API to NumPy.
https://github.com/SciSharp
Apache License 2.0
1.37k stars 192 forks source link

Slice assign for generic NDArray<T> added #267

Closed katdti closed 5 years ago

katdti commented 5 years ago

Slice assign for generic NDArray added (very primitiv implementation, limited tested and does not support untyped NDArray) Slice(1, -1) support added (limited test added) Slice inteface added to generic NDArray. Slice benchmark tests added and debug of benchmark made easier

henon commented 5 years ago

@katdti have you checked the behavior with negative indices and assignment of a sliced array against NumPy?

katdti commented 5 years ago

Have just dobbelt checked with python and see same ressult as described in the two new unit tests using step=1, slice(1,-1) in 1D and 2D arrays.

Oceania2018 commented 5 years ago

Appreciate your contribution.