summaryrefslogtreecommitdiffstats
path: root/hawkes/sanity.py
diff options
context:
space:
mode:
authorThibaut Horel <thibaut.horel@gmail.com>2015-09-14 23:08:02 -0400
committerThibaut Horel <thibaut.horel@gmail.com>2015-09-14 23:08:02 -0400
commitab0b1f3cefedb35327a19ec1b6afd560bfdf802d (patch)
treeb777f3e2c0ac0e712d8c5faab5107b1d236e2c3a /hawkes/sanity.py
parent960676226862d2d68c7a9c04c56d4f8157803025 (diff)
downloadcriminal_cascades-ab0b1f3cefedb35327a19ec1b6afd560bfdf802d.tar.gz
Import supplements and repo reorganization
Diffstat (limited to 'hawkes/sanity.py')
-rw-r--r--hawkes/sanity.py16
1 files changed, 0 insertions, 16 deletions
diff --git a/hawkes/sanity.py b/hawkes/sanity.py
deleted file mode 100644
index b6f25eb..0000000
--- a/hawkes/sanity.py
+++ /dev/null
@@ -1,16 +0,0 @@
-from cPickle import load
-from csv import reader
-from data2 import parse
-import sys
-
-
-def parse_row(row):
- return set(e for e in map(parse, row[2:]) if e)
-
-if __name__ == "__main__":
- nodes, edges, events, event_edges = load(open("data2.pickle", "rb"))
- with open(sys.argv[1]) as fh:
- fh.readline()
- reader = reader(fh)
- d = {parse(row[1]): parse_row(row) for row in reader}
- d = {k: v for (k, v) in d.iteritems() if v}