Skip to content

Commit bafa309

Browse files
authored
Update API.md
1 parent ccdf759 commit bafa309

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

API.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ You can use the device database built into `torchruntime` for your projects:
1818
```py
1919
from torchruntime.device_db import get_gpus
2020

21-
discrete_gpus = get_gpus() # Returns a list of `torchruntime.device_db.GPU` instances containing the fields: vendor_id, vendor_name, device_id, device_name, is_discrete
21+
gpus = get_gpus() # Returns a list of `torchruntime.device_db.GPU` instances containing the fields: vendor_id, vendor_name, device_id, device_name, is_discrete
2222
```
2323

2424
**Important:** This API could break in the future, so if you're writing a program using this, please open a new Issue on this repo and let me know what you're trying to do.
@@ -31,5 +31,5 @@ E.g. `cu124` or `rocm6.1` or `directml` or `ipex` or `xpu` or `cpu`.
3131
```py
3232
from torchruntime.platform_detection import get_torch_platform
3333

34-
torch_platform = get_torch_platform()
34+
torch_platform = get_torch_platform(gpus) # use `torchruntime.device_db.get_gpus()` to get a list of recognized GPUs
3535
```

0 commit comments

Comments
 (0)