Handle non normalized float

This commit is contained in:
Nicolas Mowen 2025-04-17 17:09:40 -06:00
parent c458214650
commit cc807f49a0

View File

@ -77,6 +77,8 @@ class LocalObjectDetector(ObjectDetector):
if self.dtype == InputDTypeEnum.float:
tensor_input = tensor_input.astype(np.float32)
tensor_input /= 255
elif self.dtype == InputDTypeEnum.float_denorm:
tensor_input = tensor_input.astype(np.float32)
return self.detect_api.detect_raw(tensor_input=tensor_input)