Fix testing glob patterns

This commit is contained in:
Yin Li 2019-12-18 14:37:48 -05:00
parent 796c7918d8
commit de24f8d585
4 changed files with 26 additions and 28 deletions

View File

@ -2,13 +2,11 @@
#SBATCH --job-name=dis2dis-test
#SBATCH --output=%x-%j.out
#SBATCH --error=%x-%j.err
#SBATCH --partition=ccm
#SBATCH --exclusive
#SBATCH --nodes=1
#SBATCH --mem=0
#SBATCH --time=1-00:00:00
@ -27,9 +25,9 @@ data_root_dir="/mnt/ceph/users/yinli/Quijote"
in_dir="linear"
tgt_dir="nonlin"
test_dirs="0" # FIXME
test_dirs="*99"
files="dis/512x???.npy"
files="dis/512x000.npy"
in_files="$files"
tgt_files="$files"
@ -37,9 +35,11 @@ tgt_files="$files"
m2m.py test \
--test-in-patterns "$data_root_dir/$in_dir/$test_dirs/$in_files" \
--test-tgt-patterns "$data_root_dir/$tgt_dir/$test_dirs/$tgt_files" \
--norms cosmology.dis --model VNet --cache --crop 128 --pad 50 \
--norms cosmology.dis --crop 128 --pad 42 \
--model VNet \
--load-state best_model.pth \
--batches 1 --loader-workers 0 \
--load-state best_model.pth
--cache
date

View File

@ -3,14 +3,12 @@
#SBATCH --job-name=dis2dis
#SBATCH --dependency=singleton
#SBATCH --output=%x-%j.out
#SBATCH --error=%x-%j.err
#SBATCH --partition=gpu
#SBATCH --gres=gpu:v100-32gb:4
#SBATCH --exclusive
#SBATCH --nodes=4
#SBATCH --mem=0
#SBATCH --time=7-00:00:00
@ -29,10 +27,10 @@ data_root_dir="/mnt/ceph/users/yinli/Quijote"
in_dir="linear"
tgt_dir="nonlin"
train_dirs="*[1-9]"
val_dirs="*[1-9]0"
train_dirs="*[0-8]"
val_dirs="*[0-8]9"
files="dis/128x???.npy"
files="dis/512x000.npy"
in_files="$files"
tgt_files="$files"
@ -42,9 +40,10 @@ srun m2m.py train \
--train-tgt-patterns "$data_root_dir/$tgt_dir/$train_dirs/$tgt_files" \
--val-in-patterns "$data_root_dir/$in_dir/$val_dirs/$in_files" \
--val-tgt-patterns "$data_root_dir/$tgt_dir/$val_dirs/$tgt_files" \
--norms cosmology.dis --augment --model VNet \
--epochs 1024 --batches 3 --loader-workers 3 --lr 0.001
# --load-state checkpoint.pth
--norms cosmology.dis --augment --crop 100 --pad 42 \
--model VNet \
# --load-state checkpoint.pth \
--epochs 128 --lr 0.001 --batches 1 --loader-workers 0
date

View File

@ -2,13 +2,11 @@
#SBATCH --job-name=vel2vel-test
#SBATCH --output=%x-%j.out
#SBATCH --error=%x-%j.err
#SBATCH --partition=ccm
#SBATCH --exclusive
#SBATCH --nodes=1
#SBATCH --mem=0
#SBATCH --time=1-00:00:00
@ -27,9 +25,9 @@ data_root_dir="/mnt/ceph/users/yinli/Quijote"
in_dir="linear"
tgt_dir="nonlin"
test_dirs="0" # FIXME
test_dirs="*99"
files="vel/512x???.npy"
files="vel/512x000.npy"
in_files="$files"
tgt_files="$files"
@ -37,9 +35,11 @@ tgt_files="$files"
m2m.py test \
--test-in-patterns "$data_root_dir/$in_dir/$test_dirs/$in_files" \
--test-tgt-patterns "$data_root_dir/$tgt_dir/$test_dirs/$tgt_files" \
--norms cosmology.vel --model VNet --cache --crop 128 --pad 50 \
--norms cosmology.vel --crop 128 --pad 42 \
--model VNet \
--load-state best_model.pth \
--batches 1 --loader-workers 0 \
--load-state best_model.pth
--cache
date

View File

@ -3,14 +3,12 @@
#SBATCH --job-name=vel2vel
#SBATCH --dependency=singleton
#SBATCH --output=%x-%j.out
#SBATCH --error=%x-%j.err
#SBATCH --partition=gpu
#SBATCH --gres=gpu:v100-32gb:4
#SBATCH --exclusive
#SBATCH --nodes=4
#SBATCH --mem=0
#SBATCH --time=7-00:00:00
@ -29,10 +27,10 @@ data_root_dir="/mnt/ceph/users/yinli/Quijote"
in_dir="linear"
tgt_dir="nonlin"
train_dirs="*[1-9]"
val_dirs="*[1-9]0"
train_dirs="*[0-8]"
val_dirs="*[0-8]9"
files="vel/128x???.npy"
files="vel/512x000.npy"
in_files="$files"
tgt_files="$files"
@ -42,9 +40,10 @@ srun m2m.py train \
--train-tgt-patterns "$data_root_dir/$tgt_dir/$train_dirs/$tgt_files" \
--val-in-patterns "$data_root_dir/$in_dir/$val_dirs/$in_files" \
--val-tgt-patterns "$data_root_dir/$tgt_dir/$val_dirs/$tgt_files" \
--norms cosmology.vel --augment --model VNet \
--epochs 1024 --batches 3 --loader-workers 3 --lr 0.001
# --load-state checkpoint.pth
--norms cosmology.vel --augment --crop 100 --pad 42 \
--model VNet \
# --load-state checkpoint.pth \
--epochs 128 --lr 0.001 --batches 1 --loader-workers 0
date