diff --git a/messung/farm/innovation/vs-aa-bau.ps1 b/messung/farm/innovation/vs-aa-bau.ps1 new file mode 100644 index 00000000..5a3a74d2 --- /dev/null +++ b/messung/farm/innovation/vs-aa-bau.ps1 @@ -0,0 +1,31 @@ +# innovation 05.12.: A/A auf dem Bau. Verdacht: Bau ohne .cargo/config.toml (target-cpu=native) ist langsamer. +# Arme: frisch_basis (cc6eaf527 ohne native, wie e5d15dfb5 gebaut), neu_aus (e5d15dfb5 ohne native), alt_basis (B245E3B7, mit native), neu_nativ (e5d15dfb5 mit native) +$ErrorActionPreference = 'Continue' +if (Test-Path 'D:\Projects\pokerfreak\scratch\laeufer.pid') { 'SPIELT'; exit 2 } +function Baue([string]$ordnerName) { + $bauOrt = "D:\Projects\$ordnerName" + if (-not (Test-Path "$bauOrt\entscheiden\motor\Cargo.toml")) { New-Item -ItemType Directory -Force $bauOrt | Out-Null; tar -xf "$bauOrt.tar" -C $bauOrt } + $tomlPfad = "$bauOrt\entscheiden\motor\Cargo.toml"; (Get-Content $tomlPfad) -replace 'postflop-solver-temp"', 'postflop-solver-temp-cc6eaf52"' | Set-Content $tomlPfad -Encoding utf8 + "-- $ordnerName .cargo/config.toml: " + (Test-Path "$bauOrt\.cargo\config.toml") + Push-Location "$bauOrt\entscheiden\motor"; cargo build --release -j 16 --bin motor -v 2>&1 | Select-String 'Running `rustc --crate-name motor' | % { ($_.Line -replace '.*(-C opt-level\S*|-C target-cpu\S*)', '$0') | Select-String -Pattern 'target-cpu=\w+' -AllMatches | % { '-- rustc motor: ' + ($_.Matches.Value -join ' ') } } + $bauRc = $LASTEXITCODE; Pop-Location + if ($bauRc -ne 0) { "BAU $ordnerName fehlgeschlagen $bauRc"; exit 1 } + $exeZiel = "$bauOrt\pokerbench-innovation-aa-$ordnerName.exe"; Copy-Item "$bauOrt\entscheiden\motor\target\release\motor.exe" $exeZiel -Force + "EXE $exeZiel SHA256 " + (Get-FileHash $exeZiel).Hash + return $exeZiel +} +$frischExe = @(Baue 'pf-aa-cc6eaf527-ohne')[-1] +$nativExe = @(Baue 'pf-aa-e5d15dfb5-nativ')[-1] +$neuExe = 'D:\Projects\pf-vorflopselbst-e5d15dfb5\pokerbench-innovation-vorflopselbst-uhr.exe' +$altExe = 'D:\Projects\pf-temperatur-rein-cc6eaf52\entscheiden\motor\target\release\motor.exe' +foreach ($e in $neuExe, $altExe) { "EXE $e SHA256 " + (Get-FileHash $e).Hash } +$schalterDatei = 'D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-cc6eaf52\kern_schalter.txt' +$zeileText = ((Get-Content $schalterDatei | ? { $_ -like 'MOTOR_ZEILE=*' }) | Select-Object -Last 1).Substring(12) +$umgListe = ($zeileText -split ';' | ? { $_ -match '=' }) -join ',' +$ausOrt = 'D:\Projects\pokerfreak-daten\pruefstand\vorflop-selbst-aa-bau'; New-Item -ItemType Directory -Force $ausOrt | Out-Null +Copy-Item 'D:\Projects\pokerfreak-daten\pruefstand\vorflop-selbst-aus-6de8484cb\ein500.jsonl' "$ausOrt\ein500.jsonl" +$env:ZEITPROBE_STRASSEN = 'PREFLOP,FLOP,TURN,RIVER' +Set-Location 'D:\Projects\pokerfreak-daten\pruefstand\sharingan-splash-0312\werkzeuge' +python -X utf8 farm_zeitprobe.py "$ausOrt\ein500.jsonl" $schalterDatei "$ausOrt\aus.json" "frisch_basis=$frischExe|$umgListe" "neu_aus=$neuExe|$umgListe" "alt_basis=$altExe|$umgListe" "neu_nativ=$nativExe|$umgListe" 2>&1 | % { "$_" } +python -X utf8 D:\Projects\pf-vorflopselbst-zeiten.py "$ausOrt\aus.json" frisch_basis neu_aus alt_basis neu_nativ +python -X utf8 D:\Projects\pokerfreak-daten\pruefstand\basis-0312\aus-vergleich.py "$ausOrt\aus.json" frisch_basis neu_aus alt_basis neu_nativ diff --git a/messung/farm/innovation/vs-archiv.ps1 b/messung/farm/innovation/vs-archiv.ps1 new file mode 100644 index 00000000..f25e5dd6 --- /dev/null +++ b/messung/farm/innovation/vs-archiv.ps1 @@ -0,0 +1,31 @@ +# innovation 05.12.: Aenderungsliste ueber die Archiv-Entscheidungen (Tor 1). Bau fbe807fa0 MIT .cargo/config.toml (nativ), Loeserkopie 28bcd38f. +$ErrorActionPreference = 'Continue' +if (Test-Path 'D:\Projects\pokerfreak\scratch\laeufer.pid') { 'SPIELT'; exit 2 } +$bauOrt = 'D:\Projects\pf-vorflopselbst-fbe807fa0' +if (-not (Test-Path "$bauOrt\entscheiden\motor\Cargo.toml")) { New-Item -ItemType Directory -Force $bauOrt | Out-Null; tar -xf "$bauOrt.tar" -C $bauOrt } +"-- .cargo/config.toml: " + (Test-Path "$bauOrt\.cargo\config.toml") +$tomlPfad = "$bauOrt\entscheiden\motor\Cargo.toml"; (Get-Content $tomlPfad) -replace 'postflop-solver-temp"', 'postflop-solver-temp-28bcd38f"' | Set-Content $tomlPfad -Encoding utf8 +Push-Location "$bauOrt\entscheiden\motor"; cargo build --release --locked -j 16 --bin motor 2>&1 | Select-Object -Last 1; $bauRc = $LASTEXITCODE; Pop-Location +if ($bauRc -ne 0) { "BAU fehlgeschlagen $bauRc"; exit 1 } +$exePfad = "$bauOrt\pokerbench-innovation-vorflopselbst-archiv.exe"; Copy-Item "$bauOrt\entscheiden\motor\target\release\motor.exe" $exePfad -Force +"EXE $exePfad SHA256 " + (Get-FileHash $exePfad).Hash +$umgebung = [ordered]@{ R0 = '1'; MOTOR_ALLIN_UEBERSETZUNG = '1'; MOTOR_RAKE_REGEL = '1'; MOTOR_FLOP_EXAKT = '1'; MOTOR_FLOP_EXAKT_MS = '2000'; MOTOR_FLOP_EXAKT_VOR_MS = '2000'; MOTOR_FLOP_EXAKT_S_JE_GB = '22'; MOTOR_FLOP_EXAKT_ZIEL = '1.0'; MOTOR_FLOP_EXAKT_GB = '4'; RAYON_NUM_THREADS = '24' } +foreach ($k in $umgebung.Keys) { Set-Item "env:$k" $umgebung[$k] } +"UMGEBUNG " + (($umgebung.GetEnumerator() | % { "$($_.Key)=$($_.Value)" }) -join ' ') +$tafelOrt = 'D:\Projects\pokerfreak-daten\grundstrategie-mitzaehler'; $zielOrt = 'D:\Projects\pokerfreak-daten\innovation\vorflop_selbst'; $archivOrt = 'D:\Projects\pokerfreak-daten\pruefstand\basis-rein' +foreach ($f in "$zielOrt\archiv-roh.jsonl", "$zielOrt\archiv-sonstige.txt") { if ((Test-Path $f) -and (Get-Item $f).Length -gt 0) { "ZIEL $f existiert mit Inhalt - Abbruch (nichts ueberschreiben)"; exit 3 } } +$aufrufArgs = "vorflop-selbst-archiv sechs100 $tafelOrt 2000-600-400 200 $tafelOrt\sechs100-v2.bin $zielOrt\sechs100-v2-suche-jam.vselbst $archivOrt\ein.jsonl $zielOrt\archiv-roh.jsonl ref=$archivOrt\ref.jsonl faeden=24 n_max=4096 top=5" +"AUFRUF $aufrufArgs" +$t0 = Get-Date +$proz = Start-Process -FilePath $exePfad -ArgumentList $aufrufArgs -RedirectStandardOutput "$zielOrt\archiv-sonstige.txt" -RedirectStandardError "$zielOrt\archiv-stderr.txt" -NoNewWindow -PassThru +$spitze = [long]0 +while (-not $proz.HasExited) { + try { $proz.Refresh(); $spitze = [math]::Max($spitze, [long]$proz.PeakWorkingSet64) } catch { } + if (((Get-Date) - $t0).TotalMinutes -gt 60) { 'FRIST 60 min erreicht - beende'; Stop-Process -Id $proz.Id -Force; break } + Start-Sleep 2 +} +$proz.WaitForExit() +"Rueckgabe $($proz.ExitCode) nach $([math]::Round(((Get-Date) - $t0).TotalMinutes, 1)) min, RAM-Spitze $([math]::Round($spitze / 1GB, 2)) GB" +foreach ($f in "$zielOrt\archiv-roh.jsonl", "$zielOrt\archiv-sonstige.txt", "$zielOrt\archiv-stderr.txt") { if (Test-Path $f) { $g = Get-Item $f; "DATEI $f $($g.Length) " + (Get-FileHash $f).Hash } } +'--- stderr Ende'; gc "$zielOrt\archiv-stderr.txt" -Tail 15 +'--- sonstige Ende'; gc "$zielOrt\archiv-sonstige.txt" -Tail 40 diff --git a/messung/farm/innovation/vs-uhr-umgekehrt.ps1 b/messung/farm/innovation/vs-uhr-umgekehrt.ps1 new file mode 100644 index 00000000..16a5389a --- /dev/null +++ b/messung/farm/innovation/vs-uhr-umgekehrt.ps1 @@ -0,0 +1,16 @@ +# innovation 05.12.: Zeitlauf in umgekehrter Reihenfolge (neu_aus vor basis), allein auf der Maschine, dieselben 500 Anfragen. +# Umgebung: volle MOTOR_ZEILE der Fassung cc6eaf52 (Probe-Kopie der Schalterdatei), in allen Armen gleich. +$ErrorActionPreference = 'Continue' +if (Test-Path 'D:\Projects\pokerfreak\scratch\laeufer.pid') { 'SPIELT'; exit 2 } +$basisExe = 'D:\Projects\pf-temperatur-rein-cc6eaf52\entscheiden\motor\target\release\motor.exe' +$neuExe = 'D:\Projects\pf-vorflopselbst-e5d15dfb5\pokerbench-innovation-vorflopselbst-uhr.exe' +$schalterDatei = 'D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-cc6eaf52\kern_schalter.txt' +$zeileText = ((Get-Content $schalterDatei | ? { $_ -like 'MOTOR_ZEILE=*' }) | Select-Object -Last 1).Substring(12) +$umgListe = ($zeileText -split ';' | ? { $_ -match '=' }) -join ',' +"UMGEBUNG $umgListe" +$ausOrt = 'D:\Projects\pokerfreak-daten\pruefstand\vorflop-selbst-uhr-e5d15dfb5-umgekehrt'; New-Item -ItemType Directory -Force $ausOrt | Out-Null +Copy-Item 'D:\Projects\pokerfreak-daten\pruefstand\vorflop-selbst-aus-6de8484cb\ein500.jsonl' "$ausOrt\ein500.jsonl" +$env:ZEITPROBE_STRASSEN = 'PREFLOP,FLOP,TURN,RIVER' +Set-Location 'D:\Projects\pokerfreak-daten\pruefstand\sharingan-splash-0312\werkzeuge' +python -X utf8 farm_zeitprobe.py "$ausOrt\ein500.jsonl" $schalterDatei "$ausOrt\aus.json" "neu_aus=$neuExe|$umgListe" "basis=$basisExe|$umgListe" 2>&1 | % { "$_" } +python -X utf8 D:\Projects\pf-vorflopselbst-zeiten.py "$ausOrt\aus.json" neu_aus basis diff --git a/messung/farm/innovation/vs-zeiten.py b/messung/farm/innovation/vs-zeiten.py new file mode 100644 index 00000000..6d8c6dda --- /dev/null +++ b/messung/farm/innovation/vs-zeiten.py @@ -0,0 +1,10 @@ +# Turn p50/p90 und River ueber 2,5 s je Arm aus den .jsonl von farm_zeitprobe +import json, sys +aus, arme = sys.argv[1], sys.argv[2:] +p = lambda v, q: sorted(v)[int(q * (len(v) - 1))] +for n in arme: + r = [json.loads(z) for z in open(aus + "." + n + ".jsonl", encoding="utf-8")] + t = [x["wand_s"] for x in r if x["street"] == "TURN" and x["wand_s"] is not None] + w = [x["wand_s"] for x in r if x["street"] == "RIVER" and x["wand_s"] is not None] + u = sum(x > 2.5 for x in w) + print("%s Turn n %d p50 %.3f p90 %.3f | River n %d ueber 2,5 s %d (%.1f %%)" % (n, len(t), p(t, .5), p(t, .9), len(w), u, 100 * u / len(w))) diff --git a/messung/farm/mehrweg/mehrweg-bau.ps1 b/messung/farm/mehrweg/mehrweg-bau.ps1 new file mode 100644 index 00000000..27a3c503 --- /dev/null +++ b/messung/farm/mehrweg/mehrweg-bau.ps1 @@ -0,0 +1,11 @@ +# mehrweg 05.12.: teilspiel aus dem SHARINGAN-Stamm, Zweig pokerfreak-mehrweg-flop @ 29b48b1, release, offline +$ErrorActionPreference = 'Continue' +if (Test-Path 'D:\Projects\pokerfreak\scratch\laeufer.pid') { 'SPIELT'; exit 2 } +$quellOrt = 'D:\pokerfreak-fremd\sharingan\code-mehrweg-29b48b1' +if (-not (Test-Path "$quellOrt\Cargo.toml")) { New-Item -ItemType Directory -Force $quellOrt | Out-Null; tar -xf 'D:\pokerfreak-fremd\sharingan\sharingan-mehrweg-29b48b1.tar' -C $quellOrt } +$env:CARGO_TARGET_DIR = 'D:\pokerfreak-fremd\sharingan\target-mehrweg' +Push-Location $quellOrt; cargo build --release --offline --locked -j 8 -p search --bin teilspiel 2>&1 | Select-Object -Last 3; $bauRc = $LASTEXITCODE; Pop-Location +if ($bauRc -ne 0) { "BAU fehlgeschlagen $bauRc"; exit 1 } +$exeZiel = 'D:\pokerfreak-fremd\sharingan\target-mehrweg\pokerbench-mehrweg-flop-teilspiel.exe' +Copy-Item "$env:CARGO_TARGET_DIR\release\teilspiel.exe" $exeZiel -Force +"EXE $exeZiel SHA256 " + (Get-FileHash $exeZiel).Hash diff --git a/messung/farm/mehrweg/mehrweg-ref.ps1 b/messung/farm/mehrweg/mehrweg-ref.ps1 new file mode 100644 index 00000000..ead0ed51 --- /dev/null +++ b/messung/farm/mehrweg/mehrweg-ref.ps1 @@ -0,0 +1,9 @@ +# mehrweg 05.12.: Langzeit-Referenz Mehrweg-Flop, ein Teil (I von 6), 4 Faeden, 10 Mio Iterationen, ms 3600000, Ausnutzbarkeit 5 Mio +param([int]$TeilNummer) +if (Test-Path 'D:\Projects\pokerfreak\scratch\laeufer.pid') { 'SPIELT'; exit 2 } +$exePfad = 'D:\pokerfreak-fremd\sharingan\target-mehrweg\pokerbench-mehrweg-flop-teilspiel.exe' +$datenOrt = 'D:\Projects\pf-mehrweg-flop-daten' +$warteZaehler = 0; while (-not (Test-Path 'D:\Projects\pf-batterie\messung\farm\schlange\fertig\mehrweg-bau-teilspiel.json') -or -not (Test-Path $exePfad)) { Start-Sleep 30; $warteZaehler++; if ($warteZaehler -gt 480) { 'kein Bau nach 4 h'; exit 1 } } +$zusatzArgs = @('--buckets', 'D:\pokerfreak-fremd\sharingan\data\buckets-200', '--threads', '4', '--max-infosets', '33554432', '--ausnutzbarkeit', '5000000') +& "$datenOrt\pokerbench-mehrweg-flop-starter.ps1" -Exe $exePfad -ExtraArgs $zusatzArgs -Anfragen "$datenOrt\anfragen-ref200.jsonl" -Aus "$datenOrt\referenz\antworten-$TeilNummer.jsonl" -Iters 10000000 -Ms 3600000 -Teil "$TeilNummer/6" -Threads 4 +"Rueckgabe Starter $LASTEXITCODE" diff --git a/messung/farm/nacht-0112/werkzeuge/5cc8-proben.cmd b/messung/farm/nacht-0112/werkzeuge/5cc8-proben.cmd new file mode 100644 index 00000000..a808a7f8 --- /dev/null +++ b/messung/farm/nacht-0112/werkzeuge/5cc8-proben.cmd @@ -0,0 +1,16 @@ +@echo off +rem temperatur 05.12.: Startprobe und Warteschlangen-Probe der finalen Fassung 5cc8a931 (aus temperatur-bau-16), Schalter-Kopie wie cc6eaf52, MOTOR_EXE neu, MOTOR_ZEILE + MOTOR_VORFLOP_SELBST +set W=D:\Projects\pokerfreak-daten\pruefstand\sharingan-splash-0312\werkzeuge +set A=D:\Projects\pokerfreak-daten\pruefstand\warteschlange +set E=D:\Projects\pf-temperatur\pokerbench-temperatur-rein-5cc8a931.exe +set Q=D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-cc6eaf52\kern_schalter.txt +set K=D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-5cc8a931\kern_schalter.txt +set V=D:\Projects\pokerfreak-daten\innovation\vorflop_selbst\sechs100-v2-suche-jam.vselbst +powershell -NoProfile -Command "$f='D:\Projects\pf-batterie\messung\farm\schlange\fertig\temperatur-bau-16.json'; $n=0; while (-not ((Test-Path $f) -and (Test-Path '%E%'))) { Start-Sleep 30; $n++; if ($n -gt 240) { 'kein Bau nach 2 h'; exit 1 } }" +if errorlevel 1 exit /b 1 +if not exist D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-5cc8a931 mkdir D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-5cc8a931 +if not exist %K% powershell -NoProfile -Command "$t=(Get-Content '%Q%') -replace '^MOTOR_EXE=.*$','MOTOR_EXE=%E%' -replace '^(MOTOR_ZEILE=.*)$','$1;MOTOR_VORFLOP_SELBST=%V%'; Set-Content -Path '%K%.tmp' -Value (@('# 05.12. farm: Kopie von %Q%, MOTOR_EXE auf 5cc8a931, MOTOR_ZEILE + MOTOR_VORFLOP_SELBST (temperatur-bau-16)') + $t) -Encoding utf8; Move-Item '%K%.tmp' '%K%'" +powershell -NoProfile -Command "'EXE ' + (Get-FileHash %E%).Hash; 'SCHALTER ' + (Get-FileHash %K%).Hash; Select-String -Path %K% -Pattern '^MOTOR_EXE=' | %% Line; 'SIDECAR ' + (Get-FileHash %V%).Hash; Select-String -Path %K% -Pattern MOTOR_VORFLOP_SELBST | %% { $_.Line.Length }" +powershell -NoProfile -ExecutionPolicy Bypass -File D:\Projects\pokerfreak-daten\pruefstand\basis-0312\basis_rt_5cc8.ps1 +cd /d %W% +python -X utf8 farm_warteschlange.py D:\Projects\pf-schatten-d647bb1c %E% %K% %A%\live-20261204 2026-12-04 %A%\5cc8a931-alle diff --git a/messung/farm/nacht-0112/werkzeuge/basis_rt_5cc8.ps1 b/messung/farm/nacht-0112/werkzeuge/basis_rt_5cc8.ps1 new file mode 100644 index 00000000..947ba13d --- /dev/null +++ b/messung/farm/nacht-0112/werkzeuge/basis_rt_5cc8.ps1 @@ -0,0 +1,18 @@ +# basis-rein-temperatur 5cc8a931 (temperatur-bau-16: 5cc8a931 + MOTOR_VORFLOP_SELBST; Schalter-Kopie mit MOTOR_EXE 5cc8a931 und Sidecar in MOTOR_ZEILE): Startprobe Kaltstart, frist 4,0, Lastprobe, _hand, Strassen-Lage +$zielOrdner = 'D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-5cc8a931'; New-Item -ItemType Directory -Force $zielOrdner | Out-Null +$py = 'C:\Users\marcm\AppData\Local\Programs\Python313\python.exe'; $werkzeuge = 'D:\Projects\pokerfreak-daten\pruefstand\sharingan-splash-0312\werkzeuge' +foreach ($pidDatei in 'D:\Projects\pokerfreak\scratch\laeufer.pid', 'D:\Projects\pokerfreak\.claude\worktrees\engine-lecks-angreifen-de7b88\betrieb\scratch\laeufer.pid') { + if (Test-Path $pidDatei) { "SPIELT $pidDatei" | Set-Content "$zielOrdner\abbruch.txt"; exit 1 } } +$exeDatei = 'D:\Projects\pf-temperatur\pokerbench-temperatur-rein-5cc8a931.exe'; $schalterDatei = 'D:\Projects\pokerfreak-daten\pruefstand\basis-rein-temperatur-5cc8a931\kern_schalter.txt' +Set-Location $werkzeuge +& $py -X utf8 farm_hand_probe.py $exeDatei $schalterDatei 'D:\Projects\pokerfreak-daten\gedaechtnis2-live\strom.jsonl' "$zielOrdner\hand.json" *> "$zielOrdner\hand.txt" +& $py -X utf8 farm_rein_startprobe.py $exeDatei $schalterDatei "$zielOrdner\probe" --n 1000 --kalt --frist-rest 4.0 *> "$zielOrdner\probe.txt" +$os1 = Get-CimInstance Win32_OperatingSystem; $frei = [math]::Round($os1.FreePhysicalMemory / 1MB, 1); $belegt = [math]::Round(($os1.TotalVisibleMemorySize - $os1.FreePhysicalMemory) / 1MB, 1) +& $py -X utf8 farm_betrieb_json.py "$zielOrdner\probe" (Get-FileHash $schalterDatei).Hash (Get-FileHash $exeDatei).Hash $frei $belegt *> "$zielOrdner\betrieb.txt" +& $py -X utf8 farm_flop_exakt_lage.py "$zielOrdner\probe\antworten.json" *> "$zielOrdner\flop_exakt.txt" +& $py -X utf8 farm_lastprobe.py $exeDatei $schalterDatei "$zielOrdner\probe" "$zielOrdner\last6" --n 6 --kalt --strasse FLOP,TURN,RIVER --frist-rest 4.0 *> "$zielOrdner\last6.txt" +& $py -X utf8 farm_flop_exakt_lage.py "$zielOrdner\last6\antworten.json" *> "$zielOrdner\last6_flop_exakt.txt" +& $py -X utf8 farm_strassen_lage.py "$zielOrdner\probe\antworten.json" *> "$zielOrdner\strassen_lage.txt" +& $py -X utf8 farm_strassen_lage.py "$zielOrdner\probe\antworten.json" 4.0 *> "$zielOrdner\strassen_lage_frist4.txt" +& $py -X utf8 farm_strassen_lage.py "$zielOrdner\last6\antworten.json" 4.0 *> "$zielOrdner\last6_strassen_frist4.txt" +'FERTIG' | Set-Content "$zielOrdner\FERTIG"