python 下载图片

import requests
from PIL import Image
from io import BytesIO

url = 'http://image2.buslive.cn/shp/upload/2017/11/29_00545678.jpeg'
response = requests.get(url)
image = Image.open(BytesIO(response.content))
image.save('9.jpg')

  

posted on 2018-02-23 18:22  hailuo  阅读(241)  评论(0编辑  收藏  举报