MCPcopy Create free account
hub / github.com/PolyU-ChenLab/UniPixel / forward_batch

Method forward_batch

sam2/utils/transforms.py:39–42  ·  view source on GitHub ↗
(self, img_list)

Source from the content-addressed store, hash-verified

37 return self.transforms(x)
38
39 def forward_batch(self, img_list):
40 img_batch = [self.transforms(self.to_tensor(img)) for img in img_list]
41 img_batch = torch.stack(img_batch, dim=0)
42 return img_batch
43
44 def transform_coords(self, coords: torch.Tensor, normalize=False, orig_hw=None) -> torch.Tensor:
45 """

Callers 1

set_image_batchMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected