flow module¶
- class panco.descriptor.flow.Flow(arrival_curve: List[TokenBucket], path: List[int])¶
Bases:
object
The Flow class encodes a flow circulating in the network, characterized by
an arrival curve \(\alpha(t) = \min_i (\sigma_i + \rho_i t)\)
a path \(\pi\): the sequence of servers crossed by the flow.
- Parameters:
arrival_curve (List[TokenBucket]) – the arrival curve, given by a minimum of the token-bucket functions \(\alpha\)
path (List[int]) – the path (list of servers) followed by the flow \(\pi\)
self.length (int) – the length of the path
>>> Flow([TokenBucket(1, 2), TokenBucket(3, 4)], [1, 2, 3]) <Flow: α(t) = min [1 + 2t, 3 + 4t]; π = [1, 2, 3]>