    def get_padding_lengths(self) -> Dict[str, Dict[str, int]]:
        """
        Returns a dictionary of padding lengths, keyed by field name.  Each `Field` returns a
        mapping from padding keys to actual lengths, and we just key that dictionary by field name.
        """
        lengths = {}
        for field_name, field in self.fields.items():
            lengths[field_name] = field.get_padding_lengths()
        return lengths
Returns a dictionary of padding lengths, keyed by field name.  Each `Field` returns a
mapping from padding keys to actual lengths, and we just key that dictionary by field name.
allennlp/data/instance.py