MCPcopy Create free account
hub / github.com/HobbitLong/PyContrast / __init__

Method __init__

pycontrast/datasets/util.py:18–19  ·  view source on GitHub ↗
(self, transform)

Source from the content-addressed store, hash-verified

16class StackTransform(object):
17 """transform a group of images independently"""
18 def __init__(self, transform):
19 self.transform = transform
20
21 def __call__(self, imgs):
22 return torch.stack([self.transform(crop) for crop in imgs])

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected