SingleFlowRouter

class fastscape.processes.SingleFlowRouter(*, shape, elevation, fs_context)

Single direction (convergent) flow router.

shape

Nb. of grid nodes in (y, x)

Variable properties:

Type:

attr.Attribute

elevation

Surface elevation before erosion

Variable properties:

Type:

attr.Attribute

fs_context

Accessor to fastscapelib-fortran internal variables

Variable properties:

  • type : foreign

  • reference variable : FastscapelibContext.context

  • intent : in

Type:

attr.Attribute

stack

Dfs ordered grid node indices

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’,)

Type:

attr.Attribute

nb_receivers

Number of flow receivers

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’,)

Type:

attr.Attribute

receivers

Flow receiver node indices

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’,) or (‘node’, ‘nb_rec_max’)

Type:

attr.Attribute

lengths

Out flow path length

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’,) or (‘node’, ‘nb_rec_max’)

Type:

attr.Attribute

weights

Flow partition weights

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’,) or (‘node’, ‘nb_rec_max’)

Type:

attr.Attribute

nb_donors

Number of flow donors

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’,)

Type:

attr.Attribute

donors

Flow donors node indices

Variable properties:

  • type : variable

  • intent : out

  • dimensions : (‘node’, ‘nb_don_max’)

Type:

attr.Attribute

basin

River catchments

Variable properties:

  • type : on_demand

  • intent : out

  • dimensions : (‘y’, ‘x’)

Type:

attr.Attribute

lake_depth

Lake depth

Variable properties:

  • type : on_demand

  • intent : out

  • dimensions : (‘y’, ‘x’)

Type:

attr.Attribute

slope

Out flow path slope

Variable properties:

  • type : on_demand

  • intent : out

  • dimensions : (‘node’,)

Type:

attr.Attribute

Methods

__init__(*, shape, elevation, fs_context)

Method generated by attrs for class SingleFlowRouter.

initialize()

route_flow()

run_step()

Output of process info:

In [1]: import xsimlab as xs

In [2]: from fastscape.processes import SingleFlowRouter

In [3]: xs.process_info(SingleFlowRouter)
<SingleFlowRouter  (xsimlab process)>
Variables:
    shape            [in] <--- UniformRectilinearGrid2D.shape
    elevation        [in] <--- SurfaceToErode.elevation
    fs_context       [in] <--- FastscapelibContext.context
    stack           [out] ('node',) DFS ordered grid node indices
    nb_receivers    [out] ('node',) number of flow receivers
    receivers       [out] ('node',) or ('node', 'nb_rec_max') flow ...
    lengths         [out] ('node',) or ('node', 'nb_rec_max') out f...
    weights         [out] ('node',) or ('node', 'nb_rec_max') flow ...
    nb_donors       [out] ('node',) number of flow donors
    donors          [out] ('node', 'nb_don_max') flow donors node i...
    basin           [out] ('y', 'x') river catchments
    lake_depth      [out] ('y', 'x') lake depth
    slope           [out] ('node',) out flow path slope
Simulation stages:
    initialize
    run_step