示例#1
0
def gatys_et_al_2017_images(
    root: Optional[str] = None, download: bool = True, overwrite: bool = False
):
    images = {
        "house": DownloadableImage(
            "https://associateddesigns.com/sites/default/files/plan_images/main/craftsman_house_plan_tillamook_30-519-picart.jpg",
            title="House Concept Tillamook",
            date="2014",
            md5="5629bf7b24a7c98db2580ec2a8d784e9",
        ),
        "watertown": DownloadableImage(
            "https://ae01.alicdn.com/img/pb/136/085/095/1095085136_084.jpg",
            title="Watertown",
            author="Shop602835 Store",
            md5="4cc98a503da5ce6eab0649b09fd3cf77",
        ),
        "wheat_field": DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/thumb/c/ce/Wheat-Field-with-Cypresses-%281889%29-Vincent-van-Gogh-Met.jpg/1920px-Wheat-Field-with-Cypresses-%281889%29-Vincent-van-Gogh-Met.jpg",
            title="Wheat Field with Cypresses",
            author="Vincent van Gogh",
            date="1889",
            license=ExpiredCopyrightLicense(1890),
            md5="bfd085d7e800459c8ffb44fa404f73c3",
        ),
        "schultenhof": DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/8/82/Schultenhof_Mettingen_Bauerngarten_8.jpg",
            title="Schultenhof Mettingen Bauerngarten 8",
            author="J.-H. Janßen",
            date="July 2010",
            license=CreativeCommonsLicense(("by", "sa"), "3.0"),
            md5="23f75f148b7b94d932e599bf0c5e4c8e",
        ),
        "starry_night": DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/9/94/Starry_Night_Over_the_Rhone.jpg",
            title="Starry Night Over the Rhone",
            author="Vincent Willem van Gogh",
            date="1888",
            license=ExpiredCopyrightLicense(1890),
            md5="406681ec165fa55c26cb6f988907fe11",
        ),
    }
    return DownloadableImageCollection(
        images, root=root, download=download, overwrite=overwrite
    )
示例#2
0
 def __init__(self) -> None:
     image_meta = (
         ("angel", "Eole Wind", "41b058edd2091eec467d37054a8c01fb"),
         ("arch", "James Marvin Phelps", "9378e3a129f021548ba26b99ae445ec9"),
         ("athletes", "Nathan Congleton", "6b742bd1b46bf9882cc176e0d255adab"),
         ("barn", "MrClean1982", "32abf24dd439940cf9a1265965b5e910"),
         ("berries", "HelmutZen", "58fea65145fa0bd222800d4f8946d815"),
         ("cabbage", "Leonard Chien", "19304a80d2ca2389153562700f0aab53"),
         ("cat", "Theen Moy", "de3331050c660e688463fa86c76976c4"),
         ("city", "Rob Schneider", "84e17b078ede986ea3e8f70e0a24195e"),
         ("daisy", "mgaloseau", "f3901d987490613238ef01977f9fac77"),
         ("darkwoods", "JB Banks", "f4ccbf37b3d5d3a1ca734bb65464151b"),
         ("desert", "Charles Roffey", "4a9db691d203dd693b14090b9e49f791"),
         ("headlight", "Photos By Clark", "1d4723535ea7dee84969f0c082445ad5"),
         ("mac", "Martin Kenney", "4df4e0dafe5468b86138839f68beb84d"),
         ("mountains", "Jenny Pansing", "1ea43310f2d85b271827634c733b6257"),
         ("oparara", "trevorklatko", "1adcc54d9a390b2492ee6e71acac13fd"),
         ("rimlighting", "Paul Stevenson", "8878a60ccd81e7b2ff05089cdf54773b"),
         ("snow", "John Anes", "60d55728e28d39114d0035c04c9e4495"),
         ("tomatoes", "Greg Myers", "3ffcdc427060171aabf433181cef7c52"),
         ("toque", "sicknotepix", "34fcf032b5d87877a7fc95629efb94e8"),
         ("yemeni", "Richard Messenger", "dd1e81d885cdbdd44f8d504e3951fb48"),
     )
     images = OrderedDict(
         [
             (
                 name,
                 DownloadableImage(
                     name_to_url(name),
                     title=name,
                     author=author,
                     license=NPRgeneralLicense(),
                     md5=md5,
                 ),
             )
             for name, author, md5 in image_meta
         ]
     )
     super().__init__(images)
