def register_from_data(cls, key, format, data):
        """Register a image data using key"""

        if key in cls._stock:
            logger.info('Warning, replacing resource ' + str(key))
        cls._stock[key] = {'type': 'data', 'data': data, 'format': format }
        logger.info('%s registered as %s' % ('data', key))
Register a image data using key