make densepose inference model traceable
Summary: make the densepose_inference function tracable.
@@ -27,7 +27,8 @@ def densepose_inference(densepose_predictor_output: Any, detections: List[Instan
if densepose_predictor_output is None:
# don't add `pred_densepose` attribute
continue
- n_i = len(detection_i)
+ n_i = detection_i.__len__()
+
PredictorOutput = type(densepose_predictor_output)
output_i_dict = {}
# we assume here that `densepose_predictor_output` is a dataclass object
