Skip to content

v2.0.0

Compare
Choose a tag to compare
@mcmcgrath13 mcmcgrath13 released this 14 Dec 19:10
· 485 commits to main since this release
2676ed3

v2.0.0

Version 2 of TITAN includes a major refactor and reorganization of the code base, the ability to use the model without HIV, and changes to the parameters to better capture their use in the model.

Breaking Changes

  • Params
    • demographics rearranged to reflect the actual classes the value is used at (as opposed to having it available at all levels) - sex_type key introduced and some items moved under drug_type (hiv, haart, death rate, num partners). E.g. demographics.black.MSM.hiv.init is now demographics.black.sex_type.MSM.drug_type.NonInj.hiv.init
    • aids key in demographics moved under hiv
    • drug_type now has sub-key ppl instead of init, params checking enforces the ppl s for a race/sex_type/drug_type combination must add to one
    • prep in the demographics had coverage changed to target and an explicit init key added
    • haart adherence changed to boolean adherent, this affects haart and haart_scaling params
    • msmw feature renamed to external_exposure, new params added to make it more abstract
    • pca feature retired and refactored into the pca interaction and the knowledge exposure
  • HIVModel renamed TITAN as the model no longer is explicitly an HIV model (though most available features explicitly use HIV at this time)
  • Base setting retired, those values now must be explicitly included in the setting or params
  • All agent attributes are saved with the population, no longer an option to just save core attributes
  • Standardized naming of reporting fields and removed reports other than the basic report
    • The columns in the report are dependent on the features/exposures enabled in the parameters

New Features

  • Exposures are the class of objects that can be transmitted in the model, currently hiv and knowledge
  • Interactions are the types of interactions that agents can have in the model, currently sex, injection, and pca
  • Features are interventions or similar events which affect the state of the agent, currently external_exposure (formerly msmw), haart, high_risk, incar, partner_tracing, prep, random_trial, syringe_services, vaccine
  • Random trial has been abstracted to allow treatments (prep or knowledge) to be administered independently of the enrollment type (all, bridge, random, eigenvector)
  • New settings added: Mississippi and NYC
  • prep target can be treated as a probability instead of a numeric target with target_as_prob set to true
  • modified_weibull added to available distribution types

Technical Notes

  • See the docs sections on exposures, interactions, and features for details on the required API and how to implement a new one
  • mypy can't statically determine that features and exposures validly exist on an agent, so the comment # type: ignore[attr-defined] is added to those lines to appease it
  • model.py is now agnostic to any exposures, interactions, or features so can be used as a base for any combination of those items
  • Each exposure, feature, and interaction file should be a standalone representation of that topic in the repository - there remain a few places where this could be improved, but the goal of standalone files should be used as a guiding principal in development