예제 #1
0
    def get_state(self):
        """ Returns a RunSetupScript with the state of Run_Setup_Interface
        Set up all the class parameters in RunSetupScrpt with values in the content
        """
        s = AdvancedSetupScript(self._instrument_name)

        s.pushdatapositive = str(self._content.pushdatapos_combo.currentText())
        s.unwrapref = self._content.unwrap_edit.text()
        s.lowresref = self._content.lowres_edit.text()
        s.cropwavelengthmin = str(self._content.cropwavelengthmin_edit.text())
        s.cropwavelengthmax = str(
            self._content.lineEdit_croppedWavelengthMax.text())
        s.removepropmppulsewidth = self._content.removepromptwidth_edit.text()
        s.maxchunksize = self._content.maxchunksize_edit.text()
        s.scaledata = self._content.scaledata_edit.text()
        s.filterbadpulses = self._content.filterbadpulses_edit.text()
        s.bkgdsmoothpars = self._content.bkgdsmoothpar_edit.text()

        s.stripvanadiumpeaks = self._content.stripvanpeaks_chkbox.isChecked()
        s.vanadiumfwhm = self._content.vanpeakfwhm_edit.text()
        s.vanadiumpeaktol = self._content.vanpeaktol_edit.text()
        s.vanadiumsmoothparams = self._content.vansmoothpar_edit.text()

        s.preserveevents = self._content.preserveevents_checkbox.isChecked()

        s.outputfileprefix = self._content.outputfileprefix_edit.text()

        return s
예제 #2
0
    def get_state(self):
        """ Returns a RunSetupScript with the state of Run_Setup_Interface
        Set up all the class parameters in RunSetupScrpt with values in the content
        """
        s = AdvancedSetupScript(self._instrument_name)

        s.pushdatapositive = str(self._content.pushdatapos_combo.currentText())
        s.unwrapref = self._content.unwrap_edit.text()
        s.lowresref = self._content.lowres_edit.text()
        s.cropwavelengthmin = str(self._content.cropwavelengthmin_edit.text())
        s.cropwavelengthmax = str(self._content.lineEdit_croppedWavelengthMax.text())
        s.removepropmppulsewidth = self._content.removepromptwidth_edit.text()
        s.maxchunksize = self._content.maxchunksize_edit.text()
        s.scaledata = self._content.scaledata_edit.text()
        s.filterbadpulses = self._content.filterbadpulses_edit.text()
        s.bkgdsmoothpars = self._content.bkgdsmoothpar_edit.text()

        s.stripvanadiumpeaks = self._content.stripvanpeaks_chkbox.isChecked()
        s.vanadiumfwhm = self._content.vanpeakfwhm_edit.text()
        s.vanadiumpeaktol = self._content.vanpeaktol_edit.text()
        s.vanadiumsmoothparams = self._content.vansmoothpar_edit.text()

        s.preserveevents = self._content.preserveevents_checkbox.isChecked()

        s.outputfileprefix = self._content.outputfileprefix_edit.text()

        return s
예제 #3
0
    def get_state(self):
        """ Returns a RunSetupScript with the state of Run_Setup_Interface
        Set up all the class parameters in RunSetupScrpt with values in the content
        """
        s = AdvancedSetupScript(self._instrument_name)

        #
        # Initialize AdvancedSetupScript static variables with widget's content
        #
        s.pushdatapositive = str(self._content.pushdatapos_combo.currentText())
        s.unwrapref = self._content.unwrap_edit.text()
        s.lowresref = self._content.lowres_edit.text()
        s.cropwavelengthmin = str(self._content.cropwavelengthmin_edit.text())
        s.cropwavelengthmax = str(
            self._content.lineEdit_croppedWavelengthMax.text())
        s.removepropmppulsewidth = self._content.removepromptwidth_edit.text()
        s.maxchunksize = self._content.maxchunksize_edit.text()
        s.scaledata = self._content.scaledata_edit.text()
        s.filterbadpulses = self._content.filterbadpulses_edit.text()
        s.bkgdsmoothpars = self._content.bkgdsmoothpar_edit.text()

        s.stripvanadiumpeaks = self._content.stripvanpeaks_chkbox.isChecked()
        s.vanadiumfwhm = self._content.vanpeakfwhm_edit.text()
        s.vanadiumpeaktol = self._content.vanpeaktol_edit.text()
        s.vanadiumsmoothparams = self._content.vansmoothpar_edit.text()
        s.vanadiumradius = self._content.vanadiumradius_edit.text()

        s.sampleformula = self._content.sampleformula_edit.text()
        s.samplenumberdensity = self._content.numberdensity_edit.text()
        s.measuredmassdensity = self._content.massdensity_edit.text()
        try:
            s.samplegeometry = {
                'Height': float(self._content.sampleheight_edit.text())
            }
        except ValueError:
            s.samplegeometry = {
                'Height': self._content.sampleheight_edit.text()
            }
        s.containershape = self._content.containertype_combo.currentText()
        s.typeofcorrection = self._content.correctiontype_combo.currentText()

        s.preserveevents = self._content.preserveevents_checkbox.isChecked()

        s.outputfileprefix = self._content.outputfileprefix_edit.text()
        # Caching options
        s.cache_dir_scan_save = self._content.cache_dir_edit_1.text()
        s.cache_dir_scan_1 = self._content.cache_dir_edit_2.text()
        s.cache_dir_scan_2 = self._content.cache_dir_edit_3.text()
        s.clean_cache = self._content.clean_cache_box.isChecked()

        return s