|
@@ -181,8 +181,6 @@ def main():
|
|
|
dllogger.metadata("best_hr", {"unit": None})
|
|
dllogger.metadata("best_hr", {"unit": None})
|
|
|
dllogger.metadata("average_eval_time_per_epoch", {"unit": "s"})
|
|
dllogger.metadata("average_eval_time_per_epoch", {"unit": "s"})
|
|
|
dllogger.metadata("average_train_time_per_epoch", {"unit": "s"})
|
|
dllogger.metadata("average_train_time_per_epoch", {"unit": "s"})
|
|
|
- dllogger.metadata("time_to_best", {"unit": "s"})
|
|
|
|
|
- dllogger.metadata("time_to_train", {"unit": "s"})
|
|
|
|
|
dllogger.metadata("average_train_throughput", {"unit": "samples/s"})
|
|
dllogger.metadata("average_train_throughput", {"unit": "samples/s"})
|
|
|
dllogger.metadata("average_eval_throughput", {"unit": "samples/s"})
|
|
dllogger.metadata("average_eval_throughput", {"unit": "samples/s"})
|
|
|
|
|
|
|
@@ -346,7 +344,6 @@ def main():
|
|
|
eval_times = list()
|
|
eval_times = list()
|
|
|
# Accuracy Metrics
|
|
# Accuracy Metrics
|
|
|
first_to_target = None
|
|
first_to_target = None
|
|
|
- time_to_train = 0.0
|
|
|
|
|
best_hr = 0
|
|
best_hr = 0
|
|
|
best_epoch = 0
|
|
best_epoch = 0
|
|
|
# Buffers for global metrics
|
|
# Buffers for global metrics
|
|
@@ -361,7 +358,6 @@ def main():
|
|
|
local_ndcg_count = np.ones(1)
|
|
local_ndcg_count = np.ones(1)
|
|
|
|
|
|
|
|
# Begin training
|
|
# Begin training
|
|
|
- begin_train = time.time()
|
|
|
|
|
for epoch in range(args.epochs):
|
|
for epoch in range(args.epochs):
|
|
|
# Train for one epoch
|
|
# Train for one epoch
|
|
|
train_start = time.time()
|
|
train_start = time.time()
|
|
@@ -430,11 +426,9 @@ def main():
|
|
|
# Update summary metrics
|
|
# Update summary metrics
|
|
|
if hit_rate > args.target and first_to_target is None:
|
|
if hit_rate > args.target and first_to_target is None:
|
|
|
first_to_target = epoch
|
|
first_to_target = epoch
|
|
|
- time_to_train = time.time() - begin_train
|
|
|
|
|
if hit_rate > best_hr:
|
|
if hit_rate > best_hr:
|
|
|
best_hr = hit_rate
|
|
best_hr = hit_rate
|
|
|
best_epoch = epoch
|
|
best_epoch = epoch
|
|
|
- time_to_best = time.time() - begin_train
|
|
|
|
|
if hit_rate > args.target and final_checkpoint_path:
|
|
if hit_rate > args.target and final_checkpoint_path:
|
|
|
saver.save(sess, final_checkpoint_path)
|
|
saver.save(sess, final_checkpoint_path)
|
|
|
|
|
|
|
@@ -451,8 +445,6 @@ def main():
|
|
|
'average_eval_time_per_epoch': np.mean(eval_times),
|
|
'average_eval_time_per_epoch': np.mean(eval_times),
|
|
|
'average_eval_throughput': np.mean(eval_throughputs),
|
|
'average_eval_throughput': np.mean(eval_throughputs),
|
|
|
'first_epoch_to_hit': first_to_target,
|
|
'first_epoch_to_hit': first_to_target,
|
|
|
- 'time_to_train': time_to_train,
|
|
|
|
|
- 'time_to_best': time_to_best,
|
|
|
|
|
'best_hr': best_hr,
|
|
'best_hr': best_hr,
|
|
|
'best_epoch': best_epoch})
|
|
'best_epoch': best_epoch})
|
|
|
dllogger.flush()
|
|
dllogger.flush()
|