def load(cls, data):
        """Create an object from JSON data.

        Parameters
        ----------
        data : `dict`
            JSON data.

        Returns
        ----------
        `object`
            Created object.

        Raises
        ------
        KeyError
            If `data` does not have the '__class__' key
            or the necessary class is not in the class group.
        """
        ret = cls.classes[data['__class__']]
        data_cls = data['__class__']
        del data['__class__']
        try:
            ret = ret(**data)
        finally:
            data['__class__'] = data_cls
        return ret
def load ( cls , data ) : ret = cls . classes [ data [ '__class__' ] ] data_cls = data [ '__class__' ] del data [ '__class__' ] try : ret = ret ( ** data ) finally : data [ '__class__' ] = data_cls return ret
Create an object from JSON data.

        Parameters
        ----------
        data : `dict`
            JSON data.

        Returns
        ----------
        `object`
            Created object.

        Raises
        ------
        KeyError
            If `data` does not have the '__class__' key
            or the necessary class is not in the class group.