tests/testthat/setup.R

# Ensure PyTorch cache goes to temp directory during tests
# This is redundant with .onLoad() but provides extra safety for tests
if (Sys.getenv("TORCHINDUCTOR_CACHE_DIR") == "") {
  torch_cache_dir <- file.path(tempdir(), "torchinductor_test")
  Sys.setenv(TORCHINDUCTOR_CACHE_DIR = torch_cache_dir)
}

Try the tabpfn package in your browser

Any scripts or data that you put into this service are public.

tabpfn documentation built on March 18, 2026, 5:07 p.m.