Skip to content

Commit 9a08d6d

Browse files
committed
added a manual seed since we may be randomly initializing models
Signed-off-by: Joshua Rosenkranz <[email protected]>
1 parent 3e0e1f6 commit 9a08d6d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tests/models/test_decoders.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,7 @@ def __load_validation_info(model_path, batch_size, seq_length, max_new_tokens, t
127127

128128
@pytest.mark.parametrize("model_path,batch_size,seq_length,max_new_tokens", common_shapes)
129129
def test_common_shapes(model_path, batch_size, seq_length, max_new_tokens):
130+
torch.manual_seed(42)
130131
os.environ["COMPILATION_MODE"] = "offline_decoder"
131132

132133
if "HF_HOME" not in os.environ:

0 commit comments

Comments
 (0)