gputls 2.1.0__tar.gz → 2.2.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 (34) hide show
  1. {gputls-2.1.0/src/gputls.egg-info → gputls-2.2.2}/PKG-INFO +18 -16
  2. {gputls-2.1.0 → gputls-2.2.2}/README.md +14 -3
  3. {gputls-2.1.0 → gputls-2.2.2}/pyproject.toml +6 -1
  4. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/constants.py +2 -1
  5. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/core.py +296 -61
  6. gputls-2.2.2/src/gputls/kernels.cu +1574 -0
  7. gputls-2.2.2/src/gputls/screening.py +269 -0
  8. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/stats.py +37 -20
  9. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/version.py +1 -1
  10. gputls-2.2.2/src/gputls/workspace.py +57 -0
  11. {gputls-2.1.0 → gputls-2.2.2/src/gputls.egg-info}/PKG-INFO +18 -16
  12. {gputls-2.1.0 → gputls-2.2.2}/src/gputls.egg-info/SOURCES.txt +9 -1
  13. {gputls-2.1.0 → gputls-2.2.2}/src/gputls.egg-info/requires.txt +8 -4
  14. gputls-2.2.2/tests/test_bucket_sort.py +103 -0
  15. gputls-2.2.2/tests/test_candidate_screening.py +593 -0
  16. gputls-2.2.2/tests/test_patch_scan.py +39 -0
  17. gputls-2.2.2/tests/test_stats.py +76 -0
  18. gputls-2.2.2/tests/test_window_reuse.py +73 -0
  19. gputls-2.2.2/tests/test_workspace.py +135 -0
  20. gputls-2.1.0/src/gputls/kernels.cu +0 -369
  21. {gputls-2.1.0 → gputls-2.2.2}/LICENSE +0 -0
  22. {gputls-2.1.0 → gputls-2.2.2}/setup.cfg +0 -0
  23. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/__init__.py +0 -0
  24. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/grid.py +0 -0
  25. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/helpers.py +0 -0
  26. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/interpolation.py +0 -0
  27. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/main.py +0 -0
  28. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/results.py +0 -0
  29. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/transit.py +0 -0
  30. {gputls-2.1.0 → gputls-2.2.2}/src/gputls/validate.py +0 -0
  31. {gputls-2.1.0 → gputls-2.2.2}/src/gputls.egg-info/dependency_links.txt +0 -0
  32. {gputls-2.1.0 → gputls-2.2.2}/src/gputls.egg-info/top_level.txt +0 -0
  33. {gputls-2.1.0 → gputls-2.2.2}/tests/test_gtls.py +0 -0
  34. {gputls-2.1.0 → gputls-2.2.2}/tests/test_tls_compare.py +0 -0
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.4
1
+ Metadata-Version: 2.1
2
2
  Name: gputls
3
- Version: 2.1.0
3
+ Version: 2.2.2
4
4
  Summary: GPU-accelerated Transit Least Squares (TLS) for periodic transit detection
5
5
  Author-email: Quanquan Hu <huqq1917@outlook.com>
6
6
  Maintainer-email: Quanquan Hu <huqq1917@outlook.com>
@@ -39,20 +39,11 @@ Classifier: Programming Language :: Python :: 3
39
39
  Classifier: Programming Language :: Python :: 3 :: Only
40
40
  Requires-Python: >=3.8
41
41
  Description-Content-Type: text/markdown
42
- License-File: LICENSE
43
- Requires-Dist: numpy
44
- Requires-Dist: numba
45
- Requires-Dist: tqdm
46
- Requires-Dist: batman-package
47
42
  Provides-Extra: cuda11
48
- Requires-Dist: cupy-cuda11x; extra == "cuda11"
49
43
  Provides-Extra: cuda12
50
- Requires-Dist: cupy-cuda12x; extra == "cuda12"
44
+ Provides-Extra: cuda13
51
45
  Provides-Extra: test
52
- Requires-Dist: pytest; extra == "test"
53
- Requires-Dist: astropy; extra == "test"
54
- Requires-Dist: lightkurve; extra == "test"
55
- Dynamic: license-file
46
+ License-File: LICENSE
56
47
 
57
48
  # GTLS: GPU Transit Least Squares
58
49
 
@@ -93,10 +84,21 @@ pip install gputls
93
84
  Or let pip pick a CuPy build for you:
94
85
 
95
86
  ```bash
96
- pip install "gputls[cuda12]" # CUDA 12.x
97
- pip install "gputls[cuda11]" # CUDA 11.x
87
+ pip install "gputls[cuda13]" # CUDA 13.x, installs cupy-cuda13x[ctk]
88
+ pip install "gputls[cuda12]" # CUDA 12.x, installs cupy-cuda12x[ctk]
89
+ pip install "gputls[cuda11]" # CUDA 11.x, installs cupy-cuda11x (needs a local CUDA Toolkit)
98
90
  ```
99
91
 
