From 5837008b9116620b9a5800a1062735fff440f340 Mon Sep 17 00:00:00 2001 From: CeresBarros Date: Thu, 29 Feb 2024 09:45:17 -0800 Subject: [PATCH] fix `prepInputs(..., useCache)` doc --- R/prepInputs.R | 8 +++++--- man/CacheGeo.Rd | 8 +++++--- man/prepInputs.Rd | 8 +++++--- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/R/prepInputs.R b/R/prepInputs.R index 497c2df60..b41cc3da1 100644 --- a/R/prepInputs.R +++ b/R/prepInputs.R @@ -191,9 +191,11 @@ utils::globalVariables(c( #' Defaults to `getOption("reproducible.useCache", 2L)` in `prepInputs`, and #' `getOption("reproducible.useCache", FALSE)` if calling any of the inner #' functions manually. For `prepInputs`, this mean it will use `Cache` -#' only up to 2 nested levels, which will generally including `postProcess` and -#' the first level of `*Input` functions, e.g., `cropInputs`, `projectInputs`, -#' `maskInputs`, but not `fixErrors`. +#' only up to 2 nested levels, which includes `preProcess`. `postProcess` and +#' its nested `*Input` functions (e.g., `cropInputs`, `projectInputs`, +#' `maskInputs`) are no longer internally cached, as `terra` processing speeds +#' mean internal caching is more time consuming. We recommend caching the full +#' `prepInputs` call instead (e.g. `prepInputs(...) |> Cache()`). #' #' @param .tempPath Optional temporary path for internal file intermediate steps. #' Will be cleared on.exit from this function. diff --git a/man/CacheGeo.Rd b/man/CacheGeo.Rd index 203e0e241..49eaa5de7 100644 --- a/man/CacheGeo.Rd +++ b/man/CacheGeo.Rd @@ -57,9 +57,11 @@ folder on your google drive.} Defaults to \code{getOption("reproducible.useCache", 2L)} in \code{prepInputs}, and \code{getOption("reproducible.useCache", FALSE)} if calling any of the inner functions manually. For \code{prepInputs}, this mean it will use \code{Cache} -only up to 2 nested levels, which will generally including \code{postProcess} and -the first level of \verb{*Input} functions, e.g., \code{cropInputs}, \code{projectInputs}, -\code{maskInputs}, but not \code{fixErrors}.} +only up to 2 nested levels, which includes \code{preProcess}. \code{postProcess} and +its nested \verb{*Input} functions (e.g., \code{cropInputs}, \code{projectInputs}, +\code{maskInputs}) are no longer internally cached, as \code{terra} processing speeds +mean internal caching is more time consuming. We recommend caching the full +\code{prepInputs} call instead (e.g. \code{prepInputs(...) |> Cache()}).} \item{overwrite}{Logical. Should downloading and all the other actions occur even if they pass the checksums or the files are all there.} diff --git a/man/prepInputs.Rd b/man/prepInputs.Rd index be6c8c5d6..3e67702e1 100644 --- a/man/prepInputs.Rd +++ b/man/prepInputs.Rd @@ -89,9 +89,11 @@ even if they pass the checksums or the files are all there.} Defaults to \code{getOption("reproducible.useCache", 2L)} in \code{prepInputs}, and \code{getOption("reproducible.useCache", FALSE)} if calling any of the inner functions manually. For \code{prepInputs}, this mean it will use \code{Cache} -only up to 2 nested levels, which will generally including \code{postProcess} and -the first level of \verb{*Input} functions, e.g., \code{cropInputs}, \code{projectInputs}, -\code{maskInputs}, but not \code{fixErrors}.} +only up to 2 nested levels, which includes \code{preProcess}. \code{postProcess} and +its nested \verb{*Input} functions (e.g., \code{cropInputs}, \code{projectInputs}, +\code{maskInputs}) are no longer internally cached, as \code{terra} processing speeds +mean internal caching is more time consuming. We recommend caching the full +\code{prepInputs} call instead (e.g. \code{prepInputs(...) |> Cache()}).} \item{.tempPath}{Optional temporary path for internal file intermediate steps. Will be cleared on.exit from this function.}