<commit_before># ------------------------------------------------------------------------
# coding=utf-8
# ------------------------------------------------------------------------

from __future__ import absolute_import, unicode_literals

from io import BytesIO
import re

# Try to import PIL in either of the two ways it can end up installed.
try:
    from PIL import Image
except ImportError:
    try:
        import Image
    except ImportError:
        # Django seems to silently swallow the ImportError under certain
        # circumstances. Raise a generic exception explaining why we are
        # unable to proceed.
        raise Exception('FeinCMS requires PIL to be installed')

from django import template
from django.utils.encoding import force_text, python_2_unicode_compatible
from django.core.files.storage import default_storage
from django.core.files.base import ContentFile
from django.utils import six

from feincms import settings
<commit_msg>Pillow has been out long enough to drop the old "import Image" fallback<commit_after># ------------------------------------------------------------------------
# coding=utf-8
# ------------------------------------------------------------------------

from __future__ import absolute_import, unicode_literals

from io import BytesIO
from PIL import Image
import re

from django import template
from django.utils.encoding import force_text, python_2_unicode_compatible
from django.core.files.storage import default_storage
from django.core.files.base import ContentFile
from django.utils import six

from feincms import settings

{'fraction_non_alphanumeric': 0.21572327044025158, 'fraction_numerical': 0.0025157232704402514, 'mean_word_length': 1.9906015037593985, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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}}
{'dir': 'git-commits-cleaned', 'id': '1071321', 'n_tokens_mistral': 352, 'n_tokens_neox': 345, 'n_words': 147}