Skip to content

patrickleotardif/infection

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Requirements

No package dependencies. Needs Python 2.7+ (uses dict comprehension)

Tested on 2.7 and shouldn't have any deprecated features in use as far as I know

Usage

command line : run python infection.py to run a quick test suite

python module : relevant methods include

  • randomHierarchicalGraph(size, template) : using given template (see comments for details) and size, return dict of Users representing a random graph
  • totalInfection(users,seed) : given dict of Users and a seed, return set of user ids that are infected
  • limitedInfection(users,seed,minUsers,maxUsers) : same as above, except with given minUsers and maxUsers (picks solutions within threshold where possible)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages