opendp 0.9.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (395) hide show
  1. opendp-0.9.2/MANIFEST.in +1 -0
  2. opendp-0.9.2/PKG-INFO +101 -0
  3. opendp-0.9.2/README.md +70 -0
  4. opendp-0.9.2/pyproject.toml +11 -0
  5. opendp-0.9.2/setup.cfg +55 -0
  6. opendp-0.9.2/setup.py +25 -0
  7. opendp-0.9.2/src/opendp/__init__.py +1 -0
  8. opendp-0.9.2/src/opendp/_convert.py +660 -0
  9. opendp-0.9.2/src/opendp/_data.py +450 -0
  10. opendp-0.9.2/src/opendp/_extrinsics/__init__.py +4 -0
  11. opendp-0.9.2/src/opendp/_extrinsics/_make_np_count/__init__.py +33 -0
  12. opendp-0.9.2/src/opendp/_extrinsics/_make_np_eigendecomposition/__init__.py +70 -0
  13. opendp-0.9.2/src/opendp/_extrinsics/_make_np_eigenvalues/__init__.py +50 -0
  14. opendp-0.9.2/src/opendp/_extrinsics/_make_np_eigenvector/__init__.py +207 -0
  15. opendp-0.9.2/src/opendp/_extrinsics/_make_np_mean/__init__.py +59 -0
  16. opendp-0.9.2/src/opendp/_extrinsics/_make_np_sscp/__init__.py +67 -0
  17. opendp-0.9.2/src/opendp/_extrinsics/_make_np_sum/__init__.py +49 -0
  18. opendp-0.9.2/src/opendp/_extrinsics/_test.py +18 -0
  19. opendp-0.9.2/src/opendp/_extrinsics/_utilities.py +78 -0
  20. opendp-0.9.2/src/opendp/_extrinsics/domains/__init__.py +206 -0
  21. opendp-0.9.2/src/opendp/_extrinsics/make_np_clamp/__init__.py +60 -0
  22. opendp-0.9.2/src/opendp/_extrinsics/make_np_pca/__init__.py +183 -0
  23. opendp-0.9.2/src/opendp/_extrinsics/sklearn/__init__.py +1 -0
  24. opendp-0.9.2/src/opendp/_extrinsics/sklearn/pca.py +134 -0
  25. opendp-0.9.2/src/opendp/_lib.py +412 -0
  26. opendp-0.9.2/src/opendp/accuracy.py +331 -0
  27. opendp-0.9.2/src/opendp/combinators.py +439 -0
  28. opendp-0.9.2/src/opendp/context.py +867 -0
  29. opendp-0.9.2/src/opendp/core.py +871 -0
  30. opendp-0.9.2/src/opendp/domains.py +528 -0
  31. opendp-0.9.2/src/opendp/measurements.py +1223 -0
  32. opendp-0.9.2/src/opendp/measures.py +280 -0
  33. opendp-0.9.2/src/opendp/metrics.py +433 -0
  34. opendp-0.9.2/src/opendp/mod.py +1078 -0
  35. opendp-0.9.2/src/opendp/polars.py +385 -0
  36. opendp-0.9.2/src/opendp/prelude.py +52 -0
  37. opendp-0.9.2/src/opendp/py.typed +0 -0
  38. opendp-0.9.2/src/opendp/rust/Cargo.toml +127 -0
  39. opendp-0.9.2/src/opendp/rust/build/derive.rs +193 -0
  40. opendp-0.9.2/src/opendp/rust/build/main.rs +7 -0
  41. opendp-0.9.2/src/opendp/rust/katex.html +26 -0
  42. opendp-0.9.2/src/opendp/rust/opendp_derive/Cargo.toml +25 -0
  43. opendp-0.9.2/src/opendp/rust/opendp_derive/src/full.rs +105 -0
  44. opendp-0.9.2/src/opendp/rust/opendp_derive/src/lib.rs +354 -0
  45. opendp-0.9.2/src/opendp/rust/opendp_tooling/Cargo.toml +19 -0
  46. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/bootstrap/arguments.rs +224 -0
  47. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/bootstrap/docstring.rs +389 -0
  48. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/bootstrap/mod.rs +194 -0
  49. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/bootstrap/partial.rs +124 -0
  50. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/bootstrap/signature.rs +265 -0
  51. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/mod.rs +161 -0
  52. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/python.rs +622 -0
  53. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/python_typemap.json +51 -0
  54. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/r/c.rs +435 -0
  55. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/r/mod.rs +94 -0
  56. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/r/r.rs +637 -0
  57. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/codegen/type_hierarchy.json +6 -0
  58. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/lib.rs +87 -0
  59. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/proven/filesystem.rs +137 -0
  60. opendp-0.9.2/src/opendp/rust/opendp_tooling/src/proven/mod.rs +68 -0
  61. opendp-0.9.2/src/opendp/rust/src/accuracy/accuracy_to_discrete_gaussian_scale.tex +27 -0
  62. opendp-0.9.2/src/opendp/rust/src/accuracy/accuracy_to_discrete_laplacian_scale.tex +30 -0
  63. opendp-0.9.2/src/opendp/rust/src/accuracy/discrete_gaussian_scale_to_accuracy.tex +66 -0
  64. opendp-0.9.2/src/opendp/rust/src/accuracy/discrete_laplacian_scale_to_accuracy.tex +57 -0
  65. opendp-0.9.2/src/opendp/rust/src/accuracy/ffi.rs +82 -0
  66. opendp-0.9.2/src/opendp/rust/src/accuracy/mod.rs +280 -0
  67. opendp-0.9.2/src/opendp/rust/src/accuracy/test.rs +327 -0
  68. opendp-0.9.2/src/opendp/rust/src/combinators/amplify/ffi.rs +117 -0
  69. opendp-0.9.2/src/opendp/rust/src/combinators/amplify/mod.rs +116 -0
  70. opendp-0.9.2/src/opendp/rust/src/combinators/amplify/test.rs +21 -0
  71. opendp-0.9.2/src/opendp/rust/src/combinators/chain/ffi.rs +173 -0
  72. opendp-0.9.2/src/opendp/rust/src/combinators/chain/mod.rs +199 -0
  73. opendp-0.9.2/src/opendp/rust/src/combinators/chain/shr/mod.rs +214 -0
  74. opendp-0.9.2/src/opendp/rust/src/combinators/chain/shr/partials.rs +294 -0
  75. opendp-0.9.2/src/opendp/rust/src/combinators/chain/test.rs +120 -0
  76. opendp-0.9.2/src/opendp/rust/src/combinators/fix_delta/ffi.rs +77 -0
  77. opendp-0.9.2/src/opendp/rust/src/combinators/fix_delta/mod.rs +69 -0
  78. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/mod.rs +11 -0
  79. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/pureDP_to_fixed_approxDP/ffi.rs +54 -0
  80. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/pureDP_to_fixed_approxDP/mod.rs +39 -0
  81. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/pureDP_to_zCDP/ffi.rs +56 -0
  82. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/pureDP_to_zCDP/mod.rs +46 -0
  83. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/zCDP_to_approxDP/cdp_epsilon.py +47 -0
  84. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/zCDP_to_approxDP/cdp_epsilon.rs +119 -0
  85. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/zCDP_to_approxDP/cdp_epsilon.tex +218 -0
  86. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/zCDP_to_approxDP/ffi.rs +58 -0
  87. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/zCDP_to_approxDP/mod.bib +18 -0
  88. opendp-0.9.2/src/opendp/rust/src/combinators/measure_cast/zCDP_to_approxDP/mod.rs +47 -0
  89. opendp-0.9.2/src/opendp/rust/src/combinators/mod.rs +29 -0
  90. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/interactive/ffi.rs +160 -0
  91. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/interactive/mod.rs +203 -0
  92. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/interactive/test.rs +79 -0
  93. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/mod.rs +9 -0
  94. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/noninteractive/ffi.rs +146 -0
  95. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/noninteractive/mod.rs +141 -0
  96. opendp-0.9.2/src/opendp/rust/src/combinators/sequential_compositor/noninteractive/test.rs +59 -0
  97. opendp-0.9.2/src/opendp/rust/src/combinators/test.rs +36 -0
  98. opendp-0.9.2/src/opendp/rust/src/core/ffi.rs +958 -0
  99. opendp-0.9.2/src/opendp/rust/src/core/mod.rs +474 -0
  100. opendp-0.9.2/src/opendp/rust/src/core/test.rs +44 -0
  101. opendp-0.9.2/src/opendp/rust/src/data/ffi/mod.rs +1190 -0
  102. opendp-0.9.2/src/opendp/rust/src/data/ffi/polars.rs +55 -0
  103. opendp-0.9.2/src/opendp/rust/src/data/mod.rs +103 -0
  104. opendp-0.9.2/src/opendp/rust/src/data/test.rs +21 -0
  105. opendp-0.9.2/src/opendp/rust/src/domains/code/atom_domain.R +1 -0
  106. opendp-0.9.2/src/opendp/rust/src/domains/code/atom_domain.rst +2 -0
  107. opendp-0.9.2/src/opendp/rust/src/domains/ffi.rs +439 -0
  108. opendp-0.9.2/src/opendp/rust/src/domains/mod.rs +582 -0
  109. opendp-0.9.2/src/opendp/rust/src/domains/polars/expr/ffi.rs +78 -0
  110. opendp-0.9.2/src/opendp/rust/src/domains/polars/expr/mod.rs +267 -0
  111. opendp-0.9.2/src/opendp/rust/src/domains/polars/frame/ffi.rs +197 -0
  112. opendp-0.9.2/src/opendp/rust/src/domains/polars/frame/mod.rs +367 -0
  113. opendp-0.9.2/src/opendp/rust/src/domains/polars/frame/test.rs +41 -0
  114. opendp-0.9.2/src/opendp/rust/src/domains/polars/mod.rs +8 -0
  115. opendp-0.9.2/src/opendp/rust/src/domains/polars/series/ffi.rs +106 -0
  116. opendp-0.9.2/src/opendp/rust/src/domains/polars/series/mod.rs +268 -0
  117. opendp-0.9.2/src/opendp/rust/src/domains/polars/series/test.rs +73 -0
  118. opendp-0.9.2/src/opendp/rust/src/domains/poly.rs +81 -0
  119. opendp-0.9.2/src/opendp/rust/src/error/mod.rs +218 -0
  120. opendp-0.9.2/src/opendp/rust/src/error/test.rs +18 -0
  121. opendp-0.9.2/src/opendp/rust/src/ffi/any.rs +739 -0
  122. opendp-0.9.2/src/opendp/rust/src/ffi/dispatch.rs +181 -0
  123. opendp-0.9.2/src/opendp/rust/src/ffi/mod.rs +113 -0
  124. opendp-0.9.2/src/opendp/rust/src/ffi/util.rs +518 -0
  125. opendp-0.9.2/src/opendp/rust/src/interactive/mod.rs +292 -0
  126. opendp-0.9.2/src/opendp/rust/src/lib.rs +192 -0
  127. opendp-0.9.2/src/opendp/rust/src/lib.sty +184 -0
  128. opendp-0.9.2/src/opendp/rust/src/measurements/alp/ffi.rs +89 -0
  129. opendp-0.9.2/src/opendp/rust/src/measurements/alp/mod.rs +420 -0
  130. opendp-0.9.2/src/opendp/rust/src/measurements/alp/test.rs +215 -0
  131. opendp-0.9.2/src/opendp/rust/src/measurements/code/README.md +23 -0
  132. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_gaussian.R +22 -0
  133. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_gaussian.rst +11 -0
  134. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_geometric.rst +11 -0
  135. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_laplace.rst +12 -0
  136. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_private_lazyframe.rst +63 -0
  137. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_randomized_response.rst +4 -0
  138. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_randomized_response_bool.rst +4 -0
  139. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_report_noisy_max_gumbel.rst +11 -0
  140. opendp-0.9.2/src/opendp/rust/src/measurements/code/make_user_measurement.rst +15 -0
  141. opendp-0.9.2/src/opendp/rust/src/measurements/code/then_report_noisy_max_gumbel.rst +5 -0
  142. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/ffi.rs +187 -0
  143. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/float/mod.rs +112 -0
  144. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/float/test.rs +33 -0
  145. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/integer/mod.rs +123 -0
  146. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/integer/test.rs +41 -0
  147. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/mod.rs +223 -0
  148. opendp-0.9.2/src/opendp/rust/src/measurements/gaussian/test.rs +38 -0
  149. opendp-0.9.2/src/opendp/rust/src/measurements/geometric/ffi.rs +83 -0
  150. opendp-0.9.2/src/opendp/rust/src/measurements/geometric/integer/mod.rs +115 -0
  151. opendp-0.9.2/src/opendp/rust/src/measurements/geometric/integer/test.rs +65 -0
  152. opendp-0.9.2/src/opendp/rust/src/measurements/geometric/mod.rs +121 -0
  153. opendp-0.9.2/src/opendp/rust/src/measurements/gumbel_max/ffi.rs +59 -0
  154. opendp-0.9.2/src/opendp/rust/src/measurements/gumbel_max/make_report_noisy_max_gumbel.tex +258 -0
  155. opendp-0.9.2/src/opendp/rust/src/measurements/gumbel_max/mod.rs +166 -0
  156. opendp-0.9.2/src/opendp/rust/src/measurements/gumbel_max/pseudocode/make_report_noisy_max_gumbel.py +52 -0
  157. opendp-0.9.2/src/opendp/rust/src/measurements/gumbel_max/references.bib +36 -0
  158. opendp-0.9.2/src/opendp/rust/src/measurements/gumbel_max/test.rs +40 -0
  159. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/ffi.rs +171 -0
  160. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/float/mod.rs +126 -0
  161. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/float/test.rs +58 -0
  162. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/integer/mod.rs +116 -0
  163. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/integer/test.rs +31 -0
  164. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/mod.rs +182 -0
  165. opendp-0.9.2/src/opendp/rust/src/measurements/laplace/test.rs +19 -0
  166. opendp-0.9.2/src/opendp/rust/src/measurements/laplace_threshold/ffi.rs +71 -0
  167. opendp-0.9.2/src/opendp/rust/src/measurements/laplace_threshold/mod.rs +152 -0
  168. opendp-0.9.2/src/opendp/rust/src/measurements/laplace_threshold/test.rs +25 -0
  169. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_index_candidates/mod.rs +237 -0
  170. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_index_candidates/test.rs +71 -0
  171. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_len/mod.rs +72 -0
  172. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_len/test.rs +60 -0
  173. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_literal/mod.rs +44 -0
  174. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_literal/test.rs +52 -0
  175. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_noise/mod.rs +346 -0
  176. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_noise/test.rs +135 -0
  177. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_postprocess/mod.rs +106 -0
  178. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_postprocess/test.rs +61 -0
  179. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_report_noisy_max_gumbel/mod.rs +318 -0
  180. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/expr_report_noisy_max_gumbel/test.rs +92 -0
  181. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/ffi.rs +68 -0
  182. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_expr/mod.rs +185 -0
  183. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/aggregate/mod.rs +153 -0
  184. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/aggregate/test.rs +42 -0
  185. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/ffi.rs +75 -0
  186. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/mod.rs +145 -0
  187. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/postprocess/mod.rs +56 -0
  188. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/postprocess/test.rs +41 -0
  189. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/select/mod.rs +132 -0
  190. opendp-0.9.2/src/opendp/rust/src/measurements/make_private_lazyframe/select/test.rs +83 -0
  191. opendp-0.9.2/src/opendp/rust/src/measurements/make_user_measurement/mod.rs +79 -0
  192. opendp-0.9.2/src/opendp/rust/src/measurements/mod.rs +54 -0
  193. opendp-0.9.2/src/opendp/rust/src/measurements/randomized_response/ffi.rs +72 -0
  194. opendp-0.9.2/src/opendp/rust/src/measurements/randomized_response/make_randomized_response_bool.tex +131 -0
  195. opendp-0.9.2/src/opendp/rust/src/measurements/randomized_response/mod.rs +171 -0
  196. opendp-0.9.2/src/opendp/rust/src/measurements/randomized_response/test.rs +50 -0
  197. opendp-0.9.2/src/opendp/rust/src/measures/ffi.rs +238 -0
  198. opendp-0.9.2/src/opendp/rust/src/measures/mod.rs +218 -0
  199. opendp-0.9.2/src/opendp/rust/src/metrics/ffi.rs +318 -0
  200. opendp-0.9.2/src/opendp/rust/src/metrics/mod.rs +657 -0
  201. opendp-0.9.2/src/opendp/rust/src/polars/mod.rs +433 -0
  202. opendp-0.9.2/src/opendp/rust/src/traits/arithmetic/mod.rs +645 -0
  203. opendp-0.9.2/src/opendp/rust/src/traits/bounded/mod.rs +16 -0
  204. opendp-0.9.2/src/opendp/rust/src/traits/cast/mod.rs +485 -0
  205. opendp-0.9.2/src/opendp/rust/src/traits/cast/test.rs +60 -0
  206. opendp-0.9.2/src/opendp/rust/src/traits/mod.rs +301 -0
  207. opendp-0.9.2/src/opendp/rust/src/traits/operations/mod.rs +395 -0
  208. opendp-0.9.2/src/opendp/rust/src/traits/operations/test.rs +14 -0
  209. opendp-0.9.2/src/opendp/rust/src/traits/samplers/bernoulli/mod.rs +140 -0
  210. opendp-0.9.2/src/opendp/rust/src/traits/samplers/bernoulli/pseudocode/sample_bernoulli_float.py +43 -0
  211. opendp-0.9.2/src/opendp/rust/src/traits/samplers/bernoulli/pseudocode/sample_bernoulli_rational.py +5 -0
  212. opendp-0.9.2/src/opendp/rust/src/traits/samplers/bernoulli/sample_bernoulli_float.tex +110 -0
  213. opendp-0.9.2/src/opendp/rust/src/traits/samplers/bernoulli/sample_bernoulli_rational.tex +71 -0
  214. opendp-0.9.2/src/opendp/rust/src/traits/samplers/bernoulli/test.rs +20 -0
  215. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/mod.bib +35 -0
  216. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/mod.rs +200 -0
  217. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/sample_bernoulli_exp.tex +88 -0
  218. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/sample_bernoulli_exp1.tex +102 -0
  219. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/sample_discrete_gaussian.tex +126 -0
  220. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/sample_discrete_laplace.tex +128 -0
  221. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/sample_geometric_exp_fast.tex +147 -0
  222. opendp-0.9.2/src/opendp/rust/src/traits/samplers/cks20/sample_geometric_exp_slow.tex +76 -0
  223. opendp-0.9.2/src/opendp/rust/src/traits/samplers/discretize/mod.rs +153 -0
  224. opendp-0.9.2/src/opendp/rust/src/traits/samplers/discretize/test.rs +160 -0
  225. opendp-0.9.2/src/opendp/rust/src/traits/samplers/geometric/mod.rs +235 -0
  226. opendp-0.9.2/src/opendp/rust/src/traits/samplers/geometric/sample_geometric_buffer.tex +59 -0
  227. opendp-0.9.2/src/opendp/rust/src/traits/samplers/geometric/test.rs +43 -0
  228. opendp-0.9.2/src/opendp/rust/src/traits/samplers/mod.rs +113 -0
  229. opendp-0.9.2/src/opendp/rust/src/traits/samplers/psrn/mod.rs +148 -0
  230. opendp-0.9.2/src/opendp/rust/src/traits/samplers/psrn/test.rs +32 -0
  231. opendp-0.9.2/src/opendp/rust/src/traits/samplers/test.rs +60 -0
  232. opendp-0.9.2/src/opendp/rust/src/traits/samplers/uniform/SampleUniformIntBelow.tex +135 -0
  233. opendp-0.9.2/src/opendp/rust/src/traits/samplers/uniform/mod.rs +235 -0
  234. opendp-0.9.2/src/opendp/rust/src/traits/samplers/uniform/pseudocode/sample_uniform_int_below_native.py +19 -0
  235. opendp-0.9.2/src/opendp/rust/src/traits/samplers/uniform/pseudocode/sample_uniform_int_below_ubig.py +24 -0
  236. opendp-0.9.2/src/opendp/rust/src/traits/samplers/uniform/test.rs +57 -0
  237. opendp-0.9.2/src/opendp/rust/src/trans/manipulation/make_is_equal.tex +84 -0
  238. opendp-0.9.2/src/opendp/rust/src/transformations/b_ary_tree/consistency_postprocessor/ffi.rs +32 -0
  239. opendp-0.9.2/src/opendp/rust/src/transformations/b_ary_tree/consistency_postprocessor/mod.rs +126 -0
  240. opendp-0.9.2/src/opendp/rust/src/transformations/b_ary_tree/ffi.rs +74 -0
  241. opendp-0.9.2/src/opendp/rust/src/transformations/b_ary_tree/mod.rs +145 -0
  242. opendp-0.9.2/src/opendp/rust/src/transformations/b_ary_tree/test.rs +120 -0
  243. opendp-0.9.2/src/opendp/rust/src/transformations/cast/ffi.rs +177 -0
  244. opendp-0.9.2/src/opendp/rust/src/transformations/cast/mod.rs +126 -0
  245. opendp-0.9.2/src/opendp/rust/src/transformations/cast/test.rs +145 -0
  246. opendp-0.9.2/src/opendp/rust/src/transformations/cast_metric/ffi.rs +171 -0
  247. opendp-0.9.2/src/opendp/rust/src/transformations/cast_metric/mod.rs +169 -0
  248. opendp-0.9.2/src/opendp/rust/src/transformations/cast_metric/test.rs +29 -0
  249. opendp-0.9.2/src/opendp/rust/src/transformations/cast_metric/traits.rs +47 -0
  250. opendp-0.9.2/src/opendp/rust/src/transformations/clamp/ffi.rs +66 -0
  251. opendp-0.9.2/src/opendp/rust/src/transformations/clamp/make_clamp.tex +86 -0
  252. opendp-0.9.2/src/opendp/rust/src/transformations/clamp/mod.rs +57 -0
  253. opendp-0.9.2/src/opendp/rust/src/transformations/clamp/test.rs +17 -0
  254. opendp-0.9.2/src/opendp/rust/src/transformations/count/ffi.rs +195 -0
  255. opendp-0.9.2/src/opendp/rust/src/transformations/count/make_count.tex +145 -0
  256. opendp-0.9.2/src/opendp/rust/src/transformations/count/mod.rs +266 -0
  257. opendp-0.9.2/src/opendp/rust/src/transformations/count/test.rs +65 -0
  258. opendp-0.9.2/src/opendp/rust/src/transformations/count_cdf/ffi.rs +65 -0
  259. opendp-0.9.2/src/opendp/rust/src/transformations/count_cdf/mod.rs +236 -0
  260. opendp-0.9.2/src/opendp/rust/src/transformations/count_cdf/test.rs +71 -0
  261. opendp-0.9.2/src/opendp/rust/src/transformations/covariance/ffi.rs +68 -0
  262. opendp-0.9.2/src/opendp/rust/src/transformations/covariance/mod.rs +120 -0
  263. opendp-0.9.2/src/opendp/rust/src/transformations/covariance/test.rs +23 -0
  264. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/apply/ffi.rs +171 -0
  265. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/apply/mod.rs +155 -0
  266. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/apply/test.rs +57 -0
  267. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/create/ffi.rs +109 -0
  268. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/create/mod.rs +217 -0
  269. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/create/test.rs +77 -0
  270. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/mod.rs +58 -0
  271. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/select/ffi.rs +34 -0
  272. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/select/mod.rs +57 -0
  273. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/select/test.rs +22 -0
  274. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/subset/ffi.rs +78 -0
  275. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/subset/mod.rs +63 -0
  276. opendp-0.9.2/src/opendp/rust/src/transformations/dataframe/subset/test.rs +22 -0
  277. opendp-0.9.2/src/opendp/rust/src/transformations/impute/ffi.rs +206 -0
  278. opendp-0.9.2/src/opendp/rust/src/transformations/impute/mod.rs +239 -0
  279. opendp-0.9.2/src/opendp/rust/src/transformations/impute/test.rs +75 -0
  280. opendp-0.9.2/src/opendp/rust/src/transformations/index/ffi.rs +125 -0
  281. opendp-0.9.2/src/opendp/rust/src/transformations/index/mod.rs +155 -0
  282. opendp-0.9.2/src/opendp/rust/src/transformations/index/test.rs +45 -0
  283. opendp-0.9.2/src/opendp/rust/src/transformations/lipschitz_mul/ffi.rs +65 -0
  284. opendp-0.9.2/src/opendp/rust/src/transformations/lipschitz_mul/mod.rs +134 -0
  285. opendp-0.9.2/src/opendp/rust/src/transformations/lipschitz_mul/test.rs +10 -0
  286. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_alias/mod.rs +77 -0
  287. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_alias/test.rs +88 -0
  288. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_binary/mod.rs +83 -0
  289. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_binary/test.rs +287 -0
  290. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_boolean_function/mod.rs +109 -0
  291. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_boolean_function/test.rs +238 -0
  292. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_clip/mod.rs +117 -0
  293. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_clip/test.rs +35 -0
  294. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_col/mod.rs +51 -0
  295. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_col/test.rs +51 -0
  296. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_discrete_quantile_score/mod.rs +183 -0
  297. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_discrete_quantile_score/plugin_dq_score.rs +218 -0
  298. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_discrete_quantile_score/test.rs +90 -0
  299. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_fill_nan/mod.rs +144 -0
  300. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_fill_nan/test.rs +34 -0
  301. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_fill_null/mod.rs +108 -0
  302. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_fill_null/test.rs +31 -0
  303. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_len/mod.rs +93 -0
  304. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_len/test.rs +87 -0
  305. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_lit/mod.rs +69 -0
  306. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_lit/test.rs +33 -0
  307. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_sum/mod.rs +216 -0
  308. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/expr_sum/test.rs +132 -0
  309. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/ffi.rs +28 -0
  310. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/mod.rs +201 -0
  311. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_expr/test_helper.rs +50 -0
  312. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/ffi.rs +25 -0
  313. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/filter/mod.rs +72 -0
  314. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/filter/test.rs +59 -0
  315. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/h_stack/mod.rs +107 -0
  316. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/h_stack/test.rs +62 -0
  317. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/mod.rs +100 -0
  318. opendp-0.9.2/src/opendp/rust/src/transformations/make_stable_lazyframe/source/mod.rs +58 -0
  319. opendp-0.9.2/src/opendp/rust/src/transformations/make_user_transformation/mod.rs +55 -0
  320. opendp-0.9.2/src/opendp/rust/src/transformations/manipulation/ffi.rs +179 -0
  321. opendp-0.9.2/src/opendp/rust/src/transformations/manipulation/make_row_by_row.tex +72 -0
  322. opendp-0.9.2/src/opendp/rust/src/transformations/manipulation/make_row_by_row_fallible.tex +114 -0
  323. opendp-0.9.2/src/opendp/rust/src/transformations/manipulation/mod.rs +225 -0
  324. opendp-0.9.2/src/opendp/rust/src/transformations/manipulation/test.rs +51 -0
  325. opendp-0.9.2/src/opendp/rust/src/transformations/mean/ffi.rs +69 -0
  326. opendp-0.9.2/src/opendp/rust/src/transformations/mean/mod.rs +59 -0
  327. opendp-0.9.2/src/opendp/rust/src/transformations/mean/test.rs +18 -0
  328. opendp-0.9.2/src/opendp/rust/src/transformations/mod.rs +109 -0
  329. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/compute_score.tex +64 -0
  330. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/ffi.rs +50 -0
  331. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/make_quantile_score_candidates.tex +335 -0
  332. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/mod.rs +318 -0
  333. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/pseudocode/compute_score.py +27 -0
  334. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/pseudocode/make_quantile_score_candidates.py +44 -0
  335. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/references.bib +16 -0
  336. opendp-0.9.2/src/opendp/rust/src/transformations/quantile_score_candidates/test.rs +167 -0
  337. opendp-0.9.2/src/opendp/rust/src/transformations/resize/ffi.rs +101 -0
  338. opendp-0.9.2/src/opendp/rust/src/transformations/resize/mod.rs +106 -0
  339. opendp-0.9.2/src/opendp/rust/src/transformations/resize/test.rs +19 -0
  340. opendp-0.9.2/src/opendp/rust/src/transformations/sum/ffi.rs +75 -0
  341. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/checked/ffi.rs +120 -0
  342. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/checked/mod.rs +298 -0
  343. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/checked/test.rs +98 -0
  344. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/mod.rs +57 -0
  345. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/ordered/ffi.rs +121 -0
  346. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/ordered/mod.rs +185 -0
  347. opendp-0.9.2/src/opendp/rust/src/transformations/sum/float/ordered/test.rs +27 -0
  348. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/checked/ffi.rs +57 -0
  349. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/checked/mod.rs +72 -0
  350. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/checked/test.rs +12 -0
  351. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/mod.rs +38 -0
  352. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/monotonic/ffi.rs +89 -0
  353. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/monotonic/mod.rs +138 -0
  354. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/monotonic/test.rs +30 -0
  355. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/ordered/ffi.rs +88 -0
  356. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/ordered/mod.rs +100 -0
  357. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/ordered/test.rs +32 -0
  358. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/split/ffi.rs +88 -0
  359. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/split/mod.rs +136 -0
  360. opendp-0.9.2/src/opendp/rust/src/transformations/sum/int/split/test.rs +33 -0
  361. opendp-0.9.2/src/opendp/rust/src/transformations/sum/mod.rs +218 -0
  362. opendp-0.9.2/src/opendp/rust/src/transformations/sum/test.rs +41 -0
  363. opendp-0.9.2/src/opendp/rust/src/transformations/sum_of_squared_deviations/ffi.rs +56 -0
  364. opendp-0.9.2/src/opendp/rust/src/transformations/sum_of_squared_deviations/mod.rs +123 -0
  365. opendp-0.9.2/src/opendp/rust/src/transformations/sum_of_squared_deviations/test.rs +26 -0
  366. opendp-0.9.2/src/opendp/rust/src/transformations/variance/ffi.rs +60 -0
  367. opendp-0.9.2/src/opendp/rust/src/transformations/variance/mod.rs +82 -0
  368. opendp-0.9.2/src/opendp/rust/src/transformations/variance/test.rs +25 -0
  369. opendp-0.9.2/src/opendp/transformations.py +3520 -0
  370. opendp-0.9.2/src/opendp/typing.py +545 -0
  371. opendp-0.9.2/src/opendp.egg-info/PKG-INFO +101 -0
  372. opendp-0.9.2/src/opendp.egg-info/SOURCES.txt +395 -0
  373. opendp-0.9.2/src/opendp.egg-info/dependency_links.txt +1 -0
  374. opendp-0.9.2/src/opendp.egg-info/not-zip-safe +1 -0
  375. opendp-0.9.2/src/opendp.egg-info/requires.txt +16 -0
  376. opendp-0.9.2/src/opendp.egg-info/top_level.txt +1 -0
  377. opendp-0.9.2/test/test_accuracy.py +44 -0
  378. opendp-0.9.2/test/test_binary_search.py +69 -0
  379. opendp-0.9.2/test/test_comb.py +112 -0
  380. opendp-0.9.2/test/test_context_usability.py +90 -0
  381. opendp-0.9.2/test/test_convert.py +162 -0
  382. opendp-0.9.2/test/test_core.py +307 -0
  383. opendp-0.9.2/test/test_decorators.py +21 -0
  384. opendp-0.9.2/test/test_docs.py +22 -0
  385. opendp-0.9.2/test/test_interactive.py +102 -0
  386. opendp-0.9.2/test/test_meas.py +223 -0
  387. opendp-0.9.2/test/test_metric_cast.py +40 -0
  388. opendp-0.9.2/test/test_metrics.py +18 -0
  389. opendp-0.9.2/test/test_polars.py +379 -0
  390. opendp-0.9.2/test/test_space_of.py +49 -0
  391. opendp-0.9.2/test/test_subprocesses.py +16 -0
  392. opendp-0.9.2/test/test_tests.py +3 -0
  393. opendp-0.9.2/test/test_trans.py +393 -0
  394. opendp-0.9.2/test/test_typing.py +98 -0
  395. opendp-0.9.2/test/test_user_transform.py +136 -0
