Changeset a78433dd in sasview for src/sas


Ignore:
Timestamp:
Aug 1, 2017 5:00:20 AM (7 years ago)
Author:
lewis
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.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
713a047
Parents:
2f85af7
Message:

Ensure loaded data is always sorted correctly

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sascalc/dataloader/file_reader_base_class.py

    r2f85af7 ra78433dd  
    5555                    self.get_file_contents() 
    5656 
    57                     if isinstance(self.output[0], Data1D): 
    58                         self.sort_one_d_data() 
    59                     elif isinstance(self.output[0], Data2D): 
    60                         self.sort_two_d_data() 
    61  
    6257                except DataReaderException as e: 
    6358                    self.handle_error_message(e.message) 
     
    7570            msg += "Please check your file path and try again." 
    7671            self.handle_error_message(msg) 
     72 
     73        if isinstance(self.output[0], Data1D): 
     74            self.sort_one_d_data() 
     75        elif isinstance(self.output[0], Data2D): 
     76            self.sort_two_d_data() 
     77 
    7778        # Return a list of parsed entries that data_loader can manage 
    7879        return self.output 
Note: See TracChangeset for help on using the changeset viewer.