Skip to content
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

Small bug in info_str if selected device number is >= 1 #266

Open
villekf opened this issue Apr 15, 2024 · 0 comments
Open

Small bug in info_str if selected device number is >= 1 #266

villekf opened this issue Apr 15, 2024 · 0 comments

Comments

@villekf
Copy link

villekf commented Apr 15, 2024

If the currently selected device number is 1 or greater, info_str will display incorrect information for the selected device. This is due to this conditional in device.py: https://github.com/arrayfire/arrayfire-python/blob/master/arrayfire/device.py#L108. That is, the previous device is used for the device information. An easy fix should be to simply omit the conditional.

However, the info_str seems to also show wrong devices after the platform has changed (though it could be related to something else too). For example when device number 1 is selected:
ArrayFire v3.9.0 (OpenCL 64bit)
-0- AMD Accelerated Parallel Processing: gfx1036 (Compute 2.0)
[1] AMD Accelerated Parallel Processing: gfx1036 (Compute 2.0)
-2- AMD Accelerated Parallel Processing: gfx1036 (Compute 2.0)
-3- Intel(R) OpenCL: AMD_Ryzen_5_7600X_6-Core_Processor (Compute 2.1)

With device number 3:
ArrayFire v3.9.0 (OpenCL 64bit)
-0- AMD Accelerated Parallel Processing: gfx1036 (Compute 2.0)
-1- AMD Accelerated Parallel Processing: gfx1100 (Compute 2.0)
-2- AMD Accelerated Parallel Processing: gfx1036 (Compute 2.0)
[3] AMD Accelerated Parallel Processing: gfx1036 (Compute 2.0)

The correct device is used in the actual computations though.

Note that the C++ version shows:
ArrayFire v3.9.0 (OpenCL, 64-bit Windows, build b59a1ae53)
-0- AMD: gfx1036, 24568 MB
[1] AMD: gfx1100, 20464 MB
-2- INTEL: AMD Ryzen 5 7600X 6-Core Processor , 64662 MB
-3- INTEL: AMD Ryzen 5 7600X 6-Core Processor , 64662 MB

@villekf villekf changed the title Small bug in af.info_str if selected device number is >= 1 Small bug in info_str if selected device number is >= 1 Apr 15, 2024
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

No branches or pull requests

1 participant