mramazan's picture
Upload 41 files
0edbb0d verified
raw
history blame
176 Bytes
import torch.nn as nn
class TokenEmbedding(nn.Embedding):
def __init__(self, vocab_size, embed_size=512):
super().__init__(vocab_size, embed_size, padding_idx=0)