Skip to content

Commit f01424b

Browse files
committed
• utilities.py
- expose many of the functions in html docs - need docstrings
1 parent 2c4cbf9 commit f01424b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/composition/test_grucomposition.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ def test_pytorch_learning_identicality(self, bias):
5353
torch_result_before_learning, hn = torch_gru(torch.tensor(np.array(inputs).astype(np.float32)),h0)
5454
# print("\nTORCH before learning: ",
5555
# [float(f"{value:.4f}") for value in torch_result_before_learning.flatten()])
56-
torch_result_before_learning.backward(torch.tensor([[1,1,1,1,1]], dtype=torch.float32),retain_graph=True)
56+
loss = torch_result_before_learning.backward(torch.tensor([[1,1,1,1,1]], dtype=torch.float32),
57+
retain_graph=True)
5758
torch_result_after_learning, hn = torch_gru(torch.tensor(np.array(inputs).astype(np.float32)),hn)
5859
# torch_result_after_learning.backward(torch.tensor([[1,1,1,1,1]], dtype=torch.float32))
5960
# print("TORCH after learning: ",

0 commit comments

Comments
 (0)