<commit_before>#!/usr/bin/env python

import sys

# import statepoint
sys.path.insert(0, '../../src/utils')
import statepoint

# read in statepoint file
if len(sys.argv) > 1:
    sp = statepoint.StatePoint(sys.argv[1])
else:
    sp = statepoint.StatePoint('statepoint.10.binary')
sp.read_results()

# set up output string
outstr = ''
 
# write out k-combined
outstr += 'k-combined:\n'
outstr += "{0:12.6E} {1:12.6E}\n".format(sp.k_combined[0], sp.k_combined[1])

# write results to file
with open('results_test.dat','w') as fh:
    fh.write(outstr)<commit_msg>Fix import for statepoint for test_union_energy_grids<commit_after>#!/usr/bin/env python

import sys

sys.path.insert(0, '../../src/utils')
from openmc.statepoint import StatePoint

# read in statepoint file
if len(sys.argv) > 1:
    print(sys.argv)
    sp = StatePoint(sys.argv[1])
else:
    sp = StatePoint('statepoint.10.binary')
sp.read_results()

# set up output string
outstr = ''

# write out k-combined
outstr += 'k-combined:\n'
outstr += "{0:12.6E} {1:12.6E}\n".format(sp.k_combined[0], sp.k_combined[1])

# write results to file
with open('results_test.dat','w') as fh:
    fh.write(outstr)
{'fraction_non_alphanumeric': 0.16810344827586207, 'fraction_numerical': 0.02586206896551724, 'mean_word_length': 4.253393665158371, 'pattern_counts': {'":': 0, '<': 3, '<?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': '7545265', 'n_tokens_mistral': 456, 'n_tokens_neox': 443, 'n_words': 97}