コード例 #1
0
def advance_lock_down(network, population, **kwargs):

    from metawards.iterators import advance_infprob
    from metawards.iterators import advance_play
    from metawards.iterators import advance_fixed

    state, rate, can_work = get_lock_down_vars(network=network, population=population)

    advance_infprob(scale_rate=rate, network=network, population=population, **kwargs)
    advance_play(network=network, population=population, **kwargs)
    if can_work:
        advance_fixed(network=network, population=population, **kwargs)
コード例 #2
0
def advance_lockdown_week(network, population, **kwargs):

    state, rate, can_work = get_lock_down_vars(network=network,
                                               population=population)

    advance_infprob(scale_rate=rate,
                    network=network,
                    population=population,
                    **kwargs)
    advance_play(network=network, population=population, **kwargs)
    if can_work:
        advance_fixed(network=network, population=population, **kwargs)