Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(30)  |  Call(30)  |  Derive(0)  |  Import(0)

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/math/fitting/SimpleFitConfigurationGui.py   pymca(Download)
    def loadConfiguration(self, filename):
        cfg= ConfigDict.ConfigDict()
        try:
            cfg.read(filename)
            self.initDir = os.path.dirname(filename)
    def saveConfiguration(self, filename):
        cfg = ConfigDict.ConfigDict(self.getConfiguration())
        if DEBUG:
            cfg.write(filename)
            self.initDir = os.path.dirname(filename)

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/pymca/SumRulesTool.py   pymca(Download)
 
        self.__savedConf = False
        confDict = ConfigDict.ConfigDict(self.getValuesDict())
        try:
            confDict.write(filename)
    def loadConfiguration(self):
        confDict = ConfigDict.ConfigDict()
        loadDir  = PyMcaDirs.outputDir
        filters   = 'Sum Rules Analysis files (*.sra);;All files (*.*)'
 

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/physics/xrf/XRFMCPyMca.py   pymca(Download)
    def fitFileChanged(self, ddict):
        #for the time being only one ...
        fitfile= ddict['filelist'][0]
        self.fitConfiguration = ConfigDict.ConfigDict()
        self.fitConfiguration.read(fitfile)
    def configurationFileChanged(self, ddict):
        configFile= ddict['filelist'][0]
        configuration = ConfigDict.ConfigDict()
        configuration.read(configFile)
        if not ('setup' in configuration['xrfmc']):
            # not a fit result but a configuration file
            # but this does not work
            newFile=ConfigDict.ConfigDict()
            newFile.read(pymcaFitFile)
            #perform a dummy fit till xmimsim-pymca is upgraded
                fitresult,result = mcaFit.startfit(digest=1)
                newFile = None
                nfile=ConfigDict.ConfigDict()
                nfile['result'] = result
                #nfile.write("tmpFitFileFromConfig.fit")
            else:
                nfile = ConfigDict.ConfigDict()

src/p/y/pymca-HEAD/PyMca5/PyMcaPhysics/xrf/XRFMC/XRFMCHelper.py   pymca(Download)
def getXRFMCCorrectionFactors(fitConfiguration, xmimsim_pymca=None, verbose=False):
    outputDir=tempfile.mkdtemp(prefix="pymcaTmp")
    if 'result' in fitConfiguration:
        # we have to create a .fit file with the information
        ddict = ConfigDict.ConfigDict()
        mcaFit.estimate()
        fitresult, result = mcaFit.startfit(digest=1)
        ddict=ConfigDict.ConfigDict()
        ddict['result'] = result
        ddict['xrfmc'] = fitConfiguration['xrfmc']
            raise ValueError("Inconsistent internal behaviour!")
         # recreate input in output directory
         new = ConfigDict.ConfigDict()
         new.read(fitFile)
         if os.path.exists(ddict['fit']):
def test(filename):
    fitConfig = ConfigDict.ConfigDict()
    fitConfig.read(filename)
    ddict = getXRFMCCorrectionFactors(fitConfig, verbose=True)
    fitConfig = None

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/physics/XASSelfattenuationWindow.py   pymca(Download)
    def loadConfiguration(self, filename):
        d = ConfigDict.ConfigDict()
        d.read(filename)
        self.setConfiguration(d['XAS'])
 
    def saveConfiguration(self, filename):
        d = ConfigDict.ConfigDict()

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/pymca/PyMcaMain.py   pymca(Download)
                else:
                    self.mcaWindow.showMaximized()
            currentConfigDict = ConfigDict.ConfigDict()
            try:
                defaultFileName = self.__getDefaultSettingsFile()
    def saveConfig(self, config, filename = None):
        d = ConfigDict.ConfigDict()
        d.update(config)
        if filename is None:
            filename = self.__getDefaultSettingsFile()
                del outfile
                return
            currentConfigDict = ConfigDict.ConfigDict()
            self.configDir  = os.path.dirname(filename)
            currentConfigDict.read(filename)

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/io/hdf5/QNexusWidget.py   pymca(Download)
    def _getConfigurationFromFile(self, fname):
        ddict = ConfigDict.ConfigDict()
        ddict.read(fname)
 
        keys = ddict.keys
            fname += '.ini'
 
        ddict = ConfigDict.ConfigDict()
        if "PyMcaDirs" in sys.modules:
            ddict['PyMca'] = {}

src/p/y/pymca-HEAD/PyMca5/PyMcaPhysics/xrf/McaAdvancedFitBatch.py   pymca(Download)
                useExistingResult = 1
                try:
                    dict = ConfigDict.ConfigDict()
                    dict.read(fitfile)
                    result = dict['result']
                if concentrations is not None:
                    try:
                        f=ConfigDict.ConfigDict()
                        f.read(outfile)
                        f['concentrations'] = concentrations

src/p/y/pymca-HEAD/PyMca5/PyMcaGui/pymca/PyMcaBatch.py   pymca(Download)
        if lst == self.fileList:
            if self._selection is not None:
                ddict = ConfigDict.ConfigDict()
                ddict['PyMcaBatch'] = {}
                ddict['PyMcaBatch']['filelist'] = lst
    else:
        if selection:
            tmpDict = ConfigDict.ConfigDict()
            tmpDict.read(listfile)
            tmpDict = tmpDict['PyMcaBatch']

src/p/y/pymca-HEAD/PyMca5/PyMcaPlugins/AdvancedAlignmentScanPlugin.py   pymca(Download)
        if len(filename) == 0:
            return
        inDict = ConfigDict.ConfigDict()
        try:
            inDict.read(filename)
            print('saveOptions -- Filename: "%s"' % filename)
        currentOrder = self.plugin.getOrder()
        outDict = ConfigDict.ConfigDict()
        llist, ddict = self.getDict()
        outDict['Order'] = {'Order': currentOrder}

  1 | 2  Next