<commit_before>import os
import random


class atomic_file(file):
    # Simple class that writes to a temp file and moves it on close()
    # Also cleans up the temp file if close is not invoked
    def __init__(self, path):
        self.__tmp_path = path + '-luigi-tmp-%09d' % random.randrange(0, 999999999)
        self.path = path
        super(atomic_file, self).__init__(self.__tmp_path, 'w')
<commit_msg>Always produce temp output under /tmp.<commit_after>import os
import random


class atomic_file(file):
    # Simple class that writes to a temp file and moves it on close()
    # Also cleans up the temp file if close is not invoked
    def __init__(self, path):
        # Extra slash to support relative paths.
        self.__tmp_path = '/tmp/' + path + '-luigi-tmp-%09d' % random.randrange(0, 999999999)
        self.path = path
        super(atomic_file, self).__init__(self.__tmp_path, 'w')

{'fraction_non_alphanumeric': 0.09845132743362832, 'fraction_numerical': 0.02654867256637168, 'mean_word_length': 3.1513761467889907, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, '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': '7434943', 'n_tokens_mistral': 291, 'n_tokens_neox': 266, 'n_words': 98}