Explicitly disallow duplicated devices during array construction
jax.make_array_from_single_device_arrays should not allow passing more than one array on the same device as that would lead to an invalid array. While some of this case is already detected by later checks (e.g., ArrayImpl._check_and_rearrange), this CL explicitly checks the device list before calling IFRT so that we don't create an invalid IFRT array to begin with.
Explicitly disallow duplicated devices during array construction
jax.make_array_from_single_device_arrays
should not allow passing more than one array on the same device as that would lead to an invalid array. While some of this case is already detected by later checks (e.g.,ArrayImpl._check_and_rearrange
), this CL explicitly checks the device list before calling IFRT so that we don't create an invalid IFRT array to begin with.