Cion-lab commited on
Commit
76e690e
·
verified ·
1 Parent(s): 622b4e1

p4_stop_probe: redirect stderr only (bitmask 2) so the loss curve keeps streaming; ASCII the comment

Browse files
Files changed (1) hide show
  1. kernels/p4_stop_probe.py +4 -2
kernels/p4_stop_probe.py CHANGED
@@ -58,8 +58,10 @@ ROOT, RUN = "/kaggle/working/mixroot", "/kaggle/working/run"
58
  MODE = os.environ.get("P4_PROBE_MODE", "soak")
59
  TLOG = "/kaggle/working/tlogs"
60
  # torchrun takes its first positional as the SCRIPT, not a command: passing sys.executable made
61
- # it compile the Python binary (E-037). --redirects 3 = stdout+stderr per rank into --log-dir.
62
- TORCHRUN = ["torchrun", "--nproc_per_node=2", "--redirects", "3", "--log-dir", TLOG]
 
 
63
  TPS = 262144 # the run's real step shape, in tokens
64
  if MODE == "smoke":
65
  STEPS, PUSH_EVERY, STOP1, VAL = 20, 10, 10, 200000
 
58
  MODE = os.environ.get("P4_PROBE_MODE", "soak")
59
  TLOG = "/kaggle/working/tlogs"
60
  # torchrun takes its first positional as the SCRIPT, not a command: passing sys.executable made
61
+ # it compile the Python binary (E-037). --redirects is a bitmask into the --log-dir per rank:
62
+ # 2 = redirect only stderr, so rank 1's traceback lands in a file while stdout (the loss curve,
63
+ # which §5 requires monitoring on every wake) still streams live to this log. 3 would file both.
64
+ TORCHRUN = ["torchrun", "--nproc_per_node=2", "--redirects", "2", "--log-dir", TLOG]
65
  TPS = 262144 # the run's real step shape, in tokens
66
  if MODE == "smoke":
67
  STEPS, PUSH_EVERY, STOP1, VAL = 20, 10, 10, 200000