Datawhale:动手深度学习第一次打卡!
继续一边学习一边敲代码:
循环神经网络基础
import torch
import torch.nn as nn
import time
import math
import sys
import d2lzh_pytorch as d2l
device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
#%%
(corpus_indices, char_to_idx, idx