-
Notifications
You must be signed in to change notification settings - Fork 0
/
ReadMe.txt
executable file
·67 lines (51 loc) · 3.22 KB
/
ReadMe.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
========================================================================
Network Inference (NETINF)
========================================================================
Tracking how information diffuses or how viruses spread over networks has been
a topic of considerable interest. While observing how nodes change state
(e.g., become infected) is often possible, observing the individual
transmissions (i.e., who infects whom) is typically very difficult.
Furthermore, in many scenarios the underlying network over which the diffusions
and propagations take place is actually unobserved.
We tackle these challenges by developing NETINF to infer the network over which diffusion
and infections propagate. Given the times when nodes adopt pieces of information or become
infected (i.e. cascades), we develop a scalable algorithm to infer the links in the underlying
network over which the propagations take place.
For more information about the procedure see:
Inferring Networks of Diffusion
Manuel Gomez-Rodriguez, Jure Leskovec, Andreas Krause.
http://www.stanford.edu/~manuelgr/netinf-www10.pdf
Depending on the platform (Windows or Linux) you need to edit the Makefile.
Use 'make opt' to compile the optimized (fast) version of the code.
/////////////////////////////////////////////////////////////////////////////
Parameters:
-i:Input cascades (one file) (default:'example-cascades.txt')
-n:Input ground-truth network (one file) (default:'example-network.txt')
-o:Output file name(s) prefix (default:'network')
-e:Number of iterations (default:'5')
-a:Alpha for exponential model (default:1)
-s:How much additional files to create?
1:info about each edge, 2:objective function value (+upper bound), 3:Precision-recall plot, 4:all-additional-files (default:1)
(default:1)
Generally -s:1 is the fastest (computes the least additional stuff), while -s:3
takes longest to run but calculates all the additional stuff.
/////////////////////////////////////////////////////////////////////////////
Usage:
Infer the network given a text file with cascades (nodes and timestamps):
netinf -i:demo_cascades.txt
/////////////////////////////////////////////////////////////////////////////
Format input cascades:
The cascades input file should have two blocks separated by a blank line.
- A first block with a line per node. The format of every line is <id>,<name>
- A second block with a line per cascade. The format of every line is <id>,<timestamp>;<id>,<timestamp>;<id>,<timestamp>...
A demo input file can be found under the name example-cascades.txt.
/////////////////////////////////////////////////////////////////////////////
Format gound truth:
The ground truth input file should have two blocks separated by a blank line
- A first block with a line per node. The format of every line is <id>,<name>
- A second block with a line per directed edge. The format of every line is <id1>,<id2>
/////////////////////////////////////////////////////////////////////////////
Additional Tool:
In addition, generate-nets is also provided. It allows to
build Kronecker and Forest-Fire networks and generate cascades. Please, run
without any argument to see how to use them.