code: def test_process_results_overall(seed: int):
      rng = np.random.default_rng(seed=seed)
      (
          per_session_results,
          preceding_user_turn_numbers_used_per_marker,
      ) = _generate_random_examples(num_markers=3, rng=rng)
      markers = sorted(
          preceding_user_turn_numbers_used_per_marker.keys()
      )
      num_sessions = len(per_session_results)
  
      stats = MarkerStatistics()
      for session_idx, results in enumerate(per_session_results):
          stats.process(
              session_idx=session_idx,
              sender_id=str(rng.choice(100)),
              meta_data_on_relevant_events_per_marker=results,
          )
  
      assert stats.num_sessions == num_sessions
      for marker in markers:
          # count how often we generated some results for a session:
          number_lists = preceding_user_turn_numbers_used_per_marker[
              marker
          ]
          applied_at_least_once = sum(
              len(sub_list) > 0 for sub_list in number_lists
          )
          # and compare that to the expected count:
          assert (
              stats.count_if_applied_at_least_once[marker]
              == applied_at_least_once
          )
          # check if we collected the all the "preceding user turn numbers"
          concatenated_numbers = list(
              itertools.chain.from_iterable(
                  preceding_user_turn_numbers_used_per_marker[marker]
              )
          )
          assert (
              stats.num_preceding_user_turns_collected[marker]
              == concatenated_numbers
          )
  
file_path: rasa/tests/core/evaluation/test_marker_stats.py
imports: import csv
  from pathlib import Path
  from typing import Dict, List, Text, Tuple
  import itertools
  import pytest
  import numpy
  from rasa.core.evaluation.marker_stats import EventMetaData, MarkerStatistics, compute_statistics
label_desc: Use image node_id 6 for calling a global function with example usage: test_process_results_overall(seed) without return types