(self, x)
| 905 | padding=1) |
| 906 | |
| 907 | def forward(self, x): |
| 908 | # upsampling |
| 909 | h = x |
| 910 | for k, i_level in enumerate(range(self.num_resolutions)): |
| 911 | for i_block in range(self.num_res_blocks + 1): |
| 912 | h = self.res_blocks[i_level][i_block](h, None) |
| 913 | if i_level != self.num_resolutions - 1: |
| 914 | h = self.upsample_blocks[k](h) |
| 915 | h = self.norm_out(h) |
| 916 | h = nonlinearity(h) |
| 917 | h = self.conv_out(h) |
| 918 | return h |
| 919 | |
| 920 | |
| 921 | class LatentRescaler(nn.Module): |
nothing calls this directly
no test coverage detected