ldhldh commited on
Commit
ce5ec0c
·
1 Parent(s): b23968e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -86,7 +86,7 @@ timestamp_list = []
86
 
87
  name_list = []
88
  timestamp_gpu_data = []
89
- timestamp_inference_data = []
90
  timestamp_list_date = []
91
 
92
  for block in sample_data['chain']:
@@ -97,10 +97,11 @@ for block in sample_data['chain']:
97
  name_list.append(t['id'])
98
 
99
  timestamp_gpu_data = [[0 for _ in range(len(name_list))]]
100
- timestamp_inference_data = [sample_data['chain'][0]['timestamp']]
 
101
  for block in sample_data['chain']:
102
  temp = timestamp_gpu_data[int(block['index']) - 1]
103
- if str(strftime('%Y-%m-%d', localtime( timestamp_list_date[-1] ))) != str(strftime('%Y-%m-%d', localtime( block['timestamp'] ))):
104
  timestamp_list_date.append(block['timestamp'])
105
  timestamp_inference_data.append(0)
106
 
 
86
 
87
  name_list = []
88
  timestamp_gpu_data = []
89
+ timestamp_inference_data = [0]
90
  timestamp_list_date = []
91
 
92
  for block in sample_data['chain']:
 
97
  name_list.append(t['id'])
98
 
99
  timestamp_gpu_data = [[0 for _ in range(len(name_list))]]
100
+ timestamp_list_date = [sample_data['chain'][0]['timestamp']]
101
+
102
  for block in sample_data['chain']:
103
  temp = timestamp_gpu_data[int(block['index']) - 1]
104
+ if strftime('%Y-%m-%d', localtime( timestamp_list_date[-1] )) != strftime('%Y-%m-%d', localtime( block['timestamp'] )):
105
  timestamp_list_date.append(block['timestamp'])
106
  timestamp_inference_data.append(0)
107