dist-corr 0.1.1.dev1__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 (47) hide show
  1. dist_corr-0.1.1.dev1/.github/workflows/python-publish.yml +90 -0
  2. dist_corr-0.1.1.dev1/.github/workflows/rust.yml +47 -0
  3. dist_corr-0.1.1.dev1/.gitignore +21 -0
  4. dist_corr-0.1.1.dev1/Cargo.lock +992 -0
  5. dist_corr-0.1.1.dev1/Cargo.toml +49 -0
  6. dist_corr-0.1.1.dev1/LICENSE +27 -0
  7. dist_corr-0.1.1.dev1/PKG-INFO +110 -0
  8. dist_corr-0.1.1.dev1/README.md +318 -0
  9. dist_corr-0.1.1.dev1/benches/dist_corr_speed_binary_test.rs +215 -0
  10. dist_corr-0.1.1.dev1/benches/dist_corr_speed_comparison.py +127 -0
  11. dist_corr-0.1.1.dev1/benches/dist_corr_speed_comparison.rs +107 -0
  12. dist_corr-0.1.1.dev1/benches/dist_corr_speed_comparison_multicore.json +39319 -0
  13. dist_corr-0.1.1.dev1/benches/dist_corr_speed_comparison_results.md +110 -0
  14. dist_corr-0.1.1.dev1/benches/dist_corr_speed_comparison_singlecore.json +34210 -0
  15. dist_corr-0.1.1.dev1/benches/dist_corr_speed_default_test.rs +88 -0
  16. dist_corr-0.1.1.dev1/benches/dist_corr_speed_test.rs +145 -0
  17. dist_corr-0.1.1.dev1/benches/dist_corr_speed_timing.rs +183 -0
  18. dist_corr-0.1.1.dev1/benches/poetry.lock +462 -0
  19. dist_corr-0.1.1.dev1/benches/pyproject.toml +19 -0
  20. dist_corr-0.1.1.dev1/dist_corr/__init__.py +102 -0
  21. dist_corr-0.1.1.dev1/dist_corr/_rust.pyi +16 -0
  22. dist_corr-0.1.1.dev1/dist_corr/py.typed +0 -0
  23. dist_corr-0.1.1.dev1/dist_corr_notes_gebert_lee.pdf +0 -0
  24. dist_corr-0.1.1.dev1/pyproject.toml +35 -0
  25. dist_corr-0.1.1.dev1/python/Cargo.lock +305 -0
  26. dist_corr-0.1.1.dev1/python/Cargo.toml +17 -0
  27. dist_corr-0.1.1.dev1/python/README.md +98 -0
  28. dist_corr-0.1.1.dev1/python/RELEASE.md +43 -0
  29. dist_corr-0.1.1.dev1/python/artifacts-wheelonly/dist_corr-0.1.3-cp313-cp313-macosx_11_0_arm64.whl +0 -0
  30. dist_corr-0.1.1.dev1/python/artifacts-wheelonly2/dist_corr-0.1.4-cp313-cp313-macosx_11_0_arm64.whl +0 -0
  31. dist_corr-0.1.1.dev1/python/poetry.lock +1039 -0
  32. dist_corr-0.1.1.dev1/python/src/lib.rs +54 -0
  33. dist_corr-0.1.1.dev1/python/tests/test_api.py +55 -0
  34. dist_corr-0.1.1.dev1/src/api.rs +269 -0
  35. dist_corr-0.1.1.dev1/src/dist_corr.rs +140 -0
  36. dist_corr-0.1.1.dev1/src/dist_corr_binary.rs +120 -0
  37. dist_corr-0.1.1.dev1/src/dist_corr_multi.rs +164 -0
  38. dist_corr-0.1.1.dev1/src/dist_corr_naive.rs +91 -0
  39. dist_corr-0.1.1.dev1/src/frob_inner_product.rs +167 -0
  40. dist_corr-0.1.1.dev1/src/grand_mean.rs +135 -0
  41. dist_corr-0.1.1.dev1/src/lib.rs +136 -0
  42. dist_corr-0.1.1.dev1/src/ordering.rs +60 -0
  43. dist_corr-0.1.1.dev1/src/tests/mod.rs +8 -0
  44. dist_corr-0.1.1.dev1/src/tests/test.rs +174 -0
  45. dist_corr-0.1.1.dev1/src/tests/test_binary.rs +208 -0
  46. dist_corr-0.1.1.dev1/src/tests/test_determinism.rs +42 -0
  47. dist_corr-0.1.1.dev1/src/tests/test_multi.rs +173 -0
