Changeset 8a518285 in sasview


Ignore:
Timestamp:
Aug 7, 2018 10:47:21 AM (6 years ago)
Author:
Torin Cooper-Bennun <torin.cooper-bennun@…>
Branches:
ESS_GUI, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
Children:
db05c44
Parents:
25b3d53
Message:

fix display of OpenCL options (was not displaying devices, only platforms)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/Perspectives/Fitting/GPUOptions.py

    raed0532 r8a518285  
    226226    for cl_platform in cl_platforms: 
    227227        d_index = 0 
    228         cl_platforms = cl_platform.get_devices() 
    229         for cl_platform in cl_platforms: 
    230             if len(cl_platforms) > 1 and len(cl_platforms) > 1: 
     228        cl_devices = cl_platform.get_devices() 
     229        for cl_device in cl_devices: 
     230            if len(cl_platforms) > 1 and len(cl_devices) > 1: 
    231231                combined_index = ":".join([str(p_index), str(d_index)]) 
    232232            elif len(cl_platforms) > 1: 
     
    234234            else: 
    235235                combined_index = str(d_index) 
    236             clinfo.append((combined_index, ":".join([cl_platform.name, 
    237                                                      cl_platform.name]))) 
     236            clinfo.append((combined_index, ": ".join([cl_platform.name, 
     237                                                     cl_device.name]))) 
    238238            d_index += 1 
    239239        p_index += 1 
Note: See TracChangeset for help on using the changeset viewer.