Skip to content

[UPDATE JAX API] Update trainer_test _normalized_spec #1201

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Steboss
Copy link
Contributor

@Steboss Steboss commented May 21, 2025

By running unittests:

XLA_FLAGS='--xla_force_host_platform_device_count=8' pytest --durations=100 -v   -n auto -v -m "for_8_devices" --dist worksteal ${UNQUOTED_PYTEST_FILES}

E             File "/opt/axlearn/axlearn/common/trainer_test.py", line 1093, in <lambda>
E           AttributeError: 'PartitionSpec' object has no attribute '_normalized_spec'
The internal API for `PartitionSpec` has been updated, so `_normalized_spec` is now `_normalized_spec_for_aval` ( [reference](https://github.com/jax-ml/jax/blob/609fb7f6085b52861f65c7aa3b339c40dfd207fa/jax/_src/partition_spec.py#L166) )
@matthew-e-hopkins for visibility

@Steboss Steboss requested review from ruomingp, markblee and a team as code owners May 21, 2025 16:30
Copy link
Contributor

@ruomingp ruomingp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the CI failure?

@Steboss
Copy link
Contributor Author

Steboss commented May 22, 2025

Hey @ruomingp
I can see the following error in the CI for many tests

#22 157.6 /opt/venv/lib/python3.10/site-packages/transformers/integrations/tensor_parallel.py:465: in __init__
#22 157.6     self.input_layouts = (input_layouts or Replicate(),)
#22 157.6 E   NameError: name 'Replicate' is not defined

Any idea? I can investigate on this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants