mirror of
https://github.com/huggingface/lerobot.git
synced 2026-07-25 02:36:11 +00:00
debug image norm
This commit is contained in:
@@ -573,6 +573,7 @@ class LingBotVAPolicy(PreTrainedPolicy):
|
|||||||
if size is None:
|
if size is None:
|
||||||
size = (self.config.height, self.config.width)
|
size = (self.config.height, self.config.width)
|
||||||
img = F.interpolate(img, size=size, mode="bilinear", align_corners=False)
|
img = F.interpolate(img, size=size, mode="bilinear", align_corners=False)
|
||||||
|
print(f"[lingbot_va] {key} pre-scale range: [{img.min().item():.4f}, {img.max().item():.4f}] (expect ~[0,1])")
|
||||||
img = img * 2.0 - 1.0
|
img = img * 2.0 - 1.0
|
||||||
return img.unsqueeze(2).to(self.dtype) # [1, C, F=1, H, W]
|
return img.unsqueeze(2).to(self.dtype) # [1, C, F=1, H, W]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user