mirror of
https://github.com/wassname/ray.git
synced 2026-07-04 01:24:26 +08:00
Change memory monitor warning to a logging call (#8137)
This commit is contained in:
@@ -92,10 +92,10 @@ class MemoryMonitor:
|
||||
except IOError:
|
||||
self.cgroup_memory_limit_gb = sys.maxsize / (1024**3)
|
||||
if not psutil:
|
||||
print("WARNING: Not monitoring node memory since `psutil` is not "
|
||||
"installed. Install this with `pip install psutil` "
|
||||
"(or ray[debug]) to enable debugging of memory-related "
|
||||
"crashes.")
|
||||
logger.warn("WARNING: Not monitoring node memory since `psutil` "
|
||||
"is not installed. Install this with "
|
||||
"`pip install psutil` (or ray[debug]) to enable "
|
||||
"debugging of memory-related crashes.")
|
||||
|
||||
def set_heap_limit(self, worker_name, limit_bytes):
|
||||
self.heap_limit = limit_bytes
|
||||
|
||||
Reference in New Issue
Block a user