Changeset c155a16 in sasview for src/sas/sascalc/pr


Ignore:
Timestamp:
Apr 4, 2017 12:06:27 PM (8 years ago)
Author:
Ricardo Ferraz Leal <ricleal@…>
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:
463e7ffc
Parents:
6722fae
Message:

Logging is now logger

Location:
src/sas/sascalc/pr
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sascalc/pr/invertor.py

    r2c60f304 rc155a16  
    1818from scipy import optimize 
    1919from sas.sascalc.pr.core.pr_inversion import Cinvertor 
     20 
     21logger = logging.getLogger() 
    2022 
    2123def help(): 
     
    495497            # We were not able to estimate the errors 
    496498            # Return an empty error matrix 
    497             logging.error(sys.exc_value) 
     499            logger.error(sys.exc_value) 
    498500 
    499501        # Keep a copy of the last output 
     
    541543            # number of terms 
    542544            best_alpha, _, _ = self.estimate_alpha(self.nfunc) 
    543             logging.warning("Invertor.estimate_numterms: %s" % sys.exc_value) 
     545            logger.warning("Invertor.estimate_numterms: %s" % sys.exc_value) 
    544546            return self.nfunc, best_alpha, "Could not estimate number of terms" 
    545547 
  • src/sas/sascalc/pr/num_term.py

    rb699768 rc155a16  
    55import logging 
    66from sas.sascalc.pr.invertor import Invertor 
     7 
     8logger = logging.getLogger() 
    79 
    810class NTermEstimator(object): 
     
    180182                data_err = numpy.append(data_err, err) 
    181183            except: 
    182                 logging.error(sys.exc_value) 
     184                logger.error(sys.exc_value) 
    183185 
    184186    return data_x, data_y, data_err 
Note: See TracChangeset for help on using the changeset viewer.