Environment variables#
Prefer explicit config fields for scientific settings and launch YAML for machine policy. Environment variables are appropriate for storage locations, credentials, and scheduler-provided process identity.
Where values come from#
pimm launch and pimm submit export the env: mapping from resolved launch
YAML, then call scripts/train.sh. Both scripts/train.sh and
scripts/test.sh source a repository-root .env file when present.
cp example.env .env
.env uses ordinary shell syntax, not a dotenv parser. Because it is sourced
inside the script, an assignment in .env replaces a same-named value already
in the environment. Keep each variable in one authoritative place and never
commit secrets. Direct Python API calls and pimm export do not source .env.
Data locations#
Variable |
Read by |
Meaning |
|---|---|---|
|
root of revision-v1 HDF5 split directories |
|
|
root of revision-v2 HDF5 split directories |
|
|
separately supplied revision-v3 root; the standard downloader does not provide it |
|
|
PILArNet Parquet map/stream readers |
local Parquet root for the selected revision; wins over the configured Hub repository |
|
committed JAXTPC base config |
JAXTPC production root; otherwise the config retains a non-runnable placeholder path |
An explicit dataset data_root takes priority over the corresponding PILArNet
environment variable. HDF5 then falls back to
~/.cache/pimm/pilarnet/<revision> when that directory exists.
Checkpoints and model downloads#
Variable |
Meaning and precedence |
|---|---|
|
physical checkpoint root used by |
|
cache used for downloaded Hugging Face datasets and models; set this when the cache must live on a shared or high-capacity filesystem |
|
parent directory for Hugging Face state when |
|
standard Hugging Face authentication token for private downloads/uploads |
|
standard Hub transfer switch; NERSC profiles set it to |
Hub cache selection is:
HF_HUB_CACHE → HF_HOME → MODEL_DIR/hub → Hugging Face default
Reference a Hub model by its repository URI:
hf://ORG/REPOSITORY
Logging and credentials#
Variable |
Meaning |
|---|---|
|
non-interactive Weights & Biases authentication |
|
standard W&B mode such as |
--run.wandb-api-key is converted to WANDB_API_KEY, but putting a credential
on a command line can expose it through shell history or process listings.
Prefer wandb login, a protected scheduler secret, or a permission-restricted
.env file.
--token on pimm export has the same exposure risk. Prefer hf auth login
or HF_TOKEN.
Run and distributed execution#
Variable |
Owner |
Guidance |
|---|---|---|
|
|
low-level experiment root; launcher users should set |
|
CUDA/PyTorch |
constrains devices visible to local |
|
launcher/torchrun |
rendezvous endpoint; normally rendered from job/run context or |
|
launcher/ |
advanced torchrun rendezvous overrides; normally use |
|
|
explicit node rank fallback; scheduler/torchrun normally supplies rank identity |
|
torchrun |
process identity consumed by pimm; do not hand-set for ordinary launches |
|
Slurm |
node/task/job identity and nodelist used to derive rank and rendezvous defaults |
|
pimm Submitit wrapper |
internal requeue-attempt number |
For cluster-specific NCCL, HDF5, certificate, module, and network settings, use
launch/sites/<site>.yaml. The bundled profiles show examples such as
NCCL_SOCKET_IFNAME, NCCL_NET_GDR_LEVEL, HDF5_USE_FILE_LOCKING,
REQUESTS_CA_BUNDLE, and SSL_CERT_FILE; copy only settings validated for your
site.
Reproducibility and diagnostics#
Variable |
Meaning |
|---|---|
|
set by pimm to |
|
set from the resolved seed during pimm process setup; starting Python has already initialized some hash state, so record the full environment rather than treating this as a bitwise guarantee |
Installer-only controls#
install.sh recognizes PIMM_REPO, PIMM_BRANCH, and SKIP_CLONE=1 for
bootstrap/fork workflows. They affect checkout selection, not a running pimm
experiment.
Inspect without printing secrets#
env | cut -d= -f1 | sort | rg \
'^(PIMM|PILARNET|JAXTPC|MODEL_DIR|HF_|WANDB|CUDA_VISIBLE|MASTER_|SLURM_)'
uv run pimm launch --train.config tests/tiny_semseg --dry-run
Rendered dry runs redact mapping keys that look like tokens, API keys, passwords, secrets, or credentials. That is a convenience, not a complete secret scanner; review output before sharing it.