<commit_before>import os
import Fitter.make_xml_configs as fitc
import PidHisto.make_xml_configs as pidc
import PostCorr.make_xml_configs as postc
pjoin = os.path.join


# all of them should define this
t_config_file = "{state}_{plc}.{ext}"
t_data_file = "{plc}.{ext}"
# all of them should define this
t_product_file = "Present_{state}_{plc}.{ext}"



def write_conf(  output_path, config_path ="./" ) :
	template = """
<?xml version="1.0" encoding="UTF-8"?>
<config>

	<jobType>PresentPidYield</jobType>

	<PidYieldPresenter>
		<Logger color="true" logLevel="info" globalLogLevel="warning" />
		<Reporter> <output url="{report_file}" width="800" height="500" /> </Reporter>	

		<input plc="{plc}">
			<fit url="{fit_file}" />
			<ps url="{histo_file}" />
			
		</input>

		<output path="{output_path}">
			<data url="{product_file}"/>
		</output>

		<FitRange >
			<ptBins min="0" max="30" />
			<centralityBins>0, 1, 2, 3, 4, 5, 6</centralityBins>
			<charges>1, -1</charges>

		</FitRange>

		<LastYieldBin>
			<Pi p="22" n="22" />
			<K p="22" n="22"/> 
			<P p="22" n="22"/> 
		</LastYieldBin>

		<nColl> 787.915, 633.514, 454.215, 282.678, 167.971, 71.739, 18.3058 </nColl>
		<nPart ptBin="15" > 337.893, 289.13, 225.593, 158.731, 108.064, 56.7823, 19.4839 </nPart>
		<colors>632, 416, 600, 616, 800, 880, 820, 840, 860, 900</colors>


		<centralityLabels>0-5%, 5-10%, 10-20%, 20-30%, 30-40%, 40-60%, 60-80% </centralityLabels>

<commit_msg>tweaking presenter<commit_after>import os
import Fitter.make_xml_configs as fitc
import PidHisto.make_xml_configs as pidc
import PostCorr.make_xml_configs as postc
pjoin = os.path.join


# all of them should define this
t_config_file = "{state}_{plc}.{ext}"
t_data_file = "{plc}.{ext}"
# all of them should define this
t_product_file = "Present_{state}_{plc}.{ext}"



def write_conf(  output_path, config_path ="./" ) :
	template = """
<?xml version="1.0" encoding="UTF-8"?>
<config>

	<jobType>PresentPidYield</jobType>

	<PidYieldPresenter>
		<Logger color="true" logLevel="info" globalLogLevel="warning" />
		<Reporter> <output url="{report_file}" width="800" height="500" /> </Reporter>	

		<input plc="{plc}">
			<fit url="{fit_file}" />
			<ps url="{histo_file}" />
			
		</input>

		<output path="{output_path}">
			<data url="{product_file}"/>
		</output>

		<FitRange >
			<ptBins min="0" max="30" />
			<centralityBins>0, 1, 2, 3, 4, 5, 6</centralityBins>
			<charges>1, -1</charges>

		</FitRange>

		<LastYieldBin>
			<Pi p="24" n="24" />
			<K p="24" n="24"/> 
			<P p="24" n="24"/> 
		</LastYieldBin>

		<nColl> 787.915, 633.514, 454.215, 282.678, 167.971, 71.739, 18.3058 </nColl>
		<nPart ptBin="15" > 337.893, 289.13, 225.593, 158.731, 108.064, 56.7823, 19.4839 </nPart>
		<colors>632, 416, 600, 616, 800, 880, 820, 840, 860, 900</colors>


		<centralityLabels>0-5%, 5-10%, 10-20%, 20-30%, 30-40%, 40-60%, 60-80% </centralityLabels>


{'fraction_non_alphanumeric': 0.20006898930665748, 'fraction_numerical': 0.11866160745084511, 'mean_word_length': 4.06993006993007, 'pattern_counts': {'":': 0, '<': 75, '<?xml version=': 2, '>': 75, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 8}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6182214', 'n_tokens_mistral': 1559, 'n_tokens_neox': 1199, 'n_words': 259}