interesaaat / libtorchsharp Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
In the cmake file we depend on Python otherwise we don't compile. I think there should be a way to remove this dependency.
This project could be an interesting starting point, although it requires compiling pytorch for generating the input yaml file.
I have a problem in generating project files using CMake.
I used
When I run this command:
cmake -DTorch_DIR="C:\Users\gyeongin\libtorch" . -G "Visual Studio 15 2017 Win64"
it says
CMake Error at CMakeLists.txt:4 (find_package):
By not providing "FindTorch.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Torch", but
CMake did not find one.
Could not find a package configuration file provided by "Torch" with any of
the following names:
TorchConfig.cmake
torch-config.cmake
Add the installation prefix of "Torch" to CMAKE_PREFIX_PATH or set
"Torch_DIR" to a directory containing one of the above files. If "Torch"
provides a separate development package or SDK, be sure it has been
installed.
So I tried
cmake -DTorch_DIR="C:\Users\gyeongin\libtorch\share\cmake\Torch" . -G "Visual Studio 15 2017 Win64"
(C:\Users\gyeongin\libtorch\share\cmake\Torch
contains TorchConfig.cmake
file.)
it says
CMake Error at C:/Users/gyeongin/libtorch/share/cmake/Caffe2/public/cuda.cmake:380 (message):
Unknown cmake build type:
Call Stack (most recent call first):
C:/Users/gyeongin/libtorch/share/cmake/Caffe2/Caffe2Config.cmake:88 (include)
C:/Users/gyeongin/libtorch/share/cmake/Torch/TorchConfig.cmake:39 (find_package)
CMakeLists.txt:4 (find_package)
Have you experienced this issue before?
Hi @interesaaat
@gbaydin is looking at using libtorch as the tensor implementation in the next version of DiffSharp. As part of this he is looking at using LibTorchSharp to P/Invoke into.
The problem is, he works only on Linux and can't compile the C++ in this project because it requires Visual Studio intrin.h
and the WinSal.h
is missing in this repo
Is there any chance you could get this compiling with Linux+GCC so we could start contributing here?
Many thanks
Don
Remember to do the same on the c# side
It looks that the linux build is not working anymore with a error: #if with no expression #if _GLIBCXX_USE_CXX11_ABI
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.