示例#3
0
def li_wand_2016_images(
    root: Optional[str] = None, download: bool = True, overwrite: bool = False
):

    images = {
        "emma": DownloadableImage(
            "https://live.staticflickr.com/1/2281680_656225393e_o_d.jpg",
            author="monsieuricon (mricon)",
            title="Emma",
            date="17.12.2004",
            transform=transforms("mricon"),
            license=CreativeCommonsLicense(("by", "sa"), "2.0"),
            note=image_note("https://www.flickr.com/photos/mricon/2281680/"),
            md5="7a10a2479864f394b4f06893b9202915",
        ),
        "jenny": DownloadableImage(
            "https://live.staticflickr.com/8626/16426686859_f882b3d317_o_d.jpg",
            author="Vidar Schiefloe (lydhode)",
            title="Jenny",
            date="06.02.2015",
            license=CreativeCommonsLicense(("by", "sa"), "2.0"),
            transform=transforms("lydhode"),
            note=image_note(
                "https://www.flickr.com/photos/lydhode/16426686859/", mirror=True,
            ),
            md5="5b3442909ff850551c9baea433319508",
        ),
        "blue_bottle": DownloadableImage(
            "https://raw.githubusercontent.com/chuanli11/CNNMRF/master/data/content/potrait1.jpg",
            title="Blue Bottle",
            author="Christopher Michel (cmichel67)",
            date="02.09.2014",
            license=NoLicense(),
            note=image_note("https://www.flickr.com/photos/cmichel67/15112861945"),
            md5="cb29d11ef6e1be7e074aa58700110e4f",
        ),
        "self-portrait": DownloadableImage(
            "https://raw.githubusercontent.com/chuanli11/CNNMRF/master/data/style/picasso.jpg",
            title="Self-Portrait",
            author="Pablo Ruiz Picasso",
            date="1907",
            license=ExpiredCopyrightLicense(1973),
            note=image_note("https://www.pablo-ruiz-picasso.net/images/works/57.jpg"),
            md5="4bd9c963fd52feaa940083f07e259aea",
        ),
        "s": DownloadableImage(
            "https://live.staticflickr.com/7409/9270411440_cdc2ee9c35_o_d.jpg",
            author="theilr",
            title="S",
            date="18.09.2011",
            license=CreativeCommonsLicense(("by", "sa"), "2.0"),
            transform=transforms("theilr"),
            note=image_note("https://www.flickr.com/photos/theilr/9270411440/"),
            md5="5d78432b5ca703bb85647274a5e41656",
        ),
        "composition_viii": DownloadableImage(
            "https://www.wassilykandinsky.net/images/works/50.jpg",
            title="Composition VIII",
            author="Wassily Kandinsky",
            date="1923",
            license=ExpiredCopyrightLicense(1944),
            md5="c39077aaa181fd40d7f2cd00c9c09619",
        ),
    }

    return DownloadableImageCollection(
        images, root=root, download=download, overwrite=overwrite
    )
