Changeset 98d6cfc in sasmodels
- Timestamp:
- Mar 20, 2016 6:51:31 AM (9 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:
- 3a45c2c
- Parents:
- 22975f0
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/compare.py
r72a081d r98d6cfc 69 69 -accuracy=Low accuracy of the resolution calculation Low, Mid, High, Xhigh 70 70 -edit starts the parameter explorer 71 -default/-demo* use demo vs default parameters 71 72 72 73 Any two calculation engines can be selected for comparison: … … 631 632 'hist', 'nohist', 632 633 'edit', 634 'demo', 'default', 633 635 ]) 634 636 VALUE_OPTIONS = [ … … 654 656 655 657 656 def get_ demo_pars(model_info):658 def get_pars(model_info, use_demo=False): 657 659 """ 658 660 Extract demo parameters from the model definition. … … 670 672 671 673 # Plug in values given in demo 672 pars.update(model_info['demo']) 674 if use_demo: 675 pars.update(model_info['demo']) 673 676 return pars 674 677 … … 727 730 'rel_err' : True, 728 731 'explore' : False, 732 'use_demo' : True, 729 733 } 730 734 engines = [] … … 765 769 elif arg == '-sasview': engines.append(arg[1:]) 766 770 elif arg == '-edit': opts['explore'] = True 771 elif arg == '-demo': opts['use_demo'] = True 772 elif arg == '-default': opts['use_demo'] = False 767 773 # pylint: enable=bad-whitespace 768 774 … … 782 788 # Get demo parameters from model definition, or use default parameters 783 789 # if model does not define demo parameters 784 pars = get_demo_pars(model_info) 790 pars = get_pars(model_info, opts['use_demo']) 791 785 792 786 793 # Fill in parameters given on the command line
Note: See TracChangeset
for help on using the changeset viewer.