Libtorch android by t-vi · Pull Request #16242 · pytorch/pytorch

and others added 21 commits

October 26, 2018 16:27
- change toolchain defautl to clang
- discuss x86 building
- provide facility to turn off AVX
- add some commentary about libs and headers

Fixes: pytorch#13116

@t-vi

@t-vi

ezyang

@ljk53 ljk53 mentioned this pull request

Apr 25, 2019

ljk53 added a commit that referenced this pull request

Apr 25, 2019
Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 26, 2019
Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] fix THAllocator.cpp

Summary:
Update THRefcountedMapAllocator constructor/close() to fix build error
when _WIN32 and HAVE_MMAP are undefined - which case doesn't seem to be
covered by any CI.

Discovered by Thomas in #16242
Seems to be a good fix regardless of android build.

Test Plan:
Build with stacked diffs

gh-metadata: pytorch pytorch 19759 gh/ljk53/11/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] fix labs warning in THTensorMoreMath.cpp

Summary:
Seems pretty innocent change copied from #16242

Test Plan:
Make sure the following warning is gone:
../aten/src/TH/generic/THTensorMoreMath.cpp:1140:34: note: use function 'std::abs' instead
LAB_IMPLEMENT_BASIC_FUNCTION(abs,labs)
                                 ^~~~
                                 std::abs

gh-metadata: pytorch pytorch 19760 gh/ljk53/12/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
…Math.cpp"

[pytorch] fix labs warning in THTensorMoreMath.cpp

Summary:
Seems pretty innocent change copied from #16242

Test Plan:
Make sure the following warning is gone:
../aten/src/TH/generic/THTensorMoreMath.cpp:1140:34: note: use function 'std::abs' instead
LAB_IMPLEMENT_BASIC_FUNCTION(abs,labs)
                                 ^~~~
                                 std::abs

gh-metadata: pytorch pytorch 19760 gh/ljk53/12/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] fix labs warning in THTensorMoreMath.cpp

Summary:
Seems pretty innocent change copied from #16242

Test Plan:
Make sure the following warning is gone:
../aten/src/TH/generic/THTensorMoreMath.cpp:1140:34: note: use function 'std::abs' instead
LAB_IMPLEMENT_BASIC_FUNCTION(abs,labs)
                                 ^~~~
                                 std::abs

gh-metadata: pytorch pytorch 19760 gh/ljk53/12/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

Apr 30, 2019
Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 1, 2019
…Math.cpp"

[pytorch] fix labs warning in THTensorMoreMath.cpp

Summary:
Seems pretty innocent change copied from #16242

Test Plan:
Make sure the following warning is gone:
../aten/src/TH/generic/THTensorMoreMath.cpp:1140:34: note: use function 'std::abs' instead
LAB_IMPLEMENT_BASIC_FUNCTION(abs,labs)
                                 ^~~~
                                 std::abs

gh-metadata: pytorch pytorch 19760 gh/ljk53/12/head

ljk53 added a commit that referenced this pull request

May 1, 2019
[pytorch] fix labs warning in THTensorMoreMath.cpp

Summary:
Seems pretty innocent change copied from #16242

Test Plan:
Make sure the following warning is gone:
../aten/src/TH/generic/THTensorMoreMath.cpp:1140:34: note: use function 'std::abs' instead
LAB_IMPLEMENT_BASIC_FUNCTION(abs,labs)
                                 ^~~~
                                 std::abs

gh-metadata: pytorch pytorch 19760 gh/ljk53/12/head

ljk53 added a commit that referenced this pull request

May 1, 2019
…torch for Android"

[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 1, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 2, 2019
…torch for Android"

[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 2, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 2, 2019
…torch for Android"

[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 2, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 2, 2019
…torch for Android"

[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head

ljk53 added a commit that referenced this pull request

May 2, 2019
[pytorch] CMakeLists changes to enable libtorch for Android

Summary:
Stole from #16242
Only include CMakeLists changes to make it easer for reviewers.

Change pytorch android CI job to build libtorch instead of caffe2 -
turns out it's as simple as adding a few cmake macros. Will properly
update tools/build_pytorch_libs.py in subsequent diffs.

Test Plan:
- Make sure pytorch android CI job succeeds;
- Test libtorch.so on Android device;

gh-metadata: pytorch pytorch 19762 gh/ljk53/14/head