site-calculation 2026.7.1__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.
- site_calculation-2026.7.1/.github/workflows/deptry.yml +15 -0
- site_calculation-2026.7.1/.github/workflows/numpydoc.yml +26 -0
- site_calculation-2026.7.1/.github/workflows/publish-PyPI.yml +104 -0
- site_calculation-2026.7.1/.github/workflows/pytest.yml +42 -0
- site_calculation-2026.7.1/.github/workflows/ruff.yml +8 -0
- site_calculation-2026.7.1/.github/workflows/types.yml +22 -0
- site_calculation-2026.7.1/.gitignore +32 -0
- site_calculation-2026.7.1/.python-version +1 -0
- site_calculation-2026.7.1/Cargo.lock +361 -0
- site_calculation-2026.7.1/Cargo.toml +32 -0
- site_calculation-2026.7.1/MANIFEST.in +0 -0
- site_calculation-2026.7.1/PKG-INFO +81 -0
- site_calculation-2026.7.1/README.md +65 -0
- site_calculation-2026.7.1/build.rs +194 -0
- site_calculation-2026.7.1/data/ba18_coefficients.csv +302 -0
- site_calculation-2026.7.1/data/cb14_coefficients.csv +23 -0
- site_calculation-2026.7.1/pyproject.toml +118 -0
- site_calculation-2026.7.1/setup.cfg +4 -0
- site_calculation-2026.7.1/site_calculation/__init__.py +0 -0
- site_calculation-2026.7.1/site_calculation/_utils.pyi +19 -0
- site_calculation-2026.7.1/site_calculation/amplification.py +382 -0
- site_calculation-2026.7.1/site_calculation.egg-info/PKG-INFO +81 -0
- site_calculation-2026.7.1/site_calculation.egg-info/SOURCES.txt +35 -0
- site_calculation-2026.7.1/site_calculation.egg-info/dependency_links.txt +1 -0
- site_calculation-2026.7.1/site_calculation.egg-info/requires.txt +10 -0
- site_calculation-2026.7.1/site_calculation.egg-info/scm_file_list.json +32 -0
- site_calculation-2026.7.1/site_calculation.egg-info/scm_version.json +8 -0
- site_calculation-2026.7.1/site_calculation.egg-info/top_level.txt +1 -0
- site_calculation-2026.7.1/src-rust/bayless_abrahamson_2018.rs +328 -0
- site_calculation-2026.7.1/src-rust/campbell_bozorgnia_2014.rs +171 -0
- site_calculation-2026.7.1/src-rust/lib.rs +93 -0
- site_calculation-2026.7.1/src-rust/site.rs +6 -0
- site_calculation-2026.7.1/src-rust/tests.rs +38 -0
- site_calculation-2026.7.1/tests/resources/cb14_site_factors_data.csv +23 -0
- site_calculation-2026.7.1/tests/resources/site_factors_data.csv +21 -0
- site_calculation-2026.7.1/tests/test_amplification.py +294 -0
- site_calculation-2026.7.1/uv.lock +856 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
name: Deptry Dependency Check
|
|
2
|
+
|
|
3
|
+
on: [pull_request]
|
|
4
|
+
|
|
5
|
+
jobs:
|
|
6
|
+
dependencies:
|
|
7
|
+
runs-on: ubuntu-latest
|
|
8
|
+
steps:
|
|
9
|
+
- uses: actions/checkout@v4
|
|
10
|
+
- uses: actions/setup-python@v5
|
|
11
|
+
|
|
12
|
+
- name: Setup uv
|
|
13
|
+
uses: astral-sh/setup-uv@v5
|
|
14
|
+
|
|
15
|
+
- run: uv run --group dev deptry .
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: Numpydoc Lint
|
|
2
|
+
|
|
3
|
+
on: [pull_request]
|
|
4
|
+
|
|
5
|
+
jobs:
|
|
6
|
+
numpydoc-lint:
|
|
7
|
+
runs-on: ubuntu-latest
|
|
8
|
+
|
|
9
|
+
steps:
|
|
10
|
+
- name: Checkout repository
|
|
11
|
+
uses: actions/checkout@v4
|
|
12
|
+
|
|
13
|
+
- uses: awalsh128/cache-apt-pkgs-action@latest
|
|
14
|
+
with:
|
|
15
|
+
packages: fd-find
|
|
16
|
+
version: 1.0
|
|
17
|
+
|
|
18
|
+
- name: Set up Python
|
|
19
|
+
uses: actions/setup-python@v4
|
|
20
|
+
|
|
21
|
+
- name: Install dependencies
|
|
22
|
+
run: |
|
|
23
|
+
pip install numpydoc
|
|
24
|
+
- name: Run Numpydoc Lint
|
|
25
|
+
run: |
|
|
26
|
+
fdfind . site_calculation/ -E "__init__.py" --extension py | xargs numpydoc lint
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
run-name: Publish Python Package to PyPI for release ${{ github.event.release.tag_name || inputs.tag_name || github.ref_name }}
|
|
3
|
+
|
|
4
|
+
on:
|
|
5
|
+
release:
|
|
6
|
+
types: [published]
|
|
7
|
+
workflow_dispatch:
|
|
8
|
+
inputs:
|
|
9
|
+
tag_name:
|
|
10
|
+
description: "Git tag to checkout and publish"
|
|
11
|
+
required: false
|
|
12
|
+
type: string
|
|
13
|
+
|
|
14
|
+
jobs:
|
|
15
|
+
build:
|
|
16
|
+
name: Build distribution 📦
|
|
17
|
+
runs-on: ${{ matrix.os }}
|
|
18
|
+
strategy:
|
|
19
|
+
matrix:
|
|
20
|
+
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
21
|
+
|
|
22
|
+
steps:
|
|
23
|
+
- name: Checkout code
|
|
24
|
+
uses: actions/checkout@v4.1.0
|
|
25
|
+
with:
|
|
26
|
+
ref: ${{ inputs.tag_name || github.ref }}
|
|
27
|
+
fetch-depth: 0
|
|
28
|
+
|
|
29
|
+
- name: Set up Python
|
|
30
|
+
uses: actions/setup-python@v5
|
|
31
|
+
with:
|
|
32
|
+
python-version: "3.12"
|
|
33
|
+
|
|
34
|
+
- name: Install Rust
|
|
35
|
+
uses: actions-rust-lang/setup-rust-toolchain@v1
|
|
36
|
+
|
|
37
|
+
- name: Install Rust targets for macOS
|
|
38
|
+
if: matrix.os == 'macos-latest'
|
|
39
|
+
run: |
|
|
40
|
+
rustup target add x86_64-apple-darwin
|
|
41
|
+
rustup target add aarch64-apple-darwin
|
|
42
|
+
|
|
43
|
+
- name: Build wheels
|
|
44
|
+
uses: pypa/cibuildwheel@v4.1.0
|
|
45
|
+
env:
|
|
46
|
+
CIBW_SKIP: "pp* *-musllinux_*" # Skip PyPy and musl builds
|
|
47
|
+
CIBW_ARCHS_MACOS: "x86_64 arm64" # Build for Intel and Apple Silicon
|
|
48
|
+
CIBW_ARCHS_WINDOWS: "AMD64"
|
|
49
|
+
CIBW_ARCHS_LINUX: "x86_64"
|
|
50
|
+
# This is needed as for linux the wheel build process happens inside a container instead of the Github runner
|
|
51
|
+
# See https://cibuildwheel.pypa.io/en/stable/platforms/#linux-containers
|
|
52
|
+
CIBW_BEFORE_ALL_LINUX: "curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y && source $HOME/.cargo/env"
|
|
53
|
+
CIBW_ENVIRONMENT_LINUX: 'PATH="$HOME/.cargo/bin:$PATH"'
|
|
54
|
+
# Required to build wheels with Rust extensions on macOS
|
|
55
|
+
# See https://cibuildwheel.pypa.io/en/stable/platforms/#macos-version-compatibility
|
|
56
|
+
MACOSX_DEPLOYMENT_TARGET: "11.0"
|
|
57
|
+
|
|
58
|
+
- name: Build source distribution (Linux only)
|
|
59
|
+
if: matrix.os == 'ubuntu-latest'
|
|
60
|
+
run: |
|
|
61
|
+
python3 -m pip install build
|
|
62
|
+
python3 -m build --sdist
|
|
63
|
+
|
|
64
|
+
- name: Store the distribution packages
|
|
65
|
+
uses: actions/upload-artifact@v4
|
|
66
|
+
with:
|
|
67
|
+
name: python-package-distributions-${{ matrix.os }}
|
|
68
|
+
path: |
|
|
69
|
+
wheelhouse/*.whl
|
|
70
|
+
dist/*.tar.gz
|
|
71
|
+
if-no-files-found: error
|
|
72
|
+
|
|
73
|
+
publish-to-pypi:
|
|
74
|
+
name: Publish to PyPI
|
|
75
|
+
needs:
|
|
76
|
+
- build
|
|
77
|
+
runs-on: ubuntu-latest
|
|
78
|
+
|
|
79
|
+
environment:
|
|
80
|
+
name: pypi
|
|
81
|
+
url: https://pypi.org/p/site-calculation
|
|
82
|
+
|
|
83
|
+
permissions:
|
|
84
|
+
id-token: write
|
|
85
|
+
|
|
86
|
+
steps:
|
|
87
|
+
- name: Download all the dists
|
|
88
|
+
uses: actions/download-artifact@v4
|
|
89
|
+
with:
|
|
90
|
+
pattern: python-package-distributions-*
|
|
91
|
+
merge-multiple: true
|
|
92
|
+
path: artifacts/
|
|
93
|
+
|
|
94
|
+
- name: Collect all distributions into dist/
|
|
95
|
+
run: |
|
|
96
|
+
mkdir -p dist/
|
|
97
|
+
find artifacts/ -name '*.whl' -exec cp {} dist/ \;
|
|
98
|
+
find artifacts/ -name '*.tar.gz' -exec cp {} dist/ \;
|
|
99
|
+
ls -la dist/
|
|
100
|
+
|
|
101
|
+
- name: Publish distribution to PyPI
|
|
102
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
103
|
+
with:
|
|
104
|
+
packages-dir: dist
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
name: Pytest Check
|
|
2
|
+
|
|
3
|
+
on: [pull_request]
|
|
4
|
+
|
|
5
|
+
jobs:
|
|
6
|
+
test:
|
|
7
|
+
runs-on: ubuntu-latest
|
|
8
|
+
|
|
9
|
+
steps:
|
|
10
|
+
- name: Checkout code
|
|
11
|
+
uses: actions/checkout@v4
|
|
12
|
+
|
|
13
|
+
- name: Set up Python
|
|
14
|
+
uses: actions/setup-python@v5
|
|
15
|
+
|
|
16
|
+
- name: Define a cache dependency glob
|
|
17
|
+
uses: astral-sh/setup-uv@v5
|
|
18
|
+
with:
|
|
19
|
+
enable-cache: true
|
|
20
|
+
|
|
21
|
+
- name: Run tests
|
|
22
|
+
run: |
|
|
23
|
+
uv run --extra test pytest --cov=site_calculation --cov-report=html tests
|
|
24
|
+
|
|
25
|
+
- name: Combine coverage and fail it it’s under 100 %
|
|
26
|
+
run: |
|
|
27
|
+
uv run --extra test python -m coverage html --skip-covered --skip-empty
|
|
28
|
+
|
|
29
|
+
# Report and write to summary.
|
|
30
|
+
uv run --extra test python -m coverage report | sed 's/^/ /' >> $GITHUB_STEP_SUMMARY
|
|
31
|
+
|
|
32
|
+
# Report again and fail if under 95%.
|
|
33
|
+
uv run --extra test python -Im coverage report --fail-under=95
|
|
34
|
+
|
|
35
|
+
- name: Upload HTML report if check failed
|
|
36
|
+
uses: actions/upload-artifact@v4
|
|
37
|
+
|
|
38
|
+
with:
|
|
39
|
+
name: html-report
|
|
40
|
+
path: htmlcov
|
|
41
|
+
|
|
42
|
+
if: ${{ failure() }}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
name: Type Check
|
|
2
|
+
|
|
3
|
+
on: [pull_request]
|
|
4
|
+
|
|
5
|
+
jobs:
|
|
6
|
+
typecheck:
|
|
7
|
+
runs-on: ubuntu-latest
|
|
8
|
+
|
|
9
|
+
steps:
|
|
10
|
+
- name: Checkout code
|
|
11
|
+
uses: actions/checkout@v4
|
|
12
|
+
|
|
13
|
+
- name: Setup Python
|
|
14
|
+
uses: actions/setup-python@v5
|
|
15
|
+
|
|
16
|
+
- name: Install uv
|
|
17
|
+
uses: astral-sh/setup-uv@v5
|
|
18
|
+
with:
|
|
19
|
+
enable-cache: true
|
|
20
|
+
|
|
21
|
+
- name: Run type checking with ty
|
|
22
|
+
run: uv run --extra test --extra types --group dev ty check
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Python-generated files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[oc]
|
|
4
|
+
build/
|
|
5
|
+
dist/
|
|
6
|
+
wheels/
|
|
7
|
+
*.egg-info
|
|
8
|
+
|
|
9
|
+
# Virtual environments
|
|
10
|
+
.venv
|
|
11
|
+
|
|
12
|
+
# Created by https://www.toptal.com/developers/gitignore/api/rust
|
|
13
|
+
# Edit at https://www.toptal.com/developers/gitignore?templates=rust
|
|
14
|
+
|
|
15
|
+
### Rust ###
|
|
16
|
+
# Generated by Cargo
|
|
17
|
+
# will have compiled files and executables
|
|
18
|
+
debug/
|
|
19
|
+
target/
|
|
20
|
+
|
|
21
|
+
# These are backup files generated by rustfmt
|
|
22
|
+
**/*.rs.bk
|
|
23
|
+
|
|
24
|
+
# MSVC Windows builds of rustc generate these, which store debugging information
|
|
25
|
+
*.pdb
|
|
26
|
+
|
|
27
|
+
# End of https://www.toptal.com/developers/gitignore/api/rust
|
|
28
|
+
|
|
29
|
+
# Often generated by cdylib type crates
|
|
30
|
+
*/rust_out
|
|
31
|
+
rust_out
|
|
32
|
+
/site_calculation/_utils.*.so
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.14
|
|
@@ -0,0 +1,361 @@
|
|
|
1
|
+
# This file is automatically @generated by Cargo.
|
|
2
|
+
# It is not intended for manual editing.
|
|
3
|
+
version = 4
|
|
4
|
+
|
|
5
|
+
[[package]]
|
|
6
|
+
name = "approx"
|
|
7
|
+
version = "0.5.1"
|
|
8
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
9
|
+
checksum = "cab112f0a86d568ea0e627cc1d6be74a1e9cd55214684db5561995f6dad897c6"
|
|
10
|
+
dependencies = [
|
|
11
|
+
"num-traits",
|
|
12
|
+
]
|
|
13
|
+
|
|
14
|
+
[[package]]
|
|
15
|
+
name = "autocfg"
|
|
16
|
+
version = "1.5.1"
|
|
17
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
18
|
+
checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53"
|
|
19
|
+
|
|
20
|
+
[[package]]
|
|
21
|
+
name = "csv"
|
|
22
|
+
version = "1.4.0"
|
|
23
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
24
|
+
checksum = "52cd9d68cf7efc6ddfaaee42e7288d3a99d613d4b50f76ce9827ae0c6e14f938"
|
|
25
|
+
dependencies = [
|
|
26
|
+
"csv-core",
|
|
27
|
+
"itoa",
|
|
28
|
+
"ryu",
|
|
29
|
+
"serde_core",
|
|
30
|
+
]
|
|
31
|
+
|
|
32
|
+
[[package]]
|
|
33
|
+
name = "csv-core"
|
|
34
|
+
version = "0.1.13"
|
|
35
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
36
|
+
checksum = "704a3c26996a80471189265814dbc2c257598b96b8a7feae2d31ace646bb9782"
|
|
37
|
+
dependencies = [
|
|
38
|
+
"memchr",
|
|
39
|
+
]
|
|
40
|
+
|
|
41
|
+
[[package]]
|
|
42
|
+
name = "either"
|
|
43
|
+
version = "1.16.0"
|
|
44
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
45
|
+
checksum = "91622ff5e7162018101f2fea40d6ebf4a78bbe5a49736a2020649edf9693679e"
|
|
46
|
+
|
|
47
|
+
[[package]]
|
|
48
|
+
name = "heck"
|
|
49
|
+
version = "0.5.0"
|
|
50
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
51
|
+
checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"
|
|
52
|
+
|
|
53
|
+
[[package]]
|
|
54
|
+
name = "indoc"
|
|
55
|
+
version = "2.0.7"
|
|
56
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
57
|
+
checksum = "79cf5c93f93228cf8efb3ba362535fb11199ac548a09ce117c9b1adc3030d706"
|
|
58
|
+
dependencies = [
|
|
59
|
+
"rustversion",
|
|
60
|
+
]
|
|
61
|
+
|
|
62
|
+
[[package]]
|
|
63
|
+
name = "itertools"
|
|
64
|
+
version = "0.14.0"
|
|
65
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
66
|
+
checksum = "2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285"
|
|
67
|
+
dependencies = [
|
|
68
|
+
"either",
|
|
69
|
+
]
|
|
70
|
+
|
|
71
|
+
[[package]]
|
|
72
|
+
name = "itoa"
|
|
73
|
+
version = "1.0.18"
|
|
74
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
75
|
+
checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"
|
|
76
|
+
|
|
77
|
+
[[package]]
|
|
78
|
+
name = "libc"
|
|
79
|
+
version = "0.2.186"
|
|
80
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
81
|
+
checksum = "68ab91017fe16c622486840e4c83c9a37afeff978bd239b5293d61ece587de66"
|
|
82
|
+
|
|
83
|
+
[[package]]
|
|
84
|
+
name = "matrixmultiply"
|
|
85
|
+
version = "0.3.10"
|
|
86
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
87
|
+
checksum = "a06de3016e9fae57a36fd14dba131fccf49f74b40b7fbdb472f96e361ec71a08"
|
|
88
|
+
dependencies = [
|
|
89
|
+
"autocfg",
|
|
90
|
+
"rawpointer",
|
|
91
|
+
]
|
|
92
|
+
|
|
93
|
+
[[package]]
|
|
94
|
+
name = "memchr"
|
|
95
|
+
version = "2.8.3"
|
|
96
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
97
|
+
checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98"
|
|
98
|
+
|
|
99
|
+
[[package]]
|
|
100
|
+
name = "memoffset"
|
|
101
|
+
version = "0.9.1"
|
|
102
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
103
|
+
checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a"
|
|
104
|
+
dependencies = [
|
|
105
|
+
"autocfg",
|
|
106
|
+
]
|
|
107
|
+
|
|
108
|
+
[[package]]
|
|
109
|
+
name = "ndarray"
|
|
110
|
+
version = "0.17.2"
|
|
111
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
112
|
+
checksum = "520080814a7a6b4a6e9070823bb24b4531daac8c4627e08ba5de8c5ef2f2752d"
|
|
113
|
+
dependencies = [
|
|
114
|
+
"approx",
|
|
115
|
+
"matrixmultiply",
|
|
116
|
+
"num-complex",
|
|
117
|
+
"num-integer",
|
|
118
|
+
"num-traits",
|
|
119
|
+
"portable-atomic",
|
|
120
|
+
"portable-atomic-util",
|
|
121
|
+
"rawpointer",
|
|
122
|
+
]
|
|
123
|
+
|
|
124
|
+
[[package]]
|
|
125
|
+
name = "num-complex"
|
|
126
|
+
version = "0.4.6"
|
|
127
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
128
|
+
checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495"
|
|
129
|
+
dependencies = [
|
|
130
|
+
"num-traits",
|
|
131
|
+
]
|
|
132
|
+
|
|
133
|
+
[[package]]
|
|
134
|
+
name = "num-integer"
|
|
135
|
+
version = "0.1.46"
|
|
136
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
137
|
+
checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f"
|
|
138
|
+
dependencies = [
|
|
139
|
+
"num-traits",
|
|
140
|
+
]
|
|
141
|
+
|
|
142
|
+
[[package]]
|
|
143
|
+
name = "num-traits"
|
|
144
|
+
version = "0.2.19"
|
|
145
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
146
|
+
checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841"
|
|
147
|
+
dependencies = [
|
|
148
|
+
"autocfg",
|
|
149
|
+
]
|
|
150
|
+
|
|
151
|
+
[[package]]
|
|
152
|
+
name = "numpy"
|
|
153
|
+
version = "0.27.1"
|
|
154
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
155
|
+
checksum = "7aac2e6a6e4468ffa092ad43c39b81c79196c2bb773b8db4085f695efe3bba17"
|
|
156
|
+
dependencies = [
|
|
157
|
+
"libc",
|
|
158
|
+
"ndarray",
|
|
159
|
+
"num-complex",
|
|
160
|
+
"num-integer",
|
|
161
|
+
"num-traits",
|
|
162
|
+
"pyo3",
|
|
163
|
+
"pyo3-build-config",
|
|
164
|
+
"rustc-hash",
|
|
165
|
+
]
|
|
166
|
+
|
|
167
|
+
[[package]]
|
|
168
|
+
name = "once_cell"
|
|
169
|
+
version = "1.21.4"
|
|
170
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
171
|
+
checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"
|
|
172
|
+
|
|
173
|
+
[[package]]
|
|
174
|
+
name = "portable-atomic"
|
|
175
|
+
version = "1.13.1"
|
|
176
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
177
|
+
checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49"
|
|
178
|
+
|
|
179
|
+
[[package]]
|
|
180
|
+
name = "portable-atomic-util"
|
|
181
|
+
version = "0.2.7"
|
|
182
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
183
|
+
checksum = "c2a106d1259c23fac8e543272398ae0e3c0b8d33c88ed73d0cc71b0f1d902618"
|
|
184
|
+
dependencies = [
|
|
185
|
+
"portable-atomic",
|
|
186
|
+
]
|
|
187
|
+
|
|
188
|
+
[[package]]
|
|
189
|
+
name = "proc-macro2"
|
|
190
|
+
version = "1.0.106"
|
|
191
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
192
|
+
checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934"
|
|
193
|
+
dependencies = [
|
|
194
|
+
"unicode-ident",
|
|
195
|
+
]
|
|
196
|
+
|
|
197
|
+
[[package]]
|
|
198
|
+
name = "pyo3"
|
|
199
|
+
version = "0.27.2"
|
|
200
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
201
|
+
checksum = "ab53c047fcd1a1d2a8820fe84f05d6be69e9526be40cb03b73f86b6b03e6d87d"
|
|
202
|
+
dependencies = [
|
|
203
|
+
"indoc",
|
|
204
|
+
"libc",
|
|
205
|
+
"memoffset",
|
|
206
|
+
"once_cell",
|
|
207
|
+
"portable-atomic",
|
|
208
|
+
"pyo3-build-config",
|
|
209
|
+
"pyo3-ffi",
|
|
210
|
+
"pyo3-macros",
|
|
211
|
+
"unindent",
|
|
212
|
+
]
|
|
213
|
+
|
|
214
|
+
[[package]]
|
|
215
|
+
name = "pyo3-build-config"
|
|
216
|
+
version = "0.27.2"
|
|
217
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
218
|
+
checksum = "b455933107de8642b4487ed26d912c2d899dec6114884214a0b3bb3be9261ea6"
|
|
219
|
+
dependencies = [
|
|
220
|
+
"target-lexicon",
|
|
221
|
+
]
|
|
222
|
+
|
|
223
|
+
[[package]]
|
|
224
|
+
name = "pyo3-ffi"
|
|
225
|
+
version = "0.27.2"
|
|
226
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
227
|
+
checksum = "1c85c9cbfaddf651b1221594209aed57e9e5cff63c4d11d1feead529b872a089"
|
|
228
|
+
dependencies = [
|
|
229
|
+
"libc",
|
|
230
|
+
"pyo3-build-config",
|
|
231
|
+
]
|
|
232
|
+
|
|
233
|
+
[[package]]
|
|
234
|
+
name = "pyo3-macros"
|
|
235
|
+
version = "0.27.2"
|
|
236
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
237
|
+
checksum = "0a5b10c9bf9888125d917fb4d2ca2d25c8df94c7ab5a52e13313a07e050a3b02"
|
|
238
|
+
dependencies = [
|
|
239
|
+
"proc-macro2",
|
|
240
|
+
"pyo3-macros-backend",
|
|
241
|
+
"quote",
|
|
242
|
+
"syn",
|
|
243
|
+
]
|
|
244
|
+
|
|
245
|
+
[[package]]
|
|
246
|
+
name = "pyo3-macros-backend"
|
|
247
|
+
version = "0.27.2"
|
|
248
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
249
|
+
checksum = "03b51720d314836e53327f5871d4c0cfb4fb37cc2c4a11cc71907a86342c40f9"
|
|
250
|
+
dependencies = [
|
|
251
|
+
"heck",
|
|
252
|
+
"proc-macro2",
|
|
253
|
+
"pyo3-build-config",
|
|
254
|
+
"quote",
|
|
255
|
+
"syn",
|
|
256
|
+
]
|
|
257
|
+
|
|
258
|
+
[[package]]
|
|
259
|
+
name = "quote"
|
|
260
|
+
version = "1.0.46"
|
|
261
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
262
|
+
checksum = "dfbc457d0c7a0759a614551b11a6409e5951f6c7537be1f1b7682b9ae9230368"
|
|
263
|
+
dependencies = [
|
|
264
|
+
"proc-macro2",
|
|
265
|
+
]
|
|
266
|
+
|
|
267
|
+
[[package]]
|
|
268
|
+
name = "rawpointer"
|
|
269
|
+
version = "0.2.1"
|
|
270
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
271
|
+
checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3"
|
|
272
|
+
|
|
273
|
+
[[package]]
|
|
274
|
+
name = "rustc-hash"
|
|
275
|
+
version = "2.1.3"
|
|
276
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
277
|
+
checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d"
|
|
278
|
+
|
|
279
|
+
[[package]]
|
|
280
|
+
name = "rustversion"
|
|
281
|
+
version = "1.0.23"
|
|
282
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
283
|
+
checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f"
|
|
284
|
+
|
|
285
|
+
[[package]]
|
|
286
|
+
name = "ryu"
|
|
287
|
+
version = "1.0.23"
|
|
288
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
289
|
+
checksum = "9774ba4a74de5f7b1c1451ed6cd5285a32eddb5cccb8cc655a4e50009e06477f"
|
|
290
|
+
|
|
291
|
+
[[package]]
|
|
292
|
+
name = "serde"
|
|
293
|
+
version = "1.0.228"
|
|
294
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
295
|
+
checksum = "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e"
|
|
296
|
+
dependencies = [
|
|
297
|
+
"serde_core",
|
|
298
|
+
"serde_derive",
|
|
299
|
+
]
|
|
300
|
+
|
|
301
|
+
[[package]]
|
|
302
|
+
name = "serde_core"
|
|
303
|
+
version = "1.0.228"
|
|
304
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
305
|
+
checksum = "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad"
|
|
306
|
+
dependencies = [
|
|
307
|
+
"serde_derive",
|
|
308
|
+
]
|
|
309
|
+
|
|
310
|
+
[[package]]
|
|
311
|
+
name = "serde_derive"
|
|
312
|
+
version = "1.0.228"
|
|
313
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
314
|
+
checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79"
|
|
315
|
+
dependencies = [
|
|
316
|
+
"proc-macro2",
|
|
317
|
+
"quote",
|
|
318
|
+
"syn",
|
|
319
|
+
]
|
|
320
|
+
|
|
321
|
+
[[package]]
|
|
322
|
+
name = "syn"
|
|
323
|
+
version = "2.0.118"
|
|
324
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
325
|
+
checksum = "1b9ae57f904213ebb649ce6895b8a66c66f0203b9319718f69a5612a065b1422"
|
|
326
|
+
dependencies = [
|
|
327
|
+
"proc-macro2",
|
|
328
|
+
"quote",
|
|
329
|
+
"unicode-ident",
|
|
330
|
+
]
|
|
331
|
+
|
|
332
|
+
[[package]]
|
|
333
|
+
name = "target-lexicon"
|
|
334
|
+
version = "0.13.5"
|
|
335
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
336
|
+
checksum = "adb6935a6f5c20170eeceb1a3835a49e12e19d792f6dd344ccc76a985ca5a6ca"
|
|
337
|
+
|
|
338
|
+
[[package]]
|
|
339
|
+
name = "unicode-ident"
|
|
340
|
+
version = "1.0.24"
|
|
341
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
342
|
+
checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"
|
|
343
|
+
|
|
344
|
+
[[package]]
|
|
345
|
+
name = "unindent"
|
|
346
|
+
version = "0.2.4"
|
|
347
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
348
|
+
checksum = "7264e107f553ccae879d21fbea1d6724ac785e8c3bfc762137959b5802826ef3"
|
|
349
|
+
|
|
350
|
+
[[package]]
|
|
351
|
+
name = "utils"
|
|
352
|
+
version = "0.1.0"
|
|
353
|
+
dependencies = [
|
|
354
|
+
"approx",
|
|
355
|
+
"csv",
|
|
356
|
+
"itertools",
|
|
357
|
+
"ndarray",
|
|
358
|
+
"numpy",
|
|
359
|
+
"pyo3",
|
|
360
|
+
"serde",
|
|
361
|
+
]
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
[package]
|
|
2
|
+
name = "utils"
|
|
3
|
+
version = "0.1.0"
|
|
4
|
+
edition = "2024"
|
|
5
|
+
resolver = "2"
|
|
6
|
+
|
|
7
|
+
[lib]
|
|
8
|
+
name = "_utils"
|
|
9
|
+
crate-type = ["cdylib", "lib"]
|
|
10
|
+
path = "src-rust/lib.rs"
|
|
11
|
+
|
|
12
|
+
[dependencies]
|
|
13
|
+
itertools = "0.14.0"
|
|
14
|
+
ndarray = { version = "0.17.1" }
|
|
15
|
+
numpy = "0.27"
|
|
16
|
+
pyo3 = "0.27"
|
|
17
|
+
|
|
18
|
+
[dev-dependencies]
|
|
19
|
+
ndarray = { version = "0.17.1", features = ["approx"] }
|
|
20
|
+
approx = "0.5.1"
|
|
21
|
+
csv = "1.4.0"
|
|
22
|
+
serde = { version = "1.0.228", features = ["serde_derive"] }
|
|
23
|
+
# criterion = { version = "0.8.1", features = ["html_reports"] }
|
|
24
|
+
|
|
25
|
+
[build-dependencies]
|
|
26
|
+
csv = "1.4.0"
|
|
27
|
+
serde = { version = "1.0.228", features = ["serde_derive"] }
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
# [[bench]]
|
|
31
|
+
# name = "benchmark"
|
|
32
|
+
# harness = false
|
|
File without changes
|