-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Closed
Labels
staleNo activity in 60 days on issue or PRNo activity in 60 days on issue or PR
Description
why obtained_tensor equal with expected_tensor. If the value of memory is random, I don't think it will always be equal.
Megatron-LM/tests/unit_tests/test_utils.py
Lines 13 to 17 in 2bc6cd3
| def test_global_memory_buffer(): | |
| global_memory_buffer = util.GlobalMemoryBuffer() | |
| obtained_tensor = global_memory_buffer.get_tensor((3,2), torch.float32, "test_tensor") | |
| expected_tensor = torch.empty((3,2), dtype=torch.float32, device=torch.cuda.current_device()) | |
| assert torch.equal(obtained_tensor, expected_tensor) |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
staleNo activity in 60 days on issue or PRNo activity in 60 days on issue or PR