Changeset 5124c969 in sasmodels for sasmodels/modelinfo.py


Ignore:
Timestamp:
Feb 27, 2017 5:55:59 PM (7 years ago)
Author:
Paul Kienzle <pkienzle@…>
Branches:
master, core_shell_microgels, costrafo411, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
Children:
c713c85
Parents:
a3002be
Message:

allow multicompare to select opencl+single+1d

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/modelinfo.py

    r85fe7f8 r5124c969  
    730730    info.docs = kernel_module.__doc__ 
    731731    info.category = getattr(kernel_module, 'category', None) 
    732     info.single = getattr(kernel_module, 'single', True) 
    733     info.opencl = getattr(kernel_module, 'opencl', True) 
    734732    info.structure_factor = getattr(kernel_module, 'structure_factor', False) 
    735733    info.profile_axes = getattr(kernel_module, 'profile_axes', ['x', 'y']) 
     
    745743    info.profile = getattr(kernel_module, 'profile', None) # type: ignore 
    746744    info.sesans = getattr(kernel_module, 'sesans', None) # type: ignore 
     745    # Default single and opencl to True for C models.  Python models have callable Iq. 
     746    info.opencl = getattr(kernel_module, 'opencl', not callable(info.Iq)) 
     747    info.single = getattr(kernel_module, 'single', not callable(info.Iq)) 
    747748 
    748749    # multiplicity info 
Note: See TracChangeset for help on using the changeset viewer.