#!/bin/bash

#SBATCH --qos=debug
#SBATCH -A bsc32
#SBATCH --cpus-per-task=1
#SBATCH -n 1
#SBATCH -t 00:30:00
#SBATCH -J NES_mn4_tests
#SBATCH --output=log_mn4_NES_%j.out
#SBATCH --error=log_mn4_NES_%j.err
#SBATCH --exclusive

### ulimit -s 128000

module purge
module use /gpfs/projects/bsc32/software/suselinux/11/modules/all

module load Python/3.7.4-GCCcore-8.3.0
module load netcdf4-python/1.5.3-foss-2019b-Python-3.7.4
module load cfunits/1.8-foss-2019b-Python-3.7.4
module load xarray/0.17.0-foss-2019b-Python-3.7.4
module load OpenMPI/4.0.5-GCC-8.3.0-mn4
module load filelock/3.7.1-foss-2019b-Python-3.7.4
module load eccodes-python/0.9.5-foss-2019b-Python-3.7.4
module load pyproj/2.5.0-foss-2019b-Python-3.7.4
module load geopandas/0.8.1-foss-2019b-Python-3.7.4
module load Shapely/1.7.1-foss-2019b-Python-3.7.4

# export PYTHONPATH=/gpfs/projects/bsc32/models/NES_master:${PYTHONPATH}
# cd /gpfs/projects/bsc32/models/NES_master/tests

export PYTHONPATH=/gpfs/scratch/bsc32/bsc32538/NES_tests/NES:${PYTHONPATH}
cd /gpfs/scratch/bsc32/bsc32538/NES_tests/NES/tests

mpirun --mca mpi_warn_on_fork 0 -np 1 python test_interp_conservative.py
