code: def test_janitor7():
      # Same as above but now we add 9 filths and expect the same result, the following test does 10.
  
      sequence = (
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "FILTH. lots of dirty filtHy FIlTh "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "FILTH. lots of filtHy dirty FIlTh "
          "FILTH. lots of filtHy dirty FIlTh "
          "FILTH. lots of filtHy dirty FIlTh "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
          "This is a @line #containing a certain number of characters, 76 to be exact. "
      )
  
      filths = [
          "filth lots of dirty filthy filth",
          "filth lots of filthy dirty filth",
      ]
  
      expected_result = ""
  
      janitor = Janitor(
          ngram_n=6,
          window_to_remove=200,
          too_dirty_cutoff=10,
          minimum_slice_length=200,
      )
      result = janitor.clean_python(sequence)
      result = "".join(result)
      assert result == sequence
  
      for filth in filths:
          janitor.register_contaminant(filth)
      assert janitor.dirt_ngrams == set(filths)
  
      result = janitor.clean_python(sequence)
      result = "".join(result)
      assert result == expected_result
  
file_path: lm-evaluation-harness/tests/test_janitor.py
imports: import re
  from collections import defaultdict
  from lm_eval.decontamination.janitor import Janitor, form_ngrams, word_ngrams, split_indices, word_ngrams_indices
label_desc: Use image node_id 12 for calling a global function with example usage: test_janitor7() without return types