MCPcopy Create free account
hub / github.com/HobbitLong/SupContrast / TwoCropTransform

Class TwoCropTransform

util.py:9–15  ·  view source on GitHub ↗

Create two crops of the same image

Source from the content-addressed store, hash-verified

7
8
9class TwoCropTransform:
10 """Create two crops of the same image"""
11 def __init__(self, transform):
12 self.transform = transform
13
14 def __call__(self, x):
15 return [self.transform(x), self.transform(x)]
16
17
18class AverageMeter(object):

Callers 1

set_loaderFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected