MCPcopy Create free account
hub / github.com/drinkingcoder/FlowFormer-Official / __init__

Method __init__

core/utils/flow_transforms.py:405–416  ·  view source on GitHub ↗
(self,  noise = 0.06, 
                        gamma = 0.02,
                        brightness = 0.02,
                        contrast = 0.02,
                        color = 0.02,
                        schedule_coeff=1)

Source from the content-addressed store, hash-verified

403 Chromatic augmentation: https://github.com/lmb-freiburg/flownet2/blob/master/src/caffe/layers/data_augmentation_layer.cu
404 """
405 def __init__(self, noise = 0.06,
406 gamma = 0.02,
407 brightness = 0.02,
408 contrast = 0.02,
409 color = 0.02,
410 schedule_coeff=1):
411
412 self.noise = np.random.uniform(0,noise)
413 self.gamma = np.exp(np.random.normal(0, gamma*schedule_coeff))
414 self.brightness = np.random.normal(0, brightness*schedule_coeff)
415 self.contrast = np.exp(np.random.normal(0, contrast*schedule_coeff))
416 self.color = np.exp(np.random.normal(0, color*schedule_coeff,3))
417
418 def __call__(self, inputs, target):
419 inputs[1] = self.chrom_aug(inputs[1])

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected