MCPcopy Create free account
hub / github.com/IceClear/StableSR / test

Method test

basicsr/models/sr_model.py:121–130  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

119 self.model_ema(decay=self.ema_decay)
120
121 def test(self):
122 if hasattr(self, 'net_g_ema'):
123 self.net_g_ema.eval()
124 with torch.no_grad():
125 self.output = self.net_g_ema(self.lq)
126 else:
127 self.net_g.eval()
128 with torch.no_grad():
129 self.output = self.net_g(self.lq)
130 self.net_g.train()
131
132 def test_selfensemble(self):
133 # TODO: to be tested

Callers 4

nondist_validationMethod · 0.95
main.pyFile · 0.45
dist_validationMethod · 0.45
nondist_validationMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected