Changeset abc03d8 in sasmodels


Ignore:
Timestamp:
Mar 21, 2016 4:06:45 PM (8 years ago)
Author:
wojciech
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:
e8d2276
Parents:
31641b2
Message:

Bug fixes

Location:
sasmodels
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/generate.py

    rafda63c rabc03d8  
    685685def poly_details(model_info, weights): 
    686686    pars = model_info['parameters'][2:]  # skip scale and background 
     687    weights = weights[2:] 
    687688    max_pd = model_info['max_pd'] 
    688689    npars = len(pars) # scale and background already removed 
     
    694695    pd_length = np.array([len(w) for w in weights]) 
    695696    print (pd_length) 
     697    print (weights) 
    696698    pd_offset = np.cumsum(np.hstack((0, pd_length))) 
    697699    pd_isvol = np.array([p.type=='volume' for p in pars]) 
     
    716718    details[par_offset+1*npars:par_offset+2*npars] = 0  # no coordination for most 
    717719    details[par_offset+2*npars:par_offset+3*npars] = 0  # no fast coord with 0 
    718     coord_offset = par_offset+1*pars 
     720    coord_offset = par_offset+1*npars 
    719721    for k,parameter_num in enumerate(idx): 
    720722        details[coord_offset+parameter_num] = 2**k 
  • sasmodels/kernel_iq.c

    r0a7e5eb4 rabc03d8  
    5656  local int offset[NPARS];  // NPARS excludes scale/background 
    5757 
    58 #if 1 // defined(USE_SHORTCUT_OPTIMIZATION) 
     58#if 0 // defined(USE_SHORTCUT_OPTIMIZATION) 
    5959  if (problem->pd_length[0] == 1) { 
    6060    // Shouldn't need to copy!! 
     
    7777#endif 
    7878 
    79  
     79  printf("Entering polydispersity\n"); 
    8080  // Since we are no longer looping over the entire polydispersity hypercube 
    8181  // for each q, we need to track the normalization values for each q in a 
  • sasmodels/kerneldll.py

    r445d1c0 rabc03d8  
    277277            #TODO: pd_start will need to be changed 
    278278            0, # pd_start 
    279             details[3*max_pd:4*max_pd], # pd_stop pd_stride[MAX_PD] 
     279            details[4*max_pd-1], # pd_stop pd_stride[MAX_PD] 
    280280            details.ctypes.data, # problem 
    281281            weights.ctypes.data,  # weights 
Note: See TracChangeset for help on using the changeset viewer.