diseases.hiv

diseases.hiv

Define HIV disease module

Classes

Name Description
HIV HIV disease module.
HIVPars Parameters for the HIV disease module.

HIV

diseases.hiv.HIV(pars=None, init_prev_data=None, **kwargs)

HIV disease module.

Models HIV infection with CD4-driven natural history (acute, latent, and falling stages), ART treatment with CD4 reconstitution, diagnosis tracking, and AIDS-related mortality. Supports mother-to-child transmission when a pregnancy demographic module is present.

Parameters

Name Type Description Default
pars dict Override default parameters from HIVPars. None
init_prev_data Optional initial prevalence data by age/sex/risk group. None
**kwargs Additional parameters passed to update_pars. {}

Methods

Name Description
acute_decline Acute decline in CD4
cd4_increase Increase CD4 counts for people who are receiving treatment.
falling_decline Decline in CD4 during late-stage infection, when counts are falling
init_care_seeking Set care seeking behavior
init_cd4 Set CD4 counts
init_post Set states
init_results Initialize results
make_p_hiv_death Calculate per-timestep HIV death probability based on current CD4 count.
plot Plot key HIV results
post_art_decline Decline in CD4 after going off treatment
set_prognoses Set prognoses upon infection
start_art Check who is ready to start ART treatment and put them on ART
step_die Clear all states for dead agents
step_state Carry out autonomous updates at the start of the timestep (prior to transmission)
stop_art Check who is stopping ART treatment and put them off ART
update_results Update results at each time step
update_transmission Update rel_trans and rel_sus for all agents. These are reset on each timestep then adjusted depending on states.
acute_decline
diseases.hiv.HIV.acute_decline(uids)

Acute decline in CD4

cd4_increase
diseases.hiv.HIV.cd4_increase(uids)

Increase CD4 counts for people who are receiving treatment. Growth curves are calculated to match EMODs CD4 reconstitution equation for people who initiate treatment with a CD4 count of 50 (https://docs.idmod.org/projects/emod-hiv/en/latest/hiv-model-healthcare-systems.html) However, here we use a logistic growth function and assume that ART CD4 count depends on CD4 at initiation. Sources:

- https://i-base.info/guides/starting/cd4-increase
- https://www.sciencedirect.com/science/article/pii/S1876034117302022
- https://bmcinfectdis.biomedcentral.com/articles/10.1186/1471-2334-8-20
falling_decline
diseases.hiv.HIV.falling_decline(uids)

Decline in CD4 during late-stage infection, when counts are falling

init_care_seeking
diseases.hiv.HIV.init_care_seeking()

Set care seeking behavior

init_cd4
diseases.hiv.HIV.init_cd4()

Set CD4 counts

init_post
diseases.hiv.HIV.init_post()

Set states

init_results
diseases.hiv.HIV.init_results()

Initialize results

make_p_hiv_death
diseases.hiv.HIV.make_p_hiv_death(uids=None)

Calculate per-timestep HIV death probability based on current CD4 count.

Uses CD4-stratified annual mortality rates, digitized into bins. Rates are converted from per-year to per-timestep probabilities.

plot
diseases.hiv.HIV.plot()

Plot key HIV results

post_art_decline
diseases.hiv.HIV.post_art_decline(uids)

Decline in CD4 after going off treatment This implementation has the possibly-undesirable feature that a person who goes on ART for a year and then off again might have a slightly shorter lifespan than if they’d never started treatment.

set_prognoses
diseases.hiv.HIV.set_prognoses(uids, sources=None, ti=None)

Set prognoses upon infection

start_art
diseases.hiv.HIV.start_art(uids)

Check who is ready to start ART treatment and put them on ART

step_die
diseases.hiv.HIV.step_die(uids)

Clear all states for dead agents

step_state
diseases.hiv.HIV.step_state()

Carry out autonomous updates at the start of the timestep (prior to transmission)

stop_art
diseases.hiv.HIV.stop_art(uids=None)

Check who is stopping ART treatment and put them off ART

update_results
diseases.hiv.HIV.update_results()

Update results at each time step

update_transmission
diseases.hiv.HIV.update_transmission()

Update rel_trans and rel_sus for all agents. These are reset on each timestep then adjusted depending on states. Adjustments are made throughout different modules:

  • rel_trans for acute and late-stage untreated infection are adjusted below
  • rel_trans for all people on treatment (including pregnant women) below
  • rel_sus for unborn babies of pregnant WLHIV receiving treatment is adjusted in the ART intervention

HIVPars

diseases.hiv.HIVPars(**kwargs)

Parameters for the HIV disease module.

Holds natural history parameters (CD4 dynamics, acute/latent/falling stage durations), transmission rates, ART treatment effects, and care-seeking behavior configuration.