

def ex_get_image_by_id(self, id):
    '\n        Gets a Base/Customer image in the Dimension Data Cloud given the id\n\n        Note: This first checks the base image\n              If it is not a base image we check if it is a customer image\n              If it is not in either of these a DimensionDataAPIException\n              is thrown\n\n        :param id: The id of the image\n        :type  id: ``str``\n\n        :rtype: :class:`NodeImage`\n        '
    try:
        return self.ex_get_base_image_by_id(id)
    except DimensionDataAPIException as e:
        if (e.code != 'RESOURCE_NOT_FOUND'):
            raise e
    return e.ex_get_customer_image_by_id(id)

dataset/ETHPy150Open apache/libcloud/libcloud/compute/drivers/dimensiondata.py DimensionDataNodeDriver.ex_get_image_by_id/VarMisuse@51/231 `self`->`e`