<commit_before>
from core.event import EventType, EventQueue
from core.vm_machine_state import InputFilter, InputVerifier

class CloudSimulator:

    def __init__(self, config):
        self._server_of_vm = dict()
        self._config = config
        self._logger = None
        self._event_queue = None

    def simulate(self):
        self._initialize()
        stats = self._config.statistics
        stats.start()
        while True:
            event = self._event_queue.next_event()
            if event is None:
                break
            self._process_event(event)
            while event.time > stats.next_control_time:
                stats.persist()
        stats.finish()

    def verify_input(self):
        input_verifier = InputVerifier()
        input_verifier.set_config(self._config)
        if input_verifier.is_valid():
            print("Input is valid\n")
        else:
            print("Input is invalid\n")
            input_verifier.print_statistics()

    def filter_input(self):
        input_filter = InputFilter()
        input_filter.set_config(self._config)
        input_filter.filter()

    def _initialize(self):
        self._config.initialize()
        self._logger = self._config.getLogger(self)
        self._event_queue = EventQueue()
        self._event_queue.set_config(self._config)
        self._event_queue.initialize()

    def _process_event(self, event):
        strategies = self._config.strategies
        server = None

        if event.type == EventType.SUBMIT:
            self._config.statistics.notify_event('submit_events')
            server = strategies.scheduling.schedule_vm(event.vm)

        elif event.type == EventType.UPDATE:
            self._config.statistics.notify_event('update_events')
            self._config.environment.update_vm_demands(event.vm)
            server = self._config.environment.get_server_of_vm(event.vm.name)
            if server is not None:<commit_msg>Print verify statistcs even if input is valid<commit_after>
from core.event import EventType, EventQueue
from core.vm_machine_state import InputFilter, InputVerifier

class CloudSimulator:

    def __init__(self, config):
        self._server_of_vm = dict()
        self._config = config
        self._logger = None
        self._event_queue = None

    def simulate(self):
        self._initialize()
        stats = self._config.statistics
        stats.start()
        while True:
            event = self._event_queue.next_event()
            if event is None:
                break
            self._process_event(event)
            while event.time > stats.next_control_time:
                stats.persist()
        stats.finish()

    def verify_input(self):
        input_verifier = InputVerifier()
        input_verifier.set_config(self._config)
        if input_verifier.is_valid():
            print("Input is valid\n")
        else:
            print("Input is invalid\n")
        input_verifier.print_statistics()

    def filter_input(self):
        input_filter = InputFilter()
        input_filter.set_config(self._config)
        input_filter.filter()

    def _initialize(self):
        self._config.initialize()
        self._logger = self._config.getLogger(self)
        self._event_queue = EventQueue()
        self._event_queue.set_config(self._config)
        self._event_queue.initialize()

    def _process_event(self, event):
        strategies = self._config.strategies
        server = None

        if event.type == EventType.SUBMIT:
            self._config.statistics.notify_event('submit_events')
            server = strategies.scheduling.schedule_vm(event.vm)

        elif event.type == EventType.UPDATE:
            self._config.statistics.notify_event('update_events')
            self._config.environment.update_vm_demands(event.vm)
            server = self._config.environment.get_server_of_vm(event.vm.name)
            if server is not None:
{'fraction_non_alphanumeric': 0.08841463414634146, 'fraction_numerical': 0.0, 'mean_word_length': 2.2808333333333333, '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': '6796012', 'n_tokens_mistral': 1093, 'n_tokens_neox': 1072, 'n_words': 206}