Changeset 0d64713 in sasview for src/sas/sasgui/guiframe


Ignore:
Timestamp:
Feb 28, 2017 1:17:19 PM (8 years ago)
Author:
GitHub <noreply@…>
Children:
13043af
Parents:
46f798f
git-author:
Jeff Krzywon <krzywon@…> (02/28/17 13:17:19)
git-committer:
GitHub <noreply@…> (02/28/17 13:17:19)
Message:

Revert "Sesans41"

Location:
src/sas/sasgui/guiframe
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sasgui/guiframe/dataFitting.py

    r68adf86 r0d64713  
    1717    """ 
    1818    """ 
    19  
    20     def __init__(self, x=None, y=None, dx=None, dy=None, lam=None, dlam=None, isSesans=False): 
     19    def __init__(self, x=None, y=None, dx=None, dy=None): 
    2120        """ 
    2221        """ 
     
    2524        if y is None: 
    2625            y = [] 
    27         self.isSesans = isSesans 
    28         PlotData1D.__init__(self, x, y, dx, dy, lam, dlam) 
    29         LoadData1D.__init__(self, x, y, dx, dy, lam, dlam, isSesans) 
    30  
     26        PlotData1D.__init__(self, x, y, dx, dy) 
     27        LoadData1D.__init__(self, x, y, dx, dy) 
    3128        self.id = None 
    3229        self.list_group_id = [] 
     
    3532        self.path = None 
    3633        self.xtransform = None 
    37         if self.isSesans: 
    38             self.xtransform = "x" 
    3934        self.ytransform = None 
    40         if self.isSesans: 
    41             self.ytransform = "y" 
    4235        self.title = "" 
    4336        self.scale = None 
     
    7568        # First, check the data compatibility 
    7669        dy, dy_other = self._validity_check(other) 
    77         result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=None) 
     70        result = Data1D(x=[], y=[], dx=None, dy=None) 
    7871        result.clone_without_data(length=len(self.x), clone=self) 
    7972        result.copy_from_datainfo(data1d=self) 
     
    122115        # First, check the data compatibility 
    123116        self._validity_check_union(other) 
    124         result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=None) 
     117        result = Data1D(x=[], y=[], dx=None, dy=None) 
    125118        tot_length = len(self.x) + len(other.x) 
    126119        result = self.clone_without_data(length=tot_length, clone=result) 
    127         if self.dlam == None or other.dlam is None: 
    128             result.dlam = None 
    129         else: 
    130             result.dlam = numpy.zeros(tot_length) 
    131120        if self.dy == None or other.dy is None: 
    132121            result.dy = None 
     
    152141        result.y = numpy.append(self.y, other.y) 
    153142        result.y = result.y[ind] 
    154         result.lam = numpy.append(self.lam, other.lam) 
    155         result.lam = result.lam[ind] 
    156         if result.dlam != None: 
    157             result.dlam = numpy.append(self.dlam, other.dlam) 
    158             result.dlam = result.dlam[ind] 
    159143        if result.dy != None: 
    160144            result.dy = numpy.append(self.dy, other.dy) 
     
    276260        # First, check the data compatibility 
    277261        self._validity_check_union(other) 
    278         result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=[]) 
     262        result = Data1D(x=[], y=[], dx=None, dy=None) 
    279263        tot_length = len(self.x)+len(other.x) 
    280264        result.clone_without_data(length=tot_length, clone=self) 
    281         if self.dlam == None or other.dlam is None: 
    282             result.dlam = None 
    283         else: 
    284             result.dlam = numpy.zeros(tot_length) 
    285265        if self.dy == None or other.dy is None: 
    286266            result.dy = None 
     
    305285        result.y = numpy.append(self.y, other.y) 
    306286        result.y = result.y[ind] 
    307         result.lam = numpy.append(self.lam, other.lam) 
    308         result.lam = result.lam[ind] 
    309287        if result.dy != None: 
    310288            result.dy = numpy.append(self.dy, other.dy) 
  • src/sas/sasgui/guiframe/data_manager.py

    r2ffe241 r0d64713  
    6161         
    6262        if issubclass(Data2D, data.__class__): 
    63             new_plot = Data2D(image=None, err_image=None) # For now, isSesans for 2D data is always false 
    64         else: 
    65             new_plot = Data1D(x=[], y=[], dx=None, dy=None, lam=None, dlam=None, isSesans=data.isSesans) 
    66  
    67  
    68         #elif data.meta_data['loader'] == 'SESANS': 
    69         #    new_plot = Data1D(x=[], y=[], dx=None, dy=None, lam=None, dlam=None, isSesans=True) 
    70         #else: 
    71         #    new_plot = Data1D(x=[], y=[], dx=None, dy=None, lam=None, dlam=None) #SESANS check??? 
    72  
     63            new_plot = Data2D(image=None, err_image=None)  
     64        else:  
     65            new_plot = Data1D(x=[], y=[], dx=None, dy=None) 
     66            
    7367        new_plot.copy_from_datainfo(data) 
    7468        data.clone_without_data(clone=new_plot) 
Note: See TracChangeset for help on using the changeset viewer.