orktes / go-torch Goto Github PK
View Code? Open in Web Editor NEWLibTorch (PyTorch) bindings for Golang
License: Other
LibTorch (PyTorch) bindings for Golang
License: Other
I get these (and a large number of errors afterwards):
17:37 $ docker-compose up test
Creating scripts_test_1 ... done
Attaching to scripts_test_1
test_1 | # github.com/orktes/go-torch
test_1 | torch.cpp: In function 'c10::IValue Torch_ConvertTorchIValueToIValue(Torch_IValue)':
test_1 | torch.cpp:160:28: error: 'torch::jit::Tuple' has not been declared
test_1 | return torch::jit::Tuple::create(std::move(values));
test_1 | ^~~~~
test_1 | torch.cpp: In function 'void* Torch_LoadJITModule(char*, Torch_Error*)':
test_1 | torch.cpp:226:47: error: no match for 'operator=' (operand types are 'std::shared_ptr<torch::jit::script::Module>' and 'torch::jit::script::Module')
test_1 | mod->module = torch::jit::load(module_path);
When I use the go get github.com/orktes/go-torch
command to download the package
return
torch.cpp:3:10: fatal error: 'torch/torch.h' file not found
Hi,
I'm interested to try out this package but I find that build instructions are out of date. I tried to setup docker with recent version of libtorch library https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-1.8.1%2Bcpu.zip or https://download.pytorch.org/libtorch/cpu/libtorch-shared-with-deps-1.8.1%2Bcpu.zip but go get fails on multiple fronts. For example, the libtorch library has different structure of includes now, e.g. torch/torch.h is hidden within csrc area, etc. Even if I copy everything to /usr/local the go get complains about #error C++14 or later compatible compiler is required to use PyTorch (even though docker has recent g++). There are lots of errors from c10, etc.
I'll appreciate if proper set of instruction how to build torch.cpp (supplied in this package) will be provided in order to build go based code.
torch.cpp:3:10: fatal error: 'torch/torch.h' file not found
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.