Ejemplo n.º 1
0
def downloadBestWikiaImage(url):
    url2 = url.split('/revision')[0]
    file1 = downloadFile(url)
    print 'File 1 Downloaded. ',; sys.stdout.flush()
    file2 = downloadFile(url2)
    print 'File 2 Downloaded. ',; sys.stdout.flush()
    if file1.width > file2.width:
        return shrunkImage(file1, url)
    return shrunkImage(file2, url2)
Ejemplo n.º 2
0
def downloadBestWikiaImage(url):
    url2 = url.split('/revision')[0]
    file1 = downloadFile(url)
    print 'File 1 Downloaded. ',
    sys.stdout.flush()
    file2 = downloadFile(url2)
    print 'File 2 Downloaded. ',
    sys.stdout.flush()
    if file1.width > file2.width:
        return shrunkImage(file1, url)
    return shrunkImage(file2, url2)
Ejemplo n.º 3
0
def downloadShrunkedImage(url):
    downloaded = downloadFile(url)
    return shrunkImage(downloaded, url)
Ejemplo n.º 4
0
def downloadShrunkedImage(url):
    downloaded = downloadFile(url)
    return shrunkImage(downloaded, url)