Skip to content

Instantly share code, notes, and snippets.

View meteorologytoday's full-sized avatar

XTT meteorologytoday

View GitHub Profile
@meteorologytoday
meteorologytoday / compile_WRF_on_CW3E_expanse
Created January 5, 2024 22:27
Compile WRF on CW3E expanse
#!/bin/bash
# This file is intented to be descriptive
# rather than getting run
# ===== This is the used environment setup. I name it as .bashrc_WRF4.3 =====
ml purge
ml load gcc/9.2.0
@meteorologytoday
meteorologytoday / gist:42c35cac00bfaeabe6c2b8a6c9e978f4
Created August 9, 2023 16:40
Detect a range of lat lon (python + numpy)
import numpy as np
def findfirst(a):
return np.argmax(a)
def findlast(a):
return (len(a) - 1) - np.argmax(a[::-1])