Skip to content

Add support and examples for cryptographically secure Jax privacy programs #85

@ryan112358

Description

@ryan112358

DP mechanisms typically have randomness in two places: batch selection and noise addition. Some programs that use Jax privacy may also require internal randomness, although this randomness does not typically affect the privacy guarantee. By default Jax privacy uses numpy pseudo-random number generation for batch selection, and Jax pseudo-random number generation with explicit key management.

The randomgen library can be used for generating crypographically secure random values, and conforms to the same API as numpy. This can offer a drop-in replacement for batch_selection and used via dependency injection by Jax privacy users. For noise_addition, this library can be used to generate normal random values in numpy (on CPU). For efficiency, this should be done asyncronously with the calculation + accumulation of per-example clipped gradients (which occurs on GPU/TPU).

Task:

  • Add a new example binary that demonstrates DP training with cryptographically secure randomness, adding useful reusable components to the Jax privacy library as necessary/helpful.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions