This is a equivalent to runs_info(...)$id, implemented more
efficiently.
Arguments
- runs
a runs selection. If a data.frame, the columns
idorrunare used as the run id. Otherwise, the arguments are transformed into a character vector of cli arguments, and passed on toguildas a runs filter selection. Wrap the string inI()to avoid quoting the argument for the shell.- ...
Other arguments passed on to
guild- all
Return all matching runs. If
FALSE, it returns the singly most recent run matching the selection criteria.
Details
guild supports a rich syntax for runs selection throughout the api.
The same selection syntax is shared by the runs_* family of
functions: runs_info(), runs_scalars(), runs_comment(),
runs_label(), runs_mark(), runs_tag()
runs_delete(),runs_purge(), runs_restore(), runs_export(),
runs_import().
Note
You can call Sys.setenv(GUILD_DEBUG_R = 1) to see what system
calls to the guild executable are made. This is useful when
looking to understand how R arguments are transformed into a cli
system call.
Examples
if (FALSE) {
resolve_run_ids() # returns all run ids.
resolve_run_ids(1) # last run
resolve_run_ids(1:2) # last 2 runs
resolve_run_ids(1:2, operation = "train.py")
# three ways of getting ids for the currently staged or running runs
resolve_run_ids(staged = TRUE, running = TRUE)
resolve_run_ids("--staged", "--running")
resolve_run_ids(c("--staged", "--running"))
resolve_run_ids(I("--staged --running"))
# resolve_run_ids() uses the same selection rules and syntax as runs_info()
stopifnot(identical(
resolve_run_ids(),
runs_info()$id
))
}