images = response.xpath('//a/img')
for image in images:
    a_link = image.xpath('../@href').extract_first()
image_link = image.xpath('@src').extract_first()
XPath select image links - parent href link of img src only if it exists, else select img src link