pyflwdir.FlwdirRaster.upstream_area#

FlwdirRaster.upstream_area(unit='cell')[source]#

Returns the upstream area map based on the flow direction map.

If latlon is True it converts the cell areas to metres, otherwise it assumes the coordinate unit is metres.

Parameters:

unit ({'m2', 'ha', 'km2', 'cell'}) – Upstream area unit.

Returns:

upstream area map [m2]

Return type:

2D array of float