Index: sansview/perspectives/fitting/fitpage.py
===================================================================
--- sansview/perspectives/fitting/fitpage.py	(revision 4708f3a4e5f091e5e180c8ae16d7ed3b4f48eb66)
+++ sansview/perspectives/fitting/fitpage.py	(revision cb190a1908b9984992ab659c7d34450036c35103)
@@ -1963,99 +1963,4 @@
         except:
             pass  
-        
-    def complete_chisqr(self, output, elapsed=None):  
-        """
-            print result chisqr
-        """
-        try:
-            if output ==None:
-                output= "-"
-
-            self.tcChi.SetValue(str(format_number(output)))
-
-            self.state.tcChi =self.tcChi
-
-        except:
-            pass
-        
-        
-    def compute_chisqr1D(self, smearer=None):
-        """
-            Compute chisqr for 1D
-        """
-        try:
-            self.qmin_x = float(self.qmin.GetValue())
-            self.qmax_x = float(self.qmax.GetValue())
-            ##return residuals within self.qmin_x and self.qmax_x
-            from gui_thread import CalcChisqr1D
-            ## If a thread is already started, stop it
-            if self.calc_Chisqr!= None and self.calc_Chisqr.isrunning():
-                self.calc_Chisqr.stop()
-                
-            self.calc_Chisqr= CalcChisqr1D( data1d= self.data,
-                                            model= self.model,
-                                            smearer=smearer,
-                                            qmin=self.qmin_x,
-                                            qmax=self.qmax_x,
-                                            completefn = self.complete_chisqr,
-                                            updatefn   = None)
-    
-            self.calc_Chisqr.queue()
-            
-        except:
-            raise ValueError," Could not compute Chisqr for %s Model 2D: "%self.model.name
-           
-            
-   
-        
-        
-    def compute_chisqr2D(self,smearer=None):
-        """ 
-            compute chi square given a model and data 2D and set the value
-            to the tcChi txtcrl
-        """
-        try:
-            self.qmin_x = float(self.qmin.GetValue())
-            self.qmax_x = float(self.qmax.GetValue())
-           
-            ##return residuals within self.qmin_x and self.qmax_x
-            from gui_thread import CalcChisqr2D
-            ## If a thread is already started, stop it
-            if self.calc_Chisqr!= None and self.calc_Chisqr.isrunning():
-                self.calc_Chisqr.stop()
-            if smearer !=None:
-                smearer.set_accuracy(accuracy = self.smear2d_accuracy)
-            self.calc_Chisqr= CalcChisqr2D( data2d= self.data,
-                                            model= self.model,
-                                            smearer=smearer,
-                                            qmin= self.qmin_x,
-                                            qmax = self.qmax_x,
-                                            completefn = self.complete_chisqr,
-                                            updatefn   = None)
-    
-            self.calc_Chisqr.queue()
-          
-        except:
-           raise
-
-        
-    def compute_chisqr(self ,output=None, smearer=None):
-        """ 
-            compute chi square given a model and data 1D and set the value
-            to the tcChi txtcrl
-        """
-        flag = self._validate_qrange( self.qmin, self.qmax)
-        if flag== True:
-            try:
-                if hasattr(self.data,"data"):
-                    self.compute_chisqr2D(smearer=smearer)
-                    return
-                else:
-                    self.compute_chisqr1D(smearer=smearer)
-                    return
-            except:
-                wx.PostEvent(self.parent.parent, StatusEvent(status=\
-                            "Chisqr Error: %s"% sys.exc_value))
-                return 
             
     
Index: sansview/perspectives/fitting/gui_thread.py
===================================================================
--- sansview/perspectives/fitting/gui_thread.py	(revision f72333f17352e43cc9070c075edce981b721111e)
+++ 	(revision )
@@ -1,162 +1,0 @@
-
-
-import time
-import numpy
-import copy
-import math
-import sys
-import wx
-
-from data_util.calcthread import CalcThread
-from sans.fit.AbstractFitEngine import FitData2D, FitData1D, SansAssembly
-from DataLoader.smearing_2d import Smearer2D
-
-class CalcChisqr1D(CalcThread):
-    """
-       Compute chisqr
-    """
-    def __init__(self, data1d, model,
-                 smearer=None,
-                 qmin=None,
-                 qmax=None,
-                 completefn = None,
-                 updatefn   = None,
-                 yieldtime  = 0.01,
-                 worktime   = 0.01
-                 ):
-        CalcThread.__init__(self,completefn,
-                 updatefn,
-                 yieldtime,
-                 worktime)
-        
-        if model ==None or data1d ==None:
-            raise ValueError, "Need data and model to compute chisqr"
-        
-        if data1d.__class__.__name__ !="Data1D":
-            msg= str(data1d.__class__.__name__)
-            raise ValueError, "need Data1D to compute chisqr. Current class %s"%msg
-
-        self.fitdata= FitData1D(x=data1d.x,y=data1d.y,dx=data1d.dx,dy=data1d.dy, smearer=smearer)
-        self.fitdata.setFitRange(qmin=qmin,qmax=qmax)
-        self.model = model
-       
-        self.starttime = 0  
-        
-    def isquit(self):
-        """
-             @raise KeyboardInterrupt: when the thread is interrupted
-        """
-        try:
-            CalcThread.isquit(self)
-        except KeyboardInterrupt:
-            raise KeyboardInterrupt   
-        
-        
-    def compute(self):
-        """
-            Compute the data given a model function
-        """
-        self.starttime = time.time()
-       
-        output= None
-        res=[]
-        try:
-            res = self.fitdata.residuals(self.model.evalDistribution)
-            sum=0
-            for item in res:
-                # Check whether we need to bail out
-                self.isquit()  
-                if numpy.isfinite(item):
-                    sum +=item*item
-            if len(res)>0:
-                output = sum/ len(res)
-            
-            elapsed = time.time()-self.starttime
-            self.complete(output= output,  elapsed=elapsed)
-            
-        except KeyboardInterrupt:
-            # Thread was interrupted, just proceed and re-raise.
-            # Real code should not print, but this is an example...
-            raise
-      
-        
-class CalcChisqr2D(CalcThread):
-    """
-       Compute chisqr
-    """
-    
-    def __init__(self,data2d, model,
-                 smearer,
-                 qmin,
-                 qmax,
-                 completefn = None,
-                 updatefn   = None,
-                 yieldtime  = 0.01,
-                 worktime   = 0.01
-                 ):
-        CalcThread.__init__(self,completefn,
-                 updatefn,
-                 yieldtime,
-                 worktime)
-        
-        if model ==None or data2d ==None:
-            raise ValueError, "Need data and model to compute chisqr"
-        
-        if data2d.__class__.__name__ !="Data2D":
-            msg= str(data2d.__class__.__name__)
-            raise ValueError, "need Data2D to compute chisqr. Current class %s"%msg
-        self.smearer = smearer
-        self.fitdata = FitData2D(sans_data2d=data2d ,data=data2d.data, err_data=data2d.err_data)
-        self.fitdata.setFitRange(qmin=qmin,qmax=qmax)
-     
-        self.model = model
-
-        self.starttime = 0  
-        
-    def isquit(self):
-        """
-             @raise KeyboardInterrupt: when the thread is interrupted
-        """
-        try:
-            CalcThread.isquit(self)
-        except KeyboardInterrupt:
-            raise KeyboardInterrupt   
-        
-        
-    def compute(self):
-        """
-            Compute the data given a model function
-        """
-        self.starttime = time.time()
-        
-        output= None
-        res=[]
-        try:
-            if self.smearer == None:
-                fn = self.model.evalDistribution
-            else:
-                # Set model in smearer
-                self.smearer.set_model(self.model)
-                # set fn
-                fn = self.smearer
-                # set self.smearer != None in fitdata
-                self.fitdata.set_smearer(fn)
-
-            res = self.fitdata.residuals(fn)
-            sum=0
-            for item in res:
-                # Check whether we need to bail out
-                self.isquit()  
-                if numpy.isfinite(item):
-                    sum +=item*item
-            if len(res)>0:
-                output = sum/ len(res)
-            
-            elapsed = time.time()-self.starttime
-            self.complete(output= output,  elapsed=elapsed)
-            
-        except KeyboardInterrupt:
-            # Thread was interrupted, just proceed and re-raise.
-            # Real code should not print, but this is an example...
-            raise 
-       
