solprop.calibration.child#
A calibration child: one candidate’s process settings, timed on request (SEP 46).
The controller starts one child per candidate process setting (SEP 46 section 6.2),
with the setting in its environment, and drives it over JSON lines on its standard
input and output. The child pins itself to the allocation being calibrated before the
native runtime starts, builds the calibration problems, and then times their windows
as the controller asks, under the workspace record it is given or its process’s own.
It never calibrates and never reads a profile (SOLPROP_CALIBRATION=off).
Run as python -m solprop.calibration.child CPUS, CPUS a comma-separated list
of logical CPUs (empty for no pinning). Requests:
{"op": "prepare", "problems": {"gnlse": 1.0, ...}}
{"op": "time", "problem": "gnlse", "repeats": 40, "record": {...} | null,
"planning": {...} | null}
{"op": "sizing", "record": {...} | null}
{"op": "capture", "effort": "measure", "limit": 2.0, "budget": 30.0,
"record": {...} | null}
{"op": "regions", "elements": 1000, "repeats": 200}
{"op": "exit"}
Each request has one reply line, {"ok": ...} or {"error": "..."}.
Functions
|
Pin, then serve the controller on the process's standard streams. |
|
Pin this process to cpus before the native runtime starts. |
|
Answer requests until |
- solprop.calibration.child.main(argv=None)[source]#
Pin, then serve the controller on the process’s standard streams.
The protocol keeps a private copy of standard output; anything else the process or the native runtime prints goes to standard error.
- Parameters:
- argvsequence of str or None, optional
[CPUS]; the process’s own arguments whenNone.
- Returns:
- int
Zero.
- solprop.calibration.child.pin(cpus)[source]#
Pin this process to cpus before the native runtime starts.
Linux sets its affinity mask; Windows its process affinity mask (CPUs of the first processor group); macOS has no affinity, and is left alone.
- Parameters:
- cpussequence of int
Logical CPUs; empty leaves the process as it is.