Extract the partition specs from the sharding instances that are present on the compiled object.
Extract the partition specs from the sharding instances that are present on the compiled object.

PiperOrigin-RevId: 461266290

google/paxml,google/paxml