Some simple scripts I made for analysis of the Danbooru2021 dataset as well as the resulting plots with explanations. Analysis is done using only the metadata files (total size of 21GB) rather than the actual dataset. The order of scripts is chosen in a way that is intended to be didactic rather than in chronological order.
Aspect Ratio plots the distribution of image size and aspect ratio in one dimension each.
Dimension 2d is concerned with the two-dimensional distribution of image widths and image heights and to what degree images conform to common aspect ratios.
Disk Usage Calculator is a small utility for calculating the projected disk usage for the dataset when considering tag, rating, and file extension filters as well as resizing the files.
File List Creator is a small utility for generating .txt files from Danbooru2021 metadata do only relevant files need to be downloaded.