Updated easypose scripts.
This commit is contained in:
@ -20,12 +20,12 @@ class RTMDet(BaseModel):
|
||||
self.scale = 0
|
||||
|
||||
def preprocess(self, image: np.ndarray):
|
||||
th, tw = self.input_shape[2:]
|
||||
th, tw = self.input_shape[1:3]
|
||||
image, self.dx, self.dy, self.scale = letterbox(
|
||||
image, (tw, th), fill_value=114
|
||||
)
|
||||
tensor = np.asarray(image).astype(self.input_type, copy=False)[..., ::-1]
|
||||
tensor = np.expand_dims(tensor, axis=0).transpose((0, 3, 1, 2))
|
||||
tensor = np.expand_dims(tensor, axis=0)
|
||||
return tensor
|
||||
|
||||
def postprocess(self, tensor: List[np.ndarray]):
|
||||
|
||||
Reference in New Issue
Block a user