Closed Lacunainfo closed 9 months ago
the method 'mixup' you called, it seems like channel-shuffle.
Can you guide me what you exactly meant for?
def mixup(lq, gt, alpha=1.2): if random.random() < 0.5: return lq, gt v = np.random.beta(alpha, alpha) r_index = torch.randperm(lq.size(0)).to(gt.device) lq = v * lq + (1 - v) * lq[r_index, :] gt = v * gt + (1 - v) * gt[r_index, :] return lq, gt
The dimension of input is [B, C, H, W], so 'mixup' is performed in batch dimension.
the method 'mixup' you called, it seems like channel-shuffle.
Can you guide me what you exactly meant for?