procPhotos2.Rd
procPhotos2
copies raw sample photos, renames them with the C-label
and strain name if CeNDR
is set to TRUE, and pastes them in
data/processed/fulcrum/photos folder. The function also makes thumbnails for
use with interactive maps and calculates md5 checksums for images.
procPhotos2(
dir,
data,
max_dim = 500,
overwrite = FALSE,
CeaNDR = FALSE,
pub_url = "https://storage.googleapis.com/elegansvariation.org/photos/isolation/fulcrum/"
)
The path to the base fulcrum directory, raw/fulcrum/photos. This directory must contain the raw sample photos exported from Fulcrum.
a data frame output from the joinGenoFulc
function.
This value sets the maximum dimension of the resized images in pixels. The default value is 500.
Logical, passed to fs::file_copy. If TRUE then existing files with similar names will be written over. Default is FALSE.
Logical, determines whether to also rename photos to strain
names for Caenorhabditis briggsae, Caenorhabditis elegans, Caenorhabditis
tropicalis positive collections and add those images to the
data/processed/fulcrum/photos/CeaNDR/
directory.
A public url that holds sample images organized by <your
project>/sampling_thumbs/<C-label>.jpg
. For example, if the full url for
C-5133 is
https://storage.googleapis.com/elegansvariation.org/photos/isolation/fulcrum/2020JanuaryHawaii/sampling_thumbs/C-5133.jpg,
the pub_url should be set to
https://storage.googleapis.com/elegansvariation.org/photos/isolation/fulcrum/.
The project name, "sampling_thumbs", C-label, and file extension will be
filled by the function.
A folder named photos
in the data/processed/fulcrum
directory. The folder contains sample photos renamed with C-labels. If
CeNDR
is set to TRUE sample photos will be renamed with strain names
as well organized by species. A dataframe identical to input data
with old
and new image file names, md5 photo hash values, and a public url to find
images. The function also saves a .rds file to the
data/processed/fulcrum
directory.