File tree Expand file tree Collapse file tree 2 files changed +25
-7
lines changed Expand file tree Collapse file tree 2 files changed +25
-7
lines changed Original file line number Diff line number Diff line change 44
55This repository provides tutorial code in C++ for deep learning researchers to learn PyTorch.
66
7- ## How to Build
7+ ## Getting Started
88- Install
99```
10- wget https://download.pytorch.org/libtorch/nightly/cpu/libtorch-shared-with-deps-latest.zip
11- unzip libtorch-shared-with-deps-latest.zip
10+ ./scripts.sh install
1211```
1312- Build
1413```
15- mkdir build
16- cd build
17- cmake -DCMAKE_PREFIX_PATH=/absolute/path/to/libtorch ..
18- make
14+ ./scripts.sh build
1915```
2016
2117## Table of Contents
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ function install() {
4+ wget https://download.pytorch.org/libtorch/nightly/cpu/libtorch-shared-with-deps-latest.zip
5+ unzip libtorch-shared-with-deps-latest.zip
6+ rm -rf libtorch-shared-with-deps-latest.zip
7+ }
8+
9+ function build() {
10+ rm -rf build
11+ mkdir build
12+ cd build
13+ cmake -DCMAKE_PREFIX_PATH=$( dirname $( pwd) ) /libtorch ..
14+ make
15+ }
16+
17+ if [ $1 = " install" ]
18+ then
19+ install
20+ else
21+ build
22+ fi
You can’t perform that action at this time.
0 commit comments