<jupyter_start><jupyter_text>Cloning the pyprobml repo<jupyter_code>!git clone https://github.com/probml/pyprobml 
%cd pyprobml/scripts
%%capture
%load_ext autoreload 
%autoreload 2



DISCLAIMER = 'WARNING : Editing in VM - changes lost after reboot!!'
from google.colab import files

def interactive_script(script, i=True):
  if i:
    s = open(script).read()
    if not s.split('\n', 1)[0]=="## "+DISCLAIMER:
      open(script, 'w').write(
          f'## {DISCLAIMER}\n' + '#' * (len(DISCLAIMER) + 3) + '\n\n' + s)
    files.view(script)
    %run $script
  else:
      %run $script<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.16123778501628663, 'fraction_numerical': 0.006514657980456026, 'mean_word_length': 3.880952380952381, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 1, '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}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '129211', 'license': 'MIT', 'n_tokens_mistral': 247, 'n_tokens_neox': 232, 'n_words': 52, 'path': 'notebooks/figures/chapter22_figures.ipynb', 'repo_name': 'AFIT-CSCE623/pyprobml', 'size': '614'}