You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the SIR model, for instance, samples neighbouring nodes with equal probability. I would like to see an option where edge weights can be used to weight the sampling.
The text was updated successfully, but these errors were encountered:
@GiulioRossetti I can implement this for the S*I* models relatively easily. I think the main point is to change: 1 - (1 - beta) ** len(infected_neighbors) as in:
but actually have it read the edge weights instead. So, something like: 1-np.prod((1 - beta) ** np.array(infected_neighbors_edge_weight)). That would work as now if the weights are all equal to 1:
But it will reweight things accordingly if infected_neighbors_edge_weight is different to unity. Does it make sense to you?
(EDIT: forgot the word "sense")
I made a fork of andlib on my account (https://github.com/hadjipantelis/ndlib). I think I have a working SIModel at this point, prelim. tests work as expected. I will do a quick pass of the S*I* models I can test on my own and PR it.
Currently, the SIR model, for instance, samples neighbouring nodes with equal probability. I would like to see an option where edge weights can be used to weight the sampling.
The text was updated successfully, but these errors were encountered: