vegas 6.4.1__cp313-cp313-macosx_11_0_arm64.whl
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.
- vegas/__init__.pxd +14 -0
- vegas/__init__.py +1592 -0
- vegas/_vegas.c +117028 -0
- vegas/_vegas.cpython-313-darwin.so +0 -0
- vegas/_vegas.pxd +80 -0
- vegas/_vegas.pyx +3473 -0
- vegas-6.4.1.dist-info/METADATA +56 -0
- vegas-6.4.1.dist-info/RECORD +11 -0
- vegas-6.4.1.dist-info/WHEEL +6 -0
- vegas-6.4.1.dist-info/licenses/LICENSE.txt +546 -0
- vegas-6.4.1.dist-info/top_level.txt +1 -0
|
Binary file
|
vegas/_vegas.pxd
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# cython: language_level=3
|
|
2
|
+
# Created by G. Peter Lepage (Cornell University) in 12/2013.
|
|
3
|
+
# Copyright (c) 2013-25 G. Peter Lepage.
|
|
4
|
+
#
|
|
5
|
+
# This program is free software: you can redistribute it and/or modify
|
|
6
|
+
# it under the terms of the GNU General Public License as published by
|
|
7
|
+
# the Free Software Foundation, either version 3 of the License, or
|
|
8
|
+
# any later version (see <http://www.gnu.org/licenses/>).
|
|
9
|
+
#
|
|
10
|
+
# This program is distributed in the hope that it will be useful,
|
|
11
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
12
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
13
|
+
# GNU General Public License for more details.
|
|
14
|
+
|
|
15
|
+
cdef class LBatchIntegrand:
|
|
16
|
+
cdef public object fcn
|
|
17
|
+
|
|
18
|
+
cdef class RBatchIntegrand:
|
|
19
|
+
cdef public object fcn
|
|
20
|
+
|
|
21
|
+
cdef class AdaptiveMap:
|
|
22
|
+
# first index is direction, second is increment
|
|
23
|
+
cdef readonly double[:, ::1] grid
|
|
24
|
+
cdef readonly double[:, ::1] inc
|
|
25
|
+
cdef readonly Py_ssize_t[::1] ninc
|
|
26
|
+
cdef public double[:, ::1] sum_f
|
|
27
|
+
cdef public double[:, ::1] n_f
|
|
28
|
+
|
|
29
|
+
cpdef map(self, double[:, ::1] y, double[:, ::1] x, double[::1] J, Py_ssize_t ny=*)
|
|
30
|
+
cpdef invmap(self, double[:, ::1] x, double[:, ::1] y, double[::1] J, Py_ssize_t nx=*)
|
|
31
|
+
cpdef add_training_data(self, double[:, ::1] y, double[::1] f, Py_ssize_t ny=*)
|
|
32
|
+
|
|
33
|
+
cdef class Integrator:
|
|
34
|
+
# inputs
|
|
35
|
+
cdef public Py_ssize_t neval
|
|
36
|
+
cdef public Py_ssize_t[::1] neval_hcube_range
|
|
37
|
+
cdef public Py_ssize_t min_neval_batch
|
|
38
|
+
cdef public Py_ssize_t maxinc_axis
|
|
39
|
+
cdef public Py_ssize_t max_neval_hcube
|
|
40
|
+
cdef public bint gpu_pad
|
|
41
|
+
cdef public double neval_frac
|
|
42
|
+
cdef public double max_mem
|
|
43
|
+
cdef public Py_ssize_t nitn
|
|
44
|
+
cdef public Py_ssize_t nproc
|
|
45
|
+
cdef public double alpha
|
|
46
|
+
cdef public double rtol
|
|
47
|
+
cdef public double atol
|
|
48
|
+
cdef public bint minimize_mem
|
|
49
|
+
cdef public bint adapt_to_errors
|
|
50
|
+
cdef public double beta
|
|
51
|
+
cdef public bint adapt
|
|
52
|
+
cdef public bint correlate_integrals
|
|
53
|
+
cdef public object analyzer
|
|
54
|
+
cdef public object ran_array_generator
|
|
55
|
+
cdef public bint sync_ran
|
|
56
|
+
cdef public bint mpi
|
|
57
|
+
cdef public bint uniform_nstrat
|
|
58
|
+
cdef public bint uses_jac
|
|
59
|
+
cdef public str save
|
|
60
|
+
cdef public str saveall
|
|
61
|
+
cdef readonly Py_ssize_t[::1] nstrat
|
|
62
|
+
cdef readonly object xsample
|
|
63
|
+
# generated
|
|
64
|
+
cdef readonly AdaptiveMap map
|
|
65
|
+
cdef readonly object pool
|
|
66
|
+
cdef readonly double sum_sigf
|
|
67
|
+
cdef readonly Py_ssize_t dim
|
|
68
|
+
cdef readonly Py_ssize_t last_neval
|
|
69
|
+
cdef readonly Py_ssize_t min_neval_hcube
|
|
70
|
+
cdef readonly Py_ssize_t nhcube
|
|
71
|
+
# internal work areas
|
|
72
|
+
cdef double[:, ::1] y
|
|
73
|
+
cdef double[:, ::1] x
|
|
74
|
+
cdef double[::1] jac
|
|
75
|
+
cdef double[::1] fdv2
|
|
76
|
+
cdef Py_ssize_t[::1] neval_hcube
|
|
77
|
+
# the following depend upon whether minimize_mem is False or True
|
|
78
|
+
cdef readonly object sigf # numpy array or h5py Dataset
|
|
79
|
+
cdef readonly object sigf_h5 # None or h5py file
|
|
80
|
+
|