Commit e73d011d authored by Martin Schrön's avatar Martin Schrön
Browse files

Allow master grid to contain soil and veg properties

parent cf33d386
......@@ -1481,8 +1481,12 @@ def main(configfile=None, cfg_prefix=None):
a0=float(config['conversion']['a0']), a1=float(config['conversion']['a1']), a2=float(config['conversion']['a2']))
if gridding:
M['soil_moisture'] = N2SM_Desilets(M['avg_neutrons'], N0, bd=M['bulk_density'],
lw=M['lattice_water'], owe=M['organic_water'],
M_bd = M['BD_smooth'] if 'BD_smooth' in M.columns else M['bulk_density']
M_lw = lw_from_clay( M['Clay_smooth']) if 'Clay_smooth' in M.columns else M['lattice_water']
M_owe = owe_from_corg(M['SOC_smooth'] ) if 'SOC_smooth' in M.columns else M['organic_water']
M_N = M['avg_neutrons']*M['Veg_Corr'] if 'Veg_Corr' in M.columns else M['avg_neutrons']
M['soil_moisture'] = N2SM_Desilets(M_N, N0, bd=M_bd, lw=M_lw, owe=M_owe,
a0=float(config['conversion']['a0']), a1=float(config['conversion']['a1']),
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment