Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support weighting samples before loss aggregation #314

Open
han-ol opened this issue Feb 13, 2025 · 0 comments
Open

Support weighting samples before loss aggregation #314

han-ol opened this issue Feb 13, 2025 · 0 comments
Labels
feature New feature or request

Comments

@han-ol
Copy link
Contributor

han-ol commented Feb 13, 2025

It would be useful to handle sample weights in all loss computations.
sample_weights can be an additional keyword argument for compute metrics akin to inference_variables and inference_conditions.

Users would specify sample_weights in their simulator and configure an adapter accordingly:

adapter = bf.ContinuousApproximator.build_adapter(
    inference_variables=["x"],
    inference_conditions=["y"],
    sample_weights=["sample_weight"],
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants