Closed AndersGarpebring closed 4 years ago
We have not needed that namespace yet - indeed I will take a look as it may be of use in DiffSharp (the main library using this package at the moment)
(DiffSharp implements slicing and indexing but through its own code iteratively reducing to Torch's Squeeze and IndexSelect
https://github.com/DiffSharp/DiffSharp/blob/dev/src/DiffSharp.Backends.Torch/Torch.RawTensor.fs#L98)
cc @gbaydin
@AndersGarpebring You're welcome to contribute this support, it would be a great addition
@dsyme Thank you for the fast response. I've looked around a bit and it seems like the slicing functionality that I was looking for was introduced in libtorch around version 1.4. Torchsharp is using version 1.1. Are there any plans to update the version used?
@dsyme Thank you for the fast response. I've looked around a bit and it seems like the slicing functionality that I was looking for was introduced in libtorch around version 1.4. Torchsharp is using version 1.1. Are there any plans to update the version used?
@AndersGarpebring as far as I know TorchSharp is currently based on libtorch 1.5.0. You can see this in the readme https://github.com/xamarin/TorchSharp/blob/master/README.md and libtorch nuget packages https://www.nuget.org/packages/libtorch-cpu/
@gbaydin I downloaded the version from here and then it contains some code I interpreted as version 1.1. And indeed it is missing files that are available in 1.5.
The include path I found was: ...\GitHub\TorchSharp\bin\obj\AnyCPU.Debug\LibTorch.Redist\libtorch-win-shared-with-deps-1.1.0\libtorch\include
I found the issue with version 1.1. I had an old fork on my system that I had forgotten about. In the later version the indexing methods are available in libtorch.
OK, thanks, closing this issue
I'm looking for a tensor library that can do slicing and indexing. The c++ libtorch can do that very well but I see that it is not included in this package. Would it be possible to add? I tried to do it my self but for some reason the torch::indexing namespace is missing. Is it some old version of libtorch that is used in torchsharp so this namespace is missing?