@@ -0,0 +1,90 @@
1
+ name: Python Publish
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - "v*"
7
+ workflow_dispatch:
8
+
9
+ jobs:
10
+ build-wheels:
11
+ name: Build wheels (${{ matrix.os }}, ${{ matrix.target }})
12
+ runs-on: ${{ matrix.os }}
13
+ strategy:
14
+ fail-fast: false
15
+ matrix:
16
+ include:
17
+ - os: ubuntu-latest
18
+ target: x86_64
19
+ - os: windows-latest
20
+ target: x64
21
+ - os: macos-13
22
+ target: x86_64
23
+ - os: macos-14
24
+ target: aarch64
25
+
26
+ steps:
27
+ - name: Checkout
28
+ uses: actions/checkout@v4
29
+
30
+ - name: Build wheels
31
+ uses: PyO3/maturin-action@v1
32
+ with:
33
+ target: ${{ matrix.target }}
34
+ manylinux: auto
35
+ args: --release --manifest-path python/Cargo.toml --out dist --find-interpreter
36
+
37
+ - name: Upload wheels
38
+ uses: actions/upload-artifact@v4
39
+ with:
40
+ name: wheels-${{ matrix.os }}-${{ matrix.target }}
41
+ path: dist
42
+
43
+ build-sdist:
44
+ name: Build sdist
45
+ runs-on: ubuntu-latest
46
+ steps:
47
+ - name: Checkout
48
+ uses: actions/checkout@v4
49
+
50
+ - name: Build sdist
51
+ uses: PyO3/maturin-action@v1
52
+ with:
53
+ command: sdist
54
+ args: --manifest-path python/Cargo.toml --out dist
55
+
56
+ - name: Upload sdist
57
+ uses: actions/upload-artifact@v4
58
+ with:
59
+ name: sdist
60
+ path: dist
61
+
62
+ publish:
63
+ name: Publish to PyPI
64
+ runs-on: ubuntu-latest
65
+ needs:
66
+ - build-wheels
67
+ - build-sdist
68
+ permissions:
69
+ id-token: write
70
+ environment:
71
+ name: pypi
72
+
73
+ steps:
74
+ - name: Download wheels
75
+ uses: actions/download-artifact@v4
76
+ with:
77
+ pattern: wheels-*
78
+ path: dist
79
+ merge-multiple: true
80
+
81
+ - name: Download sdist
82
+ uses: actions/download-artifact@v4
83
+ with:
84
+ name: sdist
85
+ path: dist
86
+
87
+ - name: Publish
88
+ uses: pypa/gh-action-pypi-publish@release/v1
89
+ with:
90
+ packages-dir: dist
@@ -0,0 +1,47 @@
1
+ name: Rust CI
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - '**'
7
+ pull_request:
8
+ branches:
9
+ - '**'
10
+
11
+ jobs:
12
+ build-and-test:
13
+ runs-on: ubuntu-latest
14
+
15
+ steps:
16
+ - uses: actions/checkout@v4
17
+
18
+ - name: Install Rust
19
+ uses: actions-rs/toolchain@v1
20
+ with:
21
+ toolchain: stable
22
+ profile: minimal
23
+ override: true
24
+
25
+ - name: Run cargo build
26
+ run: cargo build --verbose
27
+
28
+ - name: Run cargo test
29
+ run: cargo test --verbose
30
+
31
+ - name: Run cargo clippy
32
+ run: cargo clippy --all-targets --all-features -- -D warnings
33
+
34
+
35
+ - name: Set up Python
36
+ uses: actions/setup-python@v5
37
+ with:
38
+ python-version: '3.11'
39
+
40
+ - name: Install Python dependencies
41
+ run: |
42
+ python -m pip install --upgrade pip
43
+ pip install pytest numpy
44
+ pip install -e ./python
45
+
46
+ - name: Run Python tests
47
+ run: pytest python/tests/
@@ -0,0 +1,21 @@
1
+ /target
2
+ .vscode/*
3
+ /src/dist_corr_multi.rs
4
+
5
+ # Python binding build/runtime artifacts
6
+ /python/target/
7
+ /python/.venv/
8
+ /python/**/__pycache__/
9
+ /python/.pytest_cache/
10
+ /python/dist_corr/*.so
11
+ /python/dist_corr/*.pyd
12
+ /python/dist_corr/*.dll
13
+ /python/dist_corr/*.dylib
14
+ /python/dist_corr/*.dSYM/
15
+ /python/artifacts/
16
+
17
+ # benches artifacts
18
+ /benches/__pycache__/
19
+
20
+ # macOS/editor noise
21
+ .DS_Store