92
+ GTLS compiles its CUDA kernels at runtime, so CuPy must be able to find the CUDA
93
+ headers, otherwise the search fails with `Failed to find CUDA headers`:
94
+
95
+ - CUDA 12 / 13: the `cuda12` / `cuda13` extras install the headers from pip through
96
+ CuPy's `[ctk]` extra. If you install CuPy yourself, use `pip install "cupy-cuda12x[ctk]"`
97
+ (or `cupy-cuda13x[ctk]`), or point `CUDA_PATH` to a local CUDA Toolkit.
98
+ - CUDA 11: `cupy-cuda11x` has no `[ctk]` extra (and stops at CuPy 13), so install the
99
+ [CUDA Toolkit](https://developer.nvidia.com/cuda-toolkit-archive) and set `CUDA_PATH`
100
+ if it is not in the default location (e.g. `export CUDA_PATH=/usr/local/cuda-11.8`).
101
+
100
102
  To install from source:
101
103
 
102
104
  ```bash
@@ -130,7 +132,7 @@ print(result.period, result.T0, result.duration, result.depth, result.SDE)
130
132
  | `duration_grid_step` | `1.1` | Multiplicative step of the duration grid |
131
133
  | `transit_depth_min` | `1e-5` | Minimum depth of a trial transit |
132
134
  | `transit_template` | `"default"` | `"default"`, `"grazing"` or `"box"` |
133
- | `T0_fit_margin` | `0.125` | Epoch step of the coarse search as a fraction of the duration (0 to 0.125; 0 tests every cadence) |
135
+ | `T0_fit_margin` | `0.01` | Epoch step of the coarse search as a fraction of the duration (0 to 0.125; 0 tests every cadence) |
134
136
  | `T0_refine_margin` | `0.01` | Epoch step when the strongest peaks are re-searched, as a fraction of the duration (0 to 0.125; 0 tests every cadence). 0.01 is the T0 resolution of TLS |
135
137
  | `GPUDeviceID` | `0` | CUDA device to run on |
136
138
  | `GPUDeviceIDs` | `None` | List of CUDA devices to split the search across (e.g. `[0, 1]`); overrides `GPUDeviceID`. Results are identical to a single-GPU run |
@@ -37,10 +37,21 @@ pip install gputls
37
37
  Or let pip pick a CuPy build for you:
38
38
 
39
39
  ```bash
40
- pip install "gputls[cuda12]" # CUDA 12.x
41
- pip install "gputls[cuda11]" # CUDA 11.x
40
+ pip install "gputls[cuda13]" # CUDA 13.x, installs cupy-cuda13x[ctk]
41
+ pip install "gputls[cuda12]" # CUDA 12.x, installs cupy-cuda12x[ctk]
42
+ pip install "gputls[cuda11]" # CUDA 11.x, installs cupy-cuda11x (needs a local CUDA Toolkit)
42
43
  ```
43
44
 
45
+ GTLS compiles its CUDA kernels at runtime, so CuPy must be able to find the CUDA
46
+ headers, otherwise the search fails with `Failed to find CUDA headers`:
47
+
48
+ - CUDA 12 / 13: the `cuda12` / `cuda13` extras install the headers from pip through
49
+ CuPy's `[ctk]` extra. If you install CuPy yourself, use `pip install "cupy-cuda12x[ctk]"`
50
+ (or `cupy-cuda13x[ctk]`), or point `CUDA_PATH` to a local CUDA Toolkit.
51
+ - CUDA 11: `cupy-cuda11x` has no `[ctk]` extra (and stops at CuPy 13), so install the
52
+ [CUDA Toolkit](https://developer.nvidia.com/cuda-toolkit-archive) and set `CUDA_PATH`
53
+ if it is not in the default location (e.g. `export CUDA_PATH=/usr/local/cuda-11.8`).
54
+
44
55
  To install from source:
45
56
 
46
57
  ```bash
@@ -74,7 +85,7 @@ print(result.period, result.T0, result.duration, result.depth, result.SDE)
74
85
  | `duration_grid_step` | `1.1` | Multiplicative step of the duration grid |
75
86
  | `transit_depth_min` | `1e-5` | Minimum depth of a trial transit |
76
87
  | `transit_template` | `"default"` | `"default"`, `"grazing"` or `"box"` |
77
- | `T0_fit_margin` | `0.125` | Epoch step of the coarse search as a fraction of the duration (0 to 0.125; 0 tests every cadence) |
88
+ | `T0_fit_margin` | `0.01` | Epoch step of the coarse search as a fraction of the duration (0 to 0.125; 0 tests every cadence) |
78
89
  | `T0_refine_margin` | `0.01` | Epoch step when the strongest peaks are re-searched, as a fraction of the duration (0 to 0.125; 0 tests every cadence). 0.01 is the T0 resolution of TLS |
79
90
  | `GPUDeviceID` | `0` | CUDA device to run on |
80
91
  | `GPUDeviceIDs` | `None` | List of CUDA devices to split the search across (e.g. `[0, 1]`); overrides `GPUDeviceID`. Results are identical to a single-GPU run |
@@ -32,11 +32,16 @@ dependencies = [
32
32
  "numba",
33
33
  "tqdm",
34
34
  "batman-package",
35
+ # batman imports distutils, which Python 3.12 removed; setuptools provides it
36
+ "setuptools",
35
37
  ]
36
38
 
37
39
  [project.optional-dependencies]
40
+ # The kernels are compiled at runtime and need the CUDA headers: [ctk] installs them from
41
+ # pip. cupy-cuda11x has no [ctk] extra, so CUDA 11 needs a local CUDA Toolkit.
38
42
  cuda11 = ["cupy-cuda11x"]
39
- cuda12 = ["cupy-cuda12x"]
43
+ cuda12 = ["cupy-cuda12x[ctk]"]
44
+ cuda13 = ["cupy-cuda13x[ctk]"]
40
45
  test = ["pytest", "astropy", "lightkurve"]
41
46
 
42
47
  [project.urls]
@@ -88,7 +88,8 @@ SDE_MEDIAN_KERNEL_SIZE = 30
88
88
 
89
89
  # Step between trial transit start points in the coarse period search, as a fraction
90
90
  # of the transit duration (clipped to [0, 0.125]); 0 tests every cadence (slowest).
91
- T0_FIT_MARGIN = 0.125
91
+ # Both search stages default to a 1% duration step.
92
+ T0_FIT_MARGIN = 0.01
92
93
 
93
94
  # Step between trial transit start points when the best candidate periods are re-searched,
94
95
  # as a fraction of the transit duration (clipped to [0, 0.125]); 0 tests every cadence.