From 29fac758af818f6d8522876a105230e8b9fbdec2 Mon Sep 17 00:00:00 2001 From: "A. Unique TensorFlower" Date: Thu, 3 Jan 2019 13:42:00 -0800 Subject: [PATCH] - Fixing dependencies in setup.py and requirements.txt. PiperOrigin-RevId: 227742524 --- README.md | 5 +++-- privacy/analysis/rdp_accountant_test.py | 1 + requirements.txt | 2 ++ setup.py | 8 ++++++-- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 03affea..8c29f1e 100644 --- a/README.md +++ b/README.md @@ -20,8 +20,9 @@ performance, it is also recommended to install TensorFlow with GPU support (detailed instructions on how to do this are available in the TensorFlow installation documentation). -Installing TensorFlow will take care of all other dependencies like `numpy` and -`scipy`. +In addition to TensorFlow and its dependencies, other prerequisites are: + * `scipy` >= 0.17 + * `mpmath` (for testing) ### Installing TensorFlow Privacy diff --git a/privacy/analysis/rdp_accountant_test.py b/privacy/analysis/rdp_accountant_test.py index fab38a9..79cb797 100644 --- a/privacy/analysis/rdp_accountant_test.py +++ b/privacy/analysis/rdp_accountant_test.py @@ -27,6 +27,7 @@ import numpy as np from privacy.analysis import rdp_accountant + class TestGaussianMoments(parameterized.TestCase): ################################# # HELPER FUNCTIONS: # diff --git a/requirements.txt b/requirements.txt index 0f57144..1594174 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1,3 @@ tensorflow +mpmath +scipy diff --git a/setup.py b/setup.py index b81e407..4927033 100644 --- a/setup.py +++ b/setup.py @@ -18,10 +18,14 @@ setup(name='privacy', version='0.0.1', url='https://github.com/tensorflow/privacy', license='Apache-2.0', + install_requires=[ + 'scipy>=0.17', + 'mpmath', # used in tests only + ], # Explicit dependence on TensorFlow is not supported. # See https://github.com/tensorflow/tensorflow/issues/7166 extras_require={ - "tf": ["tensorflow>=1.0.0"], - "tf_gpu": ["tensorflow-gpu>=1.0.0"], + 'tf': ['tensorflow>=1.0.0'], + 'tf_gpu': ['tensorflow-gpu>=1.0.0'], }, packages=find_packages())