Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds support for multi-seed solver runs.
runner.benchmark's new-n/--num-seeds Nflag (internallyorchestrator.run_benchmark'snum_seeds, replacing the never-CLI-exposediterations) runs each (problem, solver configuration) pair N times, each under a different seed. Seeds are generated as1, 2, 3, ...(not0-based) — see below.seed_optionsmap inrunner/config/solvers.yamlrecords which options key holds each solver package's seed;solver.get_solver()/execution.run_solver()gained an optionalseedoverride, threaded through as a new--seed Nflag onpython -m runner.utils.solver(solving runs as a subprocess, so this crosses a process boundary, not just a function argument).Seedcolumn inresults/benchmark_results.csvand the mean/stddev summary CSV.0, except CBC. Verified each solver's own option documentation:0is an ordinary, deterministic value for GLPK, SCIP, HiGHS, Gurobi, CPLEX, Knitro, Xpress, and Mosek. CBC is the sole confirmed exception: itsrandomCbcSeedoption treats0as "use the time of day," which would make that run silently non-deterministic. CBC stays at1. The multi-seed loop generated seeds start at1for every solver.num_seeds=1never overrides the seed). Sinceresults/benchmark_results.csvis a real, growing file that gets appended to across runs, adding theSeedcolumn required a general schema-migration safety net (results.ensure_csv_schema): appending to a CSV written by older code now widens it in place to include new columns (old rows get a blank cell), rather than producing a ragged filepd.read_csvcan't parse.runner/README.md(the-n/--num-seedsflag, the--seedflag onrunner.utils.solver, usage examples) andrunner/SOLVERS.md("Adding a New Solver" now covers theseed_optionsentry too).