source: sasview/src/sas/qtgui/Perspectives/Fitting/FitPage.py @ 6066a3f

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalc
Last change on this file since 6066a3f was 6066a3f, checked in by Piotr Rozyczko <rozyczko@…>, 7 years ago

Code review comments for SASVIEW-586

  • Property mode set to 100644
File size: 1.6 KB
Line 
1"""
2Container class for fitting widget state storage
3"""
4class FitPage(object):
5    """
6    Container for all data related to the current fit page
7    """
8    MIN_RANGE = 0
9    MAX_RANGE = 1
10    NPTS = 2
11    NPTS_FIT = 3
12    LOG_POINTS = 4
13    WEIGHTING = 5
14    SMEARING_OPTION = 6
15    SMEARING_ACCURACY = 7
16    SMEARING_MIN = 8
17    SMEARING_MAX = 9
18    def __init__(self):
19        """
20        Define the dictionary
21        """
22        # Main tab
23        self.current_category = ""
24        self.current_model = ""
25        self.current_factor = ""
26
27        self.page_id = 0
28        self.data_is_loaded = False
29        self.filename = ""
30        self.data = None
31        self.parameters_to_fit = []
32
33        # QModels
34        self.param_model = None
35        self.poly_model = None
36        self.magnetism_model = None
37
38        # Displayed values - tab #1
39        self.is_polydisperse = False
40        self.is2D = False
41        self.is_magnetism = False
42        self.displayed_values = {}
43        self.chi2 = None
44
45        # Fit options - tab #2
46        self.fit_options = {}
47        # Weight options - tab #2
48        #self.weighting_options = {}
49        # Smearing options - tab #3
50        self.smearing_options = {}
51
52    def save(self):
53        """
54        Serialize the current state
55        """
56        pass
57
58    def load(self, location):
59        """
60        Retrieve serialized state from specified location
61        """
62        pass
63
64    def saveAsXML(self):
65        """
66        Serialize the current state
67        """
68        # Connect to PageState.to_xml(), which serializes
69        # to the existing XML with file I(Q)
70        pass
71
Note: See TracBrowser for help on using the repository browser.