Repository navigation
BranchCore work - #115
BranchCore work#115guanqin-123 wants to merge 13 commits into
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #115 +/- ##
==========================================
+ Coverage 75.44% 76.62% +1.17%
==========================================
Files 91 94 +3
Lines 22575 23440 +865
==========================================
+ Hits 17032 17960 +928
+ Misses 5543 5480 -63
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 3 files with indirect coverage changes Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
|
Please fix the coverage ci |
d9327ac to
0b42029
Compare
Finished. after this, the upcoming pr to support SST, and YELP (NLP verification instance that contains a transformer architecture) |
| --network "$ACT_NETS_DIR/mlp_plain_3x8_64x64_3962224133.json" \ | ||
| --solver dual --bab --bab-solver-tier dual_alpha_eta \ | ||
| --bab-branching babsr --bab-bounding depth_bound_blend \ | ||
| --bab-root-bounds-reuse none --bab-intermediate-refine none \ | ||
| --bab-per-subproblem-refine none --bab-climb-enabled \ | ||
| --bab-climb-theta 0.5 --bab-climb-recheck-k 2 \ | ||
| --bab-multi-split-levels 1 --bab-max-batch-size 16 \ | ||
| --bab-max-depth 10 --bab-max-subproblems 90 --timeout 80 \ | ||
| --device cpu --dtype float64 --verbose 2>&1) | ||
| echo "$out" | ||
| grep -qE "climb_cores_inserted: [1-9]" <<<"$out" | ||
| grep -qE "climb_main_bound_calls: [1-9]" <<<"$out" | ||
| grep -qE "climb_propagate_time_s: (0\.[0-9]*[1-9]|[1-9])" <<<"$out" |
There was a problem hiding this comment.
Could you make sure the below:
(1) Options in command line will also have the same mirrored one in yaml?
(2) Try to reduce the number of command line here in the CI file if possible
(3) I am not sure what grep commandline is doing here. Are these grep lines doing validation? I would suggest adding more assertions in your code so that we could catch any issues or implementation bugs and pinpoint them in the source code.
Please do so in the below two CI tests too.
| @@ -8,46 +8,55 @@ | |||
| # | |||
There was a problem hiding this comment.
The current bab.py is too large and should be simplified and obsolete code should be removed.
| # All tensor shapes follow the (N, D) batch convention for batch-parallel scoring. | ||
| # | ||
| # ===---------------------------------------------------------------------====# | ||
|
|
There was a problem hiding this comment.
This branching.py is too large close to 2k lines of code after your update. Redundant or obsolete code should be removed for future maintanance purposes.
…to branching/ and node.py; take CLIMB margins and BaB batch size from central config
0a112c5 to
881935b
Compare
… CLIMB CI budget 250 subproblems
…it, top-k pool, MCTS visits, witness decisions
…stored tensors instead of re-running the batched wrapper
…); smart_turn CI step asserts the rejection instead of || true
| set -e | ||
| test "$status" -eq 3 |
There was a problem hiding this comment.
Do we need to set +e and test? Can we use raise asserts instead?
| --timeout 20 --bab-max-depth 2 --bab-max-subproblems 5 >/dev/null 2>&1 | ||
| status=$? | ||
| set -e |
There was a problem hiding this comment.
Could we use raise assert?
| set +e | ||
| out=$(coverage run -p -m act.back_end --verify \ | ||
| --network "$ACT_NETS_DIR/mlp_plain_3x8_64x64_3962224133.json" \ | ||
| --solver dual --bab --bab-preset climb \ | ||
| --bab-bounding random --bab-max-depth 1 --bab-max-subproblems 1 2>&1) | ||
| status=$? | ||
| set -e | ||
| echo "$out" | ||
| test "$status" -eq 2 |
There was a problem hiding this comment.
Could we use raise asert instead of outputing them in a text file?
There was a problem hiding this comment.
Where are all asserts added in the backend folder? I didn't find the changes you made?
There was a problem hiding this comment.
Please point me to where the asserts were added. If not, please try to do another round of searching, fix the "print errors" and make them all as strict assertions.
| # Implements the 2^k sign-combination fan-out described in "Mining Verdict | ||
| # Boundaries for Neural Network Verification" (Jiawei Ren, Guanqin Zhang, | ||
| # Zhenya Zhang, Yulei Sui, FM 2026). Each lane's top-k BaBSR-scored neurons | ||
| # are split together into all 2^k sign combinations in a single wave; the | ||
| # joint gain is super-additive versus k greedy single splits. |
There was a problem hiding this comment.
should put ecoop and this FM in the vnnlib-comp references, as both are implemented in ACT
| intermediate_refine: "all" | ||
| multi_split_levels: 4 | ||
|
|
||
| climb: |
There was a problem hiding this comment.
better to explain the options in comments, as quite a number of variables/options in this file need a description.
…d, util, vnncomp); explicit fallbacks; fix NaN in HybridZ softmax ratio bound
core: raise on errors instead of printing or returning empty
| @@ -0,0 +1,84 @@ | |||
| #===- act/front_end/vnnlib_loader/test_multi_input_rejection.py - Multi-Input --====# | |||
There was a problem hiding this comment.
what is this file for? Do we need it or could some of these put in the CI?
There was a problem hiding this comment.
it's for my local testing, deleted.
| # Layout (all under the single top-level `backend:` mapping): | ||
| # runtime selectors → verification cascade → torchlp → tf → hybridz | ||
| # → bab (branch-and-bound) | ||
| # Layout: |
There was a problem hiding this comment.
For all the options (variable names), please try to add a comment for each variable.
…ced in source Remove the three set +e exit-status steps (smart_turn multi-input, top-k with random/mcts, CLIMB with non-TopK bounding) and the smart_turn download. The rejections are unchanged: BaBConfig.__post_init__ and validate_climb_config raise ConfigError (back-end CLI exit 2), and the VNNLIB pre-scan raises UnsupportedSpecError (pipeline exit 3).
Comments only; values are unchanged (the YAML parses identically and check_parity passes).
9b4036a to
da67f3d
Compare
Every key now has its own comment giving its unit, valid values and special values, checked against the code. Fixes comments that were wrong: torchlp.stagnation_patience counts iterations; backend.timeout is given in full to the LP tier and to each BaB run; hybridz.timeout null/0 falls back to backend.timeout; sigmoid_segments applies to Sigmoid only; llm_probe_neuron_topk=0 keeps the FSB fallback; bab.verbose is not read yet. Comments only; values unchanged.
Uh oh!
There was an error while loading. Please reload this page.