{"id":21710355,"url":"https://github.com/cloudinary-devs/style-transfer-contest","last_synced_at":"2025-03-20T17:51:12.016Z","repository":{"id":109429198,"uuid":"157722736","full_name":"cloudinary-devs/style-transfer-contest","owner":"cloudinary-devs","description":null,"archived":false,"fork":false,"pushed_at":"2018-11-15T15:02:50.000Z","size":29865,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-25T16:41:44.776Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cloudinary-devs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-11-15T14:17:26.000Z","updated_at":"2018-11-15T15:02:52.000Z","dependencies_parsed_at":"2023-04-10T12:04:19.400Z","dependency_job_id":null,"html_url":"https://github.com/cloudinary-devs/style-transfer-contest","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudinary-devs%2Fstyle-transfer-contest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudinary-devs%2Fstyle-transfer-contest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudinary-devs%2Fstyle-transfer-contest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudinary-devs%2Fstyle-transfer-contest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cloudinary-devs","download_url":"https://codeload.github.com/cloudinary-devs/style-transfer-contest/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244666424,"owners_count":20490286,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-25T23:14:57.340Z","updated_at":"2025-03-20T17:51:12.006Z","avatar_url":"https://github.com/cloudinary-devs.png","language":"HTML","readme":"# style-transfer-contest\n\nThis repo contains the archived results of Cloudinary’s Style Transfer Contest, held in Sept 27th – October 4th, 2017.\n\nThe archive was created by executing the following command:\n\n`wget -prHkE --level=1 -Dres.cloudinary.com,faas-cloudinary.com,codepen.io,cloudinary-res.cloudinary.com,code.jquery.com,cdnjs.cloudflare.com https://faas-cloudinary.com/wt-60a287cd40c53f6e56bd60ac8922bc3e-0/style-transfer/view/no-token`\n\nAnd then doing a couple of additional things, manually. More on the manual steps later. First, Here’s a breakdown of those gnarly `wget` switches:\n\n- `-p` downloads resources (like images) necessary to render the page (and not just the HTML)\n- `-r` follows links recursively (default depth level 5)\n- `--level 1` sets the depth level to 1\n- `-k` converts absolute URLs (starting with http://) to local, relative URLs ( starting with ./ or ../../../ or whatever)\n- `-E` renames files so their extension matches their type (e.g., .asp → .html)\n- `-H` spans hosts (so res.cloudinary images get downloaded)\n- `-D[hostname]` limits `-H` so that only links/resources on that host gets followed/downloaded (can specify multiple with commas, like `-Dres.cloudinary.com,demo-res.cloudinary.com`)\n\nExternal hosts that were not included in the `wget -D` list, and why:\n\n- `fonts.googleapis.com`, because it might break the terms of service (?) and it seems Google serves different things to different browsers depending on UA string and I didn't want to get into the business of figuring out how or why they do that or how I should or shouldn’t spoof with yet more `wget` options.\n- `platform-api.sharethis.com`, because when I did this I got CORS errors. Without it, I still get CORS errors, but ¯\\_(ツ)_/¯\n- `cloudinary.com`, because while I do want a stylesheet from over there I did not want to download the linked-to cloudinary.com homepage.\n\nIn order to get that stylesheet, I: \n\n1. Manually downloaded `https://cloudinary.com/stylesheets/g/cloudinary_public.css?1500989656` and saved it to this repo at `[repo root]/cloudinary.com/stylesheets/g/cloudinary_public.css`.\n2. Found `https://cloudinary.com/stylesheets/g/cloudinary_public.css?1500989656` + replaced with `../../../../cloudinary.com/stylesheets/g/cloudinary_public.css` on every file in `/faas-cloudinary.com/wt-60a287cd40c53f6e56bd60ac8922bc3e-0/style-transfer/view/`\n\nOne more manual thing. Because I did not want the canonical URL for this archive to be:\n\n`https://cloudinary-developers.github.io/style-transfer-contest/faas-cloudinary.com/wt-60a287cd40c53f6e56bd60ac8922bc3e-0/style-transfer/view/no-token?view=leader\u0026vote=.html`\n\n(🤮)\n\nI copied `/wt-60a287cd40c53f6e56bd60ac8922bc3e-0/style-transfer/view/no-token?view=leader\u0026vote=.html` to `/index.html` and did a couple of find/replaces on it to make sure that its links still worked.\n\n**Find**: `../../../../`\n**Replace**: `./`\n\n(makes the cross-domain links work)\n\n**Find**: `no-token`\n**Replace**: `./faas-cloudinary.com/wt-60a287cd40c53f6e56bd60ac8922bc3e-0/style-transfer/view/no-token`\n\n(makes the same-domain links to the other views work)\n\nSo now this archive is accessible at [https://cloudinary-developers.github.io/style-transfer-contest/](https://cloudinary-developers.github.io/style-transfer-contest/), and all of the links work.\n\n🎉 *fin* 🎉","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcloudinary-devs%2Fstyle-transfer-contest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcloudinary-devs%2Fstyle-transfer-contest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcloudinary-devs%2Fstyle-transfer-contest/lists"}