(self, x)
| 792 | ) |
| 793 | |
| 794 | def forward(self, x): |
| 795 | # upsampling |
| 796 | h = x |
| 797 | for k, i_level in enumerate(range(self.num_resolutions)): |
| 798 | for i_block in range(self.num_res_blocks + 1): |
| 799 | h = self.res_blocks[i_level][i_block](h, None) |
| 800 | if i_level != self.num_resolutions - 1: |
| 801 | h = self.upsample_blocks[k](h) |
| 802 | h = self.norm_out(h) |
| 803 | h = nonlinearity(h) |
| 804 | h = self.conv_out(h) |
| 805 | return h |
| 806 | |
| 807 | |
| 808 | class LatentRescaler(nn.Module): |
nothing calls this directly
no test coverage detected