Advertisement
Guest User

Untitled

a guest
Apr 23rd, 2019
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.23 KB | None | 0 0
  1. my_model = AdamNet(EMBEDDING_DIM, HIDDEN_DIM, len(word_to_ix), len(tag_to_ix))
  2. loss_function = nn.NLLLoss()
  3. optimizer = optim.SGD(my_model.parameters(), lr=0.1)
  4. device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement