<commit_before>import sys
import copy
from time import time
import logging
from multiprocessing import current_process, Lock

if sys.version_info < (2,7):
    from pulsar.utils.fallbacks.dictconfig import dictConfig
else:
    from logging.config import dictConfig
    

SERVER_NAME = 'Pulsar'
NOLOG = 100


__all__ = ['SERVER_NAME',
           'getLogger',
           'process_global',
           'LogginMixin',
           'Synchronized',
           'LogSelf',
           'LogInformation']


LOG_LEVELS = {
        "critical": logging.CRITICAL,
        "error": logging.ERROR,
        "warning": logging.WARNING,
        "info": logging.INFO,
        "debug": logging.DEBUG,
        'none': None
    }


LOGGING_CONFIG = {
    'version': 1,
    'disable_existing_loggers': False,
    'formatters': {
        'verbose': {
            'format': '%(asctime)s [p=%(process)s,t=%(thread)s]\
 [%(levelname)s] [%(name)s] %(message)s',
            'datefmt': '%Y-%m-%d %H:%M:%S'
        },
        'verbose_color': {
            '()': 'pulsar.utils.tools.ColorFormatter',
            'format': '%(asctime)s [p=%(process)s,t=%(thread)s]\
 [%(levelname)s] [%(name)s] %(message)s',
            'datefmt': '%Y-%m-%d %H:%M:%S'
        },
        'simple': {
            'format': '%(asctime)s %(levelname)s %(message)s',
            'datefmt': '%Y-%m-%d %H:%M:%S'
        },
    },
    'handlers': {
        'silent': {
            'class': 'pulsar.utils.log.Silence',
        },
        'console': {
            'level': 'DEBUG',
            'class': 'logging.StreamHandler',
            'formatter': 'verbose_color'
        }
    },
    'filters ': {},
    'loggers': {}
}


def update_config(config, c):
    for name in ('handlers','formatters','filters','loggers'):
        if name in c:
            config[name].update(c[name])


class LocalMixin(object):
    
    @property
    def local(self):
        if not hasattr(self,'_local'):
            self._local = {}<commit_msg>logging tweak<commit_after>import sys
import copy
from time import time
import logging
from multiprocessing import current_process, Lock

if sys.version_info < (2,7):
    from pulsar.utils.fallbacks.dictconfig import dictConfig
else:
    from logging.config import dictConfig
    

SERVER_NAME = 'Pulsar'
NOLOG = 100


__all__ = ['SERVER_NAME',
           'getLogger',
           'process_global',
           'LogginMixin',
           'Synchronized',
           'LogSelf',
           'LogInformation']


LOG_LEVELS = {
        "critical": logging.CRITICAL,
        "error": logging.ERROR,
        "warning": logging.WARNING,
        "info": logging.INFO,
        "debug": logging.DEBUG,
        'none': None
    }


LOGGING_CONFIG = {
    'version': 1,
    'disable_existing_loggers': False,
    'formatters': {
        'verbose': {
            'format': '%(asctime)s [p=%(process)s,t=%(thread)s]\
 [%(levelname)s] [%(name)s] %(message)s',
            'datefmt': '%Y-%m-%d %H:%M:%S'
        },
        'verbose_color': {
            '()': 'pulsar.utils.tools.ColorFormatter',
            'format': '%(asctime)s [p=%(process)s,t=%(thread)s]\
 [%(levelname)s] [%(name)s] %(message)s',
            'datefmt': '%Y-%m-%d %H:%M:%S'
        },
        'simple': {
            'format': '%(asctime)s %(levelname)s %(message)s',
            'datefmt': '%Y-%m-%d %H:%M:%S'
        },
    },
    'handlers': {
        'silent': {
            'class': 'pulsar.utils.log.Silence',
        },
        'console': {
            'level': 'DEBUG',
            'class': 'logging.StreamHandler',
            'formatter': 'verbose_color'
        }
    },
    'filters ': {},
    'loggers': {},
    'root': {}
}


def update_config(config, c):
    for name in ('handlers','formatters','filters','loggers','root'):
        if name in c:
            config[name].update(c[name])


class LocalMixin(object):
    
    @property
    def local(self):
        if not hasattr(self,'_local'):
            self._local = {}
{'fraction_non_alphanumeric': 0.17664897649734648, 'fraction_numerical': 0.003032600454890068, 'mean_word_length': 2.156299840510367, 'pattern_counts': {'":': 10, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '875910', 'n_tokens_mistral': 1333, 'n_tokens_neox': 1305, 'n_words': 244}