Numpy.NET
Numpy.NET copied to clipboard
Trouble Translating Slicer syntax from Python
Hi,
I'm really new to using the library and I'm having trouble translating the slicer syntax in the below python source to Numpy.NET.
Please let me know if there is a more appropriate place to ask such questions.
b = np.hstack((a,a[:,(a.shape[1]-2)::-1]))
c = np.hstack((b,b[:,(b.shape[1]-2):0:-1]))
Thanks
I think you need to do it like this:
a[$":,{a.shape[1]-2}::-1"]
Let me know if that doesn't work and provide a simple example with python code for reproduction.