From 11c58e0c2a0973e67678c45c1becf1caed016e4f Mon Sep 17 00:00:00 2001 From: hectornieto Date: Mon, 28 Mar 2016 16:33:34 +0200 Subject: [PATCH] Fix bug in pyTSEB related to CalcSn_Campbell --- src/pyTSEB.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pyTSEB.py b/src/pyTSEB.py index 8263dfa..8009982 100644 --- a/src/pyTSEB.py +++ b/src/pyTSEB.py @@ -1014,10 +1014,10 @@ def RunTSEBImagePixelByPixel(self, inDataArray, outDataArray, mask): Omega=TSEB.CI.CalcOmega_Kustas(omega0,sza,wc=self.wc) LAI_eff=F*Omega # Estimate the net shorwave radiation - S_nS, S_nC = TSEB.rad.CalcSnCampbell (LAI_eff, sza, Sdn_dir, Sdn_dif, fvis,fnir, + S_nS, S_nC = TSEB.rad.CalcSnCampbell (lai, sza, Sdn_dir, Sdn_dif, fvis,fnir, self.spectraVeg['rho_leaf_vis'], self.spectraVeg['tau_leaf_vis'], self.spectraVeg['rho_leaf_nir'], self.spectraVeg['tau_leaf_nir'], - self.spectraGrd['rsoilv'], self.spectraGrd['rsoiln']) + self.spectraGrd['rsoilv'], self.spectraGrd['rsoiln'],LAI_eff=LAI_eff) # And the net longwave radiation L_nS,L_nC=TSEB.rad.CalcLnKustas (Tc, Ts,Lsky, lai,self.emisVeg, self.emisGrd) # Run TSEB with the component temperatures Ts and Tc @@ -1497,10 +1497,10 @@ def stra(param): Omega=TSEB.CI.CalcOmega_Kustas(omega0,sza,wc=wc) LAI_eff=F*Omega # Estimate the net shorwave radiation - S_nS, S_nC = TSEB.rad.CalcSnCampbell (LAI_eff, sza, Sdn_dir, Sdn_dif, fvis,fnir, + S_nS, S_nC = TSEB.rad.CalcSnCampbell (lai, sza, Sdn_dir, Sdn_dif, fvis,fnir, self.spectraVeg['rho_leaf_vis'], self.spectraVeg['tau_leaf_vis'], self.spectraVeg['rho_leaf_nir'], self.spectraVeg['tau_leaf_nir'], - self.spectraGrd['rsoilv'], self.spectraGrd['rsoiln']) + self.spectraGrd['rsoilv'], self.spectraGrd['rsoiln'],LAI_eff=LAI_eff) # And the net longwave radiation L_nS,L_nC=TSEB.rad.CalcLnKustas (Tc, Ts,Lsky, lai,self.emisVeg, self.emisGrd) # Run TSEB with the component temperatures Ts and Tc