Revision bd9bc508
Added by Jim Regetz over 12 years ago
- ID bd9bc50860719d093dc4da94ae9b13e187f789a3
climate/extra/aggregate-daily-lst.py | ||
---|---|---|
146 | 146 |
gs.mapcalc('nobs_%s = %s' % (name, denominator), overwrite=overwrite) |
147 | 147 |
numerator = '(%s)' % '+'.join(['if(isnull(%s), 0, %s)' % (m, m) |
148 | 148 |
for m in maplist]) |
149 |
#gs.mapcalc('mean_%s = round(float(%s)/nobs_%s)' % (name, numerator, name), |
|
150 |
gs.mapcalc('mean_%s = %s/nobs_%s' % (name, numerator, name), |
|
149 |
gs.mapcalc('mean_%s = round(float(%s)/nobs_%s)' % (name, numerator, name), |
|
151 | 150 |
overwrite=overwrite) |
152 | 151 |
|
153 | 152 |
def load_qc_adjusted_lst(hdf): |
... | ... | |
208 | 207 |
|
209 | 208 |
# generate monthly pixelwise mean & count of high-quality daytime LST |
210 | 209 |
# values |
211 |
### [atlas 17-May-2012] Wall time: 51.18 s
|
|
210 |
### [atlas 17-May-2012] Wall time: 53.79 s
|
|
212 | 211 |
gs.os.environ['GRASS_OVERWRITE'] = '1' |
213 | 212 |
LST = [load_qc_adjusted_lst(hdf) for hdf in hdfs] |
214 | 213 |
calc_clim(LST, 'LST_%s_%d_%03d_%03d' % (tile, year, start_doy, end_doy)) |
Also available in: Unified diff
switched from truncating to rounding mean LST back to integer