-
Notifications
You must be signed in to change notification settings - Fork 74k
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
device_spec from_string method not accepting some inputs #39857
Comments
Please provide details about what platform you are using (operating system, architecture). Also include your TensorFlow version.Please, fill issue template..Request you to share colab link or simple standalone code to reproduce the issue in our environment.It helps us in localizing the issue faster.Thanks! |
system: Linux 4.15.0-99-generic #100~16.04.1-Ubuntu x86_64 GNU/Linux Minimal example: tf.python.framework.device_spec.DeviceSpecV2().from_string(tf.config.list_physical_devices()
[0].name)
|
@jaingaurav do you want to take this? |
Hi, |
@philippeller Could you please try on latest stable version of tf 2.5 or 2.4.1 and let us know if this is still an issue.Thanks! |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you. |
Hi, looks to me as this is still the same issue in tf 2.5: >>> tf.DeviceSpec().from_string(tf.config.list_physical_devices()[0].name)
raise ValueError("Unknown attribute: '%s' in '%s'" % (y[0], spec))
ValueError: Unknown attribute: 'physical_device' in '/physical_device:CPU:0'
>>> tf.__version__
'2.5.0' |
This issue still persists on the latest TF V2.12 and Tf-nightly. Please find the gist of 2.12 and tf-nightly for reference . |
The method
from_string
oftensorflow.python.framework.device_spec
does not accept device names reported bytf
itself:tf.config.list_physical_devices()
returns device names of the form'/physical_device:GPU:0'
, Howeverfrom_string
does not accept this as input. Only works when'/physical_device:'
is cut out.Expected behaviour:
Actual behaviour:
The text was updated successfully, but these errors were encountered: