Changes between Version 48 and Version 49 of ModelConvInst
- Timestamp:
- Mar 17, 2016 1:03:26 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ModelConvInst
v48 v49 40 40 - **parameters = [["name", "units", default, [min,max], "type", "tooltip"],...].** This is where the parameters get defined. The syntax should be obvious from the default. Copy the parameters from the model header file [https://github.com/SasView/sasview/tree/master/src/sas/models/include src/sas/models/include]. 41 41 - ''the order of the parameters in the definition will be the order of the parameters in the user interface and the order of the parameters in Iq(), Iqxy() and form_volume().'' 42 - VERY IMPORTANT: We are trying to make the model parameters more consistent between models. So solvent_sld, for example, should have exactly the same name in every model. ''The current list of new parameters is:'' 43 - ''radius'' = radius 44 - ''sld'' = scattering length density of particle 45 - ''solvent_sld'' = scattering length density of matrix 46 - ''regiona_sld'' = scattering length density of region a for a multi component model with several slds 47 - ''cor_length'' = correlation length 48 - ''exp'' = exponent (example: porod_exp) 49 - ''peak_pos'' = q_peak or q0 etc 50 - ''theta'' = axis_theta, phi = axis_phi 51 - ''vol_frac'' = volume fraction of particle (example: lg_vol_frac) 52 - add more as you generate them! 42 - VERY IMPORTANT: We are trying to make the model parameters more consistent between models. So sld_solvent, for example, should have exactly the same name in every model. 53 43 - **''NOTE: There is no need to specify 'scale' or 'background', these are implicit to all models.''** 54 44 - to see the list of parameters currently used across all models, use … … 56 46 python -m sasmodels.list_pars 57 47 }}} 48 - **the parameter default values are used to auto-generate a plot of the model function in the documentation**. 58 49 - lower and upper limits can be any number, or -inf or inf. 59 50 - add limits where required the (old) sasview models don't usually define them. … … 146 137 Also remember, if using a locally-built !SasView, that if you have done a ''pull'' from the repo you will need to re-build before continuing! 147 138 148 The first thing to test is that you are getting the same answer as !SasView for the 1D version of the model. This is done with:139 The first thing to test is that you are getting the same answer as !SasView for the 1D version of the model. **These tests use the ''demo='' values in your model file.** To run the tests use: 149 140 150 141 {{{ … … 199 190 Dispersion parameters n, sigma and type will be unchanged from demo so that run times are predictable. 200 191 201 Now run the unit tests that you have added :192 Now run the unit tests that you have added. **These tests use the ''test='' values in your model file**. To run the unit tests use: 202 193 203 194 {{{ … … 260 251 Once compare and the unit test(s) pass properly and everything is done, commit your new model to the repo and then edit the models table at [http://trac.sasview.org/wiki/ListofModels] to indicate that the conversion is complete. 261 252 253 Also complete the documentation check table [http://trac.sasview.org/wiki/Documentation Checks]. 254 262 255 263 256 '''OPENCL ISSUES'''