[Model] Update PPSeg Preprocess (#1007)

* 更新PPSeg pybind and python

* 更新PPSeg pybind and python
This commit is contained in:
Zheng-Bicheng
2022-12-29 21:14:39 +08:00
committed by GitHub
parent 9795a5287d
commit dd5759bd99
8 changed files with 51 additions and 29 deletions

View File

@@ -49,8 +49,10 @@ class FASTDEPLOY_DECL PaddleSegPreprocessor {
is_vertical_screen_ = value;
}
// This function will disable normalize and hwc2chw in preprocessing step.
void DisableNormalizeAndPermute();
/// This function will disable normalize in preprocessing step.
void DisableNormalize();
/// This function will disable hwc2chw in preprocessing step.
void DisablePermute();
private:
virtual bool BuildPreprocessPipelineFromConfig();
@@ -61,10 +63,12 @@ class FASTDEPLOY_DECL PaddleSegPreprocessor {
*/
bool is_vertical_screen_ = false;
// for recording the switch of normalize and hwc2chw
bool disable_normalize_and_permute_ = false;
// for recording the switch of hwc2chw
bool disable_permute_ = false;
// for recording the switch of normalize
bool disable_normalize_ = false;
bool is_contain_resize_op = false;
bool is_contain_resize_op_ = false;
bool initialized_ = false;
};