Skip to content

Instantly share code, notes, and snippets.

@alexpghayes
Created February 13, 2022 05:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alexpghayes/21ac52056ecd656623239a14356fea91 to your computer and use it in GitHub Desktop.
Save alexpghayes/21ac52056ecd656623239a14356fea91 to your computer and use it in GitHub Desktop.
library(aPPR)
library(neocache)
library(logger)
library(here)
library(glue)
library(readr)
set.seed(27)
log_appender(
appender_file(
here("logs/appr.log")
),
namespace = "aPPR"
)
log_threshold(TRACE, namespace = "aPPR")
log_appender(
appender_file(
here("logs/neocache.log")
),
namespace = "neocache"
)
log_threshold(TRACE, namespace = "neocache")
seeds <- c("omaclaren", "Corey_Yanofsky")
tracker <- appr(
neocache_graph(),
seed = seeds,
epsilon = 1e-6
)
path <- here(glue("data/ppr-{paste(seeds, collapse = '-')}.rds"))
write_rds(path, tracker)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment