Changeset e6c1491 in sasmodels
- Timestamp:
- Mar 21, 2016 4:45:31 PM (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:
- ea1f14d
- Parents:
- 5462ffb (diff), 25b30fd (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - Location:
- sasmodels
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/kernelcl.py
r48fbd50 r25b30fd 244 244 #print("compiling",name) 245 245 dtype = np.dtype(dtype) 246 program = compile_model(self.get_context(dtype), s ource, dtype, fast)246 program = compile_model(self.get_context(dtype), str(source), dtype, fast) 247 247 self.compiled[key] = program 248 248 return self.compiled[key] -
sasmodels/generate.py
r48fbd50 re8d2276 687 687 print([p.name for p in model_info['parameters']]) 688 688 pars = model_info['parameters'][2:] # skip scale and background 689 weights = weights[2:] 689 690 max_pd = model_info['max_pd'] 690 691 npars = len(pars) # scale and background already removed … … 696 697 pd_length = np.array([len(w) for w in weights]) 697 698 print (pd_length) 699 print (weights) 698 700 pd_offset = np.cumsum(np.hstack((0, pd_length))) 699 701 pd_isvol = np.array([p.type=='volume' for p in pars]) … … 708 710 if theta_par >= 0 and pd_length[theta_par] <= 1: 709 711 theta_par = -1 710 711 print("p","max_pd","constants_offset",par_offset,max_pd,constants_offset,npars)712 print(idx)713 print(pd_length[idx])714 print(pd_offset[idx])715 print(pd_stride)716 print(pd_isvol[idx])717 712 718 713 details = np.empty(constants_offset + 2, 'int32') … … 725 720 details[par_offset+1*npars:par_offset+2*npars] = 0 # no coordination for most 726 721 details[par_offset+2*npars:par_offset+3*npars] = 0 # no fast coord with 0 727 coord_offset = par_offset+1* pars722 coord_offset = par_offset+1*npars 728 723 for k,parameter_num in enumerate(idx): 729 724 details[coord_offset+parameter_num] = 2**k 730 details[constants_offset] 725 details[constants_offset] = 1 # fast_coord_count: one fast index 731 726 details[constants_offset+1] = theta_par 732 727 print ("details",details) -
sasmodels/kernel_iq.c
r0a7e5eb4 r5462ffb 56 56 local int offset[NPARS]; // NPARS excludes scale/background 57 57 58 #if 1// defined(USE_SHORTCUT_OPTIMIZATION)58 #if 0 // defined(USE_SHORTCUT_OPTIMIZATION) 59 59 if (problem->pd_length[0] == 1) { 60 60 // Shouldn't need to copy!! … … 77 77 #endif 78 78 79 79 printf("Entering polydispersity\n"); 80 80 // Since we are no longer looping over the entire polydispersity hypercube 81 81 // for each q, we need to track the normalization values for each q in a … … 193 193 } 194 194 } 195 195 196 //Makes a normalization avialable for the next round 196 197 result[nq] = norm;
Note: See TracChangeset
for help on using the changeset viewer.