示例#4
0
def ulyanov_et_al_2016_images(root: Optional[str] = None,
                              download: bool = True,
                              overwrite: bool = False):

    base_ulyanov = (
        "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/master/data/"
    )
    base_ulyanov_suppl = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/supplementary/"
    readme_ulyanov = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/data/readme_pics/"
    content_base_ulyanov = urljoin(base_ulyanov, "readme_pics/")
    content_images = {
        "karya":
        DownloadableImage(
            urljoin(content_base_ulyanov, "karya.jpg"),
            md5="232b2f03a5d20c453a41a0e6320f27be",
        ),
        "tiger":
        DownloadableImage(
            urljoin(content_base_ulyanov, "tiger.jpg"),
            md5="e82bf374da425fb2c2e2a35a5a751989",
        ),
        "neckarfront":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/0/00/Tuebingen_Neckarfront.jpg",
            title="Tübingen Neckarfront",
            author="Andreas Praefcke",
            license=CreativeCommonsLicense(("by", ), version="3.0"),
            md5="dc9ad203263f34352e18bc29b03e1066",
            file="tuebingen_neckarfront__andreas_praefcke.jpg",
        ),
        "CheHigh":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/5/58/CheHigh.jpg",
            title="CheHigh",
            author="Alberto Korda",
            date="1960",
            license=ExpiredCopyrightLicense(1960),
            md5="cffc0768090c5a705cbb30fdc24c3e64",
            file="CheHigh.jpg",
        ),
        "The_Tower_of_Babel":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/f/fc/Pieter_Bruegel_the_Elder_-_The_Tower_of_Babel_%28Vienna%29_-_Google_Art_Project_-_edited.jpg",
            title="The Tower of Babel",
            author="Pieter Bruegel",
            date="1563",
            license=ExpiredCopyrightLicense(1563),
            md5="1e113716c8aad6c2ca826ae0b83ffc76",
            file="the_tower_of_babel.jpg",
        ),
        "bird":
        DownloadableImage(
            urljoin(base_ulyanov_suppl, "bird.jpg"),
            md5="74dde9fad4749e7ff3cd4eca6cb43d0d",
        ),
        "kitty":
        DownloadableImage(
            urljoin(readme_ulyanov, "kitty.jpg"),
            md5="98262bd8f5ae25f8329158d2c2c66ad0",
        ),
    }

    texture_base_ulyanov = urljoin(base_ulyanov, "textures/")
    base_ulyanov_suppl_texture = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/supplementary//texture_models/"

    texture_images = {
        "cezanne":
        DownloadableImage(
            urljoin(texture_base_ulyanov, "cezanne.jpg"),
            md5="fab6d360c361c38c331b3ee5ef0078f5",
        ),
        "bricks":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_texture, "bricks.png"),
            md5="1e13818e1fbefbd22f110a1c2f781d40",
        ),
        "pebble":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_texture, "pebble.png"),
            md5="5b5e5aa6c579e42e268058a94d683a6c",
        ),
        "pixels":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_texture, "pixelcity_windows2.jpg"),
            md5="53026a8411e7c26e959e36d3223f3b8f",
        ),
        "peppers":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_texture, "red-peppers256.o.jpg"),
            md5="16371574a10e0d10b88b807204c4f546",
        ),
    }
    base_johnson = (
        "https://raw.githubusercontent.com/jcjohnson/fast-neural-style/master/images/"
    )
    style_base_johnson = urljoin(base_johnson, "styles/")

    base_ulyanov_suppl_style = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/supplementary//stylization_models/"
    style_images = {
        "candy":
        DownloadableImage(
            urljoin(style_base_johnson, "candy.jpg"),
            md5="00a0e3aa9775546f98abf6417e3cb478",
        ),
        "the_scream":
        DownloadableImage(
            urljoin(style_base_johnson, "the_scream.jpg"),
            md5="619b4f42c84d2b62d3518fb20fa619c2",
        ),
        "Jean Metzinger":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/c/c9/Robert_Delaunay%2C_1906%2C_Portrait_de_Metzinger%2C_oil_on_canvas%2C_55_x_43_cm%2C_DSC08255.jpg",
            title="Portrait of Jean Metzinger",
            author="Jean Metzinger",
            date="1906",
            license=ExpiredCopyrightLicense(1906),
            md5="3539d50d2808b8eec5b05f892d8cf1e1",
            file="jean_metzinger.jpg",
        ),
        "mosaic":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "mosaic.jpg"),
            md5="4f05f1e12961cebf41bd372d909342b3",
        ),
        "pleades":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "pleades.jpg"),
            md5="6fc41ac30c2852a5454a0ead2f479dc9",
        ),
        "starry":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "starry.jpg"),
            md5="c6d94f7962466b2e80a64ae82523242a",
        ),
        "turner":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "turner.jpg"),
            md5="7fdd9603a5182dcef23d7fb1c5217888",
        ),
    }
    return DownloadableImageCollection(
        {
            **texture_images,
            **content_images,
            **style_images
        },
        root=root,
        download=download,
        overwrite=overwrite,
    )
