It looks like you're looking for a smart aggregation function, which aggregate n folded rows instead of the usual 1 (out of the many falling to the group-by criteria).
Some of the aggregation function you suggested like min and max can be adjusted as the n-smallest or the n-biggest values. Alternatively, the min/max n-values can be a skip list of the sorted value (ascending for min, descending for max), choosing every n/5-th item value
In a wider approach, we can borrow the concept from time-series, where at each time interval a set of parameters are sampled. Instead of the built in time-stamp buckets (say every 1 sec, 10 min, etc..) you can use your images index, thus preserving the order.
As with time-series, that can be farther more reduced into smaller time-series (say from a 1 sec interval into 1 day interval), write a custom group-by function that "folds" every n/5 image-rows into 1 row (so that it'll leave you with 5) and apply your min/max/custom aggregation function on every n/5 values of your magic-image-property