MCPcopy Create free account
hub / github.com/JunlinHan/DCLGAN / Upsample2

Class Upsample2

models/networks.py:63–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

61
62
63class Upsample2(nn.Module):
64 def __init__(self, scale_factor, mode='nearest'):
65 super().__init__()
66 self.factor = scale_factor
67 self.mode = mode
68
69 def forward(self, x):
70 return torch.nn.functional.interpolate(x, scale_factor=self.factor, mode=self.mode)
71
72
73class Upsample(nn.Module):

Callers 2

__init__Method · 0.85
__init__Method · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected