Migrate discrete mechanisms from internal accounting utilities to dp_accounting
Maintainers usually reply within 2 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 38/100
Research direction
Start by tracing the remaining usages from dpsynth/discrete_mechanisms into the internal accounting.py module, then compare the relevant event and conversion APIs in dp_accounting, including RdpAccountant. Run or add equivalence tests for zCDP and GDP conversions where applicable; done requires a confirmed migration path or documented reasons for helpers that must remain local.
Written by the indexing model from the issue text.
Description
dpsynth/discrete_mechanisms currently relies on the internal accounting.py module, which is intended to be deprecated by dp_accounting
I looked into the remaining usages to understand whether the discrete mechanisms could be migrated.
There appear to be direct equivalents for the event representation:
- ZCDpEvent(rho) → dp_accounting.dp_event.ZCDpEvent(rho)
- ComposedDpEvent → dp_accounting.dp_event.ComposedDpEvent
dp_accounting also explicitly uses the same Gaussian/zCDP relationship when handling a ZCDpEvent with xi == 0:
noise_multiplier = 1 / sqrt(2 * rho)
which is mathematically equivalent to the current zcdp_gaussian_sigma() implementation:
sqrt(0.5 / rho).
The remaining helpers in the internal module include conversions/calibration such as zcdp_eps, zcdp_delta, zcdp_rho, zcdp_exponential_eps, and the GDP helpers. Some may be replaceable through RdpAccountant (get_epsilon/get_delta), while others appear to be simple mechanism-calibration formulas that may need to remain local.
Before working on the migration, I wanted to check whether there are known numerical or semantic differences between the existing zCDP accounting implementation and dp_accounting, or another reason the discrete mechanisms have intentionally remained on the internal accounting utilities.
If migration is the intended direction, I'm interested in working on it and can first add equivalence tests for the relevant conversions.
- Dominant language
- Python
- Stars
- 32
- Forks
- 13
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 20
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from google/dpsynth
-
import dpsynth fails because mbi.Dataset is registered as a JAX dataclass twicePossibly taken @hanzalaareeb claimed this 9 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 2 days
-
Clarify installation requirements in quickstart.ipynbPossibly taken @hanzalaareeb claimed this 8 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
google/dpsynth#194 · 1 comment ·
Maintainers usually reply within 2 days
-
`IndependentConfig` synthesis raises "Cliques must be unique."May be free again A pull request for this issue was closed without being merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 2 days
-
Windows install of pylock.toml fails on the pipeline extra due to missing Windows wheel for python-dpPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 3/5 1-2 days Newbie friendliness 72/100
Maintainers usually reply within 2 days
-
Add an option to control the maximum marginal degree in AIM workload constructionPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 3/5 1-2 days Newbie friendliness 65/100
google/dpsynth#199 · 3 comments ·
Maintainers usually reply within 2 days
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Maintainers usually reply within 3 days
-
Negation with "not" and "no" is ignored during sentiment analysisPossibly taken @vivek-3728 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
techcsispit/mess-mood#11 · 1 comment ·
-
changelog investigate
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
ramnes/notion-sdk-py#408 ·
-
good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
btclib-org/btclib-wallet#267 ·
Maintainers usually reply within 1 day
-
good first issue tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
knnmelprop/YAADO#111 ·