<commit_before>import os
import sys
import subprocess
import jinja2
from metadata_extractor import CORDEXMetadataExtractor, obs4MIPSMetadataExtractor

# These should be modified. TODO: domains can also be made into separate group
# CORDEX domain

user_input = sys.argv[1:]
if len(user_input) == 4:
    domain, workdir, obs_dir, models_dir = user_input[:]
else:
    domain = 'NAM-44'

    # The output directory
    workdir = os.getcwd()+'/'+domain+'_analysis'
<commit_msg>CLIMATE-963 Enabling Python command line arguments for cordex.py - cordex.py has been updated<commit_after>import os
import sys
import subprocess
import jinja2
from metadata_extractor import CORDEXMetadataExtractor, obs4MIPSMetadataExtractor

# These should be modified. TODO: domains can also be made into separate group
# CORDEX domain

user_input = sys.argv[1:]
if len(user_input) == 4:
    domain, workdir, obs_dir, models_dir = user_input[:]
    models_dir = (models_dir+'/*').format(domain=domain)
else:
    domain = 'NAM-44'

    # The output directory
    workdir = os.getcwd()+'/'+domain+'_analysis'

{'fraction_non_alphanumeric': 0.09435707678075855, 'fraction_numerical': 0.013876040703052728, 'mean_word_length': 4.945054945054945, 'pattern_counts': {'":': 0, '<': 3, '<?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': '3704612', 'n_tokens_mistral': 353, 'n_tokens_neox': 339, 'n_words': 105}