[Feature Request]: Add clamp functionality to input.preprocess
#23,001 创建于 2024年2月21日
仓库指标
- Star
- (10,286 star)
- PR 合并指标
- (平均合并 14天 3小时) (30 天内合并 305 个 PR)
描述
Request Description
My team deploys Tensorflow and Pytorch models converted to OpenVINO's IR format to the edge which require preprocessing. Our data is often non-RGB, like thermal or depth data. Often for preprocessing the dataset before or during training we apply a clamping operation, like np.clip, to remove things like background noise in thermal data.
A lot of the models and frameworks we use we don't have access to the low-level layer code of the model so we end up converting the model to Openvino's IR format and deploying that model to our edge software along with metadata about the clip values (minimum_temperature and maximum_temperature) and we need to apply this preprocessing outside of the OpenVINO model Preprocessing Pipeline as there is no built-in clamp function in OpenVINO.
If clamping functionality was built in to OpenVINO's Preprocessing API it would allow some portability in implementation for our models as well. We usually train our models in Python but our edge software using the C++ OpenVINO API.
Another avenue (which may require a separate feature request?) could include an option during model conversion to add this clamping similar to how you can pass mean values into the convert model function.
Feature Use Case
No response
Issue submission checklist
- The feature request or improvement must be related to OpenVINO