#!/bin/csh

#source .env_mach_specific.csh
eval `../../cime/CIME/Tools/get_case_env`

set topdir = "/pscratch/sd/z/zhan391/DARPA_project/e3sm_model/code/deepONet"
setenv LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:${topdir}/pytorch/torch/lib:${topdir}/pytorch-fortran/gnu/install/lib"
#setenv PYTHONPATH "${topdir}/pytorch/torch" #/lib/python3.10/site-packages"

gfortran deeponet.f90 -o exec -g -fbounds-check -I${topdir}/pytorch/torch/include -I${topdir}/pytorch-fortran/gnu/install/include/mod_files -L${topdir}/pytorch-fortran/gnu/install/lib -lpytorch_fort_proxy -lpytorch_proxy

./exec #deepONet.pt 

#-L"/pscratch/sd/z/zhan391/DARPA_project/e3sm_model/code/deepONet/pytorch/torch/lib" $exp1

