Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions torchlm/data/_converters.py
Original file line number Diff line number Diff line change
Expand Up @@ -490,8 +490,8 @@ def _process_annotation(
# crop padded face
crop = image[int(ymin):int(ymax), int(xmin):int(xmax), :]
# adjust according to left-top corner
landmarks[:, 0] -= float(xmin)
landmarks[:, 1] -= float(ymin)
landmarks[:, 0] = landmarks[:, 0] - float(xmin)
landmarks[:, 1] = landmarks[:, 1] - float(ymin)

if self.target_size is not None and self.resize_op is not None:
crop, landmarks = self.resize_op(crop, landmarks)
Expand Down