in smdebug_rulesconfig/profiler_rules/rules.py [0:0]
def __init__(self, min_threshold=70, max_threshold=200, scan_interval_us=60000000):
"""
This rule helps to detect how many dataloader processes are running in parallel and whether the total number is equal the number of available CPU cores.
:param min_threshold: how many cores should be at least used by dataloading processes. Default 70%
:param max_threshold: how many cores should be at maximum used by dataloading processes. Default 200%
:param scan_interval_us: interval with which timeline files are scanned. Default is 60000000 us.
"""
validate_positive_integer(self.__class__.__name__, "min_threshold", min_threshold)
validate_positive_integer(self.__class__.__name__, "max_threshold", max_threshold)
validate_positive_integer(self.__class__.__name__, "scan_interval_us", scan_interval_us)
super().__init__(
min_threshold=min_threshold,
max_threshold=max_threshold,
scan_interval_us=scan_interval_us,
)
self.min_threshold = min_threshold
self.max_threshold = max_threshold
self.scan_interval_us = scan_interval_us