segan_pytorch icon indicating copy to clipboard operation
segan_pytorch copied to clipboard

run_segan+_clean.sh with cuda have error

Open qinxiaoyi opened this issue 5 years ago • 1 comments

When i run run_segan+_clean.sh and set cuda, but got the following error.

RuntimeError: Expected object of type torch.FloatTensor but found type torch.cuda.FloatTensor for argument #2 'weight'

qinxiaoyi avatar Jul 03 '19 13:07 qinxiaoyi

I had the same problem and i solved it. In script clean.py, replace line 72 by c_wav, g_c = self.segan.generate(pwav, device=device). Do not forget to define device: device = torch.device('cuda')

ukemamaster avatar Apr 13 '21 08:04 ukemamaster