From e0b8d804b294c38f3e8d6e75ceb227378ec6c37c Mon Sep 17 00:00:00 2001 From: shivesh Date: Sun, 14 Apr 2019 12:25:09 -0500 Subject: Sun 14 Apr 12:25:09 CDT 2019 --- sens.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'sens.py') diff --git a/sens.py b/sens.py index 6ecbea7..db3859b 100755 --- a/sens.py +++ b/sens.py @@ -229,7 +229,7 @@ def main(): ) llh = '{0}'.format(args.likelihood).split('.')[1] data = '{0}'.format(args.data).split('.')[1] - src_string = solve_ratio(args.source_ratio) + src_string = misc_utils.solve_ratio(args.source_ratio) prefix = args.mn_output + '/DIM{0}/{1}/{2}/s{3}/{4}'.format( args.dimension, data, llh, src_string, identifier ) @@ -252,10 +252,14 @@ def main(): stat_arr[idx_sc] = np.array([scale, stat]) # Cleanup. - for f in glob.glob(prefix + '*'): - os.remove(f) if reset_range is not None: scale_prm.ranges = reset_range + try: + for f in glob.glob(prefix + '*'): + os.remove(f) + except: + print 'got error trying to cleanup, continuing' + pass misc_utils.make_dir(outfile) print 'Saving to {0}'.format(outfile+'.npy') -- cgit v1.2.3