richter2: Schnappschuss (Befehl + Schalter je Arm, 16:47) und Exe-Kopie pokerbench-rnr-richter2.exe (md5 5fa0b0d0); Neustarts laufen nur darauf, nie auf dem Live-Stand von jetzt (Hybrid live 17:00)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -45,16 +45,41 @@ def md5(p):
|
||||
return hashlib.md5(open(p, "rb").read()).hexdigest()
|
||||
|
||||
|
||||
FEST = os.path.join(HIER, "schnappschuss.json") # 29.11. 17:05: Hybrid live (neue Exe + Schalter); Neustarts bleiben auf dem Stand von 16:47
|
||||
EXE_FEST = os.path.join(W, "entscheiden", "motor", "target", "release", "pokerbench-rnr-richter2.exe")
|
||||
|
||||
|
||||
def starte_fest(arm):
|
||||
"""Neustart eines Arms genau mit Befehl und Schaltern aus schnappschuss.json (Exe-Kopie, md5 geprueft), nie mit dem Live-Stand von jetzt."""
|
||||
import subprocess, queue, threading, re
|
||||
S = json.load(open(FEST, encoding="utf-8")); A = S["arme"][arm]
|
||||
assert md5(EXE_FEST) == S["exe_md5"], "Exe-Kopie passt nicht zum Schnappschuss"
|
||||
bekannt = set(re.findall(r'"([A-Z][A-Z0-9_]+)"', open(os.path.join(LM.LIVE, "entscheiden", "decide.py"), encoding="utf-8").read()))
|
||||
env = {k: v for k, v in os.environ.items() if k not in bekannt and k not in A["schalter"]}
|
||||
env.update(A["schalter"]); env["RAYON_NUM_THREADS"] = FAEDEN
|
||||
p = subprocess.Popen([EXE_FEST] + A["befehl"][1:], stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True,
|
||||
encoding="utf-8", bufsize=1, creationflags=0x08004000, env=env)
|
||||
out = queue.Queue(); threading.Thread(target=lambda: [out.put(z) for z in p.stdout], daemon=True).start()
|
||||
return p, out, [], {"befehl": [EXE_FEST] + A["befehl"][1:], "schalter": A["schalter"], "fest": True}
|
||||
|
||||
|
||||
def lauf(arm):
|
||||
"""ein Arm, ein Motor-Prozess -> antworten_<arm>.jsonl"""
|
||||
if os.path.exists(FEST):
|
||||
return lauf_mit(arm, starte_fest(arm))
|
||||
assert md5(EXE) == md5(LIVE_EXE), "Exe ist nicht die Live-Exe"
|
||||
extra, ohne = ARME[arm]
|
||||
return lauf_mit(arm, LM.starte(EXE, extra, ohne, FAEDEN))
|
||||
|
||||
|
||||
def lauf_mit(arm, m):
|
||||
F, N = anfragen(); print("Haende", N, "Turn/River-Anfragen", len(F), "Arm", arm, flush=True)
|
||||
aus = os.path.join(HIER, "antworten_%s.jsonl" % arm)
|
||||
fertig = set(x["i"] for x in lesen(arm))
|
||||
extra, ohne = ARME[arm]
|
||||
m = LM.starte(EXE, extra, ohne, FAEDEN); open(os.path.join(HIER, "lauf_%s.pid" % arm), "w").write(str(m[0].pid))
|
||||
open(os.path.join(HIER, "lauf_%s.pid" % arm), "w").write(str(m[0].pid))
|
||||
print("Motor", json.dumps(m[3], ensure_ascii=False), flush=True)
|
||||
vertrauen_an = "VERTRAUEN" not in ohne and (m[3]["schalter"].get("VERTRAUEN") == "1")
|
||||
vertrauen_an = "VERTRAUEN" not in ohne and "MOTOR_RNR" in m[3]["schalter"] and (m[3]["schalter"].get("VERTRAUEN") == "1")
|
||||
if vertrauen_an:
|
||||
os.environ["VERTRAUEN"] = "1"; import vertrauen
|
||||
assert os.path.normcase(os.path.dirname(vertrauen.__file__)) == os.path.normcase(os.path.normpath(os.path.join(LM.LIVE, "entscheiden")))
|
||||
|
||||
@@ -0,0 +1,185 @@
|
||||
{
|
||||
"zeit": "2026-11-29 16:47",
|
||||
"exe_md5": "5fa0b0d02189ba7fd1fe49ab40a8020f",
|
||||
"arme": {
|
||||
"live": {
|
||||
"befehl": [
|
||||
"D:\\Projects\\pokerfreak\\.claude\\worktrees\\motor-rnr\\entscheiden\\motor\\target\\release\\pokerbench-rnr-live2.exe",
|
||||
"dienst",
|
||||
"sechs100",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor",
|
||||
"2000-600-400",
|
||||
"200q400",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\sechs100-q.bin",
|
||||
"genau",
|
||||
"hu=D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu100-v1.bin,D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu200-v2.bin"
|
||||
],
|
||||
"schalter": {
|
||||
"GEGNERZAHL_FEST": "1",
|
||||
"MOTOR_BAHN_STAU": "1",
|
||||
"MOTOR_BRETTQ": "1",
|
||||
"MOTOR_FLOPBLUFF": "0",
|
||||
"MOTOR_FOLDRUNDUNG": "0",
|
||||
"MOTOR_LUFT": "0",
|
||||
"MOTOR_NACH_BREIT": "1",
|
||||
"MOTOR_NACH_BREIT_FRIST": "2.5",
|
||||
"MOTOR_NACH_BREIT_MAL": "3",
|
||||
"MOTOR_NACH_BREIT_SCHAETZ": "3",
|
||||
"MOTOR_NACH_BREIT_ZIEL": "1",
|
||||
"MOTOR_RNR": "1",
|
||||
"MOTOR_RNR_MODELL": "pool",
|
||||
"MOTOR_STRASSEN": "0",
|
||||
"MOTOR_SUCHE_BODEN_VR": "0.1",
|
||||
"MOTOR_SUCHE_RIVER_JAM": "1",
|
||||
"MOTOR_TEMPO_LOS": "1",
|
||||
"MOTOR_VORRECHNEN_MERK": "6",
|
||||
"MOTOR_VORRECHNEN_STRASSE": "1",
|
||||
"TISCHWAHL": "1",
|
||||
"TISCHWAHL_GEWICHTE": "hhd",
|
||||
"TISCHWAHL_STAFFEL": "1",
|
||||
"TISCHWAHL_VERGLEICH": "1",
|
||||
"TISCHWAHL_WARTEN": "1",
|
||||
"VERTRAUEN": "1",
|
||||
"VORWISSEN": "C:\\Users\\marcm\\pokerfreak-vorwissen\\speicher-1117-h90v.json.gz",
|
||||
"VORWISSEN_ART": "fold",
|
||||
"VORWISSEN_OHNE": "raiseToBet,reraiseToRaise"
|
||||
},
|
||||
"ohne": []
|
||||
},
|
||||
"k2": {
|
||||
"befehl": [
|
||||
"D:\\Projects\\pokerfreak\\.claude\\worktrees\\motor-rnr\\entscheiden\\motor\\target\\release\\pokerbench-rnr-live2.exe",
|
||||
"dienst",
|
||||
"sechs100",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor",
|
||||
"2000-600-400",
|
||||
"200q400",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\sechs100-q.bin",
|
||||
"genau",
|
||||
"hu=D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu100-v1.bin,D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu200-v2.bin"
|
||||
],
|
||||
"schalter": {
|
||||
"GEGNERZAHL_FEST": "1",
|
||||
"MOTOR_BAHN_STAU": "1",
|
||||
"MOTOR_BRETTQ": "1",
|
||||
"MOTOR_FLOPBLUFF": "0",
|
||||
"MOTOR_FOLDRUNDUNG": "0",
|
||||
"MOTOR_LUFT": "0",
|
||||
"MOTOR_NACH_BREIT": "1",
|
||||
"MOTOR_NACH_BREIT_FRIST": "2.5",
|
||||
"MOTOR_NACH_BREIT_MAL": "3",
|
||||
"MOTOR_NACH_BREIT_SCHAETZ": "3",
|
||||
"MOTOR_NACH_BREIT_ZIEL": "1",
|
||||
"MOTOR_RNR": "1",
|
||||
"MOTOR_RNR_GEGEN": "1",
|
||||
"MOTOR_RNR_MODELL": "pool",
|
||||
"MOTOR_RNR_TURN": "1",
|
||||
"MOTOR_STRASSEN": "0",
|
||||
"MOTOR_SUCHE_BODEN_VR": "0.1",
|
||||
"MOTOR_SUCHE_RIVER_JAM": "1",
|
||||
"MOTOR_TEMPO_LOS": "1",
|
||||
"MOTOR_VORRECHNEN_MERK": "6",
|
||||
"MOTOR_VORRECHNEN_STRASSE": "1",
|
||||
"TISCHWAHL": "1",
|
||||
"TISCHWAHL_GEWICHTE": "hhd",
|
||||
"TISCHWAHL_STAFFEL": "1",
|
||||
"TISCHWAHL_VERGLEICH": "1",
|
||||
"TISCHWAHL_WARTEN": "1",
|
||||
"VERTRAUEN": "1",
|
||||
"VORWISSEN": "C:\\Users\\marcm\\pokerfreak-vorwissen\\speicher-1117-h90v.json.gz",
|
||||
"VORWISSEN_ART": "fold",
|
||||
"VORWISSEN_OHNE": "raiseToBet,reraiseToRaise"
|
||||
},
|
||||
"ohne": []
|
||||
},
|
||||
"ohne": {
|
||||
"befehl": [
|
||||
"D:\\Projects\\pokerfreak\\.claude\\worktrees\\motor-rnr\\entscheiden\\motor\\target\\release\\pokerbench-rnr-live2.exe",
|
||||
"dienst",
|
||||
"sechs100",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor",
|
||||
"2000-600-400",
|
||||
"200q400",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\sechs100-q.bin",
|
||||
"genau",
|
||||
"hu=D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu100-v1.bin,D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu200-v2.bin"
|
||||
],
|
||||
"schalter": {
|
||||
"GEGNERZAHL_FEST": "1",
|
||||
"MOTOR_BAHN_STAU": "1",
|
||||
"MOTOR_BRETTQ": "1",
|
||||
"MOTOR_FLOPBLUFF": "0",
|
||||
"MOTOR_FOLDRUNDUNG": "0",
|
||||
"MOTOR_LUFT": "0",
|
||||
"MOTOR_NACH_BREIT": "1",
|
||||
"MOTOR_NACH_BREIT_FRIST": "2.5",
|
||||
"MOTOR_NACH_BREIT_MAL": "3",
|
||||
"MOTOR_NACH_BREIT_SCHAETZ": "3",
|
||||
"MOTOR_NACH_BREIT_ZIEL": "1",
|
||||
"MOTOR_STRASSEN": "0",
|
||||
"MOTOR_SUCHE_BODEN_VR": "0.1",
|
||||
"MOTOR_SUCHE_RIVER_JAM": "1",
|
||||
"MOTOR_TEMPO_LOS": "1",
|
||||
"MOTOR_VORRECHNEN_MERK": "6",
|
||||
"MOTOR_VORRECHNEN_STRASSE": "1",
|
||||
"TISCHWAHL": "1",
|
||||
"TISCHWAHL_GEWICHTE": "hhd",
|
||||
"TISCHWAHL_STAFFEL": "1",
|
||||
"TISCHWAHL_VERGLEICH": "1",
|
||||
"TISCHWAHL_WARTEN": "1",
|
||||
"VORWISSEN": "C:\\Users\\marcm\\pokerfreak-vorwissen\\speicher-1117-h90v.json.gz",
|
||||
"VORWISSEN_ART": "fold",
|
||||
"VORWISSEN_OHNE": "raiseToBet,reraiseToRaise"
|
||||
},
|
||||
"ohne": [
|
||||
"MOTOR_RNR",
|
||||
"MOTOR_RNR_MODELL",
|
||||
"VERTRAUEN"
|
||||
]
|
||||
},
|
||||
"live_k": {
|
||||
"befehl": [
|
||||
"D:\\Projects\\pokerfreak\\.claude\\worktrees\\motor-rnr\\entscheiden\\motor\\target\\release\\pokerbench-rnr-live2.exe",
|
||||
"dienst",
|
||||
"sechs100",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor",
|
||||
"2000-600-400",
|
||||
"200q400",
|
||||
"D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\sechs100-q.bin",
|
||||
"genau",
|
||||
"hu=D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu100-v1.bin,D:\\Projects\\pokerfreak\\daten\\grundstrategie\\motor\\hu200-v2.bin"
|
||||
],
|
||||
"schalter": {
|
||||
"GEGNERZAHL_FEST": "1",
|
||||
"MOTOR_BAHN_STAU": "1",
|
||||
"MOTOR_BRETTQ": "1",
|
||||
"MOTOR_FLOPBLUFF": "0",
|
||||
"MOTOR_FOLDRUNDUNG": "0",
|
||||
"MOTOR_LUFT": "0",
|
||||
"MOTOR_NACH_BREIT": "1",
|
||||
"MOTOR_NACH_BREIT_FRIST": "2.5",
|
||||
"MOTOR_NACH_BREIT_MAL": "3",
|
||||
"MOTOR_NACH_BREIT_SCHAETZ": "3",
|
||||
"MOTOR_NACH_BREIT_ZIEL": "1",
|
||||
"MOTOR_RNR": "1",
|
||||
"MOTOR_RNR_MODELL": "pool",
|
||||
"MOTOR_STRASSEN": "0",
|
||||
"MOTOR_SUCHE_BODEN_VR": "0.1",
|
||||
"MOTOR_SUCHE_RIVER_JAM": "1",
|
||||
"MOTOR_TEMPO_LOS": "1",
|
||||
"MOTOR_VORRECHNEN_MERK": "6",
|
||||
"MOTOR_VORRECHNEN_STRASSE": "1",
|
||||
"TISCHWAHL": "1",
|
||||
"TISCHWAHL_GEWICHTE": "hhd",
|
||||
"TISCHWAHL_STAFFEL": "1",
|
||||
"TISCHWAHL_VERGLEICH": "1",
|
||||
"TISCHWAHL_WARTEN": "1",
|
||||
"VERTRAUEN": "1",
|
||||
"VORWISSEN": "C:\\Users\\marcm\\pokerfreak-vorwissen\\speicher-1117-h90v.json.gz",
|
||||
"VORWISSEN_ART": "fold",
|
||||
"VORWISSEN_OHNE": "raiseToBet,reraiseToRaise"
|
||||
},
|
||||
"ohne": []
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user