P5 audit: the overset march saves the composite at every N-th committed step (RTX_FSI2O_SAVE_EVERY: background, the deformed patch's nodes, its vectors, d, ddot, time), and fsi2_overset_audit_of_saved_instants (RTX_FSI2O_AUDIT=dir) rebuilds the composite around each saved patch (build_case_with an initial mesh, so the overlap is the instant's) and prints the solver-metric chain — the CFD23 instrument on the moving patch
CI / Build CPU-Only (Explicit) (push) Canceled after 0s
Performance Benchmarks / Run Benchmarks (push) Canceled after 0s
CI / Format Check (push) Canceled after 0s
CI / Clippy Check (push) Canceled after 0s
CI / Build (macos-latest) (push) Canceled after 0s
CI / CI Success (push) Canceled after 0s
CI / Build (ubuntu-latest) (push) Canceled after 0s
CI / Test (macos-latest) (push) Canceled after 0s
CI / Test (ubuntu-latest) (push) Canceled after 0s
CI / Python Bindings (maturin) (macos-latest) (push) Canceled after 0s
Documentation / Build API Documentation (push) Canceled after 0s
Documentation / Build User Guide (push) Canceled after 0s
CI / Python Bindings (maturin) (ubuntu-latest) (push) Canceled after 0s
CI / WASM Build + Size Check (push) Canceled after 0s
CI / Distributed Training Tests (push) Canceled after 0s
CI / Build CPU-Only (Explicit) (push) Canceled after 0s
Performance Benchmarks / Run Benchmarks (push) Canceled after 0s
CI / Format Check (push) Canceled after 0s
CI / Clippy Check (push) Canceled after 0s
CI / Build (macos-latest) (push) Canceled after 0s
CI / CI Success (push) Canceled after 0s
CI / Build (ubuntu-latest) (push) Canceled after 0s
CI / Test (macos-latest) (push) Canceled after 0s
CI / Test (ubuntu-latest) (push) Canceled after 0s
CI / Python Bindings (maturin) (macos-latest) (push) Canceled after 0s
Documentation / Build API Documentation (push) Canceled after 0s
Documentation / Build User Guide (push) Canceled after 0s
CI / Python Bindings (maturin) (ubuntu-latest) (push) Canceled after 0s
CI / WASM Build + Size Check (push) Canceled after 0s
CI / Distributed Training Tests (push) Canceled after 0s
Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_0116sg1Qz1gMv9hdcKP1XUam
This commit is contained in:
co-authored by
Claude Fable 5.1
parent
3a68048934
commit
3c2add3f32
@@ -18,6 +18,45 @@ const REF_UX_AMP: f64 = 12.44e-3;
|
||||
const REF_DRAG_MEAN: f64 = 208.83;
|
||||
const REF_LIFT_AMP: f64 = 234.2;
|
||||
|
||||
/// `RTX_FSI2O_AUDIT=dir`: the solver-metric chain on every saved instant
|
||||
/// under `dir` (`inst_*`, from `RTX_FSI2O_SAVE_EVERY`), no march.
|
||||
#[test]
|
||||
fn fsi2_overset_audit_of_saved_instants() {
|
||||
let Ok(dir) = std::env::var("RTX_FSI2O_AUDIT") else {
|
||||
return;
|
||||
};
|
||||
let ny = std::env::var("RTX_FSI2O_NY")
|
||||
.ok()
|
||||
.and_then(|v| v.parse().ok())
|
||||
.unwrap_or(41);
|
||||
let flag_nx = std::env::var("RTX_FSI2O_FLAG_NX")
|
||||
.ok()
|
||||
.and_then(|v| v.parse().ok())
|
||||
.unwrap_or(35);
|
||||
let case = case_from_env("FSI2O", FSI2);
|
||||
let mut dirs: Vec<_> = std::fs::read_dir(&dir)
|
||||
.expect("audit dir")
|
||||
.filter_map(|e| e.ok().map(|e| e.path()))
|
||||
.filter(|p| {
|
||||
p.file_name()
|
||||
.and_then(|n| n.to_str())
|
||||
.is_some_and(|n| n.starts_with("inst_"))
|
||||
})
|
||||
.collect();
|
||||
dirs.sort();
|
||||
for d in dirs {
|
||||
let (fluid, dvec, t) =
|
||||
fsi2_harness::overset::OversetFluid::from_instant(case, ny, flag_nx, &d)
|
||||
.expect("instant");
|
||||
let tip: f64 = dvec.iter().map(|v| v * v).sum::<f64>().sqrt();
|
||||
println!(
|
||||
" AUDIT {} t = {t:.4} |d| {tip:.3e}: {}",
|
||||
d.file_name().unwrap().to_string_lossy(),
|
||||
fluid.chain_line()
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn fsi2_on_the_overset() {
|
||||
let config = OversetMarchConfig::from_env(
|
||||
|
||||
Reference in New Issue
Block a user