d is a dict

def cast_number_strings_to_integers(d):
    """d is a dict"""
    for k, v in d.items():
        # print type(v)
        if determine_if_str_or_unicode(v):
            if v.isdigit():
                d[k] = int(v)
    return d