Changeset b514adf in sasmodels for sasmodels/compare.py
- Timestamp:
- Nov 24, 2015 3:43:22 PM (8 years ago)
- Branches:
- master, core_shell_microgels, costrafo411, magnetic_model, release_v0.94, release_v0.95, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- 92da231
- Parents:
- 062c56d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/compare.py
r5753e4e rb514adf 130 130 if name == 'capped_cylinder' and pars['cap_radius'] < pars['radius']: 131 131 pars['radius'],pars['cap_radius'] = pars['cap_radius'],pars['radius'] 132 if name == 'barbell' and pars['bell_radius'] < pars['radius']: 133 pars['radius'],pars['bell_radius'] = pars['bell_radius'],pars['radius'] 134 135 # Limit guinier to an Rg such that Iq > 1e-30 (single precision cutoff) 136 if name == 'guinier': 137 #q_max = 0.2 # mid q maximum 138 q_max = 1.0 # high q maximum 139 rg_max = np.sqrt(90*np.log(10) + 3*np.log(pars['scale']))/q_max 140 pars['rg'] = min(pars['rg'],rg_max) 132 141 133 142 # These constraints are only needed for comparison to sasview … … 247 256 seed = int(opt_values['-random']) if '-random' in opt_values else None 248 257 pars, seed = randomize_model(pars, seed=seed) 249 constrain_pars(model_definition, pars)250 258 print "Randomize using -random=%i"%seed 251 259 pars.update(set_pars) # set value after random to control value 260 constrain_pars(model_definition, pars) 252 261 253 262 # parameter selection
Note: See TracChangeset
for help on using the changeset viewer.