示例#5
0
def images() -> DownloadableImageCollection:
    """Collection of images used in the usage examples.

    .. note::

        You can use

        .. code-block:: python

            print(images())

        to get a list of all available images.
    """
    return DownloadableImageCollection({
        "bird1":
        DownloadableImage(
            "https://download.pystiche.org/images/bird1.jpg",
            file="bird1.jpg",
            author="gholmz0",
            date="09.03.2013",
            license=PixabayLicense(),
            md5="ca869559701156c66fc1519ffc26123c",
            note=
            "https://pixabay.com/photos/bird-wildlife-australian-bird-1139734/",
        ),
        "paint":
        DownloadableImage(
            "https://download.pystiche.org/images/paint.jpg",
            file="paint.jpg",
            author="garageband",
            date="03.07.2017",
            license=PixabayLicense(),
            md5="a991e222806ef49d34b172a67cf97d91",
            note=
            "https://pixabay.com/de/photos/abstrakt-kunst-hintergrund-farbe-2468874/",
        ),
        "bird2":
        DownloadableImage(
            "https://download.pystiche.org/images/bird2.jpg",
            file="bird2.jpg",
            author="12019",
            date="09.04.2012",
            license=PixabayLicense(),
            md5="2398e8f6d102b9b8de7c74d4c73b71f4",
            note=
            "https://pixabay.com/photos/bird-wildlife-sky-clouds-nature-92956/",
        ),
        "mosaic":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/2/23/Mosaic_ducks_Massimo.jpg",
            file="mosaic.jpg",
            author="Marie-Lan Nguyen",
            date="2006",
            license=PublicDomainLicense(),
            md5="5b60cd1724395f7a0c21dc6dd006f8ae",
        ),
        "castle":
        DownloadableImage(
            "https://download.pystiche.org/images/castle.jpg",
            file="castle.jpg",
            author="Christian Hänsel",
            date="23.03.2014",
            license=PixabayLicense(),
            md5="9d085fac77065e0da66629162f759f90",
            note=
            "https://pixabay.com/de/photos/lemgo-brake-schloss-br%C3%BCcke-310586/",
            guides=DownloadableImageCollection(
                {
                    "building":
                    DownloadableImage(
                        "https://download.pystiche.org/images/castle/building.png",
                        file="building.png",
                        author="Julian Bültemeier",
                        license=PublicDomainLicense(),
                        md5="680bd875f4fdb919d446d6210cbe1035",
                    ),
                    "sky":
                    DownloadableImage(
                        "https://download.pystiche.org/images/castle/sky.png",
                        file="sky.png",
                        author="Julian Bültemeier",
                        license=PublicDomainLicense(),
                        md5="c4d5f18b3ca22a1ff879f40ca797ed26",
                    ),
                    "water":
                    DownloadableImage(
                        "https://download.pystiche.org/images/castle/water.png",
                        file="water.png",
                        author="Julian Bültemeier",
                        license=PublicDomainLicense(),
                        md5="2642552e8c98b6a63f24dd67bb54e2a3",
                    ),
                }, ),
        ),
        "church":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/a/ad/Vincent_van_Gogh_-_The_Church_in_Auvers-sur-Oise%2C_View_from_the_Chevet_-_Google_Art_Project.jpg",
            file="church.jpg",
            author="Vincent van Gogh",
            title="The Church at Auvers",
            date="1890",
            license=ExpiredCopyrightLicense(1890),
            md5="fd866289498367afd72a5c9cf626073a",
            guides=DownloadableImageCollection({
                "building":
                DownloadableImage(
                    "https://download.pystiche.org/images/church/building.png",
                    file="building.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="41256f62d2bd1560ed1e66623c8d9c9f",
                ),
                "sky":
                DownloadableImage(
                    "https://download.pystiche.org/images/church/sky.png",
                    file="sky.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="c87c7234d2788a1d2a4e1633723c794b",
                ),
                "surroundings":
                DownloadableImage(
                    "https://download.pystiche.org/images/church/surroundings.png",
                    file="surroundings.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="807a40beed727af81333edbd8eb89aff",
                ),
            }),
        ),
        "cliff":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/a/a4/Claude_Monet_-_Cliff_Walk_at_Pourville_-_Google_Art_Project.jpg",
            file="cliff.jpg",
            author="Claude Monet",
            title="The Cliff Walk at Pourville",
            date="1882",
            license=ExpiredCopyrightLicense(1926),
            md5="8f6b8101b484f17cea92a12ad27be31d",
            guides=DownloadableImageCollection({
                "landscape":
                DownloadableImage(
                    "https://download.pystiche.org/images/cliff/landscape.png",
                    file="landscape.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="4d02ee8aaa610ced3ef12a5c82f29b81",
                ),
                "sky":
                DownloadableImage(
                    "https://download.pystiche.org/images/cliff/sky.png",
                    file="sky.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="8f76b7ed88ff1b23feaab1de51501ae1",
                ),
                "water":
                DownloadableImage(
                    "https://download.pystiche.org/images/cliff/water.png",
                    file="water.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="f0cab02afadf38d3262ce1c61a36f6da",
                ),
            }),
        ),
    })
