forked from OpenMined/PyDP
-
Notifications
You must be signed in to change notification settings - Fork 0
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
SKLearn Pipeine use LaplaceDistribution Class from Google DP (#408) #1
Merged
SandeepJabez
merged 1 commit into
SandeepJabez:feature/machine-learning-1
from
OpenMined:feature/machine-learning-1
Jul 20, 2022
Merged
SKLearn Pipeine use LaplaceDistribution Class from Google DP (#408) #1
SandeepJabez
merged 1 commit into
SandeepJabez:feature/machine-learning-1
from
OpenMined:feature/machine-learning-1
Jul 20, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Added machine learning and mechanisms directory * Added files for utils Files include: - acountant.py (for BudgetAccountant purposes) - utils.py - validation.py * Directory change for machine learning & mechanism Anything related to machine learning and mechanism is located in the "ml" directory * Added function to check epsilon delta in validation.py * Added function to check min max bounds in validation.py * Added function to clip 2-d array to given maximum norm in validation.py * Added function to clip 2-d array to given bounds in validation.py * Added gunction to set global seed in utils.py * Added function to copy docstring in ml/util/utils.py * Added subclass Budget for privacy budgets epsilon delta * Add class BudgetError for exceeded privacy budget error * Added class for privacy leakage warning * Added class for incompatible arguments PyDP * Added function for warning incompitable argument * Added class for budget accountant The class added main goal is to allocate privacy budget * Added file as base for mechanism and add base class * Added methods for base class * Added class for truncated and folded mechanism * Added files for laplace & geometric mechanism * Added class as main laplace mechanism * Added class for truncated laplacian * Added class for folder laplacian * Added class for main geometric mechanism * Added class for truncated geometric * Added file for naive bayes model with model class * FIX: Move ml directory to src/pydp directory * FEAT: Added LaplaceBoundedDomain class in laplce mechanism file * Added folder that contains machine learning capabilities * Apply Python and C++ styling * Added type:ignored on unresolved imports * Python formatting with Black after adding type:ignore * Fix mypy test errors in ml directory * Fix apply Python format with blac * Add source link to ml directory files * Removed extra special characters * Added example notebook for Naive Bayes implementation * Added Jupyter Notebook for PyDP NB comparison * Moved matplotlib as dev dependincy * change setup msbuild to version 1.0.2 * Test remove python 3.5 in Windows workflow * Add back python 3.5 for Windows build * Remove python-dp in docs/requirements.txt * Change version to cehck build doc action * conf.py in /docs append pydp build path * Change ubuntu version for build docs action * Change Python to 3.6 in build docs action * Revert back ubuntu and Python versions * Add pre-build-command in sphinx-action@master * Fix pre-build-command syntax * Change pre-build-comman for sphinx-action * pre-build-command install software-properties-common * Fix pre-build-command * Fix pre-build-command * Fix pre-build-command * Change ubuntu version for build doc action * Change Python Version to 3.8 * Removed test limited to dev branch. This test would run on all Pull requests now rather than just PR to dev. Other than that, tests are to be triggered if there's a change in ipynb too. * Wrapper for numerical mechanism class [Continuation from #372] (#380) * initial addition of partition selection * corrected instantiation to 'builder.Build' instead * build works, TODO: deal with passing Laplace/Gaussian mechanims builders * post-review changes, moved partition selection python related code to own submodule * fixed some formatting * Added documentation * post formatting * added tests for partition selection * moved imports for patition_selection * clarified TODO dependency * attempt to resolve linting issues * * Added exports in algorithms.partition_selection * Replaced the Create*PartitionStrategy functions with a template function and instantiantions * revert a to latest stable commit * restore the correct commit for google-dp submodule * added python bindings for numerical mechanisms * added some python files * fixed prereqs_linux.sh script * saving changes * build + tests work * added docs for numerical mechanisms * Fix Bazel build Bazel failed to build since the name of the workspace was inconsistent with the DP Library. This commit also fixes the order in which we install dependencies of the DP Lib. Additionally, on Linux we used the wrong compiler flags, which is now fixed in the .bazelrc. * Revert "Fix Bazel build" * Update README.md (#385) * Update README.md Changed "Currently supports Linux and macOS (Windows support coming soon)" to "Compatible with all three types of Operating Systems - Linux, macOS, and Windows" * Update README.md Changed "Currently supports Linux and macOS (Windows support coming soon)" to "Compatible with all three types of Operating Systems - Linux, macOS, and Windows" * sha upgrade and added temporary fix for bazel reference * upgraded SHA * removal of functions and dependency in accordance with SHA upgrade * fixed build file reference issue for test cases * build file reference fix * Made the system release ready * Fixed the ubuntu version for google collab * fixed the BUILD file naming * c++ styling * fixed the RC version * Attempt to trigger the find replace in BUILD file * added find replace in version scripts * updated the release number to 1.1.1 * Fixed the bazel build absolute reference * removed the temporary fix in the build actions * fix * fix * Removing unused code (#400) * clean-ups * tiny fix * format * format c++ * Add support for categorical features for Laplace mechanism * Clean-ups (#401) Removing unused code and using c++ style guidelines * Improve Laplace Demo Notebook and add minimal README (#404) * Improve Laplace Demo NB and add minimal README * Improve the Conclusion Section * Add back the old conclusion * Removed partial privacy budget + Update Google C++ DP library to the latest commit and fix compilation errors (#405) * update * update * remove unintended changed * tests * FIX: Change Google DP Commit Hash * FEAT: SKLearn Laplace Mechanism use Google DP Modifie the `LaplaceMechanism`class in `/src/pydp/ml/mechanisms/sklearn_pipeline.py` so that it uses `LaplaceDistribution` class from Google DP` * Fix typo in build-docs.yml * FIX: Stling pythong and cpp * FIX: Styling python and cpp * FIX: Typo in build-docs.yml * FIX: Changed clang-format version * FIX: Try clang-format 12 * Update to the latest version of Google building block library (#415) * remove privacy budget * fixes * fixes * tests * FIX: Change clang format action version * Reset HEAD Co-authored-by: Chinmay Shah <[email protected]> Co-authored-by: Lev Zlotnik <[email protected]> Co-authored-by: Christoph Dibak <[email protected]> Co-authored-by: Abin (אבין ברגיס) <[email protected]> Co-authored-by: FIRhinmay <[email protected]> Co-authored-by: Vadym Doroshenko <[email protected]> Co-authored-by: dvadym <[email protected]> Co-authored-by: Saurav Maheshkar <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Added machine learning and mechanisms directory
Added files for utils
Files include:
Anything related to machine learning
and mechanism is located in the
"ml" directory
Added function to check epsilon delta in validation.py
Added function to check min max bounds in validation.py
Added function to clip 2-d array to given maximum norm in validation.py
Added function to clip 2-d array to given bounds in validation.py
Added gunction to set global seed in utils.py
Added function to copy docstring in ml/util/utils.py
Added subclass Budget for privacy budgets epsilon delta
Add class BudgetError for exceeded privacy budget error
Added class for privacy leakage warning
Added class for incompatible arguments PyDP
Added function for warning incompitable argument
Added class for budget accountant
The class added main goal is
to allocate privacy budget
Added file as base for mechanism and add base class
Added methods for base class
Added class for truncated and folded mechanism
Added files for laplace & geometric mechanism
Added class as main laplace mechanism
Added class for truncated laplacian
Added class for folder laplacian
Added class for main geometric mechanism
Added class for truncated geometric
Added file for naive bayes model with model class
FIX: Move ml directory to src/pydp directory
FEAT: Added LaplaceBoundedDomain class in laplce mechanism file
Added folder that contains machine learning capabilities
Apply Python and C++ styling
Added type:ignored on unresolved imports
Python formatting with Black after adding type:ignore
Fix mypy test errors in ml directory
Fix apply Python format with blac
Add source link to ml directory files
Removed extra special characters
Added example notebook for Naive Bayes implementation
Added Jupyter Notebook for PyDP NB comparison
Moved matplotlib as dev dependincy
change setup msbuild to version 1.0.2
Test remove python 3.5 in Windows workflow
Add back python 3.5 for Windows build
Remove python-dp in docs/requirements.txt
Change version to cehck build doc action
conf.py in /docs append pydp build path
Change ubuntu version for build docs action
Change Python to 3.6 in build docs action
Revert back ubuntu and Python versions
Add pre-build-command in sphinx-action@master
Fix pre-build-command syntax
Change pre-build-comman for sphinx-action
pre-build-command install software-properties-common
Fix pre-build-command
Fix pre-build-command
Fix pre-build-command
Change ubuntu version for build doc action
Change Python Version to 3.8
Removed test limited to dev branch.
This test would run on all Pull requests now rather than just PR to dev.
Other than that, tests are to be triggered if there's a change in ipynb too.
Wrapper for numerical mechanism class [Continuation from [WIP] Wrapper for numerical mechanism class OpenMined/PyDP#372] (Wrapper for numerical mechanism class [Continuation from #372] OpenMined/PyDP#380)
initial addition of partition selection
corrected instantiation to 'builder.Build' instead
build works, TODO: deal with passing Laplace/Gaussian mechanims builders
post-review changes, moved partition selection python related code to own submodule
fixed some formatting
Added documentation
post formatting
added tests for partition selection
moved imports for patition_selection
clarified TODO dependency
attempt to resolve linting issues
Replaced the Create*PartitionStrategy functions with a template
function and instantiantions
revert a to latest stable commit
restore the correct commit for google-dp submodule
added python bindings for numerical mechanisms
added some python files
fixed prereqs_linux.sh script
saving changes
build + tests work
added docs for numerical mechanisms
Fix Bazel build
Bazel failed to build since the name of the workspace was inconsistent
with the DP Library. This commit also fixes the order in which we
install dependencies of the DP Lib. Additionally, on Linux we used the
wrong compiler flags, which is now fixed in the .bazelrc.
Revert "Fix Bazel build"
Update README.md (Update README.md OpenMined/PyDP#385)
Update README.md
Changed "Currently supports Linux and macOS (Windows support coming soon)" to "Compatible with all three types of Operating Systems - Linux, macOS, and Windows"
Changed "Currently supports Linux and macOS (Windows support coming soon)" to "Compatible with all three types of Operating Systems - Linux, macOS, and Windows"
sha upgrade and added temporary fix for bazel reference
upgraded SHA
removal of functions and dependency in accordance with SHA upgrade
fixed build file reference issue for test cases
build file reference fix
Made the system release ready
Fixed the ubuntu version for google collab
fixed the BUILD file naming
c++ styling
fixed the RC version
Attempt to trigger the find replace in BUILD file
added find replace in version scripts
updated the release number to 1.1.1
Fixed the bazel build absolute reference
removed the temporary fix in the build actions
fix
fix
Removing unused code (Removing unused code OpenMined/PyDP#400)
clean-ups
tiny fix
format
format c++
Add support for categorical features for Laplace mechanism
Clean-ups (Clean-ups OpenMined/PyDP#401)
Removing unused code and using c++ style guidelines
Improve Laplace Demo Notebook and add minimal README (Improve Laplace Demo Notebook and add minimal README OpenMined/PyDP#404)
Improve Laplace Demo NB and add minimal README
Improve the Conclusion Section
Add back the old conclusion
Removed partial privacy budget + Update Google C++ DP library to the latest commit and fix compilation errors (Update Google C++ DP library to the latest commit and fix compilation errors OpenMined/PyDP#405)
update
update
remove unintended changed
tests
FIX: Change Google DP Commit Hash
FEAT: SKLearn Laplace Mechanism use Google DP
Modifie the
LaplaceMechanism
class in/src/pydp/ml/mechanisms/sklearn_pipeline.py
so that it uses
LaplaceDistribution
classfrom Google DP`
Fix typo in build-docs.yml
FIX: Stling pythong and cpp
FIX: Styling python and cpp
FIX: Typo in build-docs.yml
FIX: Changed clang-format version
FIX: Try clang-format 12
Update to the latest version of Google building block library (Update to the latest version of Google building block library OpenMined/PyDP#415)
remove privacy budget
fixes
fixes
tests
FIX: Change clang format action version
Reset HEAD
Co-authored-by: Chinmay Shah [email protected]
Co-authored-by: Lev Zlotnik [email protected]
Co-authored-by: Christoph Dibak [email protected]
Co-authored-by: Abin (אבין ברגיס) [email protected]
Co-authored-by: FIRhinmay [email protected]
Co-authored-by: Vadym Doroshenko [email protected]
Co-authored-by: dvadym [email protected]
Co-authored-by: Saurav Maheshkar [email protected]