Closed rmnldwg closed 10 months ago
Recently, I needed to write a risk prediction in the LyProX app. There, too, I needed to write a lot of redundant stuff.
For example, the function create_diagnose_probs
in the LyProX' new risk predictor should be something I can use this library for. But since it's not well modularized, I needed to write that from scratch.
Similarly - or even more so - for the function create_marginalisation
: This is routinely computed in the lymph
library, but in a way that makes it somewhat hard to reuse from the outside. And therefore, I had to write that function again as well.
Currently, most of the methods do their job well, but can't be reused. There is also the issue with overlap in the functionality. For example, both inside the
likelihood
and therisk
methods, it computes the prior over the hidden states, given the spread parameters.To resolve this, large parts of the code base should be broken apart and refactored into smaller and more general methods. A consequence of this would also be that large methods like the
risk
and thelikelihood
are easier to understand on an abstract level and the smaller methods they are made up of can be tested more effectively.