示例#6
0
def images() -> DownloadableImageCollection:
    root = (
        "https://raw.githubusercontent.com/jcjohnson/fast-neural-style/master/images/"
    )

    content_root = urljoin(root, "content/")
    content_images = {
        "chicago": DownloadableImage(
            urljoin(content_root, "chicago.jpg"), md5="16ea186230a8a5131b224ddde01d0dd5"
        ),
        "hoovertowernight": DownloadableImage(
            urljoin(content_root, "hoovertowernight.jpg"),
            md5="97f7bab04e1f4c852fd2499356163b15",
        ),
    }

    style_root = urljoin(root, "styles/")
    style_images = {
        "candy": DownloadableImage(
            urljoin(style_root, "candy.jpg"), md5="00a0e3aa9775546f98abf6417e3cb478"
        ),
        "composition_vii": DownloadableImage(
            urljoin(style_root, "composition_vii.jpg"),
            md5="8d4f97cb0e8b1b07dee923599ee86cbd",
        ),
        "feathers": DownloadableImage(
            urljoin(style_root, "feathers.jpg"), md5="461c8a1704b59af1cf686883b16feec6"
        ),
        "la_muse": DownloadableImage(
            urljoin(style_root, "la_muse.jpg"), md5="77262ef6985cc427f84d78784ab5c1d8"
        ),
        "mosaic": DownloadableImage(
            urljoin(style_root, "mosaic.jpg"), md5="67b11e9cb1a69df08d70d9c2c7778fba"
        ),
        "starry_night": DownloadableImage(
            urljoin(style_root, "starry_night.jpg"),
            md5="ff217acb6db32785b8651a0e316aeab3",
        ),
        "the_scream": DownloadableImage(
            urljoin(style_root, "the_scream.jpg"),
            md5="619b4f42c84d2b62d3518fb20fa619c2",
        ),
        "udnie": DownloadableImage(
            urljoin(style_root, "udnie.jpg"), md5="6f3fa51706b21580a4b77f232d3b8ba9"
        ),
        "the_wave": DownloadableImage(
            urljoin(style_root, "wave.jpg"),
            md5="b06acee16641a2a04fb87bade8cee529",
            file="the_wave.jpg",
        ),
    }
    return DownloadableImageCollection({**content_images, **style_images})
