Changeset facb052 in sasmodels


Ignore:
Timestamp:
Mar 27, 2019 10:02:32 AM (5 years ago)
Author:
richardh
Branches:
master, ticket-1257-vesicle-product, ticket_1156, ticket_822_more_unit_tests
Children:
a7db39fa, a430f5f
Parents:
0b8a1fc
Message:

added some debug print in direct_model

Location:
sasmodels
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/direct_model.py

    r0b8a1fc rfacb052  
    5959    """ 
    6060    mesh = get_mesh(calculator.info, pars, dim=calculator.dim, mono=mono) 
    61     #print("pars", list(zip(*mesh))[0]) 
     61    print("in call_kernel: pars:", list(zip(*mesh))[0]) 
    6262    call_details, values, is_magnetic = make_kernel_args(calculator, mesh) 
    63     #print("values:", values) 
     63    #print("in call_kernel: values:", values) 
    6464    return calculator(call_details, values, cutoff, is_magnetic) 
    6565 
     
    7676    R_eff_type = int(pars.pop(RADIUS_MODE_ID, 1.0)) 
    7777    mesh = get_mesh(calculator.info, pars, dim=calculator.dim, mono=mono) 
    78     #print("pars", list(zip(*mesh))[0]) 
     78    print("in call_Fq: pars", list(zip(*mesh))[0]) 
    7979    call_details, values, is_magnetic = make_kernel_args(calculator, mesh) 
    80     #print("values:", values) 
     80    #print("in call_Fq: values:", values) 
    8181    return calculator.Fq(call_details, values, cutoff, is_magnetic, R_eff_type) 
    8282 
     
    118118        active = lambda name: True 
    119119 
    120     #print("pars",[p.id for p in parameters.call_parameters]) 
     120    print("in get_mesh: pars:",[p.id for p in parameters.call_parameters]) 
    121121    mesh = [_get_par_weights(p, values, active(p.name)) 
    122122            for p in parameters.call_parameters] 
  • sasmodels/model_test.py

    r0b8a1fc rfacb052  
    242242                    # build the P@S model 
    243243                    s_info = load_model_info(s_name) 
     244                    print("in run_all: s_info:", s_info) 
    244245                    ps_info = product.make_product_info(self.info, s_info) 
    245246                    ps_model = build_model(ps_info, dtype=self.dtype, 
  • sasmodels/models/sphere.py

    r0b8a1fc rfacb052  
    9999     0.1, None, None, 120., None, 1.0], 
    100100    [{"@S": "hardsphere"}, 
    101        0.1, 0.7940350343881906], # this is current value, not verified elsewhere yet 
     101       0.1, 0.7940350343881906], # Q=0.1 this is current value, not verified elsewhere yet 
    102102        [{"@S": "hardsphere",          # hard sphere structure factor 
    103103     "structure_factor_mode": 1,  # decoupling approximation 
    104      "effective_radius_type": 1, "radius_effective":27.0  # equivalent sphere   Currently have hardwired model_test to accept radius_effective BUT doe sit get passed to S(Q)??? 
     104     "effective_radius_type": 1, "radius_effective":27.0 # equivalent sphere   Currently have hardwired model_test to accept radius_effective  
     105     # direct_model has the name & value BUT does it get passed to S(Q)???  What about volfracion, plus the many parameters used by other S(Q) ? 
     106     # effective_radius_type does NOT appear in the list, has it been stripped out??? 
    105107         }, 0.1, 0.7940350343881906], 
    106         [{"@S": "hardsphere",          # hard sphere structure factor 
    107      "structure_factor_mode": 2,  #  -  WHY same result? 
    108      "effective_radius_type": 2, "radius_effective":23.0    #  
    109          }, 0.1, 0.7940350343881906] 
     108#       [{"@S": "hardsphere",          # hard sphere structure factor 
     109#     "structure_factor_mode": 3,  #  -  WHY same result? 
     110#     "effective_radius_type": 3, "radius_effective":23.0    #  
     111#        }, 0.1, 0.7940350343881906] 
    110112] 
    111113# putting None for expected result will pass the test if there are no errors from the routine, but without any check on the value of the result 
Note: See TracChangeset for help on using the changeset viewer.