@XiaXuehai (Xia Xuehai) posted a new topic, subject "How to use LibTorch?". It read:

   I installed the pytorch 1.0 by `conda install pytorch-nightly -c pytorch`, and test the code in LOADING A PYTORCH MODEL IN C++ from * Tutorials and got a ld error in this part:
    
    and in commend line using  
    `gcc test.cpp -I/.../anaconda3/lib/python3.6/site-packages/torch/lib/include -L/..../anaconda3/lib/python3.6/site-packages/torch/lib/ -ltorch`
    
    Which part I was wrong?

@ahkarami replied

    Dear @XiaXuehai,  
    Would you please kindly tell me how you have installed the `libtorch`? I mean that can you tell me the Cmake file?

@ZLeopard (Teddy) replied

    haha, i recognize you, i ask you some question some days ago, now also find the method to using pytorch1.0 by C++，Fist, How to build the libtorch? Do you succeed??@XiaXuehai

To which @ptrblck replied

    You can find the `CMakeLists.txt` file with other install instructions here.  
    CC @ZLeopard

To which @ZLeopard (Teddy) replied

    I have build the libtorch1.0 using the VS2017 Generator by CMake in the Windows10, it's OK now. emmm, Why this installing style not written in the tutorial?? I try a lot to figure it out…@ptrblck  
    @XiaXuehai 这是我总结windows版的编译方式 ：https://zhuanlan.zhihu.com/p/52806730

To which @ptrblck replied

    Good to hear it's working!  
    Would you expect to have a link to the install doc in part 3 of the tutorial or at which point did you miss the install requirements?


{'source': 'discourse', 'url': 'https://discuss.pytorch.org/t/how-to-use-libtorch/25472', 'title': 'How to use LibTorch?', 'views': 3254, 'has_accepted_answer': False, 'word_count': 250, 'like_count': 0, 'reply_count': 3, 'participant_count': 4, 'posts': 6, 'tags': '', 'author': '@XiaXuehai (Xia Xuehai)', 'participants': '@XiaXuehai (Xia Xuehai), @ahkarami, @ZLeopard (Teddy), @ptrblck', 'image_url': ['https://discuss.pytorch.org/uploads/default/original/2X/6/62fac02ada8de2b31c1bf4caeaeac8a381faf1e6.jpeg'], 'created_at': '2018-09-19T09:18:56.396Z', 'last_posted_at': '2018-12-20T10:03:53.420Z'}