We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0169520 commit 49a0d2aCopy full SHA for 49a0d2a
1 file changed
libmultilabel/common_utils.py
@@ -6,7 +6,6 @@
6
from functools import wraps
7
8
import numpy as np
9
-from pytorch_lightning.utilities.rank_zero import rank_zero_info
10
11
12
class AttributeDict(dict):
@@ -131,14 +130,14 @@ def is_multiclass_dataset(dataset, label="label"):
131
130
132
133
def timer(func):
134
- """Emit info-level wall time only on global rank 0."""
+ """Log info-level wall time"""
135
136
@wraps(func)
137
def wrapper(*args, **kwargs):
138
start_time = time.time()
139
value = func(*args, **kwargs)
140
wall_time = time.time() - start_time
141
- rank_zero_info(f"{repr(func.__name__)} finished in {wall_time:.2f} seconds")
+ logging.info(f"{repr(func.__name__)} finished in {wall_time:.2f} seconds")
142
return value
143
144
return wrapper
0 commit comments