Skip to content

Commit

Permalink
Merge pull request #271 from VectorInstitute/fix_elapsed_time
Browse files Browse the repository at this point in the history
Elapsed time was backwards
  • Loading branch information
scarere authored Oct 29, 2024
2 parents a3d0dfb + 6cab7fa commit 5be778d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fl4health/server/base_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ def fit(self, num_rounds: int, timeout: Optional[float]) -> Tuple[History, float
end_time = datetime.datetime.now()
self.reports_manager.report(
{
"fit_elapsed_time": str(start_time - end_time),
"fit_elapsed_time": str(end_time - start_time),
"fit_end": str(end_time),
"num_rounds": num_rounds,
"host_type": "server",
Expand Down Expand Up @@ -453,7 +453,7 @@ def fit(self, num_rounds: int, timeout: Optional[float]) -> Tuple[History, float
end_time = datetime.datetime.now()
self.reports_manager.report(
{
"fit_elapsed_time": str(start_time - end_time),
"fit_elapsed_time": str(end_time - start_time),
"fit_end": str(end_time),
"num_rounds": num_rounds,
"host_type": "server",
Expand Down

0 comments on commit 5be778d

Please sign in to comment.