#%Module 1.0## julia# module-whatis"Load Julia (configured for XFEL)"# https://docs.julialang.org/en/v1/manual/environment-variables/#JULIA_DEPOT_PATHif{[infoexistsenv(SASE)]}{# On the online cluster we don't have scratch so we have to use the default depotsetenvJULIA_DEPOT_PATH$env(HOME)/.julia:/gpfs/exfel/sw/software/julia-depot:
}elseif{![filewritable/gpfs/exfel/data/scratch]}{# For users who don't have access to scratch we also have to use the default depotsetenvJULIA_DEPOT_PATH$env(HOME)/.julia:/gpfs/exfel/sw/software/julia-depot:
}elseif{[module-infousername"xsoft"]}{# For xsoft we only enable the global depotsetenvJULIA_DEPOT_PATH/gpfs/exfel/sw/software/julia-depot:
}else{setenvJULIA_DEPOT_PATH/gpfs/exfel/data/scratch/$env(USER)/julia-depot:/gpfs/exfel/sw/software/julia-depot:
}setenvJULIA_EXFEL_BINDIR/gpfs/exfel/sw/software/julia-depot/bin
setenvJULIA_EXFEL_ENV/gpfs/exfel/sw/software/euxfel-environment-management/environments/202502setenvJULIA_EXFEL_SYSIMAGE$env(JULIA_EXFEL_ENV)/julia-exfel-sysimage.so
# https://juliahpc.github.io/user_gettingstarted/#set_julia_cpu_target_appropriatelysetenvJULIA_CPU_TARGET"generic;broadwell,clone_all;skylake-avx512,clone_all;cascadelake,clone_all;sapphirerapids,clone_all;znver3,clone_all;znver2,clone_all"setenvJULIA_NUM_THREADSauto
setenvJULIA_PROJECT$env(JULIA_EXFEL_ENV)# https://docs.julialang.org/en/v1/manual/performance-tips/#man-multithreading-linear-algebrasetenvOPENBLAS_NUM_THREADS1# https://carstenbauer.github.io/ThreadPinning.jl/stable/examples/ex_blas/#Intel-MKLsetenvMKL_NUM_THREADS1# Need this for P100's to work: https://github.com/JuliaGPU/CUDA.jl/issues/3023setenvJULIA_CUDA_USE_COMPATfalse
# https://juliapy.github.io/PythonCall.jl/stable/pythoncall/#If-you-already-have-Python-and-required-Python-packages-installedsetenvJULIA_CONDAPKG_BACKENDNull
setenvJULIA_PYTHONCALL_EXE/gpfs/exfel/sw/software/euxfel-environment-management/environments/202502/.pixi/envs/default/bin/python
# setenv JULIA_PYTHONCALL_LIB /gpfs/exfel/sw/software/euxfel-environment-management/environments/202502/.pixi/envs/default/lib/libpython3.sosetenvPYTHON_JULIACALL_BINDIR/gpfs/exfel/sw/software/juliaup/juliaup/julia-1.12-nightly/bin
setenvPYTHON_JULIACALL_HANDLE_SIGNALSyes
setenvPYTHON_JULIACALL_EXE$env(PYTHON_JULIACALL_BINDIR)/julia
setenvPYTHON_JULIACALL_PROJECT$env(JULIA_EXFEL_ENV)setenvPYTHON_JULIAPKG_OFFLINEyes
# Needed for Bonito/WGLMakie to set the proxy URL automatically# setenv BONITO_JUPYTER_REMOTE_HOST "https://max-jhub.desy.de"# https://timholy.github.io/Revise.jl/stable/config/#Polling-and-NFS-mounted-code-directories:-JULIA_REVISE_POLLsetenvJULIA_REVISE_POLL1prepend-pathPATH/gpfs/exfel/sw/software/euxfel-environment-management/scripts/julia
prepend-pathPATH$env(PYTHON_JULIACALL_BINDIR)prepend-pathPATH$env(JULIA_EXFEL_BINDIR)system/gpfs/exfel/sw/software/euxfel-environment-management/scripts/julia/create-julia-depot
procModulesHelp{}{putsstdout" "putsstdout"This sets the path and environment variables for Julia 1.12"putsstdout" "}