Skip to content

Commit 4e7d4e8

Browse files
committed
relax unit test to 1e-05
1 parent c8d4320 commit 4e7d4e8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

distributed_embeddings/python/layers/dist_model_parallel_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ def run_and_test(self, ref_model, ref_inputs, test_model, test_inputs):
189189

190190
for ref_w, test_w in zip(ref_weights, test_weights):
191191
# assert close here since order of accumulations(inputs and batch dim) might have changed
192-
self.assertAllClose(tf.convert_to_tensor(ref_w), tf.convert_to_tensor(test_w))
192+
self.assertAllClose(tf.convert_to_tensor(ref_w), tf.convert_to_tensor(test_w), 1e-05, 1e-05)
193193

194194
def test_broadcast(self):
195195
tf.keras.utils.set_random_seed(int(time.time()) + self.hvd_rank)

tests/dist_model_parallel_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ def run_and_test(self, ref_model, ref_inputs, test_model, test_inputs):
189189

190190
for ref_w, test_w in zip(ref_weights, test_weights):
191191
# assert close here since order of accumulations(inputs and batch dim) might have changed
192-
self.assertAllClose(tf.convert_to_tensor(ref_w), tf.convert_to_tensor(test_w))
192+
self.assertAllClose(tf.convert_to_tensor(ref_w), tf.convert_to_tensor(test_w), 1e-05, 1e-05)
193193

194194
def test_broadcast(self):
195195
tf.keras.utils.set_random_seed(int(time.time()) + self.hvd_rank)

0 commit comments

Comments
 (0)