diff --git a/SBATCH/run_mutagenesis.sh b/SBATCH/run_mutagenesis.sh index 352b746..4ae4353 100644 --- a/SBATCH/run_mutagenesis.sh +++ b/SBATCH/run_mutagenesis.sh @@ -1,5 +1,5 @@ #!/bin/bash -#SBATCH -t 10:00 +#SBATCH -t 30:00 #SBATCH --job-name=run_mutagenesis_davis_esm #SBATCH --mem=10G diff --git a/SBATCH/run_platinum.sh b/SBATCH/run_platinum.sh index a32613f..c02eda2 100644 --- a/SBATCH/run_platinum.sh +++ b/SBATCH/run_platinum.sh @@ -14,8 +14,8 @@ # Then to get most accurate mutagenesis you can average these matrices # and visualize them with src.analysis.mutagenesis_plot.plot_sequence - -cd /home/jyaacoub/projects/def-sushant/jyaacoub/MutDTA +ROOT_DIR="/lustre06/project/6069023" +cd ${ROOT_DIR}/jyaacoub/MutDTA source .venv/bin/activate python -u run_platinum.py \ diff --git a/SBATCH/test.sh b/SBATCH/test.sh new file mode 100644 index 0000000..6a196f8 --- /dev/null +++ b/SBATCH/test.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +ROOT_DIR="/lustre06/project/6069023" +SCRATCH_DIR="/lustre07/scratch/jyaacoub/" # this is used for outputs on narval +BIN_DIR="${ROOT_DIR}/jyaacoub/bin" # for modeller + +# Modeller is needed for this to run... (see: Generic install - https://salilab.org/modeller/10.5/release.html#unix) +export PYTHONPATH="${PYTHONPATH}:${BIN_DIR}/modeller10.5/lib/x86_64-intel8/python3.3:${BIN_DIR}/modeller10.5/lib/x86_64-intel8:${BIN_DIR}/modeller10.5/modlib" +export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:${BIN_DIR}/modeller10.5/lib/x86_64-intel8" + +cd ${ROOT_DIR}/jyaacoub/MutDTA +source .venv/bin/activate + +# export TRANSFORMERS_CACHE="${ROOT_DIR}/jyaacoub/hf_models/" +# export HF_HOME=${TRANSFORMERS_CACHE} +# export HF_HUB_OFFLINE=1 + +python -u playground.py \ No newline at end of file diff --git a/playground.py b/playground.py index 8f5e4b7..a98fbb6 100644 --- a/playground.py +++ b/playground.py @@ -1,13 +1,20 @@ #%% +import os +print("os.env.TRANSFORMERS_CACHE - ", os.environ.get('TRANSFORMERS_CACHE')) +print(" os.env.HF_HOME - ", os.environ.get('HF_HOME')) +print(" os.env.HF_HUB_OFFLINE - ", os.environ.get('HF_HUB_OFFLINE')) + import torch from tqdm import tqdm -import os from src import cfg from src.utils.loader import Loader DEVICE = torch.device("cuda:0" if torch.cuda.is_available() else "cpu") -print("os.env - ", os.environ['HF_HOME']) +print("\n############### After imports: #############") +print("os.env.TRANSFORMERS_CACHE - ", os.environ['TRANSFORMERS_CACHE']) +print(" os.env.HF_HOME - ", os.environ['HF_HOME']) +print(" os.env.HF_HUB_OFFLINE - ", os.environ['HF_HUB_OFFLINE']) m, _ = Loader.load_tuned_model('davis_esm', fold=0, device=DEVICE) m.eval()