batch_extract: batch_extract

Description Usage Arguments Details Value References Examples

View source: R/batch_extract.R

Description

Batch extraction of raw data from FLIR thermal images.

Usage

1
2
3
4
5
6
7
8
9
batch_extract(
  in_dir,
  write_results = TRUE,
  out_dir = NULL,
  file_name = NULL,
  inc = NULL,
  exc = NULL,
  exiftoolpath = "installed"
)

Arguments

in_dir

Path to directory where thermal images are stored.

write_results

Should the results be written as an Rdata file? Defaults to true.

out_dir

Path to directory where output Rdata file will be stored. Defaults to working directory.

file_name

File name (without extension). Defaults to NULL, with the name 'flir_raw_' plus the current date. File format is .Rds

inc

Vector of file names to include. Defaults to NULL, meaning all files are included.

exc

Vector of file names to exclude. Defaults to NULL, meaning all files are included.

exiftoolpath

Passed directly to Thermimage::readflirJPG: "A character string that determines whether ExifTool has been 'installed' (http://www.sno.phy.queensu.ca/~phil/exiftool/) or not. If ExifTool has been installed in a specific location, use to direct to the folder location."

Details

Batch implementation of Thermimage::readflirJPG.

Note that ExifTool is essential for this function to work correctly. See the documentation of Thermimage::readflirJPG:

"Exiftool should install on most operating systems. Consult with http://www.sno.phy.queensu.ca/~phil/exiftool/ for information on installing Exiftool. If trouble installing, download Exiftool and set exiftoolpath to the custom folder location. To test if the custom path to Exiftool will work on your OS, try your own system or system2 call: system2('/custompath/exiftool') to see if you get an error or not."

Value

A list containing:

raw_dat

A list with one element per input thermal image. Each element is a numeric matrix of the raw infrared data.

camera_params

A dataframe of callibration constants unique to each camera.

References

ExifTool Command line tool: http://www.sno.phy.queensu.ca/~phil/exiftool/

Examples

1
2
3
4
# Batch extract four FLIR thermal images included in this package.
results <-
    batch_extract(system.file("extdata", package = "ThermStats"),
                  write_results = FALSE)

rasenior/ThermStats documentation built on Oct. 31, 2020, 3:48 p.m.