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

Add in-cluster test with DP #3314

Merged
merged 2 commits into from
Jul 25, 2024
Merged

Add in-cluster test with DP #3314

merged 2 commits into from
Jul 25, 2024

Conversation

divergentdave
Copy link
Contributor

This adds an in-cluster integration test exercising aggregator-based differential privacy noise.

This shouldn't be merged until #3302 and divviup/divviup-api#1173 have been deployed.

Base automatically changed from david/dp-sumvec-histogram to main July 23, 2024 20:02
@divergentdave divergentdave marked this pull request as ready for review July 24, 2024 19:17
@divergentdave divergentdave requested a review from a team as a code owner July 24, 2024 19:17
// Smoke test: Just confirm that some noise was added. Since epsilon is small, the noise will be
// large (drawn from Laplace_Z(20) + Laplace_Z(20)), and it is highly unlikely that all 100
// noise values will be zero simultaneously.
assert_ne!(aggregate_result, un_noised_result);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are there any useful bounds on the amount of noise added such that we could check that the actual result is close enough to the non-noised result to be plausibly the result of aggregation + DP noise? "Useful" in this case meaning the condition is unlikely to be satisfied if DP noise is not being added correctly.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

@divergentdave divergentdave Jul 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could check that each coordinate is not in the middle of the field's range (p*1/4 to p*3/4). That'll be more than far enough out that false positives won't be a problem, while still catching errors in secret sharing/unsharding with a probability of 1/2 on each coordinate.

@divergentdave
Copy link
Contributor Author

This is now passing against staging. https://github.com/divviup/janus-ops/actions/runs/10097504244/job/27922510921

@divergentdave divergentdave enabled auto-merge (squash) July 25, 2024 16:25
@divergentdave divergentdave merged commit 9cc7d1f into main Jul 25, 2024
8 checks passed
@divergentdave divergentdave deleted the david/dp-in-cluster-test branch July 25, 2024 16:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants