Changeset 9855699 in sasview for park_integration
- Timestamp:
- Jul 29, 2008 5:36:57 PM (16 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 7924042
- Parents:
- 8bd8ea4
- Location:
- park_integration
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
park_integration/Fitting.py
r4c718654 r9855699 62 62 """ return list of data""" 63 63 self._engine.get_model(Uid) 64 64 65 65 def remove_Fit_Problem(self,Uid): 66 66 """remove fitarrange in Uid""" 67 67 self._engine.remove_Fit_Problem(Uid) 68 69 -
park_integration/ParkFitting.py
r202f93a r9855699 55 55 56 56 def eval(self,x): 57 print "eval",self.parameterset[0].value 57 58 return self.model.run(x) 58 59 … … 162 163 couple=(parkmodel,parkdata) 163 164 mylist.append(couple) 164 165 print "mylist",mylist 165 166 self.problem = park.Assembly(mylist) 166 167 … … 182 183 @return result.cov: Covariance matrix 183 184 """ 184 185 print "Parkfitting: fit method probably breaking just right before \ 186 call fit" 185 187 self.createProblem() 186 188 pars=self.problem.fit_parameters() 187 189 self.problem.eval() 188 190 #print "M0.B",self.problem[1].parameterset['B'].value,self.problem[0].parameterset['B'].value 191 189 192 localfit = FitSimplex() 190 193 localfit.ftol = 1e-8 191 194 fitter = FitMC(localfit=localfit) 192 195 193 196 result = fit.fit(self.problem, 194 197 fitter=fitter, 195 198 handler= fitresult.ConsoleUpdate(improvement_delta=0.1)) 196 199 for p in result.parameters: 200 print "fit in park fitting", p.name, p.value 197 201 return result.fitness,result.pvec,result.cov 198 202
Note: See TracChangeset
for help on using the changeset viewer.