示例#7
0
文件: _data.py 项目: pystiche/papers
def images() -> DownloadableImageCollection:
    r"""Images from :cite:`ULVL2016,UVL2017`."""
    base_ulyanov = (
        "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/master/data/"
    )
    base_ulyanov_suppl = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/supplementary/"
    readme_ulyanov = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/data/readme_pics/"
    content_base_ulyanov = urljoin(base_ulyanov, "readme_pics/")
    content_images = {
        "karya":
        DownloadableImage(
            urljoin(content_base_ulyanov, "karya.jpg"),
            license=LICENSE_ULYANOV,
            md5="232b2f03a5d20c453a41a0e6320f27be",
        ),
        "tiger":
        DownloadableImage(
            urljoin(content_base_ulyanov, "tiger.jpg"),
            license=LICENSE_ULYANOV,
            md5="e82bf374da425fb2c2e2a35a5a751989",
        ),
        "neckarfront":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/0/00/Tuebingen_Neckarfront.jpg",
            title="Tübingen Neckarfront",
            author="Andreas Praefcke",
            license=CreativeCommonsLicense(("by", ), version="3.0"),
            md5="dc9ad203263f34352e18bc29b03e1066",
            file="tuebingen_neckarfront__andreas_praefcke.jpg",
        ),
        "tower_of_babel":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/f/fc/Pieter_Bruegel_the_Elder_-_The_Tower_of_Babel_%28Vienna%29_-_Google_Art_Project_-_edited.jpg",
            title="The Tower of Babel",
            author="Pieter Bruegel",
            date="1563",
            license=ExpiredCopyrightLicense(1563),
            md5="1e113716c8aad6c2ca826ae0b83ffc76",
            file="the_tower_of_babel.jpg",
        ),
        "bird":
        DownloadableImage(
            urljoin(base_ulyanov_suppl, "bird.jpg"),
            license=LICENSE_ULYANOV,
            md5="74dde9fad4749e7ff3cd4eca6cb43d0d",
        ),
        "kitty":
        DownloadableImage(
            urljoin(readme_ulyanov, "kitty.jpg"),
            license=LICENSE_ULYANOV,
            md5="98262bd8f5ae25f8329158d2c2c66ad0",
        ),
    }

    base_johnson = (
        "https://raw.githubusercontent.com/jcjohnson/fast-neural-style/master/images/"
    )
    style_base_johnson = urljoin(base_johnson, "styles/")

    base_ulyanov_suppl_style = "https://raw.githubusercontent.com/DmitryUlyanov/texture_nets/texture_nets_v1/supplementary//stylization_models/"
    style_images = {
        "candy":
        DownloadableImage(
            urljoin(style_base_johnson, "candy.jpg"),
            license=LICENSE_JOHNSON,
            md5="00a0e3aa9775546f98abf6417e3cb478",
        ),
        "the_scream":
        DownloadableImage(
            urljoin(style_base_johnson, "the_scream.jpg"),
            license=LICENSE_JOHNSON,
            md5="619b4f42c84d2b62d3518fb20fa619c2",
        ),
        "jean_metzinger":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/c/c9/Robert_Delaunay%2C_1906%2C_Portrait_de_Metzinger%2C_oil_on_canvas%2C_55_x_43_cm%2C_DSC08255.jpg",
            title="Portrait of Jean Metzinger",
            author="Jean Metzinger",
            date="1906",
            license=ExpiredCopyrightLicense(1906),
            md5="3539d50d2808b8eec5b05f892d8cf1e1",
            file="jean_metzinger.jpg",
        ),
        "mosaic":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "mosaic.jpg"),
            license=LICENSE_ULYANOV,
            md5="4f05f1e12961cebf41bd372d909342b3",
        ),
        "pleades":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "pleades.jpg"),
            license=LICENSE_ULYANOV,
            md5="6fc41ac30c2852a5454a0ead2f479dc9",
        ),
        "starry":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "starry.jpg"),
            license=LICENSE_ULYANOV,
            md5="c6d94f7962466b2e80a64ae82523242a",
        ),
        "turner":
        DownloadableImage(
            urljoin(base_ulyanov_suppl_style, "turner.jpg"),
            license=LICENSE_ULYANOV,
            md5="7fdd9603a5182dcef23d7fb1c5217888",
        ),
    }
    return DownloadableImageCollection({**content_images, **style_images})
