Skip to content

Proper test coverage for Neuron CollectivePermute #8818

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 12, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion test/neuron/run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ function run_op_tests {
function run_mp_op_tests {
run_test "$CDIR/test_mp_replication.py"
#run_test "$CDIR/test_mp_all_to_all.py"
run_test "$CDIR/test_mp_collective_permute.py"
PJRT_DEVICE=NEURON NEURONCORE_NUM_DEVICES=8 run_test "$CDIR/test_mp_collective_permute.py"
#run_test "$CDIR/test_mp_all_gather.py" # "wrong reductions"?
run_test "$CDIR/test_mp_reduce_scatter.py"
run_test "$CDIR/test_zero1.py"
Expand Down
7 changes: 2 additions & 5 deletions test/test_mp_collective_permute.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,10 @@ def _mp_fn(index):
expected = [ordinal - 1] * 100 if ordinal != 0 else [world_size - 1] * 100

if result != expected:
print(
'Wrong result from core {}: {}'.format(ordinal, result),
file=sys.stderr)
print(f"Wrong result from core {ordinal}: {result}", file=sys.stderr)
sys.exit(1)
else:
print(
'Default device {} is not a TPU device'.format(device), file=sys.stderr)
print(f"Default device {device} is not a supported device", file=sys.stderr)


if __name__ == '__main__':
Expand Down
Loading