Changes in / [43bdddc:02dfcab] in sasmodels
- Location:
- sasmodels
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/core.py
rf734e7d r84e01d2 12 12 try: 13 13 from .kernelcl import load_model as load_model_cl 14 except ImportError,exc:14 except Exception,exc: 15 15 load_model_cl = None 16 16 from .kerneldll import load_model as load_model_dll -
sasmodels/kernelcl.py
rf734e7d r664c8e7 30 30 try: 31 31 import pyopencl as cl 32 except ImportError,exc: 32 context = cl.create_some_context(interactive=False) 33 del context 34 except Exception,exc: 33 35 warnings.warn(str(exc)) 34 36 raise RuntimeError("OpenCL not available") 35 36 try:37 context = cl.create_some_context(interactive=False)38 del context39 except cl.RuntimeError, exc:40 warnings.warn(str(exc))41 raise RuntimeError("OpenCl not available")42 37 43 38 from pyopencl import mem_flags as mf -
sasmodels/model_test.py
r6137124 r84e01d2 145 145 loaders = ['dll'] 146 146 models = models[1:] 147 elif models and models[0] == 'opencl_and_dll': 148 if load_model_cl is None: 149 print >>sys.stderr, "opencl is not available" 150 sys.exit(1) 151 loaders = ['opencl', 'dll'] 152 models = models[1:] 147 153 else: 148 154 loaders = ['opencl', 'dll'] … … 151 157 runner.run(suite(loaders, models)) 152 158 else: 153 print >>sys.stderr, "usage: python -m sasmodels.model_test [opencl|dll ] model1 model2 ..."159 print >>sys.stderr, "usage: python -m sasmodels.model_test [opencl|dll|opencl_and_dll] model1 model2 ..." 154 160 print >>sys.stderr, "if model1 is 'all', then all except the remaining models will be tested" 155 161
Note: See TracChangeset
for help on using the changeset viewer.