@@ -0,0 +1 @@
1
+ recursive-include src/opendp/rust *
opendp-0.9.2/PKG-INFO ADDED
@@ -0,0 +1,101 @@
1
+ Metadata-Version: 2.1
2
+ Name: opendp
3
+ Version: 0.9.2
4
+ Summary: Python bindings for the OpenDP Library
5
+ Home-page: https://opendp.org
6
+ Author: The OpenDP Project
7
+ Author-email: info@opendp.org
8
+ Project-URL: Source, https://github.com/opendp/opendp
9
+ Project-URL: Issues, https://github.com/opendp/opendp/issues
10
+ Project-URL: Documentation, https://docs.opendp.org/
11
+ Keywords: differential privacy
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: License :: OSI Approved :: MIT License
14
+ Classifier: Operating System :: OS Independent
15
+ Requires-Python: >=3.9
16
+ Description-Content-Type: text/markdown
17
+ License-File: ../LICENSE
18
+ Provides-Extra: numpy
19
+ Requires-Dist: numpy<2.0,>=1.17; extra == "numpy"
20
+ Requires-Dist: randomgen; extra == "numpy"
21
+ Provides-Extra: scikit-learn
22
+ Requires-Dist: scikit-learn; extra == "scikit-learn"
23
+ Requires-Dist: numpy<2.0,>=1.17; extra == "scikit-learn"
24
+ Requires-Dist: randomgen; extra == "scikit-learn"
25
+ Provides-Extra: polars
26
+ Requires-Dist: polars==0.20.16; extra == "polars"
27
+ Requires-Dist: pyarrow; extra == "polars"
28
+ Requires-Dist: scikit-learn; extra == "polars"
29
+ Requires-Dist: numpy<2.0,>=1.17; extra == "polars"
30
+ Requires-Dist: randomgen; extra == "polars"
31
+
32
+ # OpenDP
33
+ [![Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
34
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
35
+
36
+ [![Python](https://img.shields.io/badge/Python-3.9%20%E2%80%93%203.12-blue)](https://docs.opendp.org/en/nightly/api/python/index.html)
37
+ [![R](https://img.shields.io/badge/R-grey)](https://docs.opendp.org/en/stable/api/r/)
38
+ [![Rust](https://img.shields.io/badge/Rust-grey)](https://docs.rs/crate/opendp/latest)
39
+
40
+ [![main CI](https://github.com/opendp/opendp/actions/workflows/smoke-test.yml/badge.svg)](https://github.com/opendp/opendp/actions/workflows/smoke-test.yml?query=branch%3Amain)
41
+ [![nightly CI](https://github.com/opendp/opendp/actions/workflows/nightly.yml/badge.svg)](https://github.com/opendp/opendp/actions/workflows/nightly.yml?query=branch%3Amain)
42
+
43
+ The OpenDP Library is a modular collection of statistical algorithms that adhere to the definition of
44
+ [differential privacy](https://en.wikipedia.org/wiki/Differential_privacy).
45
+ It can be used to build applications of privacy-preserving computations, using a number of different models of privacy.
46
+ OpenDP is implemented in Rust, with bindings for easy use from Python and R.
47
+
48
+ The architecture of the OpenDP Library is based on a conceptual framework for expressing privacy-aware computations.
49
+ This framework is described in the paper [A Programming Framework for OpenDP](https://projects.iq.harvard.edu/files/opendp/files/opendp_programming_framework_11may2020_1_01.pdf).
50
+
51
+ The OpenDP Library is part of the larger [OpenDP Project](https://opendp.org), a community effort to build trustworthy,
52
+ open source software tools for analysis of private data.
53
+ (For simplicity in these docs, when we refer to “OpenDP,” we mean just the library, not the entire project.)
54
+
55
+ ## Status
56
+
57
+ OpenDP is under development, and we expect to [release new versions](https://github.com/opendp/opendp/releases) frequently,
58
+ incorporating feedback and code contributions from the OpenDP Community.
59
+ It's a work in progress, but it can already be used to build some applications and to prototype contributions that will expand its functionality.
60
+ We welcome you to try it and look forward to feedback on the library! However, please be aware of the following limitations:
61
+
62
+ > OpenDP, like all real-world software, has both known and unknown issues.
63
+ > If you intend to use OpenDP for a privacy-critical application, you should evaluate the impact of these issues on your use case.
64
+ >
65
+ > More details can be found in the [Limitations section of the User Guide](https://docs.opendp.org/en/stable/user/limitations.html).
66
+
67
+
68
+ ## Installation
69
+
70
+ Install OpenDP for Python with `pip` (the [package installer for Python](https://pypi.org/project/pip/)):
71
+
72
+ $ pip install opendp
73
+
74
+ Install OpenDP for R from an R session:
75
+
76
+ install.packages("opendp", repos = "https://opendp.r-universe.dev")
77
+
78
+ More information can be found in the [Getting Started section of the User Guide](https://docs.opendp.org/en/stable/user/getting-started.html).
79
+
80
+ ## Documentation
81
+
82
+ The full documentation for OpenDP is located at https://docs.opendp.org. Here are some helpful entry points:
83
+
84
+ * [User Guide](https://docs.opendp.org/en/stable/user/index.html)
85
+ * [Python API Docs](https://docs.opendp.org/en/stable/api/python/index.html)
86
+ * [Contributor Guide](https://docs.opendp.org/en/stable/contributor/index.html)
87
+
88
+ ## Getting Help
89
+
90
+ If you're having problems using OpenDP, or want to submit feedback, please reach out! Here are some ways to contact us:
91
+
92
+ * Ask questions on our [discussions forum](https://github.com/opendp/opendp/discussions)
93
+ * Open issues on our [issue tracker](https://github.com/opendp/opendp/issues)
94
+ * Join our [Slack](https://join.slack.com/t/opendp/shared_invite/zt-zw7o1k2s-dHg8NQE8WTfAGFnN_cwomA)
95
+ * Send general queries to [info@opendp.org](mailto:info@opendp.org)
96
+ * Reach us on Twitter at [@opendp_org](https://twitter.com/opendp_org)
97
+
98
+ ## Contributing
99
+
100
+ OpenDP is a community effort, and we welcome your contributions to its development!
101
+ If you'd like to participate, please contact us! We also have a [contribution process section in the Contributor Guide](https://docs.opendp.org/en/stable/contributor/contribution-process.html).
opendp-0.9.2/README.md ADDED
@@ -0,0 +1,70 @@
1
+ # OpenDP
2
+ [![Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
3
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
4
+
5
+ [![Python](https://img.shields.io/badge/Python-3.9%20%E2%80%93%203.12-blue)](https://docs.opendp.org/en/nightly/api/python/index.html)
6
+ [![R](https://img.shields.io/badge/R-grey)](https://docs.opendp.org/en/stable/api/r/)
7
+ [![Rust](https://img.shields.io/badge/Rust-grey)](https://docs.rs/crate/opendp/latest)
8
+
9
+ [![main CI](https://github.com/opendp/opendp/actions/workflows/smoke-test.yml/badge.svg)](https://github.com/opendp/opendp/actions/workflows/smoke-test.yml?query=branch%3Amain)
10
+ [![nightly CI](https://github.com/opendp/opendp/actions/workflows/nightly.yml/badge.svg)](https://github.com/opendp/opendp/actions/workflows/nightly.yml?query=branch%3Amain)
11
+
12
+ The OpenDP Library is a modular collection of statistical algorithms that adhere to the definition of
13
+ [differential privacy](https://en.wikipedia.org/wiki/Differential_privacy).
14
+ It can be used to build applications of privacy-preserving computations, using a number of different models of privacy.
15
+ OpenDP is implemented in Rust, with bindings for easy use from Python and R.
16
+
17
+ The architecture of the OpenDP Library is based on a conceptual framework for expressing privacy-aware computations.
18
+ This framework is described in the paper [A Programming Framework for OpenDP](https://projects.iq.harvard.edu/files/opendp/files/opendp_programming_framework_11may2020_1_01.pdf).
19
+
20
+ The OpenDP Library is part of the larger [OpenDP Project](https://opendp.org), a community effort to build trustworthy,
21
+ open source software tools for analysis of private data.
22
+ (For simplicity in these docs, when we refer to “OpenDP,” we mean just the library, not the entire project.)
23
+
24
+ ## Status
25
+
26
+ OpenDP is under development, and we expect to [release new versions](https://github.com/opendp/opendp/releases) frequently,
27
+ incorporating feedback and code contributions from the OpenDP Community.
28
+ It's a work in progress, but it can already be used to build some applications and to prototype contributions that will expand its functionality.
29
+ We welcome you to try it and look forward to feedback on the library! However, please be aware of the following limitations:
30
+
31
+ > OpenDP, like all real-world software, has both known and unknown issues.
32
+ > If you intend to use OpenDP for a privacy-critical application, you should evaluate the impact of these issues on your use case.
33
+ >
34
+ > More details can be found in the [Limitations section of the User Guide](https://docs.opendp.org/en/stable/user/limitations.html).
35
+
36
+
37
+ ## Installation
38
+
39
+ Install OpenDP for Python with `pip` (the [package installer for Python](https://pypi.org/project/pip/)):
40
+
41
+ $ pip install opendp
42
+
43
+ Install OpenDP for R from an R session:
44
+
45
+ install.packages("opendp", repos = "https://opendp.r-universe.dev")
46
+
47
+ More information can be found in the [Getting Started section of the User Guide](https://docs.opendp.org/en/stable/user/getting-started.html).
48
+
49
+ ## Documentation
50
+
51
+ The full documentation for OpenDP is located at https://docs.opendp.org. Here are some helpful entry points:
52
+
53
+ * [User Guide](https://docs.opendp.org/en/stable/user/index.html)
54
+ * [Python API Docs](https://docs.opendp.org/en/stable/api/python/index.html)
55
+ * [Contributor Guide](https://docs.opendp.org/en/stable/contributor/index.html)
56
+
57
+ ## Getting Help
58
+
59
+ If you're having problems using OpenDP, or want to submit feedback, please reach out! Here are some ways to contact us:
60
+
61
+ * Ask questions on our [discussions forum](https://github.com/opendp/opendp/discussions)
62
+ * Open issues on our [issue tracker](https://github.com/opendp/opendp/issues)
63
+ * Join our [Slack](https://join.slack.com/t/opendp/shared_invite/zt-zw7o1k2s-dHg8NQE8WTfAGFnN_cwomA)
64
+ * Send general queries to [info@opendp.org](mailto:info@opendp.org)
65
+ * Reach us on Twitter at [@opendp_org](https://twitter.com/opendp_org)
66
+
67
+ ## Contributing
68
+
69
+ OpenDP is a community effort, and we welcome your contributions to its development!
70
+ If you'd like to participate, please contact us! We also have a [contribution process section in the Contributor Guide](https://docs.opendp.org/en/stable/contributor/contribution-process.html).
@@ -0,0 +1,11 @@
1
+ [build-system]
2
+ requires = [
3
+ "setuptools>=42",
4
+ "wheel",
5
+ "setuptools-rust",
6
+ ]
7
+ build-backend = "setuptools.build_meta"
8
+
9
+ [tool.pyright]
10
+ include = ["src", "test", "../docs/source"]
11
+ reportWildcardImportFromLibrary = false
opendp-0.9.2/setup.cfg ADDED
@@ -0,0 +1,55 @@
1
+ [metadata]
2
+ name = opendp
3
+ version = 0.9.2
4
+ url = https://opendp.org
5
+ project_urls =
6
+ Source = https://github.com/opendp/opendp
7
+ Issues = https://github.com/opendp/opendp/issues
8
+ Documentation = https://docs.opendp.org/
9
+ author = The OpenDP Project
10
+ author_email = info@opendp.org
11
+ classifiers =
12
+ Programming Language :: Python :: 3
13
+ License :: OSI Approved :: MIT License
14
+ Operating System :: OS Independent
15
+ license_files = ../LICENSE
16
+ description = Python bindings for the OpenDP Library
17
+ long_description = file: README.md
18
+ long_description_content_type = text/markdown
19
+ keywords =
20
+ differential privacy
21
+
22
+ [options]
23
+ zip_safe = false
24
+ python_requires = >=3.9
25
+ packages = find:
26
+ package_dir =
27
+ = src
28
+
29
+ [options.packages.find]
30
+ where = src
31
+
32
+ [options.package_data]
33
+ opendp =
34
+ lib/*
35
+ py.typed
36
+
37
+ [options.extras_require]
38
+ numpy =
39
+ numpy>=1.17,<2.0
40
+ randomgen
41
+ scikit-learn =
42
+ scikit-learn
43
+ %(numpy)s
44
+ polars =
45
+ polars==0.20.16
46
+ pyarrow
47
+ %(scikit-learn)s
48
+
49
+ [bdist_wheel]
50
+ py-limited-api = cp39
51
+
52
+ [egg_info]
53
+ tag_build =
54
+ tag_date = 0
55
+
opendp-0.9.2/setup.py ADDED
@@ -0,0 +1,25 @@
1
+ from setuptools import setup # type: ignore
2
+ import os
3
+
4
+ if not os.path.isdir("src/opendp/lib") and os.path.isdir("src/opendp/rust"):
5
+ try:
6
+ from setuptools_rust import RustExtension, Binding # type: ignore[import]
7
+ except ImportError:
8
+ raise ImportError(
9
+ "A binary wheel is not available for your platform. Attempting to build from source instead, but setuptools-rust is not installed. Please run `pip install setuptools-rust` first."
10
+ )
11
+
12
+ setup(
13
+ rust_extensions=[
14
+ RustExtension(
15
+ # for reference, target=path/in/package/[BINARY_NAME]
16
+ target="opendp/lib/opendp",
17
+ path="src/opendp/rust/Cargo.toml",
18
+ args=["--color", "always"],
19
+ features=["untrusted", "ffi", "polars"],
20
+ binding=Binding.NoBinding,
21
+ )
22
+ ]
23
+ )
24
+ else:
25
+ setup()
@@ -0,0 +1 @@
1
+ from opendp.mod import Transformation, Measurement, OpenDPException, UnknownTypeException