diff options
| author | Ben Green <ben@SEASITs-MacBook-Pro.local> | 2015-06-16 00:38:40 -0400 |
|---|---|---|
| committer | Ben Green <ben@SEASITs-MacBook-Pro.local> | 2015-06-16 00:38:40 -0400 |
| commit | 289cc934a3e4c130563538a462e0cd32a08b0256 (patch) | |
| tree | a1159e3c7437e60c45ec47090234f54ce5143de1 /experiments/process.py | |
| parent | f7997e0c67ea85b42da94894b6a6f9bef7382170 (diff) | |
| download | criminal_cascades-289cc934a3e4c130563538a462e0cd32a08b0256.tar.gz | |
Changed model for spawning. Began fixing underflow error in
prob_success/failure
Diffstat (limited to 'experiments/process.py')
| -rw-r--r-- | experiments/process.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/experiments/process.py b/experiments/process.py index 8ebe953..68c3507 100644 --- a/experiments/process.py +++ b/experiments/process.py @@ -11,11 +11,16 @@ if __name__ == "__main__": sys.exit("usage: {0} <file>".format(sys.argv[0])) root_victims, victims, non_victims, age = load(open(sys.argv[1])) - alphas = 1. / np.arange(1., 1000., 50.) # parameter of the time component + alphas = 1. / np.arange(0., 1000., 100.) # parameter of the time component deltas = np.arange(0.01, 0.5, 0.1) # parameter of the structural component with open("out.log", "w") as fh: for alpha, delta in product(alphas, deltas): beta, roots, ll = ml(root_victims, victims, non_victims, age, alpha, delta) - print "\t".join(map(str, [1/alpha, delta, beta, roots, ll, exp(ll)])) + print "\t".join(map(str, [1/alpha, delta, beta, roots, ll])) fh.write("\t".join(map(str, [alpha, delta, beta, roots, ll])) + "\n") fh.flush() + + # alpha = 100. + # delta = 0.2 + # beta, roots, ll = ml(root_victims, victims, non_victims, age, alpha, delta) + # print "\t".join(map(str, [1./alpha, delta, beta, roots, ll]))
\ No newline at end of file |
