from modules.prospect_d import prospect_d from modules.sail import sail def prosail(N, Cab, Car, Ant, Cbrown, Cw, Cm, LIDFa, LIDFb, TypeLidf, lai, hspot, tts, tto, psi, rsoil, wl, nr, Kab, Kcar, Kant, Kbrown, Kw, Km): """ PROSAIL simulator using PROSPECT-D + 4SAIL. Returns: refl: canopy directional reflectance LRT : leaf reflectance/transmittance spectra """ # Step 1: simulate leaf optical properties using PROSPECT-D LRT = prospect_d(N, Cab, Car, Ant, Cbrown, Cw, Cm, wl, nr, Kab, Kcar, Kant, Kbrown, Kw, Km) rho = LRT[:, 1] tau = LRT[:, 2] # Step 2: simulate canopy reflectance using 4SAIL refl = sail(rho, tau, LIDFa, LIDFb, TypeLidf, lai, hspot, tts, tto, psi, rsoil, wl) return wl, refl, LRT