Add paddlelite backend support (#260)

* Add paddlelite backend support

* Update CMakeLists.txt

* Update __init__.py
This commit is contained in:
Jason
2022-09-21 13:22:34 +08:00
committed by GitHub
parent 32596b3b89
commit addce837bc
22 changed files with 370 additions and 56 deletions

View File

@@ -21,7 +21,7 @@
namespace fastdeploy {
enum FASTDEPLOY_DECL Backend { UNKNOWN, ORT, TRT, PDINFER, OPENVINO };
enum FASTDEPLOY_DECL Backend { UNKNOWN, ORT, TRT, PDINFER, OPENVINO, LITE };
// AUTOREC will according to the name of model file
// to decide which Frontend is
enum FASTDEPLOY_DECL Frontend { AUTOREC, PADDLE, ONNX };
@@ -66,6 +66,9 @@ struct FASTDEPLOY_DECL RuntimeOption {
// use openvino backend
void UseOpenVINOBackend();
// use paddle lite backend
void UseLiteBackend();
// enable mkldnn while use paddle inference in CPU
void EnablePaddleMKLDNN();
// disable mkldnn while use paddle inference in CPU
@@ -161,6 +164,8 @@ struct FASTDEPLOY_DECL Runtime {
void CreateOpenVINOBackend();
void CreateLiteBackend();
int NumInputs() { return backend_->NumInputs(); }
int NumOutputs() { return backend_->NumOutputs(); }
TensorInfo GetInputInfo(int index);