Skip to content

Commit

Permalink
Fixed mean, median, and ninetieth print statements
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben Edidin committed Apr 17, 2024
1 parent 837cd15 commit 05800d5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/scripts/eval_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ def eval(cfg: DictConfig) -> None:
loss: torch.Tensor = criterion(output, target)

log_dict = eval_metrics(cfg, features, target, output, loss, prefix="test")
mean.append(log_dict["test/avg_l1"])
med.append(log_dict["test/med_l1"])
ninetieth.append(log_dict["test/ninetieth_l1"])
mean.append(log_dict[f"l1_movement_mean/time_{cfg.time_steps-1}"])
med.append(log_dict[f"l1_movement_median/time_{cfg.time_steps-1}"])
ninetieth.append(log_dict[f"l1_movement_90th_percentile/time_{cfg.time_steps-1}"])

print(f"Mean: {sum(mean) / len(mean)}")
print(f"Median: {sum(med) / len(med)}")
Expand Down

0 comments on commit 05800d5

Please sign in to comment.