<jupyter_start><jupyter_text>Python module/package imports for this chapter<jupyter_code>import math, json, collections, itertools
import numpy as np
import matplotlib.pyplot as pp
%matplotlib inline
from mpl_toolkits.basemap import Basemap
import geopy<jupyter_output><empty_output><jupyter_text>Code and data needed from previous videos<jupyter_code>medal = collections.namedtuple('medal',['year','athlete','team','event'])
medals = [medal(*line.strip().split('\t')) for line in open('goldmedals.txt','r')]<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.12639405204460966, 'fraction_numerical': 0.0, 'mean_word_length': 10.0, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, '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}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '599997', 'license': 'MIT', 'n_tokens_mistral': 179, 'n_tokens_neox': 179, 'n_words': 39, 'path': 'sandbox/efficientPy/Exercise Files/chapter2/02_08/02_08_challenge_begin.ipynb', 'repo_name': 'IvanaEscobar/sandbox', 'size': '538'}