| 326 | |
| 327 | |
| 328 | class UpSample1d(nn.Module): |
| 329 | def __init__(self, layer_type): |
| 330 | super().__init__() |
| 331 | self.layer_type = layer_type |
| 332 | |
| 333 | def forward(self, x): |
| 334 | if self.layer_type == 'none': |
| 335 | return x |
| 336 | else: |
| 337 | return F.interpolate(x, scale_factor=2, mode='nearest') |
| 338 | |
| 339 | |
| 340 | class AdainResBlk1d(nn.Module): |