Spaces:
Running
on
Zero
Running
on
Zero
Update cosyvoice/hifigan/f0_predictor.py
Browse files
cosyvoice/hifigan/f0_predictor.py
CHANGED
|
@@ -93,6 +93,7 @@ class CausalConvRNNF0Predictor(nn.Module):
|
|
| 93 |
self.classifier = nn.Linear(in_features=cond_channels, out_features=self.num_class)
|
| 94 |
|
| 95 |
def forward(self, x: torch.Tensor, finalize: bool = True) -> torch.Tensor:
|
|
|
|
| 96 |
if finalize is True:
|
| 97 |
print('x.device {} weight.device {}'.format(x.device, self.condnet[0].weight.device))
|
| 98 |
x = self.condnet[0](x)
|
|
|
|
| 93 |
self.classifier = nn.Linear(in_features=cond_channels, out_features=self.num_class)
|
| 94 |
|
| 95 |
def forward(self, x: torch.Tensor, finalize: bool = True) -> torch.Tensor:
|
| 96 |
+
self.cuda()
|
| 97 |
if finalize is True:
|
| 98 |
print('x.device {} weight.device {}'.format(x.device, self.condnet[0].weight.device))
|
| 99 |
x = self.condnet[0](x)
|