Changeset f3113c9 in sasview
- Timestamp:
- Feb 27, 2009 8:18:12 AM (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:
- e9e914f
- Parents:
- 85e94e7
- Location:
- sansview/perspectives/fitting
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
sansview/perspectives/fitting/fitpage1D.py
r51d47b5 rf3113c9 241 241 ix += 1 242 242 self.sizer9.Add(self.btFit,(iy,ix),(1,1), wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 0) 243 243 """ 244 244 id = wx.NewId() 245 245 self.btStopFit =wx.Button(self,id,'Stop') … … 249 249 ix += 1 250 250 self.sizer9.Add(self.btStopFit,(iy,ix),(1,1), wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 0) 251 251 """ 252 252 ix =0 253 253 iy+=1 … … 334 334 335 335 def onStopFit(self, event): 336 337 336 self.manager.stop_fit() 338 337 self.btStopFit.Hide() 338 self.btFit.Show(True) 339 339 self.vbox.Layout() 340 340 self.SetScrollbars(20,20,55,40) 341 341 self.Layout() 342 342 self.parent.GetSizer().Layout() 343 343 344 def compute_chisqr(self): 344 345 """ @param fn: function that return model value … … 434 435 ymin=self.data.ymin, ymax=self.data.ymax, 435 436 xmin=self.data.xmin,xmax=self.data.xmax) 436 self.btStopFit.Show() 437 #self.btStopFit.Show() 438 #self.btFit.Hide() 437 439 else: 438 440 self.manager._on_single_fit(qmin=self.qmin_x,qmax=self.qmax_x) 439 self.btStopFit.Show() 441 #self.btStopFit.Show() 442 #self.btFit.Hide() 440 443 self.vbox.Layout() 441 444 self.SetScrollbars(20,20,55,40) -
sansview/perspectives/fitting/fitting.py
r51d47b5 rf3113c9 1 import os,os.path, re1 #import os,os.path, re 2 2 import sys, wx, logging 3 3 import string, numpy, math … … 13 13 from fitpanel import FitPanel 14 14 from fit_thread import FitThread 15 import models ,modelpage15 import models#,modelpage 16 16 import fitpage1D 17 import park17 #import park 18 18 DEFAULT_BEAM = 0.005 19 19 DEFAULT_QMIN = 0.0 … … 47 47 self.standalone=True 48 48 ## Fit engine 49 self._fit_engine = ' scipy'49 self._fit_engine = 'park' 50 50 self.enable_model2D=False 51 51 # list of selcted data … … 76 76 #Set park engine 77 77 id3 = wx.NewId() 78 self.menu1.AppendCheckItem(id3, " park")78 self.menu1.AppendCheckItem(id3, "scipy") 79 79 wx.EVT_MENU(owner, id3, self._onset_engine) 80 80 … … 427 427 def stop_fit(self): 428 428 if self.calc_thread != None and self.calc_thread.isrunning(): 429 430 self.calc_thread.interrupt() 431 self.calc_thread.stop() 432 wx.PostEvent(self.parent, StatusEvent(status="Fitting \ 433 is cancelled" , type="stop")) 429 #self.calc_thread.interrupt() 430 self.calc_thread.stop() 431 wx.PostEvent(self.parent, StatusEvent(status="Fitting \ 432 is cancelled" , type="stop")) 434 433 def _on_single_fit(self,id=None,qmin=None, qmax=None,ymin=None, ymax=None,xmin=None,xmax=None): 435 434 """ -
sansview/perspectives/fitting/modelpage.py
r51d47b5 rf3113c9 539 539 wx.EXPAND|wx.ADJUST_MINSIZE, 0) 540 540 self.text2_3.Hide() 541 541 542 ix +=1 542 543 self.text2_5 = wx.StaticText(self, -1, 'Min') … … 547 548 self.sizer5.Add(self.text2_6,(iy, ix),(1,1),\ 548 549 wx.EXPAND|wx.ADJUST_MINSIZE, 0) 550 if self.data ==None: 551 self.text2_5.Hide() 552 self.text2_6.Hide() 549 553 ix +=1 550 554 self.text2_4 = wx.StaticText(self, -1, 'Units') … … 604 608 ctl4.Bind(wx.EVT_TEXT_ENTER,self._onparamEnter) 605 609 self.sizer5.Add(ctl4, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0) 606 610 if self.data==None: 611 ctl4.Hide() 612 ctl3.Hide() 607 613 ix +=1 608 614 # Units
Note: See TracChangeset
for help on using the changeset viewer.