--- license: mit --- # 🗿 Megalith-10m ### What is Megalith-10m? ![](megalith_banner.jpg) Megalith-10m is a dataset of ~10 million links to Flickr images that were categorized as "photo" with [license info](https://www.flickr.com/services/api/flickr.photos.licenses.getInfo.htm) of: * [No known copyright restrictions (Flickr commons)](https://www.flickr.com/commons/usage), or * [United States Government Work](https://en.wikipedia.org/wiki/Copyright_status_of_works_by_the_federal_government_of_the_United_States), or * [Public Domain Dedication (CC0)](https://creativecommons.org/publicdomain/zero/1.0/), or * [Public Domain Mark](https://en.wikipedia.org/wiki/Public_Domain_Mark) ### What's the intended use of Megalith-10m? Megalith-10m is intended to contain only links to wholesome unedited uncopyrighted photographs - the sort of images that we humans see when we walk around outside. I collected Megalith-10m for the purpose of training neural networks, but you're welcome to use Megalith-10m for whatever you want. Of course, I recommend conducting your own independent analysis of content and copyright status before using Megalith-linked images in Serious Projects. ### How was Megalith-10m collected? I used the Flickr API to query for photos matching some basic criteria (SFW photo with CC0 / public domain license info), which gave me around 12 million links. I then used various filtering strategies to exclude ~2m image links which didn't appear to point to wholesome public-domain minimally-edited photos. These filtering strategies included: 1. Account-level filtering, based on 1. Manual adjudication for the top 5000 most prolific accounts 2. Repeated-watermark detection 2. Photo-level filtering, based on 1. Image metadata 1. Mention of copyright restrictions in the EXIF tags 2. Mention of copyright restrictions in the text description 2. Image content 1. Duplicate detection 2. CLIP-assisted checking for 1. Clearly non-photo images (illustrations, screenshots, 3d renders, etc.) 2. Clearly non-wholesome images (violence, nudity, etc.) 3. Minimum-resolution enforcement (at least 256x256 pixels) 4. Manual spot-checking of some images and metadata ### What content does Megalith-10m contain? The [demo notebook](./Megalith_Demo_Notebook.ipynb) shows a random sample of 100 images being loaded from the links in Megalith-10m. Based on this random sample, I would estimate the following dataset statistics: * 5-7% of images may have minor edits or annotatations (timestamps, color grading, borders, etc.) * 1-2% of images may be copyright-constrained (watermarks or text descriptions cast doubt on the license metadata) * 1-2% of images may be non-wholesome (guns, suggestive poses, etc.) * 1-2% of images may be non-photos (paintings, screenshots, etc.) ### Is 10 million images really enough to teach a neural network about the visual world? For the parts of the visual world that are well-represented in Megalith-10m, definitely! Projects like [CommonCanvas](https://arxiv.org/abs/2310.16825), [Mitsua Diffusion](https://huggingface.co/Mitsua/mitsua-diffusion-one), and [Matroyshka Diffusion](https://arxiv.org/abs/2310.15111) have shown that you can train useable generative models on similarly-sized image datasets. Of course, many parts of the world aren't well-represented in Megalith-10m, so you'd need additional data to learn about those.