Changeset 7feb69d in sasview for src/sas/sasgui/perspectives
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/perspectives/fitting/gpu_options.py
r71ac835 r7feb69d 64 64 accept_btn = wx.Button(self, wx.ID_OK) 65 65 accept_btn.SetToolTipString("Accept new OpenCL settings. This will" 66 " overwrite SAS_OPENCL variable if set")66 " overwrite SAS_OPENCL variable if set") 67 67 68 68 help_id = wx.NewId() … … 91 91 self.SetSizer(self.vbox) 92 92 self.vbox.Fit(self) 93 93 self.SetTitle("OpenCL options") 94 94 self.Centre() 95 95 96 96 def _get_clinfo(self): 97 """ 98 Reading in information about available OpenCL infrastructure 99 :return: 100 """ 97 101 clinfo = [] 98 102 try: … … 100 104 for platform in cl.get_platforms(): 101 105 for device in platform.get_devices(): 102 clinfo.append( device.name)106 clinfo.append(":".join([platform.name,device.name])) 103 107 except ImportError: 104 108 warnings.warn("pyopencl import failed. Please check installation") … … 117 121 if btn != selected_button: 118 122 btn.SetValue(0) 119 self.sas_opencl = self.option_button[selected_button.Name] 123 if selected_button.GetValue(): 124 self.sas_opencl = self.option_button[selected_button.Name] 125 else: 126 self.sas_opencl = None 120 127 121 128 def on_OK(self, event):
Note: See TracChangeset
for help on using the changeset viewer.