# HG changeset patch # User Nicolas Saunier # Date 1531369336 14400 # Node ID a2e20aba0740098c37d2803764503a36247a810e # Parent 671426ce0f3e22ae90fc7ff1d735d134dd4f6c6c bug correctiong diff -r 671426ce0f3e -r a2e20aba0740 scripts/process.py --- a/scripts/process.py Wed Jul 11 17:31:26 2018 -0400 +++ b/scripts/process.py Thu Jul 12 00:22:16 2018 -0400 @@ -214,7 +214,7 @@ # aggregation per site data = [] # list of observation per site-user with time headers = ['site', 'date', 'time', 'user_type'] - aggFunctions, tmpheaders = utils.aggregationMethods(arg.aggMethods, args.aggCentiles) + aggFunctions, tmpheaders = utils.aggregationMethods(args.aggMethods, args.aggCentiles) headers.extend(tmpheaders) for vs in videoSequences: d = vs.startTime.date() @@ -276,7 +276,7 @@ plt.savefig(events.Interaction.indicatorNames[i]+'.png', dpi=150) plt.close() -if args.analyze == 'event': # aggregate event data by 15 min interval (arg.intervalDuration), count events with thresholds +if args.analyze == 'event': # aggregate event data by 15 min interval (args.intervalDuration), count events with thresholds data = pd.read_csv(args.eventFilename, parse_dates = [2]) #data = pd.read_csv('./speeds.csv', converters = {'time': lambda s: datetime.datetime.strptime(s, "%H:%M:%S").time()}, nrows = 5000) # create time for end of each 15 min, then group by, using the agg method for each data column