rystylee / ofxLibTorch

an openFrameworks wrapper for LibTorch
MIT License
14 stars 6 forks source link

How can I include the <torch/torch.h> to my OF src file without cmake ? #1

Open bemoregt opened 4 years ago

bemoregt commented 4 years ago

Hi, @rystylee

How can I include the <torch/torch.h> to my OF src file without cmake ?

I wonder.

Thanks. Best, @bemoregt.

felixdollack commented 4 years ago

Hi @bemoregt, I figured it out. You have to copy libTorch into ofxLibTorch/libs. And add the following 2 paths:

../../../addons/ofxLibTorch/libs/libtorch/include/torch/csrc/api/include ../../../addons/ofxLibTorch/libs/libtorch/include

rystylee commented 4 years ago

I added the setup details to the README.md. Please check it out.