Lingkungan Pytorch Conda
conda install pytorch torchvision torchaudio cudatoolkit=11.0 -c pytorch
Yucky Yacare
conda install pytorch torchvision torchaudio cudatoolkit=11.0 -c pytorch
conda install pytorch torchvision torchaudio cudatoolkit=10.2 -c pytorch
>>> import torch.fft
>>> t = torch.arange(4)
>>> t
tensor([0, 1, 2, 3])
>>> torch.fft.fft(t)
tensor([ 6.+0.j, -2.+2.j, -2.+0.j, -2.-2.j])
>>> t = tensor([0.+1.j, 2.+3.j, 4.+5.j, 6.+7.j])
>>> torch.fft.fft(t)
tensor([12.+16.j, -8.+0.j, -4.-4.j, 0.-8.j])