Commit graph

37 commits

Author SHA1 Message Date
Shuang Song
44dc40454b Minor fix to tutorials.
PiperOrigin-RevId: 463145196
2022-07-25 12:07:46 -07:00
Fabien Hertschuh
5493a3baf0 Explicitly import estimator from tensorflow as a separate import instead of
accessing it via tf.estimator and depend on the tensorflow estimator target.

PiperOrigin-RevId: 438419860
2022-03-30 16:05:01 -07:00
Michael Reneer
28db674240 Ensure that TF 1.0 API is referenced at the call site in TensorFlow Privacy.
This change makes it easy to search for usage of TF 1.0 API and updates the TF imports across TFP to be written consistently.

PiperOrigin-RevId: 427043028
2022-02-07 16:06:22 -08:00
Michael Reneer
943ef91ee9 Format TensorFlow Privacy files.
PiperOrigin-RevId: 424923635
2022-01-28 11:57:24 -08:00
Michael Reneer
a749ce4e30 Remove TensorFlow Privacy __future__ imports.
Note: Exclude changes to the research directory.
PiperOrigin-RevId: 424650953
2022-01-27 10:37:22 -08:00
Steve Chien
1a959eec34 Fix import of tutorials common module.
PiperOrigin-RevId: 321789833
2020-07-17 09:07:30 -07:00
Steve Chien
10335f6177 Refactor MNIST tutorials and create new TPU tutorial:
1. Move common code to new file mnist_dpsgd_tutorial_common.py.
2. Move epsilon computation function out of binary into its own library.
3. Create new TPU tutorial.

PiperOrigin-RevId: 310409308
2020-05-07 12:05:50 -07:00
A. Unique TensorFlower
2301931725 Fix issue with importing tensorflow.compat.v1.
PiperOrigin-RevId: 300175680
2020-03-10 14:16:46 -07:00
Yanhua Sun
856eda3aa1 Explicitly replace "import tensorflow" with "tensorflow.compat.v1"
PiperOrigin-RevId: 290355582
2020-02-07 10:18:46 -08:00
A. Unique TensorFlower
1a448b4272 Document how to set delta. Document orders list in eps computation.
PiperOrigin-RevId: 289514598
2020-01-13 14:07:14 -08:00
Steve Chien
d69879d360 Changes to make Tensorflow Privacy compatible with TF 2.0.
PiperOrigin-RevId: 277561553
2019-10-30 12:33:02 -07:00
Steve Chien
1ce8cd4032 Restructure TF Privacy to be more in line with other repos in the TF ecosystem.
PiperOrigin-RevId: 274674077
2019-10-14 15:29:52 -07:00
Nicolas Papernot
a06bc6c99b fix imports for v1 and make the versioning more explicit through LooseVersion
PiperOrigin-RevId: 249732562
2019-05-23 15:57:08 -07:00
Ilya Mironov
9cece21d92 Clean-up pass to eliminate warnings: replacing deprecated endpoints with recommended versions and annotating test sizes.
PiperOrigin-RevId: 246901723
2019-05-06 14:50:23 -07:00
Ilya Mironov
85280ab568 Removing max_samples and max_queries from the tutorial.
PiperOrigin-RevId: 246850557
2019-05-06 10:30:35 -07:00
Nicolas Papernot
c09ec4c22b minor fixes to improve tf 1 and 2 compatibility
PiperOrigin-RevId: 246008822
2019-04-30 13:22:57 -07:00
A. Unique TensorFlower
ab466b156c Check batch_size % microbatches = 0 and calculate privacy budget only when dpsgd is set.
PiperOrigin-RevId: 244949900
2019-04-23 16:40:33 -07:00
Galen Andrew
9106a04e2c Use PrivacyLedger for privacy accounting.
Prior to this change the PrivacyLedger is running to keep a log of private queries, but the ledger is not actually used to compute the (epsilon, delta) guarantees. This CL adds a function to compute the RDP directly from the ledger.

Note I did verify that the tutorial builds and runs with the changes and for the first few iterations prints the same epsilon values as before the change.

