Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion prereqs_linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ fi
# Downloading the Google DP library
git submodule update --init --recursive


# checkout out to particular commit
cd third_party/differential-privacy && git checkout 0b0a5c2315d84a6a7b1ff34591e33ec11680891e && \
cd third_party/differential-privacy && git checkout 1b1dc6639173c0a13613189ec21851604a4c7335 && \
cd -
# renaming workspace.bazel to workspace
mv third_party/differential-privacy/cc/WORKSPACE.bazel third_party/differential-privacy/cc/WORKSPACE
Expand Down
4 changes: 2 additions & 2 deletions pydp/algorithms/algorithm.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ def __init__(self, **kwargs):
if "upper_bound" in kwargs and kwargs["upper_bound"] is None:
kwargs.pop("upper_bound")

binded_class = f"{self.__class__.__name__}{self.__map_dtype_str(dtype)}"
binded_class = self.__class__.__name__ + self.__map_dtype_str(dtype)
class_ = getattr(_algorithms, binded_class)

self.dtype = dtype
Expand All @@ -26,7 +26,7 @@ def __map_dtype_str(dtype):
elif dtype == "float":
return "Double"
else:
raise RuntimeError(f"dtype: {dtype} is not supported")
raise RuntimeError("dtype: {} is not supported".format(dtype))

@property
def epsilon(self):
Expand Down
3 changes: 2 additions & 1 deletion src/bindings/PyDP/algorithms/order_statistics.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
// Provides bindings for Order Statistics
#include "../pydp_lib/algorithm_builder.hpp"
#include "algorithms/order-statistics.h"
#include "pybind11/complex.h"
#include "pybind11/functional.h"
#include "pybind11/pybind11.h"
#include "pybind11/stl.h"

#include "../pydp_lib/algorithm_builder.hpp"

using namespace std;

namespace py = pybind11;
Expand Down
2 changes: 0 additions & 2 deletions tests/algorithms/test_distributions.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
from itertools import accumulate
import math

pytestmark = pytest.mark.skip(reason="distributions fail to compile")

k_num_samples = 10000000
k_num_geometric_samples = 1000000
k_gaussian_samples = 1000000
Expand Down
5 changes: 4 additions & 1 deletion tests/base/test_percentile.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
import pytest
import pydp as dp

pytestmark = pytest.mark.skip(reason="this percentile is not the DP implementation")
# TODO: check whether to delete this test suit or update it
pytestmark = pytest.mark.skip(
reason="these tests were for the older percentile wrapping."
)


@pytest.mark.parametrize("input_class", [dp.algorithms.laplacian.Percentile])
Expand Down