Files
pokerfreak/src/bin/plateau.rs
T
mmintelandClaude Opus 5.5 20da294c5a E2-Plateau-Befund: die Kartenabstraktion ist der Boden (Fest-Flop +54, Fest-Turn -72 gegen +190), kein MCCFR/LBR-Fehler; Diagnosewerkzeuge, Fortsetzungstest
Aus worktree-agent-a3689a5f9ba457171 (b79d9e3), flop_fest auf die Szenariofamilie uebertragen. blueprint:: 28/28.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 02:28:26 +01:00

30 lines
1.5 KiB
Rust

//! Diagnostic for the E2 plateau: best response inside the abstract game vs LBR (real cards).
//!
//! plateau <abstraktion-dir> <ckpt> <iterationen> [lbr-haende]
//! Bench copy: `pokerbench-engine-plateau.exe`. Threads: POKERBENCH_THREADS (default 2).
use rechner::blueprint::lbr::lbr;
use rechner::blueprint::mccfr::{beste_antwort, Tabellen};
use rechner::blueprint::s1::{Abstraktion, S1};
use std::path::Path;
fn main() {
let a: Vec<String> = std::env::args().collect();
let n: u64 = a[3].parse().unwrap();
let h: usize = a.get(4).and_then(|s| s.parse().ok()).unwrap_or(4000);
let threads: usize = std::env::var("POKERBENCH_THREADS").ok().and_then(|s| s.parse().ok()).unwrap_or(2).max(1);
let s = S1::neu(Abstraktion::laden(Path::new(&a[1])).unwrap());
let mut tab = Tabellen::neu(&s);
assert!(tab.datei_lesen(Path::new(&a[2])));
println!("Runden {}, Eintraege {}", tab.runden, tab.eintraege());
let e = lbr(&s, &tab, h, threads, 77);
println!("LBR {:+.1} ±{:.1} (BB {:+.1}, BTN {:+.1})", e.bb100, e.ci95, e.je_sitz[0], e.je_sitz[1]);
let w: Vec<(usize, (f64, f64))> = std::thread::scope(|sc| {
let hs: Vec<_> = (0..2).map(|p| { let (s, tab) = (&s, &tab); sc.spawn(move || (p, beste_antwort(s, tab, p, n, 5 + p as u64))) }).collect();
hs.into_iter().map(|h| h.join().unwrap()).collect()
});
for (p, (a1, a2)) in &w {
println!("abstrakte beste Antwort Sitz {p}: 1. Haelfte {:+.1}, 2. Haelfte {:+.1} bb/100", 100.0 * a1, 100.0 * a2);
}
}