@classmethod
def get_serializer(cls, value):
    """
        Get the serializer for a python object.

        :param value: The python object.
        """
    serializer = None
    try:
        serializer = cls._serializers[type(value)]
    except KeyError:
        for key, serializer_ in cls._serializers.items():
            if isinstance(value, key):
                serializer = serializer_
                break
    if serializer:
        serializer = serializer.get_specialized_serializer(value)
    return serializer