示例#8
0
def demo_images() -> DownloadableImageCollection:
    """Collection of images used in the usage examples.

    .. note::

        You can use

        .. code-block:: python

            print(demo_images())

        to get a list of all available images.
    """
    return DownloadableImageCollection({
        # TODO: remove
        "dancing":
        DownloadableImage(
            "https://pytorch.org/tutorials/_static/img/neural-style/dancing.jpg",
            md5="0a2df538901452d639170a2ed89815a4",
        ),
        # TODO: remove
        "picasso":
        DownloadableImage(
            "https://pytorch.org/tutorials/_static/img/neural-style/picasso.jpg",
            md5="d1d60fc3f9d0b22d2d826c47934a37ea",
        ),
        "bird1":
        DownloadableImage(
            "https://cdn.pixabay.com/photo/2016/01/14/11/26/bird-1139734_960_720.jpg",
            file="bird1.jpg",
            author="gholmz0",
            date="09.03.2013",
            license=PixabayLicense(),
            md5="36e5fef725943a5d1d22b5048095da86",
        ),
        "paint":
        DownloadableImage(
            "https://cdn.pixabay.com/photo/2017/07/03/20/17/abstract-2468874_960_720.jpg",
            file="paint.jpg",
            author="garageband",
            date="03.07.2017",
            license=PixabayLicense(),
            md5="a991e222806ef49d34b172a67cf97d91",
        ),
        "bird2":
        DownloadableImage(
            "https://cdn.pixabay.com/photo/2013/03/12/17/53/bird-92956_960_720.jpg",
            file="bird2.jpg",
            author="12019",
            date="09.04.2012",
            license=PixabayLicense(),
            md5="8c5b608bd579d931e2cfe7229840fe9b",
        ),
        "mosaic":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/2/23/Mosaic_ducks_Massimo.jpg",
            file="mosaic.jpg",
            author="Marie-Lan Nguyen",
            date="2006",
            license=PublicDomainLicense(),
            md5="5b60cd1724395f7a0c21dc6dd006f8ae",
        ),
        "castle":
        DownloadableImage(
            "https://cdn.pixabay.com/photo/2014/04/03/10/28/lemgo-310586_960_720.jpg",
            file="castle.jpg",
            author="Christian Hänsel",
            date="23.03.2014",
            license=PixabayLicense(),
            md5="f6e7d9ed61223c12230b99ed496849a9",
            guides=DownloadableImageCollection(
                {
                    "building":
                    DownloadableImage(
                        "https://download.pystiche.org/images/castle/building.png",
                        file="building.png",
                        author="Julian Bültemeier",
                        license=PublicDomainLicense(),
                        md5="680bd875f4fdb919d446d6210cbe1035",
                    ),
                    "sky":
                    DownloadableImage(
                        "https://download.pystiche.org/images/castle/sky.png",
                        file="sky.png",
                        author="Julian Bültemeier",
                        license=PublicDomainLicense(),
                        md5="c4d5f18b3ca22a1ff879f40ca797ed26",
                    ),
                    "water":
                    DownloadableImage(
                        "https://download.pystiche.org/images/castle/water.png",
                        file="water.png",
                        author="Julian Bültemeier",
                        license=PublicDomainLicense(),
                        md5="2642552e8c98b6a63f24dd67bb54e2a3",
                    ),
                }, ),
        ),
        "church":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/a/ad/Vincent_van_Gogh_-_The_Church_in_Auvers-sur-Oise%2C_View_from_the_Chevet_-_Google_Art_Project.jpg",
            file="church.jpg",
            author="Vincent van Gogh",
            title="The Church at Auvers",
            date="1890",
            license=ExpiredCopyrightLicense(1890),
            md5="fd866289498367afd72a5c9cf626073a",
            guides=DownloadableImageCollection({
                "building":
                DownloadableImage(
                    "https://download.pystiche.org/images/church/building.png",
                    file="building.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="41256f62d2bd1560ed1e66623c8d9c9f",
                ),
                "sky":
                DownloadableImage(
                    "https://download.pystiche.org/images/church/sky.png",
                    file="sky.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="c87c7234d2788a1d2a4e1633723c794b",
                ),
                "surroundings":
                DownloadableImage(
                    "https://download.pystiche.org/images/church/surroundings.png",
                    file="surroundings.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="807a40beed727af81333edbd8eb89aff",
                ),
            }),
        ),
        "cliff":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/a/a4/Claude_Monet_-_Cliff_Walk_at_Pourville_-_Google_Art_Project.jpg",
            file="cliff.jpg",
            author="Claude Monet",
            title="The Cliff Walk at Pourville",
            date="1882",
            license=ExpiredCopyrightLicense(1926),
            md5="8f6b8101b484f17cea92a12ad27be31d",
            guides=DownloadableImageCollection({
                "landscape":
                DownloadableImage(
                    "https://download.pystiche.org/images/cliff/landscape.png",
                    file="landscape.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="4d02ee8aaa610ced3ef12a5c82f29b81",
                ),
                "sky":
                DownloadableImage(
                    "https://download.pystiche.org/images/cliff/sky.png",
                    file="sky.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="8f76b7ed88ff1b23feaab1de51501ae1",
                ),
                "water":
                DownloadableImage(
                    "https://download.pystiche.org/images/cliff/water.png",
                    file="water.png",
                    author="Julian Bültemeier",
                    license=PublicDomainLicense(),
                    md5="f0cab02afadf38d3262ce1c61a36f6da",
                ),
            }),
        ),
    })
