Find sub-directories which contain images

uas_dirs_find(x, ext = c("jpg", "tif"), min_images = 3, exclude_tb = TRUE)

Arguments

x

The base directory

ext

A character vector of the file extensions to search for (excluding the '.')

min_images

The minimum number of image files a directory must contain to be included in the results

exclude_tb

Exclude folders called 'tb' (thumbnails)

Value

A tibble with 3 columns: path, ext, and num_files.

Details

This function recurses through sub-directories of `x` and returns those that contain image files. This can be used to help identify folders that need to be cataloged.

Only directories that have at least min_images image files will be returned. If exclude_tb = TRUE, directories named `tb` (which is where uas_thumbnails_make saves thumbnail images) are excluded. Hidden directories and directories that start with `.` are excluded.