<jupyter_start><jupyter_text>entropy_evaluator> Entropy evaluator.<jupyter_code># export
from abc import ABCMeta, abstractmethod
from uid3.data import Data
# export
class EntropyEvaluator:
    __metaclass__ = ABCMeta

    @abstractmethod
    def calculate_entropy(self, data: Data) -> float: 
        raise NotImplementedError<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.07303370786516854, 'fraction_numerical': 0.0028089887640449437, 'mean_word_length': 5.611111111111111, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, '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': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '391899', 'license': 'Apache-2.0', 'n_tokens_mistral': 117, 'n_tokens_neox': 116, 'n_words': 26, 'path': 'src/entropy_evaluator.ipynb', 'repo_name': 'AnetaKaczynska/uid3', 'size': '356'}