UCL / TLOmodel

Epidemiology modelling framework for the Thanzi la Onse project
https://www.tlomodel.org/
MIT License
10 stars 4 forks source link

Setting up TLOmodel for analysts (not installing the repo in editable mode) #1030

Open tamuri opened 1 year ago

tamuri commented 1 year ago

The current instructions are geared towards developers of the TLOmodel i.e. cloning the respository, installing it in editable mode, and special treatment of the root TLOmodel directory e.g. in the writing of output files.

This is not necessary for those running scenarios: TLOmodel could be installed as a normal Python package & scenario scripts and outputs sit somewhere else.

thewati commented 2 months ago

Hi @tamuri, I have pushed a genanalysis.py file as a skeleton of the initial setup of the package. I wanted to check with you if this is also what you had in mind before I proceed. Below are some of the issues:

  1. Every analysis would have a function in the genanalysis.py file. This means an analyst (user) would just have to call the function of interest after running a pip install of the tlo model. For instance, the analyst would just call the function run_lifestlye_calibration in the genanalysis.py file to run analyses for the lifestlye module. Analyses for other modules would be run in a similar way (I would have to create functions for them).
  2. It seems there's another library on Pypi already called tlo. I thought it may not be able to deploy onto Pypi with a name already in use. Stumbled upon this while debugging.
  3. I am sure my naming of the files may not also be up to standard

I hope it all makes sense