Update code-review: pre-JOSS fixes (9daf77f)#19
Merged
Conversation
Correctness & crashes:
- S1: DiscreteDistance was inverted (match -> large distance). Now
`y == x ? 0.0 : λ`, consistent with QuadraticDistance, so rows matching
the evidence receive the highest similarity weight.
- C1: ConditionalUncertaintyReductionMDP normalizes target_condition keys to
String (Symbol keys constructed fine but crashed at runtime) and validates
ranges; conditional_likelihood is now robust to String/Symbol keys.
- C2: accept Union{Missing,<:Real} constraint columns (nonmissingtype check)
and exclude missing rows via coalesce(..., false).
- M1: max_experiments now counts completed experiments, not raw evidence
entries, so prior evidence / multi-feature experiments are not mis-counted.
- M4: QuadraticDistance raises a clear ArgumentError on a zero-variance
(constant) column and recomputes σ per call (drops cross-column memoization).
- N3: DistanceBased validates importance_weights vector length.
Reproducibility & concurrency:
- S2: default_solver(rng) is seedable; each Sim runoff gets an independent rng
(fixes a parallel data race); efficient_designs / conditional_efficient_designs
use a fresh solver+rng per threshold; perform_ensemble_designs uses an
independent rng per ensemble run.
- S3: optimal_arrangement takes an rng (no implicit GLOBAL_RNG); static
efficient_designs pre-seeds one rng per task before @threads.
Docs / robustness / naming:
- C3: public-input @Assert -> ArgumentError across MDP constructors,
conditional_likelihood, and Entropy.
- D1: EfficientValueMDP docstring value signature -> value(evidence, costs).
- D2: Exponential docstring (λ=1/2, exp(-λx)); typos; unified terminal_condition
default; tau_set alias (thred_set still accepted).
- D3: static evaluate_experiments normalizes Symbol features; plot_front empty
guard and get_labels -> make_labels docstring fix; ensemble column
Average_Utility -> Average_Cost.
- M2: ensemble_to_dataframe de-duplicates identical points within a run so
realized_uncertainty collapses no longer inflate MLASP frequencies.
- P1/P2: documented normalized uncertainty and hard terminal condition.
Also adds CHANGELOG.md summarizing these changes, regression tests
(test_review_fixes.jl, ensemble M2 dedupe, static S3 reproducibility), and
.gitignore entries for local workspace/tooling artifacts. Full suite green
with JULIA_NUM_THREADS=4.
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.
Summary
Pushes the latest local
code-reviewwork to update Merck'scode-reviewbranch.Commit:
9daf77f— Fix correctness, reproducibility, and API issues from pre-JOSS reviewFork is 1 commit ahead of
Merck/code-review(compare:code-review...danielchen26:code-review).Note
Direct push to
Merck/CEEDesigns.jlis not permitted for this account (push: false). Please merge this PR to land changes oncode-review.