pytorch
b4a098f1 - [pytorch][nnc] mobile nnc backend skeleton (#56852)

Commit
4 years ago
[pytorch][nnc] mobile nnc backend skeleton (#56852) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/56852 This is part of the changes to enable NNC AOT compilation for mobile. It introduced a custom backend for NNC, which uses the components defined in the stacked PRs to load and execute a NNC-compiled model. ghstack-source-id: 128285801 Test Plan: - On X86 host: ``` buck build //xplat/caffe2/fb/lite_predictor:lite_predictor_nnc buck-out/last/lite_predictor_nnc --model xplat/pytorch_models/build/pytorch_dev_linear/v1/nnc/compiled.pt --print_output true --input_dims '4,4' --input_type float ``` - On Android: ``` buck build fbsource//fbandroid/mode/gnustl //xplat/caffe2/fb/lite_predictor:lite_predictor_nncAndroid#android-armv7 adb push buck-out/last/lite_predictor_nncAndroid#android-armv7 /data/local/tmp adb push xplat/pytorch_models/build/pytorch_dev_linear/v1/nnc/compiled.pt /data/local/tmp adb shell 'cd /data/local/tmp; ./lite_predictor_nncAndroid\#android-armv7 --model compiled.pt --print_output true --input_dims "4,4" --input_type float' ``` Reviewed By: kimishpatel, raziel Differential Revision: D27897153 fbshipit-source-id: 8e039089d1602782582747adfd75b31496b525ca
Author
Parents
Loading