MCPcopy Create free account
hub / github.com/VCIP-RGBD/DFormer / random_mirror

Function random_mirror

utils/transforms.py:136–144  ·  view source on GitHub ↗
(img, gt)

Source from the content-addressed store, hash-verified

134
135
136def random_mirror(img, gt):
137 if random.random() >= 0.5:
138 img = cv2.flip(img, 1)
139 gt = cv2.flip(gt, 1)
140
141 return (
142 img,
143 gt,
144 )
145
146
147def random_rotation(img, gt):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected