Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)

src/c/h/chitwanabm-1.5/chitwanabm/agents.py   chitwanabm(Download)
from chitwanabm import rc_params
from chitwanabm.statistics import calc_probability_death, \
        calc_probability_migration_simple, calc_first_birth_time, \
        calc_birth_interval, calc_hh_area, calc_des_num_children, \
        deaths = {}
        for person in self.iter_all_persons():
            if np.random.rand() < calc_probability_death(person):
                if not person.is_away():
                    # People who in Chitwan need to have their deaths tracked