示例#9
0
def gatys_ecker_bethge_2015_images(root: Optional[str] = None,
                                   download: bool = True,
                                   overwrite: bool = False):
    images = {
        "neckarfront":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/0/00/Tuebingen_Neckarfront.jpg",
            title="Tübingen Neckarfront",
            author="Andreas Praefcke",
            license=CreativeCommonsLicense(("by", ), version="3.0"),
            md5="dc9ad203263f34352e18bc29b03e1066",
            file="tuebingen_neckarfront__andreas_praefcke.jpg",
        ),
        "shipwreck":
        DownloadableImage(
            "https://blog-imgs-51.fc2.com/b/e/l/bell1976brain/800px-Shipwreck_turner.jpg",
            title="Shipwreck of the Minotaur",
            author="J. M. W. Turner",
            date="ca. 1810",
            license=ExpiredCopyrightLicense(1851),
            md5="4fb76d6f6fc1678cb74e858324d4d0cb",
            file="shipwreck_of_the_minotaur__turner.jpg",
        ),
        "starry_night":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/thumb/e/ea/Van_Gogh_-_Starry_Night_-_Google_Art_Project.jpg/1280px-Van_Gogh_-_Starry_Night_-_Google_Art_Project.jpg",
            title="Starry Night",
            author="Vincent van Gogh",
            date="ca. 1889",
            license=ExpiredCopyrightLicense(1890),
            md5="372e5bc438e3e8d0eb52cc6f7ef44760",
        ),
        "the_scream":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/f/f4/The_Scream.jpg",
            title="The Scream",
            author="Edvard Munch",
            date="ca. 1893",
            license=ExpiredCopyrightLicense(1944),
            md5="46ef64eea5a7b2d13dbadd420b531249",
        ),
        "femme_nue_assise":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/en/8/8f/Pablo_Picasso%2C_1909-10%2C_Figure_dans_un_Fauteuil_%28Seated_Nude%2C_Femme_nue_assise%29%2C_oil_on_canvas%2C_92.1_x_73_cm%2C_Tate_Modern%2C_London.jpg",
            title="Figure dans un Fauteuil",
            author="Pablo Ruiz Picasso",
            date="ca. 1909",
            license=ExpiredCopyrightLicense(1973),
            md5="ba14b947b225d9e5c59520a814376944",
        ),
        "composition_vii":
        DownloadableImage(
            "https://upload.wikimedia.org/wikipedia/commons/b/b4/Vassily_Kandinsky%2C_1913_-_Composition_7.jpg",
            title="Composition VII",
            author="Wassily Kandinsky",
            date="1913",
            license=ExpiredCopyrightLicense(1944),
            md5="bfcbc420684bf27d2d8581fa8cc9522f",
        ),
    }
    return DownloadableImageCollection(images,
                                       root=root,
                                       download=download,
                                       overwrite=overwrite)