<commit_before># emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
# vi: set ft=python sts=4 ts=4 sw=4 et:
'''
Created on 20 Apr 2010

logging options : INFO, DEBUG
hash_method : content, timestamp

@author: <NAME>
'''
import ConfigParser, os
from StringIO import StringIO
import os

homedir = os.environ['HOME']
default_cfg = StringIO("""
[logging]
workflow_level = INFO
filemanip_level = INFO
interface_level = INFO
log_directory = %s
log_size = 254000
log_rotate = 4

[execution]
plugin = Linear
stop_on_first_crash = false
stop_on_first_rerun = false
hash_method = content
single_thread_matlab = true
remove_node_directories = false
remove_unnecessary_outputs = true
use_relative_paths = false
"""%(homedir))

config = ConfigParser.ConfigParser()
config.readfp(default_cfg)
config.read([os.path.expanduser('~/.nipype.cfg'), 'nipype.cfg'])
<commit_msg>Added matplotlib_backend config option with Agg as default<commit_after># emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
# vi: set ft=python sts=4 ts=4 sw=4 et:
'''
Created on 20 Apr 2010

logging options : INFO, DEBUG
hash_method : content, timestamp

@author: <NAME>
'''
import ConfigParser, os
from StringIO import StringIO
import os

homedir = os.environ['HOME']
default_cfg = StringIO("""
[logging]
workflow_level = INFO
filemanip_level = INFO
interface_level = INFO
log_directory = %s
log_size = 254000
log_rotate = 4

[execution]
plugin = Linear
stop_on_first_crash = false
stop_on_first_rerun = false
hash_method = content
single_thread_matlab = true
remove_node_directories = false
remove_unnecessary_outputs = true
use_relative_paths = false
matplotlib_backend = Agg
"""%(homedir))

config = ConfigParser.ConfigParser()
config.readfp(default_cfg)
config.read([os.path.expanduser('~/.nipype.cfg'), 'nipype.cfg'])

{'fraction_non_alphanumeric': 0.11567982456140351, 'fraction_numerical': 0.01864035087719298, 'mean_word_length': 5.992337164750958, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '883731', 'n_tokens_mistral': 646, 'n_tokens_neox': 609, 'n_words': 165}