Landslide Science
Rule · insar_creep
insar_creep
→ writes insar_creep
This is read live from inventory/derived.py via
inspect.getsource(); what you see is exactly what runs.
def compute_insar_creep(row):
"""Tri-state OR-merge of the per-study InSAR creep flags.
Preserves the distinction between "no study has flagged this" and
"no study has assessed this":
- True if any of (insar_schaefer, insar_kim, insar_opera, insar_other)
is explicitly True.
- False if at least one is explicitly False AND none is True
(i.e., at least one study assessed it and saw no creep).
- None if all four are NULL (no study has assessed this site).
"""
vals = [row.get(c) for c in
('insar_schaefer', 'insar_kim', 'insar_opera', 'insar_other')]
if any(v is True for v in vals):
return True
if any(v is False for v in vals):
return False
return None
All rows already match this rule — nothing to apply.