Get an object from :class:`bytes`

        :param bytes data: stream of bytes to decode
        :param str encoding: character set used to decode the incoming
            bytes before calling the ``loads`` function.  This defaults
            to :attr:`default_encoding`
        :param dict content_parameters: optional :class:`dict` of
            content type parameters from the :mailheader:`Content-Type`
            header
        :returns: decoded :class:`object` instance

def from_bytes(self, data, encoding=None):
        """
        Get an object from :class:`bytes`

        :param bytes data: stream of bytes to decode
        :param str encoding: character set used to decode the incoming
            bytes before calling the ``loads`` function.  This defaults
            to :attr:`default_encoding`
        :param dict content_parameters: optional :class:`dict` of
            content type parameters from the :mailheader:`Content-Type`
            header
        :returns: decoded :class:`object` instance

        """
        return self._loads(data.decode(encoding or self.default_encoding))