Commit graph

133 commits

Author SHA1 Message Date
Yanhua Sun
856eda3aa1 Explicitly replace "import tensorflow" with "tensorflow.compat.v1"
PiperOrigin-RevId: 290355582
2020-02-07 10:18:46 -08:00
woodyx218
bcbb0c9553
Add files via upload 2020-01-22 10:42:27 +08:00
woodyx218
239827251a
Add files via upload 2020-01-22 10:28:09 +08:00
woodyx218
1d5c5ac2fc
Add files via upload 2020-01-19 20:27:35 +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
woodyx218
47a984dc25
Delete 2020-01-02 16:41:42 +08:00
woodyx218
4a39d26c2f
Initial commit 2020-01-02 16:37:24 +08:00
woodyx218
45e9280a8c
Initial commit 2020-01-02 16:35:37 +08:00
Nicolas Papernot
8d185c81c7 fix language in colab
PiperOrigin-RevId: 281372393
2019-11-19 14:39:58 -08:00
Steve Chien
28d6db4c92 Update Colab to advise users to use a GPU.
PiperOrigin-RevId: 277761946
2019-10-31 11:14:57 -07: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
8a80c1a745 Suppress warnings in Colab
PiperOrigin-RevId: 277393252
2019-10-29 16:49:32 -07:00
Steve Chien
853ec20b52 Specify TF 1.x in Colab.
PiperOrigin-RevId: 277385438
2019-10-29 16:07:28 -07:00
Steve Chien
cad86b925e Update link in Colab button at top of page.
PiperOrigin-RevId: 276752314
2019-10-25 13:44:44 -07:00
anirudh161
596bba431d
Fix Colab link and remove link to tensorflow.org 2019-10-24 17:00:08 -07:00
anirudh161
eb5666b16b
Fix Colab link 2019-10-24 15:36:03 -07:00
anirudh161
ab67fcc455
Change Colab Link 2019-10-24 15:30:27 -07:00
anirudh161
41910b10e9 Add DPSGD-Keras Tutorial 2019-10-24 15:25:13 -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
Steve Chien
0776ed124b Add link to paper on Renyi Differential Privacy.
PiperOrigin-RevId: 267412177
2019-09-05 11:15:27 -07:00
A. Unique TensorFlower
0e84af1e69 Merge pull request #70 from georgianpartners:master
PiperOrigin-RevId: 265056745
2019-08-23 08:06:16 -07:00
A. Unique TensorFlower
602b1c3f37 Update tfds.load() callers to specify shuffle_files=True when necessary.
PiperOrigin-RevId: 264803647
2019-08-22 04:02:08 -07:00
Christopher Choquette Choo
ce20982db0 Merge remote-tracking branch 'origin/master' 2019-08-21 22:57:51 -04:00
Christopher Choquette Choo
18ce9c2335 Stable version for tf2.0a0, b0. 2019-08-21 22:57:35 -04:00
Nicolas Papernot
c7ca8092fb Introduce vectorized DP optimizer
PiperOrigin-RevId: 262414086
2019-08-08 12:56:28 -07:00
A. Unique TensorFlower
9fe5e91de4 Merge pull request #53 from georgianpartners:master
PiperOrigin-RevId: 260990063
2019-07-31 13:44:12 -07:00
Christopher Choquette Choo
4bd0ad482a Refactoring bolton to bolt_on from package refactor for comments + strings. 2019-07-31 10:55:25 -04:00
Christopher Choquette Choo
c0bd19365b Refactoring bolton package to bolt_on only in code usages. 2019-07-31 10:52:41 -04:00
Christopher Choquette Choo
2065f2b16a Code style and documentation changes. 2019-07-30 15:12:22 -04:00
Christopher Choquette Choo
92f97ae32c Fixing missing args. 2019-07-27 13:54:19 -04:00
npapernot
0317ce8077 print 2019-07-25 16:17:56 +00:00
npapernot
8974a95b9a more fixes 2019-07-25 16:13:32 +00:00
npapernot
8e6bcf9b4a many fixes 2019-07-25 15:37:54 +00:00
Christopher Choquette Choo
5857e838ba
Merge pull request #4 from georgianpartners/bolton
Ensuring pylint is 10/10
2019-07-18 15:07:52 -04:00
Christopher Choquette Choo
c05c2aa0d4 Ensuring pylint is 10/10 2019-07-18 15:04:35 -04:00
Christopher Choquette Choo
eab43e8294
Merge pull request #3 from georgianpartners/bolton
Code review changes
2019-07-16 20:02:31 -04:00
Nicolas Papernot
bb7956ed7e fix keras typo
PiperOrigin-RevId: 258434656
2019-07-16 13:59:14 -07:00
Christopher Choquette Choo
b03eb6914b Code review changes: Fixed doc string spacing, copyrighting, and changed the jupyter file to a python script. 2019-07-16 10:33:57 -04:00
Ilya Mironov
45bcb3a0e4 Adding privacy analysis to the Logistic Regression for MNIST tutorial.
PiperOrigin-RevId: 254815428
2019-06-24 12:50:08 -07:00
cchoquette
0b244f0e47
Working bolton model without unit tests. (#1)
Bolton implementation including:
- Bolton Model wrapper for using Bolton method
- Bolton Optimizer encompassing all privacy components
- Introduction of Strongly Convex Loss functions with 2 pre-implemented
- Unit tests for the above.
2019-06-19 11:21:50 -04:00
Christopher Choquette Choo
3080b654b5 Minor changes to function arguments 2019-06-19 11:18:42 -04:00
Christopher Choquette Choo
56e16f0a15 Minor changes + tutorial 2019-06-19 11:04:18 -04:00
A. Unique TensorFlower
2b97c7c735 Logistic regression for mnist with new privacy analysis.
PiperOrigin-RevId: 252743967
2019-06-11 18:58:56 -07:00
Galen Andrew
d5dcfec745 Remove set_denominator functions from DPQuery and make QueryWithLedger easier to use.
set_denominator was added so that the batch size doesn't need to be specified before constructing the optimizer, but it breaks the DPQuery abstraction. Now the optimizer uses a GaussianSumQuery instead of GaussianAverageQuery, and normalization by batch size is done inside the optimizer.

Also instead of creating all DPQueries with a PrivacyLedger and then wrapping with QueryWithLedger, it is now sufficient to create the queries with no ledger and QueryWithLedger will construct the ledger and pass it to all inner queries.

PiperOrigin-RevId: 251462353
2019-06-04 10:14:32 -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
Nicolas Papernot
febafd830d update API calls for TF2
PiperOrigin-RevId: 245817981
2019-04-29 14:00:40 -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
Ilya Mironov
a3e03f773e Adding a paragraph to the walk-through on how to choose RDP orders. Plus deleting empty lines in rdp_accountant.py. Fixing issue #47.
PiperOrigin-RevId: 244467825
2019-04-19 21:50:49 -07:00
Tim Garnsey
aeb6a94b59 added a ledger during optimizer instantiation to the language model tutorial 2019-04-17 12:52:08 +10:00
Steve Chien
3dc2b398d2 Closes #41
PiperOrigin-RevId: 241786994
2019-04-03 12:48:25 -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
8507094f2b add walkthrough MD
PiperOrigin-RevId: 241016765
2019-03-29 11:24:36 -07:00
Nicolas Papernot
03050adb27 adding scratch for walkthrough blog post
PiperOrigin-RevId: 240425310
2019-03-26 14:16:27 -07:00
Nicolas Papernot
3c1e9994eb fix vector loss issue with Keras by instantiate a loss object
PiperOrigin-RevId: 239483918
2019-03-20 15:08:58 -07:00
Nicolas Papernot
0ebd134d99 Closes #33
PiperOrigin-RevId: 239129202
2019-03-18 22:42:01 -07:00
Nicolas Papernot
f58891f3e3 Closes #25
PiperOrigin-RevId: 239031260
2019-03-18 11:55:00 -07:00
Nicolas Papernot
d226cf3172 update tutorial README
PiperOrigin-RevId: 237161576
2019-03-06 18:37:35 -08:00
Nicolas Papernot
fdd110b7df add a Penn TreeBank example
PiperOrigin-RevId: 237160380
2019-03-06 18:27:37 -08:00
Nicolas Papernot
517584d7a6 add Keras tutorial
PiperOrigin-RevId: 236199395
2019-02-28 14:35:28 -08:00
Nicolas Papernot
c2d4b17881 Add support for the Eager mode
PiperOrigin-RevId: 235733975
2019-02-26 09:20:28 -08: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
Ilya Mironov
ff295b6a70 Adding no-privacy baseline (dpsgd=False) to README.md.
PiperOrigin-RevId: 231004783
2019-01-25 18:37:11 -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
A. Unique TensorFlower
047e1eef0e Updating README.md for the tutorial. Included discussion of learning_rate and target accuracy/privacy for several settings of training parameters.
PiperOrigin-RevId: 230016922
2019-01-18 16:49:24 -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