Repository navigation
Expand file tree
/
Copy pathconfig.sh
More file actions
70 lines (59 loc) · 2.89 KB
/
Copy pathconfig.sh
File metadata and controls
70 lines (59 loc) · 2.89 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
#!/usr/bin/env bash
# =============================================================================
# CIDER simulation benchmark -- site configuration
#
# Every path used by the pipeline is set here. Nothing else in the repository
# contains an absolute path. Override any variable by exporting it before
# sourcing this file, or by creating `config.local.sh` next to it (gitignored).
#
# source config.sh
#
# Part of the CIDER simulation benchmark. GPL-3.0-or-later.
# =============================================================================
# Repository root (this file's location).
CIDER_REPO="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
export CIDER_REPO
# --- Site overrides ----------------------------------------------------------
if [ -f "$CIDER_REPO/config.local.sh" ]; then
# shellcheck disable=SC1091
source "$CIDER_REPO/config.local.sh"
fi
# --- Where simulation output is written --------------------------------------
# Per-run outputs land in $CIDER_OUT/runs/<cell>/.
# per-cell aggregates in $CIDER_OUT/aggregated/<cell>.txt.
export CIDER_OUT="${CIDER_OUT:-$CIDER_REPO/output}"
# --- Library directory for the R simulation modules --------------------------
export CIDER_SIM_LIB="${CIDER_SIM_LIB:-$CIDER_REPO/sim/R}"
# --- GTEx whole-blood input (real-TF stages 2 and 4) -------------------------
# NOT shared with this repository. Build it with
# python sim/python/build_gtex_wholeblood_input.py
# See docs/DATA.md.
export CIDER_GTEX_DIR="${CIDER_GTEX_DIR:-$CIDER_REPO/data/gtex}"
export CIDER_GTEX_EXPR="${CIDER_GTEX_EXPR:-$CIDER_GTEX_DIR/gtex_v10_wholeblood_3cpm_25perc_log1tmmcpm.tsv}"
export CIDER_GTEX_ANNT="${CIDER_GTEX_ANNT:-$CIDER_GTEX_DIR/gtex_v10_wholeblood_3cpm_25perc_log1tmmcpm_annt.tsv}"
# --- Parameter grids ---------------------------------------------------------
export CIDER_GRID_DIR="${CIDER_GRID_DIR:-$CIDER_REPO/sim/grids}"
# --- R environment -----------------------------------------------------------
# The published runs used R 4.4.0 with a dedicated library tree.
export CIDER_R_LIBS="${CIDER_R_LIBS:-}"
# --- Python interpreter ------------------------------------------------------
export CIDER_PYTHON="${CIDER_PYTHON:-python3}"
export CIDER_TMPDIR="${CIDER_TMPDIR:-${TMPDIR:-/tmp}}"
# Optional hook for module/spack/conda systems. Define CIDER_LOAD_R in
# config.local.sh to run whatever your site needs, e.g.
# CIDER_LOAD_R() { eval "$(spack load --sh r@4.4.0)"; }
if ! declare -F CIDER_LOAD_R > /dev/null; then
CIDER_LOAD_R() { :; }
fi
# Optional hook for the Python environment used by the linear stages and the
# plotting scripts, e.g. CIDER_LOAD_PY() { conda activate cider; }
if ! declare -F CIDER_LOAD_PY > /dev/null; then
CIDER_LOAD_PY() { :; }
fi
# Apply the R library path once overrides have been read.
if [ -n "$CIDER_R_LIBS" ]; then
export R_LIBS_SITE="$CIDER_R_LIBS"
export R_LIBS="$CIDER_R_LIBS"
fi
export TMP="$CIDER_TMPDIR"
export TMPDIR="$CIDER_TMPDIR"