PiperOrigin-RevId: 241063532
2019-03-29 15:31:32 -07:00
Nicolas Papernot
0ebd134d99 Closes #33
PiperOrigin-RevId: 239129202
2019-03-18 22:42:01 -07:00
Nicolas Papernot
bfba26801d Closes #16
PiperOrigin-RevId: 235070241
2019-02-21 14:34:27 -08:00
Steve Chien
d75f1b80ba Fix copybara to limit some transformations to the beginning of the line.
PiperOrigin-RevId: 233151293
2019-02-08 16:55:57 -08:00
A. Unique TensorFlower
4d0ab48c35 Add privacy ledger.
The privacy ledger keeps a record of all sampling and query events for analysis post hoc by the privacy accountant.

PiperOrigin-RevId: 233094012
2019-02-08 11:21:43 -08:00
A. Unique TensorFlower
36d9959c19 internal change
PiperOrigin-RevId: 233093203
2019-02-08 11:17:09 -08:00
Ilya Mironov
d435fcbf9a Updating README.md to reflect ReLU activation function.
+ clean-up of mnist_dpsgd_tutorial

PiperOrigin-RevId: 232707393
2019-02-06 11:06:31 -08:00
Nicolas Papernot
8c99088cf1 add ReLUs to tutorial model
PiperOrigin-RevId: 232073877
2019-02-01 18:43:35 -08:00
Nicolas Papernot
668888c1a6 change kernel initializer to fix dpsgd=False tutorial
PiperOrigin-RevId: 230931823
2019-01-25 10:59:51 -08:00
A. Unique TensorFlower
4f9cc8ef3e 1. Adding a CLI script for computing privacy loss for DP-SGD.
2. Fixing typos in the MNIST tutorial.

PiperOrigin-RevId: 230608908
2019-01-23 14:56:27 -08:00
Galen Andrew
c8cb3c6b70 General cleanup.
1. Rename PrivateQuery to DPQuery.
2. Move construction of DPQuery to outside of optimizer.
3. Remove PrivateAverageQuery and PrivateSumQuery, and rename DPQuery's 'get_query_result' method to 'get_noised_result'. Rename private_queries.py to dp_query.py.
4. Remove thrice-replicated run_query function from the test classes and replace with a single function in new test_utils.py.
5. Add functions gaussian_sum_query_from_noise_multplier and gaussian_average_query_from_noise_multplier.

PiperOrigin-RevId: 230595991
2019-01-23 14:41:44 -08:00
Nicolas Papernot
4487099296 Closes #11
PiperOrigin-RevId: 229430188
2019-01-15 13:32:56 -08:00
Nicolas Papernot
4c1f3c07f4 Modify loss passed to optimizer when dpsgd is False in MNIST tutorial
PiperOrigin-RevId: 229233829
2019-01-14 12:38:20 -08:00
schien1729
3b4ddf6914 Merge pull request #3 from carlini:master
PiperOrigin-RevId: 228556799
2019-01-09 11:40:16 -08:00
Steve Chien
932190c4e5 Automated rollback of commit a7190fc1ed
PiperOrigin-RevId: 228425879
2019-01-08 18:04:36 -08:00
Steve Chien
a7190fc1ed Fix python3 bug: range() is no longer list. From @carlini
PiperOrigin-RevId: 228237806
2019-01-08 17:38:10 -08:00
A. Unique TensorFlower
01ab549902 Renaming stddev_to_sensitivity_ratio to noise_multiplier in rdp_accountant.
PiperOrigin-RevId: 227552068
2019-01-04 15:57:52 -08:00
Nicholas Carlini
21de1f9dd8 Fix python3 bug: range() is no longer list 2018-12-26 18:23:36 +00:00
A. Unique TensorFlower
b4188446e0 Project import generated by Copybara.
PiperOrigin-RevId: 226345615
2018-12-20 09:17:59 -08:00
Steve Chien
1595ed3cd1 Project import generated by Copybara.
PiperOrigin-RevId: 226056146
2018-12-18 15:44:04 -08:00