'Returns a dict with image data for the given opaque image id.
:param context: The context object to pass to image client
:param image_id: The UUID of the image
:param include_locations: (Optional) include locations in the returned
dict of information if the image service API
supports it. If the image service API does
not support the locations attribute, it will
still be included in the returned dict, as an
empty list.
:param show_deleted: (Optional) show the image even the status of
image is deleted.'

def show(self, context, image_id, include_locations=False, show_deleted=True):

    try:
        image = self._client.call(context, 2, 'get', image_id)
    except Exception:
        _reraise_translated_image_exception(image_id)
    if ((not show_deleted) and getattr(image, 'deleted', False)):
        raise exception.ImageNotFound(image_id=image_id)
    if (not _is_image_available(context, image)):
        raise exception.ImageNotFound(image_id=image_id)
    image = _translate_from_glance(image, include_locations=include_locations)
    if include_locations:
        locations = (image.get('locations', None) or [])
        du = image.get('direct_url', None)
        if du:
            locations.append({'url': du, 'metadata': {}})
        image['locations'] = locations
    return image
