multipers 2.3.1__cp313-cp313-manylinux_2_34_x86_64.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.

Potentially problematic release.


This version of multipers might be problematic. Click here for more details.

Files changed (179) hide show
  1. multipers/__init__.py +33 -0
  2. multipers/_signed_measure_meta.py +430 -0
  3. multipers/_slicer_meta.py +211 -0
  4. multipers/data/MOL2.py +458 -0
  5. multipers/data/UCR.py +18 -0
  6. multipers/data/__init__.py +1 -0
  7. multipers/data/graphs.py +466 -0
  8. multipers/data/immuno_regions.py +27 -0
  9. multipers/data/minimal_presentation_to_st_bf.py +0 -0
  10. multipers/data/pytorch2simplextree.py +91 -0
  11. multipers/data/shape3d.py +101 -0
  12. multipers/data/synthetic.py +113 -0
  13. multipers/distances.py +198 -0
  14. multipers/filtration_conversions.pxd +229 -0
  15. multipers/filtration_conversions.pxd.tp +84 -0
  16. multipers/filtrations/__init__.py +18 -0
  17. multipers/filtrations/density.py +563 -0
  18. multipers/filtrations/filtrations.py +289 -0
  19. multipers/filtrations.pxd +224 -0
  20. multipers/function_rips.cpython-313-x86_64-linux-gnu.so +0 -0
  21. multipers/function_rips.pyx +105 -0
  22. multipers/grids.cpython-313-x86_64-linux-gnu.so +0 -0
  23. multipers/grids.pyx +350 -0
  24. multipers/gudhi/Persistence_slices_interface.h +132 -0
  25. multipers/gudhi/Simplex_tree_interface.h +239 -0
  26. multipers/gudhi/Simplex_tree_multi_interface.h +516 -0
  27. multipers/gudhi/cubical_to_boundary.h +59 -0
  28. multipers/gudhi/gudhi/Bitmap_cubical_complex.h +450 -0
  29. multipers/gudhi/gudhi/Bitmap_cubical_complex_base.h +1070 -0
  30. multipers/gudhi/gudhi/Bitmap_cubical_complex_periodic_boundary_conditions_base.h +579 -0
  31. multipers/gudhi/gudhi/Debug_utils.h +45 -0
  32. multipers/gudhi/gudhi/Fields/Multi_field.h +484 -0
  33. multipers/gudhi/gudhi/Fields/Multi_field_operators.h +455 -0
  34. multipers/gudhi/gudhi/Fields/Multi_field_shared.h +450 -0
  35. multipers/gudhi/gudhi/Fields/Multi_field_small.h +531 -0
  36. multipers/gudhi/gudhi/Fields/Multi_field_small_operators.h +507 -0
  37. multipers/gudhi/gudhi/Fields/Multi_field_small_shared.h +531 -0
  38. multipers/gudhi/gudhi/Fields/Z2_field.h +355 -0
  39. multipers/gudhi/gudhi/Fields/Z2_field_operators.h +376 -0
  40. multipers/gudhi/gudhi/Fields/Zp_field.h +420 -0
  41. multipers/gudhi/gudhi/Fields/Zp_field_operators.h +400 -0
  42. multipers/gudhi/gudhi/Fields/Zp_field_shared.h +418 -0
  43. multipers/gudhi/gudhi/Flag_complex_edge_collapser.h +337 -0
  44. multipers/gudhi/gudhi/Matrix.h +2107 -0
  45. multipers/gudhi/gudhi/Multi_critical_filtration.h +1038 -0
  46. multipers/gudhi/gudhi/Multi_persistence/Box.h +171 -0
  47. multipers/gudhi/gudhi/Multi_persistence/Line.h +282 -0
  48. multipers/gudhi/gudhi/Off_reader.h +173 -0
  49. multipers/gudhi/gudhi/One_critical_filtration.h +1433 -0
  50. multipers/gudhi/gudhi/Persistence_matrix/Base_matrix.h +769 -0
  51. multipers/gudhi/gudhi/Persistence_matrix/Base_matrix_with_column_compression.h +686 -0
  52. multipers/gudhi/gudhi/Persistence_matrix/Boundary_matrix.h +842 -0
  53. multipers/gudhi/gudhi/Persistence_matrix/Chain_matrix.h +1350 -0
  54. multipers/gudhi/gudhi/Persistence_matrix/Id_to_index_overlay.h +1105 -0
  55. multipers/gudhi/gudhi/Persistence_matrix/Position_to_index_overlay.h +859 -0
  56. multipers/gudhi/gudhi/Persistence_matrix/RU_matrix.h +910 -0
  57. multipers/gudhi/gudhi/Persistence_matrix/allocators/entry_constructors.h +139 -0
  58. multipers/gudhi/gudhi/Persistence_matrix/base_pairing.h +230 -0
  59. multipers/gudhi/gudhi/Persistence_matrix/base_swap.h +211 -0
  60. multipers/gudhi/gudhi/Persistence_matrix/boundary_cell_position_to_id_mapper.h +60 -0
  61. multipers/gudhi/gudhi/Persistence_matrix/boundary_face_position_to_id_mapper.h +60 -0
  62. multipers/gudhi/gudhi/Persistence_matrix/chain_pairing.h +136 -0
  63. multipers/gudhi/gudhi/Persistence_matrix/chain_rep_cycles.h +190 -0
  64. multipers/gudhi/gudhi/Persistence_matrix/chain_vine_swap.h +616 -0
  65. multipers/gudhi/gudhi/Persistence_matrix/columns/chain_column_extra_properties.h +150 -0
  66. multipers/gudhi/gudhi/Persistence_matrix/columns/column_dimension_holder.h +106 -0
  67. multipers/gudhi/gudhi/Persistence_matrix/columns/column_utilities.h +219 -0
  68. multipers/gudhi/gudhi/Persistence_matrix/columns/entry_types.h +327 -0
  69. multipers/gudhi/gudhi/Persistence_matrix/columns/heap_column.h +1140 -0
  70. multipers/gudhi/gudhi/Persistence_matrix/columns/intrusive_list_column.h +934 -0
  71. multipers/gudhi/gudhi/Persistence_matrix/columns/intrusive_set_column.h +934 -0
  72. multipers/gudhi/gudhi/Persistence_matrix/columns/list_column.h +980 -0
  73. multipers/gudhi/gudhi/Persistence_matrix/columns/naive_vector_column.h +1092 -0
  74. multipers/gudhi/gudhi/Persistence_matrix/columns/row_access.h +192 -0
  75. multipers/gudhi/gudhi/Persistence_matrix/columns/set_column.h +921 -0
  76. multipers/gudhi/gudhi/Persistence_matrix/columns/small_vector_column.h +1093 -0
  77. multipers/gudhi/gudhi/Persistence_matrix/columns/unordered_set_column.h +1012 -0
  78. multipers/gudhi/gudhi/Persistence_matrix/columns/vector_column.h +1244 -0
  79. multipers/gudhi/gudhi/Persistence_matrix/matrix_dimension_holders.h +186 -0
  80. multipers/gudhi/gudhi/Persistence_matrix/matrix_row_access.h +164 -0
  81. multipers/gudhi/gudhi/Persistence_matrix/ru_pairing.h +156 -0
  82. multipers/gudhi/gudhi/Persistence_matrix/ru_rep_cycles.h +376 -0
  83. multipers/gudhi/gudhi/Persistence_matrix/ru_vine_swap.h +540 -0
  84. multipers/gudhi/gudhi/Persistent_cohomology/Field_Zp.h +118 -0
  85. multipers/gudhi/gudhi/Persistent_cohomology/Multi_field.h +173 -0
  86. multipers/gudhi/gudhi/Persistent_cohomology/Persistent_cohomology_column.h +128 -0
  87. multipers/gudhi/gudhi/Persistent_cohomology.h +745 -0
  88. multipers/gudhi/gudhi/Points_off_io.h +171 -0
  89. multipers/gudhi/gudhi/Simple_object_pool.h +69 -0
  90. multipers/gudhi/gudhi/Simplex_tree/Simplex_tree_iterators.h +463 -0
  91. multipers/gudhi/gudhi/Simplex_tree/Simplex_tree_node_explicit_storage.h +83 -0
  92. multipers/gudhi/gudhi/Simplex_tree/Simplex_tree_siblings.h +106 -0
  93. multipers/gudhi/gudhi/Simplex_tree/Simplex_tree_star_simplex_iterators.h +277 -0
  94. multipers/gudhi/gudhi/Simplex_tree/hooks_simplex_base.h +62 -0
  95. multipers/gudhi/gudhi/Simplex_tree/indexing_tag.h +27 -0
  96. multipers/gudhi/gudhi/Simplex_tree/serialization_utils.h +62 -0
  97. multipers/gudhi/gudhi/Simplex_tree/simplex_tree_options.h +157 -0
  98. multipers/gudhi/gudhi/Simplex_tree.h +2794 -0
  99. multipers/gudhi/gudhi/Simplex_tree_multi.h +152 -0
  100. multipers/gudhi/gudhi/distance_functions.h +62 -0
  101. multipers/gudhi/gudhi/graph_simplicial_complex.h +104 -0
  102. multipers/gudhi/gudhi/persistence_interval.h +253 -0
  103. multipers/gudhi/gudhi/persistence_matrix_options.h +170 -0
  104. multipers/gudhi/gudhi/reader_utils.h +367 -0
  105. multipers/gudhi/mma_interface_coh.h +256 -0
  106. multipers/gudhi/mma_interface_h0.h +223 -0
  107. multipers/gudhi/mma_interface_matrix.h +291 -0
  108. multipers/gudhi/naive_merge_tree.h +536 -0
  109. multipers/gudhi/scc_io.h +310 -0
  110. multipers/gudhi/truc.h +957 -0
  111. multipers/io.cpython-313-x86_64-linux-gnu.so +0 -0
  112. multipers/io.pyx +714 -0
  113. multipers/ml/__init__.py +0 -0
  114. multipers/ml/accuracies.py +90 -0
  115. multipers/ml/invariants_with_persistable.py +79 -0
  116. multipers/ml/kernels.py +176 -0
  117. multipers/ml/mma.py +713 -0
  118. multipers/ml/one.py +472 -0
  119. multipers/ml/point_clouds.py +352 -0
  120. multipers/ml/signed_measures.py +1589 -0
  121. multipers/ml/sliced_wasserstein.py +461 -0
  122. multipers/ml/tools.py +113 -0
  123. multipers/mma_structures.cpython-313-x86_64-linux-gnu.so +0 -0
  124. multipers/mma_structures.pxd +127 -0
  125. multipers/mma_structures.pyx +2742 -0
  126. multipers/mma_structures.pyx.tp +1083 -0
  127. multipers/multi_parameter_rank_invariant/diff_helpers.h +84 -0
  128. multipers/multi_parameter_rank_invariant/euler_characteristic.h +97 -0
  129. multipers/multi_parameter_rank_invariant/function_rips.h +322 -0
  130. multipers/multi_parameter_rank_invariant/hilbert_function.h +769 -0
  131. multipers/multi_parameter_rank_invariant/persistence_slices.h +148 -0
  132. multipers/multi_parameter_rank_invariant/rank_invariant.h +369 -0
  133. multipers/multiparameter_edge_collapse.py +41 -0
  134. multipers/multiparameter_module_approximation/approximation.h +2298 -0
  135. multipers/multiparameter_module_approximation/combinatory.h +129 -0
  136. multipers/multiparameter_module_approximation/debug.h +107 -0
  137. multipers/multiparameter_module_approximation/euler_curves.h +0 -0
  138. multipers/multiparameter_module_approximation/format_python-cpp.h +286 -0
  139. multipers/multiparameter_module_approximation/heap_column.h +238 -0
  140. multipers/multiparameter_module_approximation/images.h +79 -0
  141. multipers/multiparameter_module_approximation/list_column.h +174 -0
  142. multipers/multiparameter_module_approximation/list_column_2.h +232 -0
  143. multipers/multiparameter_module_approximation/ru_matrix.h +347 -0
  144. multipers/multiparameter_module_approximation/set_column.h +135 -0
  145. multipers/multiparameter_module_approximation/structure_higher_dim_barcode.h +36 -0
  146. multipers/multiparameter_module_approximation/unordered_set_column.h +166 -0
  147. multipers/multiparameter_module_approximation/utilities.h +403 -0
  148. multipers/multiparameter_module_approximation/vector_column.h +223 -0
  149. multipers/multiparameter_module_approximation/vector_matrix.h +331 -0
  150. multipers/multiparameter_module_approximation/vineyards.h +464 -0
  151. multipers/multiparameter_module_approximation/vineyards_trajectories.h +649 -0
  152. multipers/multiparameter_module_approximation.cpython-313-x86_64-linux-gnu.so +0 -0
  153. multipers/multiparameter_module_approximation.pyx +218 -0
  154. multipers/pickle.py +90 -0
  155. multipers/plots.py +342 -0
  156. multipers/point_measure.cpython-313-x86_64-linux-gnu.so +0 -0
  157. multipers/point_measure.pyx +322 -0
  158. multipers/simplex_tree_multi.cpython-313-x86_64-linux-gnu.so +0 -0
  159. multipers/simplex_tree_multi.pxd +133 -0
  160. multipers/simplex_tree_multi.pyx +10402 -0
  161. multipers/simplex_tree_multi.pyx.tp +1947 -0
  162. multipers/slicer.cpython-313-x86_64-linux-gnu.so +0 -0
  163. multipers/slicer.pxd +2552 -0
  164. multipers/slicer.pxd.tp +218 -0
  165. multipers/slicer.pyx +16530 -0
  166. multipers/slicer.pyx.tp +931 -0
  167. multipers/tensor/tensor.h +672 -0
  168. multipers/tensor.pxd +13 -0
  169. multipers/test.pyx +44 -0
  170. multipers/tests/__init__.py +57 -0
  171. multipers/torch/__init__.py +1 -0
  172. multipers/torch/diff_grids.py +217 -0
  173. multipers/torch/rips_density.py +310 -0
  174. multipers-2.3.1.dist-info/LICENSE +21 -0
  175. multipers-2.3.1.dist-info/METADATA +144 -0
  176. multipers-2.3.1.dist-info/RECORD +179 -0
  177. multipers-2.3.1.dist-info/WHEEL +5 -0
  178. multipers-2.3.1.dist-info/top_level.txt +1 -0
  179. multipers.libs/libtbb-f2c6754f.so.12.14 +0 -0
multipers/slicer.pxd ADDED
@@ -0,0 +1,2552 @@
1
+
2
+ cimport numpy as cnp
3
+
4
+ # SequentialDataset and its two concrete subclasses are (optionally randomized)
5
+ # iterators over the rows of a matrix X and corresponding target values y.
6
+
7
+ from libcpp.utility cimport pair
8
+ from libcpp cimport bool, int, float
9
+ from libcpp.vector cimport vector
10
+
11
+
12
+ from libc.stdint cimport intptr_t, uint16_t, uint32_t, int32_t, uint64_t, int64_t
13
+ from cython cimport uint
14
+
15
+ import numpy as np
16
+ python_value_type=np.float32
17
+ from libcpp.string cimport string
18
+
19
+ cdef extern from "Simplex_tree_multi_interface.h" namespace "Gudhi::multiparameter::python_interface":
20
+ cdef cppclass Simplex_tree_multi_interface[F=*, value_type=*]:
21
+ pass
22
+
23
+ from multipers.filtrations cimport *
24
+ ctypedef vector[uint] cycle_type ## its the cycle type of matrix
25
+
26
+
27
+ #------------------------------------------------------------------------------
28
+ cdef extern from "Persistence_slices_interface.h":
29
+ cdef cppclass C_KSlicer_Matrix0_vine_i32 "TrucPythonInterface<BackendsEnum::Matrix,true,true,int32_t,Available_columns::INTRUSIVE_SET>":
30
+ ctypedef int32_t value_type
31
+
32
+ C_KSlicer_Matrix0_vine_i32()
33
+
34
+ C_KSlicer_Matrix0_vine_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int32_t]]&)
35
+
36
+ C_KSlicer_Matrix0_vine_i32& operator=(const C_KSlicer_Matrix0_vine_i32&)
37
+
38
+ C_KSlicer_Matrix0_vine_i32 colexical_rearange() except + nogil
39
+
40
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
41
+ void push_to(const Line[int32_t]&) nogil
42
+ void set_one_filtration(const vector[int32_t]&) nogil
43
+ int prune_above_dimension(int) except + nogil
44
+
45
+ vector[int32_t] get_one_filtration()
46
+ # void compute_persistence(vector[bool]) except+ nogil
47
+ void compute_persistence(bool) except+ nogil # ignore_inf
48
+ void compute_persistence() except+ nogil # ignore_inf
49
+ uint32_t num_generators() nogil
50
+ uint32_t num_parameters() nogil
51
+ string to_str() nogil
52
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
53
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
54
+ vector[int] get_dimensions() nogil
55
+ vector[vector[uint]] get_boundaries() nogil
56
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
57
+ vector[Multi_critical_filtration[int32_t]]& get_filtrations() nogil
58
+ C_KSlicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
59
+ void vineyard_update() nogil
60
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
61
+ vector[uint32_t] get_current_order() nogil
62
+ void add_generator(const One_critical_filtration[int32_t] &) nogil
63
+
64
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
65
+
66
+
67
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
68
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
69
+
70
+ #------------------------------------------------------------------------------
71
+ cdef extern from "Persistence_slices_interface.h":
72
+ cdef cppclass C_KSlicer_Matrix1_vine_i32 "TrucPythonInterface<BackendsEnum::Matrix,true,true,int32_t,Available_columns::SMALL_VECTOR>":
73
+ ctypedef int32_t value_type
74
+
75
+ C_KSlicer_Matrix1_vine_i32()
76
+
77
+ C_KSlicer_Matrix1_vine_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int32_t]]&)
78
+
79
+ C_KSlicer_Matrix1_vine_i32& operator=(const C_KSlicer_Matrix1_vine_i32&)
80
+
81
+ C_KSlicer_Matrix1_vine_i32 colexical_rearange() except + nogil
82
+
83
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
84
+ void push_to(const Line[int32_t]&) nogil
85
+ void set_one_filtration(const vector[int32_t]&) nogil
86
+ int prune_above_dimension(int) except + nogil
87
+
88
+ vector[int32_t] get_one_filtration()
89
+ # void compute_persistence(vector[bool]) except+ nogil
90
+ void compute_persistence(bool) except+ nogil # ignore_inf
91
+ void compute_persistence() except+ nogil # ignore_inf
92
+ uint32_t num_generators() nogil
93
+ uint32_t num_parameters() nogil
94
+ string to_str() nogil
95
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
96
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
97
+ vector[int] get_dimensions() nogil
98
+ vector[vector[uint]] get_boundaries() nogil
99
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
100
+ vector[Multi_critical_filtration[int32_t]]& get_filtrations() nogil
101
+ C_KSlicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
102
+ void vineyard_update() nogil
103
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
104
+ vector[uint32_t] get_current_order() nogil
105
+ void add_generator(const One_critical_filtration[int32_t] &) nogil
106
+
107
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
108
+
109
+
110
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
111
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
112
+
113
+ #------------------------------------------------------------------------------
114
+ cdef extern from "Persistence_slices_interface.h":
115
+ cdef cppclass C_KSlicer_Matrix0_vine_i64 "TrucPythonInterface<BackendsEnum::Matrix,true,true,int64_t,Available_columns::INTRUSIVE_SET>":
116
+ ctypedef int64_t value_type
117
+
118
+ C_KSlicer_Matrix0_vine_i64()
119
+
120
+ C_KSlicer_Matrix0_vine_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int64_t]]&)
121
+
122
+ C_KSlicer_Matrix0_vine_i64& operator=(const C_KSlicer_Matrix0_vine_i64&)
123
+
124
+ C_KSlicer_Matrix0_vine_i64 colexical_rearange() except + nogil
125
+
126
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
127
+ void push_to(const Line[int64_t]&) nogil
128
+ void set_one_filtration(const vector[int64_t]&) nogil
129
+ int prune_above_dimension(int) except + nogil
130
+
131
+ vector[int64_t] get_one_filtration()
132
+ # void compute_persistence(vector[bool]) except+ nogil
133
+ void compute_persistence(bool) except+ nogil # ignore_inf
134
+ void compute_persistence() except+ nogil # ignore_inf
135
+ uint32_t num_generators() nogil
136
+ uint32_t num_parameters() nogil
137
+ string to_str() nogil
138
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
139
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
140
+ vector[int] get_dimensions() nogil
141
+ vector[vector[uint]] get_boundaries() nogil
142
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
143
+ vector[Multi_critical_filtration[int64_t]]& get_filtrations() nogil
144
+ C_KSlicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
145
+ void vineyard_update() nogil
146
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
147
+ vector[uint32_t] get_current_order() nogil
148
+ void add_generator(const One_critical_filtration[int64_t] &) nogil
149
+
150
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
151
+
152
+
153
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
154
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
155
+
156
+ #------------------------------------------------------------------------------
157
+ cdef extern from "Persistence_slices_interface.h":
158
+ cdef cppclass C_KSlicer_Matrix1_vine_i64 "TrucPythonInterface<BackendsEnum::Matrix,true,true,int64_t,Available_columns::SMALL_VECTOR>":
159
+ ctypedef int64_t value_type
160
+
161
+ C_KSlicer_Matrix1_vine_i64()
162
+
163
+ C_KSlicer_Matrix1_vine_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int64_t]]&)
164
+
165
+ C_KSlicer_Matrix1_vine_i64& operator=(const C_KSlicer_Matrix1_vine_i64&)
166
+
167
+ C_KSlicer_Matrix1_vine_i64 colexical_rearange() except + nogil
168
+
169
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
170
+ void push_to(const Line[int64_t]&) nogil
171
+ void set_one_filtration(const vector[int64_t]&) nogil
172
+ int prune_above_dimension(int) except + nogil
173
+
174
+ vector[int64_t] get_one_filtration()
175
+ # void compute_persistence(vector[bool]) except+ nogil
176
+ void compute_persistence(bool) except+ nogil # ignore_inf
177
+ void compute_persistence() except+ nogil # ignore_inf
178
+ uint32_t num_generators() nogil
179
+ uint32_t num_parameters() nogil
180
+ string to_str() nogil
181
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
182
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
183
+ vector[int] get_dimensions() nogil
184
+ vector[vector[uint]] get_boundaries() nogil
185
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
186
+ vector[Multi_critical_filtration[int64_t]]& get_filtrations() nogil
187
+ C_KSlicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
188
+ void vineyard_update() nogil
189
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
190
+ vector[uint32_t] get_current_order() nogil
191
+ void add_generator(const One_critical_filtration[int64_t] &) nogil
192
+
193
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
194
+
195
+
196
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
197
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
198
+
199
+ #------------------------------------------------------------------------------
200
+ cdef extern from "Persistence_slices_interface.h":
201
+ cdef cppclass C_KSlicer_Matrix0_vine_f32 "TrucPythonInterface<BackendsEnum::Matrix,true,true,float,Available_columns::INTRUSIVE_SET>":
202
+ ctypedef float value_type
203
+
204
+ C_KSlicer_Matrix0_vine_f32()
205
+
206
+ C_KSlicer_Matrix0_vine_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[float]]&)
207
+
208
+ C_KSlicer_Matrix0_vine_f32& operator=(const C_KSlicer_Matrix0_vine_f32&)
209
+
210
+ C_KSlicer_Matrix0_vine_f32 colexical_rearange() except + nogil
211
+
212
+ vector[vector[pair[float, float]]] get_barcode() nogil
213
+ void push_to(const Line[float]&) nogil
214
+ void set_one_filtration(const vector[float]&) nogil
215
+ int prune_above_dimension(int) except + nogil
216
+
217
+ vector[float] get_one_filtration()
218
+ # void compute_persistence(vector[bool]) except+ nogil
219
+ void compute_persistence(bool) except+ nogil # ignore_inf
220
+ void compute_persistence() except+ nogil # ignore_inf
221
+ uint32_t num_generators() nogil
222
+ uint32_t num_parameters() nogil
223
+ string to_str() nogil
224
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
225
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
226
+ vector[int] get_dimensions() nogil
227
+ vector[vector[uint]] get_boundaries() nogil
228
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
229
+ vector[Multi_critical_filtration[float]]& get_filtrations() nogil
230
+ C_KSlicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[float]]) nogil
231
+ void vineyard_update() nogil
232
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
233
+ vector[uint32_t] get_current_order() nogil
234
+ void add_generator(const One_critical_filtration[float] &) nogil
235
+
236
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
237
+
238
+
239
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
240
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
241
+
242
+ #------------------------------------------------------------------------------
243
+ cdef extern from "Persistence_slices_interface.h":
244
+ cdef cppclass C_KSlicer_Matrix1_vine_f32 "TrucPythonInterface<BackendsEnum::Matrix,true,true,float,Available_columns::SMALL_VECTOR>":
245
+ ctypedef float value_type
246
+
247
+ C_KSlicer_Matrix1_vine_f32()
248
+
249
+ C_KSlicer_Matrix1_vine_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[float]]&)
250
+
251
+ C_KSlicer_Matrix1_vine_f32& operator=(const C_KSlicer_Matrix1_vine_f32&)
252
+
253
+ C_KSlicer_Matrix1_vine_f32 colexical_rearange() except + nogil
254
+
255
+ vector[vector[pair[float, float]]] get_barcode() nogil
256
+ void push_to(const Line[float]&) nogil
257
+ void set_one_filtration(const vector[float]&) nogil
258
+ int prune_above_dimension(int) except + nogil
259
+
260
+ vector[float] get_one_filtration()
261
+ # void compute_persistence(vector[bool]) except+ nogil
262
+ void compute_persistence(bool) except+ nogil # ignore_inf
263
+ void compute_persistence() except+ nogil # ignore_inf
264
+ uint32_t num_generators() nogil
265
+ uint32_t num_parameters() nogil
266
+ string to_str() nogil
267
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
268
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
269
+ vector[int] get_dimensions() nogil
270
+ vector[vector[uint]] get_boundaries() nogil
271
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
272
+ vector[Multi_critical_filtration[float]]& get_filtrations() nogil
273
+ C_KSlicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[float]]) nogil
274
+ void vineyard_update() nogil
275
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
276
+ vector[uint32_t] get_current_order() nogil
277
+ void add_generator(const One_critical_filtration[float] &) nogil
278
+
279
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
280
+
281
+
282
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
283
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
284
+
285
+ #------------------------------------------------------------------------------
286
+ cdef extern from "Persistence_slices_interface.h":
287
+ cdef cppclass C_KSlicer_Matrix0_vine_f64 "TrucPythonInterface<BackendsEnum::Matrix,true,true,double,Available_columns::INTRUSIVE_SET>":
288
+ ctypedef double value_type
289
+
290
+ C_KSlicer_Matrix0_vine_f64()
291
+
292
+ C_KSlicer_Matrix0_vine_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[double]]&)
293
+
294
+ C_KSlicer_Matrix0_vine_f64& operator=(const C_KSlicer_Matrix0_vine_f64&)
295
+
296
+ C_KSlicer_Matrix0_vine_f64 colexical_rearange() except + nogil
297
+
298
+ vector[vector[pair[double, double]]] get_barcode() nogil
299
+ void push_to(const Line[double]&) nogil
300
+ void set_one_filtration(const vector[double]&) nogil
301
+ int prune_above_dimension(int) except + nogil
302
+
303
+ vector[double] get_one_filtration()
304
+ # void compute_persistence(vector[bool]) except+ nogil
305
+ void compute_persistence(bool) except+ nogil # ignore_inf
306
+ void compute_persistence() except+ nogil # ignore_inf
307
+ uint32_t num_generators() nogil
308
+ uint32_t num_parameters() nogil
309
+ string to_str() nogil
310
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
311
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
312
+ vector[int] get_dimensions() nogil
313
+ vector[vector[uint]] get_boundaries() nogil
314
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
315
+ vector[Multi_critical_filtration[double]]& get_filtrations() nogil
316
+ C_KSlicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[double]]) nogil
317
+ void vineyard_update() nogil
318
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
319
+ vector[uint32_t] get_current_order() nogil
320
+ void add_generator(const One_critical_filtration[double] &) nogil
321
+
322
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
323
+
324
+
325
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
326
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
327
+
328
+ #------------------------------------------------------------------------------
329
+ cdef extern from "Persistence_slices_interface.h":
330
+ cdef cppclass C_KSlicer_Matrix1_vine_f64 "TrucPythonInterface<BackendsEnum::Matrix,true,true,double,Available_columns::SMALL_VECTOR>":
331
+ ctypedef double value_type
332
+
333
+ C_KSlicer_Matrix1_vine_f64()
334
+
335
+ C_KSlicer_Matrix1_vine_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[double]]&)
336
+
337
+ C_KSlicer_Matrix1_vine_f64& operator=(const C_KSlicer_Matrix1_vine_f64&)
338
+
339
+ C_KSlicer_Matrix1_vine_f64 colexical_rearange() except + nogil
340
+
341
+ vector[vector[pair[double, double]]] get_barcode() nogil
342
+ void push_to(const Line[double]&) nogil
343
+ void set_one_filtration(const vector[double]&) nogil
344
+ int prune_above_dimension(int) except + nogil
345
+
346
+ vector[double] get_one_filtration()
347
+ # void compute_persistence(vector[bool]) except+ nogil
348
+ void compute_persistence(bool) except+ nogil # ignore_inf
349
+ void compute_persistence() except+ nogil # ignore_inf
350
+ uint32_t num_generators() nogil
351
+ uint32_t num_parameters() nogil
352
+ string to_str() nogil
353
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
354
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
355
+ vector[int] get_dimensions() nogil
356
+ vector[vector[uint]] get_boundaries() nogil
357
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
358
+ vector[Multi_critical_filtration[double]]& get_filtrations() nogil
359
+ C_KSlicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[double]]) nogil
360
+ void vineyard_update() nogil
361
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
362
+ vector[uint32_t] get_current_order() nogil
363
+ void add_generator(const One_critical_filtration[double] &) nogil
364
+
365
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
366
+
367
+
368
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
369
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
370
+
371
+ #------------------------------------------------------------------------------
372
+ cdef extern from "Persistence_slices_interface.h":
373
+ cdef cppclass C_Slicer_Matrix0_vine_i32 "TrucPythonInterface<BackendsEnum::Matrix,true,false,int32_t,Available_columns::INTRUSIVE_SET>":
374
+ ctypedef int32_t value_type
375
+
376
+ C_Slicer_Matrix0_vine_i32()
377
+
378
+ C_Slicer_Matrix0_vine_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int32_t]]&)
379
+
380
+ C_Slicer_Matrix0_vine_i32& operator=(const C_Slicer_Matrix0_vine_i32&)
381
+
382
+ C_Slicer_Matrix0_vine_i32 colexical_rearange() except + nogil
383
+
384
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
385
+ void push_to(const Line[int32_t]&) nogil
386
+ void set_one_filtration(const vector[int32_t]&) nogil
387
+ int prune_above_dimension(int) except + nogil
388
+
389
+ vector[int32_t] get_one_filtration()
390
+ # void compute_persistence(vector[bool]) except+ nogil
391
+ void compute_persistence(bool) except+ nogil # ignore_inf
392
+ void compute_persistence() except+ nogil # ignore_inf
393
+ uint32_t num_generators() nogil
394
+ uint32_t num_parameters() nogil
395
+ string to_str() nogil
396
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
397
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
398
+ vector[int] get_dimensions() nogil
399
+ vector[vector[uint]] get_boundaries() nogil
400
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
401
+ vector[One_critical_filtration[int32_t]]& get_filtrations() nogil
402
+ C_Slicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
403
+ void vineyard_update() nogil
404
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
405
+ vector[uint32_t] get_current_order() nogil
406
+
407
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
408
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
409
+
410
+
411
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
412
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
413
+
414
+ #------------------------------------------------------------------------------
415
+ cdef extern from "Persistence_slices_interface.h":
416
+ cdef cppclass C_Slicer_Matrix1_vine_i32 "TrucPythonInterface<BackendsEnum::Matrix,true,false,int32_t,Available_columns::SMALL_VECTOR>":
417
+ ctypedef int32_t value_type
418
+
419
+ C_Slicer_Matrix1_vine_i32()
420
+
421
+ C_Slicer_Matrix1_vine_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int32_t]]&)
422
+
423
+ C_Slicer_Matrix1_vine_i32& operator=(const C_Slicer_Matrix1_vine_i32&)
424
+
425
+ C_Slicer_Matrix1_vine_i32 colexical_rearange() except + nogil
426
+
427
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
428
+ void push_to(const Line[int32_t]&) nogil
429
+ void set_one_filtration(const vector[int32_t]&) nogil
430
+ int prune_above_dimension(int) except + nogil
431
+
432
+ vector[int32_t] get_one_filtration()
433
+ # void compute_persistence(vector[bool]) except+ nogil
434
+ void compute_persistence(bool) except+ nogil # ignore_inf
435
+ void compute_persistence() except+ nogil # ignore_inf
436
+ uint32_t num_generators() nogil
437
+ uint32_t num_parameters() nogil
438
+ string to_str() nogil
439
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
440
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
441
+ vector[int] get_dimensions() nogil
442
+ vector[vector[uint]] get_boundaries() nogil
443
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
444
+ vector[One_critical_filtration[int32_t]]& get_filtrations() nogil
445
+ C_Slicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
446
+ void vineyard_update() nogil
447
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
448
+ vector[uint32_t] get_current_order() nogil
449
+
450
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
451
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
452
+
453
+
454
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
455
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
456
+
457
+ #------------------------------------------------------------------------------
458
+ cdef extern from "Persistence_slices_interface.h":
459
+ cdef cppclass C_Slicer_Matrix0_vine_i64 "TrucPythonInterface<BackendsEnum::Matrix,true,false,int64_t,Available_columns::INTRUSIVE_SET>":
460
+ ctypedef int64_t value_type
461
+
462
+ C_Slicer_Matrix0_vine_i64()
463
+
464
+ C_Slicer_Matrix0_vine_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int64_t]]&)
465
+
466
+ C_Slicer_Matrix0_vine_i64& operator=(const C_Slicer_Matrix0_vine_i64&)
467
+
468
+ C_Slicer_Matrix0_vine_i64 colexical_rearange() except + nogil
469
+
470
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
471
+ void push_to(const Line[int64_t]&) nogil
472
+ void set_one_filtration(const vector[int64_t]&) nogil
473
+ int prune_above_dimension(int) except + nogil
474
+
475
+ vector[int64_t] get_one_filtration()
476
+ # void compute_persistence(vector[bool]) except+ nogil
477
+ void compute_persistence(bool) except+ nogil # ignore_inf
478
+ void compute_persistence() except+ nogil # ignore_inf
479
+ uint32_t num_generators() nogil
480
+ uint32_t num_parameters() nogil
481
+ string to_str() nogil
482
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
483
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
484
+ vector[int] get_dimensions() nogil
485
+ vector[vector[uint]] get_boundaries() nogil
486
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
487
+ vector[One_critical_filtration[int64_t]]& get_filtrations() nogil
488
+ C_Slicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
489
+ void vineyard_update() nogil
490
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
491
+ vector[uint32_t] get_current_order() nogil
492
+
493
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
494
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
495
+
496
+
497
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
498
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
499
+
500
+ #------------------------------------------------------------------------------
501
+ cdef extern from "Persistence_slices_interface.h":
502
+ cdef cppclass C_Slicer_Matrix1_vine_i64 "TrucPythonInterface<BackendsEnum::Matrix,true,false,int64_t,Available_columns::SMALL_VECTOR>":
503
+ ctypedef int64_t value_type
504
+
505
+ C_Slicer_Matrix1_vine_i64()
506
+
507
+ C_Slicer_Matrix1_vine_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int64_t]]&)
508
+
509
+ C_Slicer_Matrix1_vine_i64& operator=(const C_Slicer_Matrix1_vine_i64&)
510
+
511
+ C_Slicer_Matrix1_vine_i64 colexical_rearange() except + nogil
512
+
513
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
514
+ void push_to(const Line[int64_t]&) nogil
515
+ void set_one_filtration(const vector[int64_t]&) nogil
516
+ int prune_above_dimension(int) except + nogil
517
+
518
+ vector[int64_t] get_one_filtration()
519
+ # void compute_persistence(vector[bool]) except+ nogil
520
+ void compute_persistence(bool) except+ nogil # ignore_inf
521
+ void compute_persistence() except+ nogil # ignore_inf
522
+ uint32_t num_generators() nogil
523
+ uint32_t num_parameters() nogil
524
+ string to_str() nogil
525
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
526
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
527
+ vector[int] get_dimensions() nogil
528
+ vector[vector[uint]] get_boundaries() nogil
529
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
530
+ vector[One_critical_filtration[int64_t]]& get_filtrations() nogil
531
+ C_Slicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
532
+ void vineyard_update() nogil
533
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
534
+ vector[uint32_t] get_current_order() nogil
535
+
536
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
537
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
538
+
539
+
540
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
541
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
542
+
543
+ #------------------------------------------------------------------------------
544
+ cdef extern from "Persistence_slices_interface.h":
545
+ cdef cppclass C_Slicer_Matrix0_vine_f32 "TrucPythonInterface<BackendsEnum::Matrix,true,false,float,Available_columns::INTRUSIVE_SET>":
546
+ ctypedef float value_type
547
+
548
+ C_Slicer_Matrix0_vine_f32()
549
+
550
+ C_Slicer_Matrix0_vine_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[float]]&)
551
+
552
+ C_Slicer_Matrix0_vine_f32& operator=(const C_Slicer_Matrix0_vine_f32&)
553
+
554
+ C_Slicer_Matrix0_vine_f32 colexical_rearange() except + nogil
555
+
556
+ vector[vector[pair[float, float]]] get_barcode() nogil
557
+ void push_to(const Line[float]&) nogil
558
+ void set_one_filtration(const vector[float]&) nogil
559
+ int prune_above_dimension(int) except + nogil
560
+
561
+ vector[float] get_one_filtration()
562
+ # void compute_persistence(vector[bool]) except+ nogil
563
+ void compute_persistence(bool) except+ nogil # ignore_inf
564
+ void compute_persistence() except+ nogil # ignore_inf
565
+ uint32_t num_generators() nogil
566
+ uint32_t num_parameters() nogil
567
+ string to_str() nogil
568
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
569
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
570
+ vector[int] get_dimensions() nogil
571
+ vector[vector[uint]] get_boundaries() nogil
572
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
573
+ vector[One_critical_filtration[float]]& get_filtrations() nogil
574
+ C_Slicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[float]]) nogil
575
+ void vineyard_update() nogil
576
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
577
+ vector[uint32_t] get_current_order() nogil
578
+
579
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
580
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
581
+
582
+
583
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
584
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
585
+
586
+ #------------------------------------------------------------------------------
587
+ cdef extern from "Persistence_slices_interface.h":
588
+ cdef cppclass C_Slicer_Matrix1_vine_f32 "TrucPythonInterface<BackendsEnum::Matrix,true,false,float,Available_columns::SMALL_VECTOR>":
589
+ ctypedef float value_type
590
+
591
+ C_Slicer_Matrix1_vine_f32()
592
+
593
+ C_Slicer_Matrix1_vine_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[float]]&)
594
+
595
+ C_Slicer_Matrix1_vine_f32& operator=(const C_Slicer_Matrix1_vine_f32&)
596
+
597
+ C_Slicer_Matrix1_vine_f32 colexical_rearange() except + nogil
598
+
599
+ vector[vector[pair[float, float]]] get_barcode() nogil
600
+ void push_to(const Line[float]&) nogil
601
+ void set_one_filtration(const vector[float]&) nogil
602
+ int prune_above_dimension(int) except + nogil
603
+
604
+ vector[float] get_one_filtration()
605
+ # void compute_persistence(vector[bool]) except+ nogil
606
+ void compute_persistence(bool) except+ nogil # ignore_inf
607
+ void compute_persistence() except+ nogil # ignore_inf
608
+ uint32_t num_generators() nogil
609
+ uint32_t num_parameters() nogil
610
+ string to_str() nogil
611
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
612
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
613
+ vector[int] get_dimensions() nogil
614
+ vector[vector[uint]] get_boundaries() nogil
615
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
616
+ vector[One_critical_filtration[float]]& get_filtrations() nogil
617
+ C_Slicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[float]]) nogil
618
+ void vineyard_update() nogil
619
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
620
+ vector[uint32_t] get_current_order() nogil
621
+
622
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
623
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
624
+
625
+
626
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
627
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
628
+
629
+ #------------------------------------------------------------------------------
630
+ cdef extern from "Persistence_slices_interface.h":
631
+ cdef cppclass C_Slicer_Matrix0_vine_f64 "TrucPythonInterface<BackendsEnum::Matrix,true,false,double,Available_columns::INTRUSIVE_SET>":
632
+ ctypedef double value_type
633
+
634
+ C_Slicer_Matrix0_vine_f64()
635
+
636
+ C_Slicer_Matrix0_vine_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[double]]&)
637
+
638
+ C_Slicer_Matrix0_vine_f64& operator=(const C_Slicer_Matrix0_vine_f64&)
639
+
640
+ C_Slicer_Matrix0_vine_f64 colexical_rearange() except + nogil
641
+
642
+ vector[vector[pair[double, double]]] get_barcode() nogil
643
+ void push_to(const Line[double]&) nogil
644
+ void set_one_filtration(const vector[double]&) nogil
645
+ int prune_above_dimension(int) except + nogil
646
+
647
+ vector[double] get_one_filtration()
648
+ # void compute_persistence(vector[bool]) except+ nogil
649
+ void compute_persistence(bool) except+ nogil # ignore_inf
650
+ void compute_persistence() except+ nogil # ignore_inf
651
+ uint32_t num_generators() nogil
652
+ uint32_t num_parameters() nogil
653
+ string to_str() nogil
654
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
655
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
656
+ vector[int] get_dimensions() nogil
657
+ vector[vector[uint]] get_boundaries() nogil
658
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
659
+ vector[One_critical_filtration[double]]& get_filtrations() nogil
660
+ C_Slicer_Matrix0_vine_i32 coarsen_on_grid(vector[vector[double]]) nogil
661
+ void vineyard_update() nogil
662
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
663
+ vector[uint32_t] get_current_order() nogil
664
+
665
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
666
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
667
+
668
+
669
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
670
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
671
+
672
+ #------------------------------------------------------------------------------
673
+ cdef extern from "Persistence_slices_interface.h":
674
+ cdef cppclass C_Slicer_Matrix1_vine_f64 "TrucPythonInterface<BackendsEnum::Matrix,true,false,double,Available_columns::SMALL_VECTOR>":
675
+ ctypedef double value_type
676
+
677
+ C_Slicer_Matrix1_vine_f64()
678
+
679
+ C_Slicer_Matrix1_vine_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[double]]&)
680
+
681
+ C_Slicer_Matrix1_vine_f64& operator=(const C_Slicer_Matrix1_vine_f64&)
682
+
683
+ C_Slicer_Matrix1_vine_f64 colexical_rearange() except + nogil
684
+
685
+ vector[vector[pair[double, double]]] get_barcode() nogil
686
+ void push_to(const Line[double]&) nogil
687
+ void set_one_filtration(const vector[double]&) nogil
688
+ int prune_above_dimension(int) except + nogil
689
+
690
+ vector[double] get_one_filtration()
691
+ # void compute_persistence(vector[bool]) except+ nogil
692
+ void compute_persistence(bool) except+ nogil # ignore_inf
693
+ void compute_persistence() except+ nogil # ignore_inf
694
+ uint32_t num_generators() nogil
695
+ uint32_t num_parameters() nogil
696
+ string to_str() nogil
697
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
698
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
699
+ vector[int] get_dimensions() nogil
700
+ vector[vector[uint]] get_boundaries() nogil
701
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
702
+ vector[One_critical_filtration[double]]& get_filtrations() nogil
703
+ C_Slicer_Matrix1_vine_i32 coarsen_on_grid(vector[vector[double]]) nogil
704
+ void vineyard_update() nogil
705
+ vector[vector[vector[vector[unsigned int]]]] get_representative_cycles(bool, bool) nogil
706
+ vector[uint32_t] get_current_order() nogil
707
+
708
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
709
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
710
+
711
+
712
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
713
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
714
+
715
+ #------------------------------------------------------------------------------
716
+ cdef extern from "Persistence_slices_interface.h":
717
+ cdef cppclass C_KSlicer_Matrix0_i32 "TrucPythonInterface<BackendsEnum::Matrix,false,true,int32_t,Available_columns::INTRUSIVE_SET>":
718
+ ctypedef int32_t value_type
719
+
720
+ C_KSlicer_Matrix0_i32()
721
+
722
+ C_KSlicer_Matrix0_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int32_t]]&)
723
+
724
+ C_KSlicer_Matrix0_i32& operator=(const C_KSlicer_Matrix0_i32&)
725
+
726
+ C_KSlicer_Matrix0_i32 colexical_rearange() except + nogil
727
+
728
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
729
+ void push_to(const Line[int32_t]&) nogil
730
+ void set_one_filtration(const vector[int32_t]&) nogil
731
+ int prune_above_dimension(int) except + nogil
732
+
733
+ vector[int32_t] get_one_filtration()
734
+ # void compute_persistence(vector[bool]) except+ nogil
735
+ void compute_persistence(bool) except+ nogil # ignore_inf
736
+ void compute_persistence() except+ nogil # ignore_inf
737
+ uint32_t num_generators() nogil
738
+ uint32_t num_parameters() nogil
739
+ string to_str() nogil
740
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
741
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
742
+ vector[int] get_dimensions() nogil
743
+ vector[vector[uint]] get_boundaries() nogil
744
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
745
+ vector[Multi_critical_filtration[int32_t]]& get_filtrations() nogil
746
+ C_KSlicer_Matrix0_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
747
+ void add_generator(const One_critical_filtration[int32_t] &) nogil
748
+
749
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
750
+
751
+
752
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
753
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
754
+
755
+ #------------------------------------------------------------------------------
756
+ cdef extern from "Persistence_slices_interface.h":
757
+ cdef cppclass C_KSlicer_Matrix1_i32 "TrucPythonInterface<BackendsEnum::Matrix,false,true,int32_t,Available_columns::SMALL_VECTOR>":
758
+ ctypedef int32_t value_type
759
+
760
+ C_KSlicer_Matrix1_i32()
761
+
762
+ C_KSlicer_Matrix1_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int32_t]]&)
763
+
764
+ C_KSlicer_Matrix1_i32& operator=(const C_KSlicer_Matrix1_i32&)
765
+
766
+ C_KSlicer_Matrix1_i32 colexical_rearange() except + nogil
767
+
768
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
769
+ void push_to(const Line[int32_t]&) nogil
770
+ void set_one_filtration(const vector[int32_t]&) nogil
771
+ int prune_above_dimension(int) except + nogil
772
+
773
+ vector[int32_t] get_one_filtration()
774
+ # void compute_persistence(vector[bool]) except+ nogil
775
+ void compute_persistence(bool) except+ nogil # ignore_inf
776
+ void compute_persistence() except+ nogil # ignore_inf
777
+ uint32_t num_generators() nogil
778
+ uint32_t num_parameters() nogil
779
+ string to_str() nogil
780
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
781
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
782
+ vector[int] get_dimensions() nogil
783
+ vector[vector[uint]] get_boundaries() nogil
784
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
785
+ vector[Multi_critical_filtration[int32_t]]& get_filtrations() nogil
786
+ C_KSlicer_Matrix1_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
787
+ void add_generator(const One_critical_filtration[int32_t] &) nogil
788
+
789
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
790
+
791
+
792
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
793
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
794
+
795
+ #------------------------------------------------------------------------------
796
+ cdef extern from "Persistence_slices_interface.h":
797
+ cdef cppclass C_KSlicer_Matrix0_i64 "TrucPythonInterface<BackendsEnum::Matrix,false,true,int64_t,Available_columns::INTRUSIVE_SET>":
798
+ ctypedef int64_t value_type
799
+
800
+ C_KSlicer_Matrix0_i64()
801
+
802
+ C_KSlicer_Matrix0_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int64_t]]&)
803
+
804
+ C_KSlicer_Matrix0_i64& operator=(const C_KSlicer_Matrix0_i64&)
805
+
806
+ C_KSlicer_Matrix0_i64 colexical_rearange() except + nogil
807
+
808
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
809
+ void push_to(const Line[int64_t]&) nogil
810
+ void set_one_filtration(const vector[int64_t]&) nogil
811
+ int prune_above_dimension(int) except + nogil
812
+
813
+ vector[int64_t] get_one_filtration()
814
+ # void compute_persistence(vector[bool]) except+ nogil
815
+ void compute_persistence(bool) except+ nogil # ignore_inf
816
+ void compute_persistence() except+ nogil # ignore_inf
817
+ uint32_t num_generators() nogil
818
+ uint32_t num_parameters() nogil
819
+ string to_str() nogil
820
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
821
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
822
+ vector[int] get_dimensions() nogil
823
+ vector[vector[uint]] get_boundaries() nogil
824
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
825
+ vector[Multi_critical_filtration[int64_t]]& get_filtrations() nogil
826
+ C_KSlicer_Matrix0_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
827
+ void add_generator(const One_critical_filtration[int64_t] &) nogil
828
+
829
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
830
+
831
+
832
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
833
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
834
+
835
+ #------------------------------------------------------------------------------
836
+ cdef extern from "Persistence_slices_interface.h":
837
+ cdef cppclass C_KSlicer_Matrix1_i64 "TrucPythonInterface<BackendsEnum::Matrix,false,true,int64_t,Available_columns::SMALL_VECTOR>":
838
+ ctypedef int64_t value_type
839
+
840
+ C_KSlicer_Matrix1_i64()
841
+
842
+ C_KSlicer_Matrix1_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int64_t]]&)
843
+
844
+ C_KSlicer_Matrix1_i64& operator=(const C_KSlicer_Matrix1_i64&)
845
+
846
+ C_KSlicer_Matrix1_i64 colexical_rearange() except + nogil
847
+
848
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
849
+ void push_to(const Line[int64_t]&) nogil
850
+ void set_one_filtration(const vector[int64_t]&) nogil
851
+ int prune_above_dimension(int) except + nogil
852
+
853
+ vector[int64_t] get_one_filtration()
854
+ # void compute_persistence(vector[bool]) except+ nogil
855
+ void compute_persistence(bool) except+ nogil # ignore_inf
856
+ void compute_persistence() except+ nogil # ignore_inf
857
+ uint32_t num_generators() nogil
858
+ uint32_t num_parameters() nogil
859
+ string to_str() nogil
860
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
861
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
862
+ vector[int] get_dimensions() nogil
863
+ vector[vector[uint]] get_boundaries() nogil
864
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
865
+ vector[Multi_critical_filtration[int64_t]]& get_filtrations() nogil
866
+ C_KSlicer_Matrix1_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
867
+ void add_generator(const One_critical_filtration[int64_t] &) nogil
868
+
869
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
870
+
871
+
872
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
873
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
874
+
875
+ #------------------------------------------------------------------------------
876
+ cdef extern from "Persistence_slices_interface.h":
877
+ cdef cppclass C_KSlicer_Matrix0_f32 "TrucPythonInterface<BackendsEnum::Matrix,false,true,float,Available_columns::INTRUSIVE_SET>":
878
+ ctypedef float value_type
879
+
880
+ C_KSlicer_Matrix0_f32()
881
+
882
+ C_KSlicer_Matrix0_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[float]]&)
883
+
884
+ C_KSlicer_Matrix0_f32& operator=(const C_KSlicer_Matrix0_f32&)
885
+
886
+ C_KSlicer_Matrix0_f32 colexical_rearange() except + nogil
887
+
888
+ vector[vector[pair[float, float]]] get_barcode() nogil
889
+ void push_to(const Line[float]&) nogil
890
+ void set_one_filtration(const vector[float]&) nogil
891
+ int prune_above_dimension(int) except + nogil
892
+
893
+ vector[float] get_one_filtration()
894
+ # void compute_persistence(vector[bool]) except+ nogil
895
+ void compute_persistence(bool) except+ nogil # ignore_inf
896
+ void compute_persistence() except+ nogil # ignore_inf
897
+ uint32_t num_generators() nogil
898
+ uint32_t num_parameters() nogil
899
+ string to_str() nogil
900
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
901
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
902
+ vector[int] get_dimensions() nogil
903
+ vector[vector[uint]] get_boundaries() nogil
904
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
905
+ vector[Multi_critical_filtration[float]]& get_filtrations() nogil
906
+ C_KSlicer_Matrix0_i32 coarsen_on_grid(vector[vector[float]]) nogil
907
+ void add_generator(const One_critical_filtration[float] &) nogil
908
+
909
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
910
+
911
+
912
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
913
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
914
+
915
+ #------------------------------------------------------------------------------
916
+ cdef extern from "Persistence_slices_interface.h":
917
+ cdef cppclass C_KSlicer_Matrix1_f32 "TrucPythonInterface<BackendsEnum::Matrix,false,true,float,Available_columns::SMALL_VECTOR>":
918
+ ctypedef float value_type
919
+
920
+ C_KSlicer_Matrix1_f32()
921
+
922
+ C_KSlicer_Matrix1_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[float]]&)
923
+
924
+ C_KSlicer_Matrix1_f32& operator=(const C_KSlicer_Matrix1_f32&)
925
+
926
+ C_KSlicer_Matrix1_f32 colexical_rearange() except + nogil
927
+
928
+ vector[vector[pair[float, float]]] get_barcode() nogil
929
+ void push_to(const Line[float]&) nogil
930
+ void set_one_filtration(const vector[float]&) nogil
931
+ int prune_above_dimension(int) except + nogil
932
+
933
+ vector[float] get_one_filtration()
934
+ # void compute_persistence(vector[bool]) except+ nogil
935
+ void compute_persistence(bool) except+ nogil # ignore_inf
936
+ void compute_persistence() except+ nogil # ignore_inf
937
+ uint32_t num_generators() nogil
938
+ uint32_t num_parameters() nogil
939
+ string to_str() nogil
940
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
941
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
942
+ vector[int] get_dimensions() nogil
943
+ vector[vector[uint]] get_boundaries() nogil
944
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
945
+ vector[Multi_critical_filtration[float]]& get_filtrations() nogil
946
+ C_KSlicer_Matrix1_i32 coarsen_on_grid(vector[vector[float]]) nogil
947
+ void add_generator(const One_critical_filtration[float] &) nogil
948
+
949
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
950
+
951
+
952
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
953
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
954
+
955
+ #------------------------------------------------------------------------------
956
+ cdef extern from "Persistence_slices_interface.h":
957
+ cdef cppclass C_KSlicer_Matrix0_f64 "TrucPythonInterface<BackendsEnum::Matrix,false,true,double,Available_columns::INTRUSIVE_SET>":
958
+ ctypedef double value_type
959
+
960
+ C_KSlicer_Matrix0_f64()
961
+
962
+ C_KSlicer_Matrix0_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[double]]&)
963
+
964
+ C_KSlicer_Matrix0_f64& operator=(const C_KSlicer_Matrix0_f64&)
965
+
966
+ C_KSlicer_Matrix0_f64 colexical_rearange() except + nogil
967
+
968
+ vector[vector[pair[double, double]]] get_barcode() nogil
969
+ void push_to(const Line[double]&) nogil
970
+ void set_one_filtration(const vector[double]&) nogil
971
+ int prune_above_dimension(int) except + nogil
972
+
973
+ vector[double] get_one_filtration()
974
+ # void compute_persistence(vector[bool]) except+ nogil
975
+ void compute_persistence(bool) except+ nogil # ignore_inf
976
+ void compute_persistence() except+ nogil # ignore_inf
977
+ uint32_t num_generators() nogil
978
+ uint32_t num_parameters() nogil
979
+ string to_str() nogil
980
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
981
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
982
+ vector[int] get_dimensions() nogil
983
+ vector[vector[uint]] get_boundaries() nogil
984
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
985
+ vector[Multi_critical_filtration[double]]& get_filtrations() nogil
986
+ C_KSlicer_Matrix0_i32 coarsen_on_grid(vector[vector[double]]) nogil
987
+ void add_generator(const One_critical_filtration[double] &) nogil
988
+
989
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
990
+
991
+
992
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
993
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
994
+
995
+ #------------------------------------------------------------------------------
996
+ cdef extern from "Persistence_slices_interface.h":
997
+ cdef cppclass C_KSlicer_Matrix1_f64 "TrucPythonInterface<BackendsEnum::Matrix,false,true,double,Available_columns::SMALL_VECTOR>":
998
+ ctypedef double value_type
999
+
1000
+ C_KSlicer_Matrix1_f64()
1001
+
1002
+ C_KSlicer_Matrix1_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[double]]&)
1003
+
1004
+ C_KSlicer_Matrix1_f64& operator=(const C_KSlicer_Matrix1_f64&)
1005
+
1006
+ C_KSlicer_Matrix1_f64 colexical_rearange() except + nogil
1007
+
1008
+ vector[vector[pair[double, double]]] get_barcode() nogil
1009
+ void push_to(const Line[double]&) nogil
1010
+ void set_one_filtration(const vector[double]&) nogil
1011
+ int prune_above_dimension(int) except + nogil
1012
+
1013
+ vector[double] get_one_filtration()
1014
+ # void compute_persistence(vector[bool]) except+ nogil
1015
+ void compute_persistence(bool) except+ nogil # ignore_inf
1016
+ void compute_persistence() except+ nogil # ignore_inf
1017
+ uint32_t num_generators() nogil
1018
+ uint32_t num_parameters() nogil
1019
+ string to_str() nogil
1020
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
1021
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
1022
+ vector[int] get_dimensions() nogil
1023
+ vector[vector[uint]] get_boundaries() nogil
1024
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
1025
+ vector[Multi_critical_filtration[double]]& get_filtrations() nogil
1026
+ C_KSlicer_Matrix1_i32 coarsen_on_grid(vector[vector[double]]) nogil
1027
+ void add_generator(const One_critical_filtration[double] &) nogil
1028
+
1029
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1030
+
1031
+
1032
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
1033
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
1034
+
1035
+ #------------------------------------------------------------------------------
1036
+ cdef extern from "Persistence_slices_interface.h":
1037
+ cdef cppclass C_Slicer_Matrix0_i32 "TrucPythonInterface<BackendsEnum::Matrix,false,false,int32_t,Available_columns::INTRUSIVE_SET>":
1038
+ ctypedef int32_t value_type
1039
+
1040
+ C_Slicer_Matrix0_i32()
1041
+
1042
+ C_Slicer_Matrix0_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int32_t]]&)
1043
+
1044
+ C_Slicer_Matrix0_i32& operator=(const C_Slicer_Matrix0_i32&)
1045
+
1046
+ C_Slicer_Matrix0_i32 colexical_rearange() except + nogil
1047
+
1048
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
1049
+ void push_to(const Line[int32_t]&) nogil
1050
+ void set_one_filtration(const vector[int32_t]&) nogil
1051
+ int prune_above_dimension(int) except + nogil
1052
+
1053
+ vector[int32_t] get_one_filtration()
1054
+ # void compute_persistence(vector[bool]) except+ nogil
1055
+ void compute_persistence(bool) except+ nogil # ignore_inf
1056
+ void compute_persistence() except+ nogil # ignore_inf
1057
+ uint32_t num_generators() nogil
1058
+ uint32_t num_parameters() nogil
1059
+ string to_str() nogil
1060
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
1061
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
1062
+ vector[int] get_dimensions() nogil
1063
+ vector[vector[uint]] get_boundaries() nogil
1064
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
1065
+ vector[One_critical_filtration[int32_t]]& get_filtrations() nogil
1066
+ C_Slicer_Matrix0_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
1067
+
1068
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1069
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1070
+
1071
+
1072
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
1073
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
1074
+
1075
+ #------------------------------------------------------------------------------
1076
+ cdef extern from "Persistence_slices_interface.h":
1077
+ cdef cppclass C_Slicer_Matrix1_i32 "TrucPythonInterface<BackendsEnum::Matrix,false,false,int32_t,Available_columns::SMALL_VECTOR>":
1078
+ ctypedef int32_t value_type
1079
+
1080
+ C_Slicer_Matrix1_i32()
1081
+
1082
+ C_Slicer_Matrix1_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int32_t]]&)
1083
+
1084
+ C_Slicer_Matrix1_i32& operator=(const C_Slicer_Matrix1_i32&)
1085
+
1086
+ C_Slicer_Matrix1_i32 colexical_rearange() except + nogil
1087
+
1088
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
1089
+ void push_to(const Line[int32_t]&) nogil
1090
+ void set_one_filtration(const vector[int32_t]&) nogil
1091
+ int prune_above_dimension(int) except + nogil
1092
+
1093
+ vector[int32_t] get_one_filtration()
1094
+ # void compute_persistence(vector[bool]) except+ nogil
1095
+ void compute_persistence(bool) except+ nogil # ignore_inf
1096
+ void compute_persistence() except+ nogil # ignore_inf
1097
+ uint32_t num_generators() nogil
1098
+ uint32_t num_parameters() nogil
1099
+ string to_str() nogil
1100
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
1101
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
1102
+ vector[int] get_dimensions() nogil
1103
+ vector[vector[uint]] get_boundaries() nogil
1104
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
1105
+ vector[One_critical_filtration[int32_t]]& get_filtrations() nogil
1106
+ C_Slicer_Matrix1_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
1107
+
1108
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1109
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1110
+
1111
+
1112
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
1113
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
1114
+
1115
+ #------------------------------------------------------------------------------
1116
+ cdef extern from "Persistence_slices_interface.h":
1117
+ cdef cppclass C_Slicer_Matrix0_i64 "TrucPythonInterface<BackendsEnum::Matrix,false,false,int64_t,Available_columns::INTRUSIVE_SET>":
1118
+ ctypedef int64_t value_type
1119
+
1120
+ C_Slicer_Matrix0_i64()
1121
+
1122
+ C_Slicer_Matrix0_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int64_t]]&)
1123
+
1124
+ C_Slicer_Matrix0_i64& operator=(const C_Slicer_Matrix0_i64&)
1125
+
1126
+ C_Slicer_Matrix0_i64 colexical_rearange() except + nogil
1127
+
1128
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
1129
+ void push_to(const Line[int64_t]&) nogil
1130
+ void set_one_filtration(const vector[int64_t]&) nogil
1131
+ int prune_above_dimension(int) except + nogil
1132
+
1133
+ vector[int64_t] get_one_filtration()
1134
+ # void compute_persistence(vector[bool]) except+ nogil
1135
+ void compute_persistence(bool) except+ nogil # ignore_inf
1136
+ void compute_persistence() except+ nogil # ignore_inf
1137
+ uint32_t num_generators() nogil
1138
+ uint32_t num_parameters() nogil
1139
+ string to_str() nogil
1140
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
1141
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
1142
+ vector[int] get_dimensions() nogil
1143
+ vector[vector[uint]] get_boundaries() nogil
1144
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
1145
+ vector[One_critical_filtration[int64_t]]& get_filtrations() nogil
1146
+ C_Slicer_Matrix0_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
1147
+
1148
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1149
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1150
+
1151
+
1152
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
1153
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
1154
+
1155
+ #------------------------------------------------------------------------------
1156
+ cdef extern from "Persistence_slices_interface.h":
1157
+ cdef cppclass C_Slicer_Matrix1_i64 "TrucPythonInterface<BackendsEnum::Matrix,false,false,int64_t,Available_columns::SMALL_VECTOR>":
1158
+ ctypedef int64_t value_type
1159
+
1160
+ C_Slicer_Matrix1_i64()
1161
+
1162
+ C_Slicer_Matrix1_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int64_t]]&)
1163
+
1164
+ C_Slicer_Matrix1_i64& operator=(const C_Slicer_Matrix1_i64&)
1165
+
1166
+ C_Slicer_Matrix1_i64 colexical_rearange() except + nogil
1167
+
1168
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
1169
+ void push_to(const Line[int64_t]&) nogil
1170
+ void set_one_filtration(const vector[int64_t]&) nogil
1171
+ int prune_above_dimension(int) except + nogil
1172
+
1173
+ vector[int64_t] get_one_filtration()
1174
+ # void compute_persistence(vector[bool]) except+ nogil
1175
+ void compute_persistence(bool) except+ nogil # ignore_inf
1176
+ void compute_persistence() except+ nogil # ignore_inf
1177
+ uint32_t num_generators() nogil
1178
+ uint32_t num_parameters() nogil
1179
+ string to_str() nogil
1180
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
1181
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
1182
+ vector[int] get_dimensions() nogil
1183
+ vector[vector[uint]] get_boundaries() nogil
1184
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
1185
+ vector[One_critical_filtration[int64_t]]& get_filtrations() nogil
1186
+ C_Slicer_Matrix1_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
1187
+
1188
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1189
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1190
+
1191
+
1192
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
1193
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
1194
+
1195
+ #------------------------------------------------------------------------------
1196
+ cdef extern from "Persistence_slices_interface.h":
1197
+ cdef cppclass C_Slicer_Matrix0_f32 "TrucPythonInterface<BackendsEnum::Matrix,false,false,float,Available_columns::INTRUSIVE_SET>":
1198
+ ctypedef float value_type
1199
+
1200
+ C_Slicer_Matrix0_f32()
1201
+
1202
+ C_Slicer_Matrix0_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[float]]&)
1203
+
1204
+ C_Slicer_Matrix0_f32& operator=(const C_Slicer_Matrix0_f32&)
1205
+
1206
+ C_Slicer_Matrix0_f32 colexical_rearange() except + nogil
1207
+
1208
+ vector[vector[pair[float, float]]] get_barcode() nogil
1209
+ void push_to(const Line[float]&) nogil
1210
+ void set_one_filtration(const vector[float]&) nogil
1211
+ int prune_above_dimension(int) except + nogil
1212
+
1213
+ vector[float] get_one_filtration()
1214
+ # void compute_persistence(vector[bool]) except+ nogil
1215
+ void compute_persistence(bool) except+ nogil # ignore_inf
1216
+ void compute_persistence() except+ nogil # ignore_inf
1217
+ uint32_t num_generators() nogil
1218
+ uint32_t num_parameters() nogil
1219
+ string to_str() nogil
1220
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
1221
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
1222
+ vector[int] get_dimensions() nogil
1223
+ vector[vector[uint]] get_boundaries() nogil
1224
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
1225
+ vector[One_critical_filtration[float]]& get_filtrations() nogil
1226
+ C_Slicer_Matrix0_i32 coarsen_on_grid(vector[vector[float]]) nogil
1227
+
1228
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1229
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1230
+
1231
+
1232
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
1233
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
1234
+
1235
+ #------------------------------------------------------------------------------
1236
+ cdef extern from "Persistence_slices_interface.h":
1237
+ cdef cppclass C_Slicer_Matrix1_f32 "TrucPythonInterface<BackendsEnum::Matrix,false,false,float,Available_columns::SMALL_VECTOR>":
1238
+ ctypedef float value_type
1239
+
1240
+ C_Slicer_Matrix1_f32()
1241
+
1242
+ C_Slicer_Matrix1_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[float]]&)
1243
+
1244
+ C_Slicer_Matrix1_f32& operator=(const C_Slicer_Matrix1_f32&)
1245
+
1246
+ C_Slicer_Matrix1_f32 colexical_rearange() except + nogil
1247
+
1248
+ vector[vector[pair[float, float]]] get_barcode() nogil
1249
+ void push_to(const Line[float]&) nogil
1250
+ void set_one_filtration(const vector[float]&) nogil
1251
+ int prune_above_dimension(int) except + nogil
1252
+
1253
+ vector[float] get_one_filtration()
1254
+ # void compute_persistence(vector[bool]) except+ nogil
1255
+ void compute_persistence(bool) except+ nogil # ignore_inf
1256
+ void compute_persistence() except+ nogil # ignore_inf
1257
+ uint32_t num_generators() nogil
1258
+ uint32_t num_parameters() nogil
1259
+ string to_str() nogil
1260
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
1261
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
1262
+ vector[int] get_dimensions() nogil
1263
+ vector[vector[uint]] get_boundaries() nogil
1264
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
1265
+ vector[One_critical_filtration[float]]& get_filtrations() nogil
1266
+ C_Slicer_Matrix1_i32 coarsen_on_grid(vector[vector[float]]) nogil
1267
+
1268
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1269
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1270
+
1271
+
1272
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
1273
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
1274
+
1275
+ #------------------------------------------------------------------------------
1276
+ cdef extern from "Persistence_slices_interface.h":
1277
+ cdef cppclass C_Slicer_Matrix0_f64 "TrucPythonInterface<BackendsEnum::Matrix,false,false,double,Available_columns::INTRUSIVE_SET>":
1278
+ ctypedef double value_type
1279
+
1280
+ C_Slicer_Matrix0_f64()
1281
+
1282
+ C_Slicer_Matrix0_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[double]]&)
1283
+
1284
+ C_Slicer_Matrix0_f64& operator=(const C_Slicer_Matrix0_f64&)
1285
+
1286
+ C_Slicer_Matrix0_f64 colexical_rearange() except + nogil
1287
+
1288
+ vector[vector[pair[double, double]]] get_barcode() nogil
1289
+ void push_to(const Line[double]&) nogil
1290
+ void set_one_filtration(const vector[double]&) nogil
1291
+ int prune_above_dimension(int) except + nogil
1292
+
1293
+ vector[double] get_one_filtration()
1294
+ # void compute_persistence(vector[bool]) except+ nogil
1295
+ void compute_persistence(bool) except+ nogil # ignore_inf
1296
+ void compute_persistence() except+ nogil # ignore_inf
1297
+ uint32_t num_generators() nogil
1298
+ uint32_t num_parameters() nogil
1299
+ string to_str() nogil
1300
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
1301
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
1302
+ vector[int] get_dimensions() nogil
1303
+ vector[vector[uint]] get_boundaries() nogil
1304
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
1305
+ vector[One_critical_filtration[double]]& get_filtrations() nogil
1306
+ C_Slicer_Matrix0_i32 coarsen_on_grid(vector[vector[double]]) nogil
1307
+
1308
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1309
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1310
+
1311
+
1312
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
1313
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
1314
+
1315
+ #------------------------------------------------------------------------------
1316
+ cdef extern from "Persistence_slices_interface.h":
1317
+ cdef cppclass C_Slicer_Matrix1_f64 "TrucPythonInterface<BackendsEnum::Matrix,false,false,double,Available_columns::SMALL_VECTOR>":
1318
+ ctypedef double value_type
1319
+
1320
+ C_Slicer_Matrix1_f64()
1321
+
1322
+ C_Slicer_Matrix1_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[double]]&)
1323
+
1324
+ C_Slicer_Matrix1_f64& operator=(const C_Slicer_Matrix1_f64&)
1325
+
1326
+ C_Slicer_Matrix1_f64 colexical_rearange() except + nogil
1327
+
1328
+ vector[vector[pair[double, double]]] get_barcode() nogil
1329
+ void push_to(const Line[double]&) nogil
1330
+ void set_one_filtration(const vector[double]&) nogil
1331
+ int prune_above_dimension(int) except + nogil
1332
+
1333
+ vector[double] get_one_filtration()
1334
+ # void compute_persistence(vector[bool]) except+ nogil
1335
+ void compute_persistence(bool) except+ nogil # ignore_inf
1336
+ void compute_persistence() except+ nogil # ignore_inf
1337
+ uint32_t num_generators() nogil
1338
+ uint32_t num_parameters() nogil
1339
+ string to_str() nogil
1340
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
1341
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
1342
+ vector[int] get_dimensions() nogil
1343
+ vector[vector[uint]] get_boundaries() nogil
1344
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
1345
+ vector[One_critical_filtration[double]]& get_filtrations() nogil
1346
+ C_Slicer_Matrix1_i32 coarsen_on_grid(vector[vector[double]]) nogil
1347
+
1348
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1349
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1350
+
1351
+
1352
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
1353
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
1354
+
1355
+ #------------------------------------------------------------------------------
1356
+ cdef extern from "Persistence_slices_interface.h":
1357
+ cdef cppclass C_KSlicer_GudhiCohomology0_i32 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,true,int32_t,Available_columns::INTRUSIVE_SET>":
1358
+ ctypedef int32_t value_type
1359
+
1360
+ C_KSlicer_GudhiCohomology0_i32()
1361
+
1362
+ C_KSlicer_GudhiCohomology0_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int32_t]]&)
1363
+
1364
+ C_KSlicer_GudhiCohomology0_i32& operator=(const C_KSlicer_GudhiCohomology0_i32&)
1365
+
1366
+ C_KSlicer_GudhiCohomology0_i32 colexical_rearange() except + nogil
1367
+
1368
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
1369
+ void push_to(const Line[int32_t]&) nogil
1370
+ void set_one_filtration(const vector[int32_t]&) nogil
1371
+ int prune_above_dimension(int) except + nogil
1372
+
1373
+ vector[int32_t] get_one_filtration()
1374
+ # void compute_persistence(vector[bool]) except+ nogil
1375
+ void compute_persistence(bool) except+ nogil # ignore_inf
1376
+ void compute_persistence() except+ nogil # ignore_inf
1377
+ uint32_t num_generators() nogil
1378
+ uint32_t num_parameters() nogil
1379
+ string to_str() nogil
1380
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
1381
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
1382
+ vector[int] get_dimensions() nogil
1383
+ vector[vector[uint]] get_boundaries() nogil
1384
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
1385
+ vector[Multi_critical_filtration[int32_t]]& get_filtrations() nogil
1386
+ C_KSlicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
1387
+ void add_generator(const One_critical_filtration[int32_t] &) nogil
1388
+
1389
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1390
+
1391
+
1392
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
1393
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
1394
+
1395
+ #------------------------------------------------------------------------------
1396
+ cdef extern from "Persistence_slices_interface.h":
1397
+ cdef cppclass C_KSlicer_GudhiCohomology0_i64 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,true,int64_t,Available_columns::INTRUSIVE_SET>":
1398
+ ctypedef int64_t value_type
1399
+
1400
+ C_KSlicer_GudhiCohomology0_i64()
1401
+
1402
+ C_KSlicer_GudhiCohomology0_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[int64_t]]&)
1403
+
1404
+ C_KSlicer_GudhiCohomology0_i64& operator=(const C_KSlicer_GudhiCohomology0_i64&)
1405
+
1406
+ C_KSlicer_GudhiCohomology0_i64 colexical_rearange() except + nogil
1407
+
1408
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
1409
+ void push_to(const Line[int64_t]&) nogil
1410
+ void set_one_filtration(const vector[int64_t]&) nogil
1411
+ int prune_above_dimension(int) except + nogil
1412
+
1413
+ vector[int64_t] get_one_filtration()
1414
+ # void compute_persistence(vector[bool]) except+ nogil
1415
+ void compute_persistence(bool) except+ nogil # ignore_inf
1416
+ void compute_persistence() except+ nogil # ignore_inf
1417
+ uint32_t num_generators() nogil
1418
+ uint32_t num_parameters() nogil
1419
+ string to_str() nogil
1420
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
1421
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
1422
+ vector[int] get_dimensions() nogil
1423
+ vector[vector[uint]] get_boundaries() nogil
1424
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
1425
+ vector[Multi_critical_filtration[int64_t]]& get_filtrations() nogil
1426
+ C_KSlicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
1427
+ void add_generator(const One_critical_filtration[int64_t] &) nogil
1428
+
1429
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1430
+
1431
+
1432
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
1433
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
1434
+
1435
+ #------------------------------------------------------------------------------
1436
+ cdef extern from "Persistence_slices_interface.h":
1437
+ cdef cppclass C_KSlicer_GudhiCohomology0_f32 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,true,float,Available_columns::INTRUSIVE_SET>":
1438
+ ctypedef float value_type
1439
+
1440
+ C_KSlicer_GudhiCohomology0_f32()
1441
+
1442
+ C_KSlicer_GudhiCohomology0_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[float]]&)
1443
+
1444
+ C_KSlicer_GudhiCohomology0_f32& operator=(const C_KSlicer_GudhiCohomology0_f32&)
1445
+
1446
+ C_KSlicer_GudhiCohomology0_f32 colexical_rearange() except + nogil
1447
+
1448
+ vector[vector[pair[float, float]]] get_barcode() nogil
1449
+ void push_to(const Line[float]&) nogil
1450
+ void set_one_filtration(const vector[float]&) nogil
1451
+ int prune_above_dimension(int) except + nogil
1452
+
1453
+ vector[float] get_one_filtration()
1454
+ # void compute_persistence(vector[bool]) except+ nogil
1455
+ void compute_persistence(bool) except+ nogil # ignore_inf
1456
+ void compute_persistence() except+ nogil # ignore_inf
1457
+ uint32_t num_generators() nogil
1458
+ uint32_t num_parameters() nogil
1459
+ string to_str() nogil
1460
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
1461
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
1462
+ vector[int] get_dimensions() nogil
1463
+ vector[vector[uint]] get_boundaries() nogil
1464
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
1465
+ vector[Multi_critical_filtration[float]]& get_filtrations() nogil
1466
+ C_KSlicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[float]]) nogil
1467
+ void add_generator(const One_critical_filtration[float] &) nogil
1468
+
1469
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1470
+
1471
+
1472
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
1473
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
1474
+
1475
+ #------------------------------------------------------------------------------
1476
+ cdef extern from "Persistence_slices_interface.h":
1477
+ cdef cppclass C_KSlicer_GudhiCohomology0_f64 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,true,double,Available_columns::INTRUSIVE_SET>":
1478
+ ctypedef double value_type
1479
+
1480
+ C_KSlicer_GudhiCohomology0_f64()
1481
+
1482
+ C_KSlicer_GudhiCohomology0_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[Multi_critical_filtration[double]]&)
1483
+
1484
+ C_KSlicer_GudhiCohomology0_f64& operator=(const C_KSlicer_GudhiCohomology0_f64&)
1485
+
1486
+ C_KSlicer_GudhiCohomology0_f64 colexical_rearange() except + nogil
1487
+
1488
+ vector[vector[pair[double, double]]] get_barcode() nogil
1489
+ void push_to(const Line[double]&) nogil
1490
+ void set_one_filtration(const vector[double]&) nogil
1491
+ int prune_above_dimension(int) except + nogil
1492
+
1493
+ vector[double] get_one_filtration()
1494
+ # void compute_persistence(vector[bool]) except+ nogil
1495
+ void compute_persistence(bool) except+ nogil # ignore_inf
1496
+ void compute_persistence() except+ nogil # ignore_inf
1497
+ uint32_t num_generators() nogil
1498
+ uint32_t num_parameters() nogil
1499
+ string to_str() nogil
1500
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
1501
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
1502
+ vector[int] get_dimensions() nogil
1503
+ vector[vector[uint]] get_boundaries() nogil
1504
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
1505
+ vector[Multi_critical_filtration[double]]& get_filtrations() nogil
1506
+ C_KSlicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[double]]) nogil
1507
+ void add_generator(const One_critical_filtration[double] &) nogil
1508
+
1509
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1510
+
1511
+
1512
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
1513
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
1514
+
1515
+ #------------------------------------------------------------------------------
1516
+ cdef extern from "Persistence_slices_interface.h":
1517
+ cdef cppclass C_Slicer_GudhiCohomology0_i32 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,false,int32_t,Available_columns::INTRUSIVE_SET>":
1518
+ ctypedef int32_t value_type
1519
+
1520
+ C_Slicer_GudhiCohomology0_i32()
1521
+
1522
+ C_Slicer_GudhiCohomology0_i32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int32_t]]&)
1523
+
1524
+ C_Slicer_GudhiCohomology0_i32& operator=(const C_Slicer_GudhiCohomology0_i32&)
1525
+
1526
+ C_Slicer_GudhiCohomology0_i32 colexical_rearange() except + nogil
1527
+
1528
+ vector[vector[pair[int32_t, int32_t]]] get_barcode() nogil
1529
+ void push_to(const Line[int32_t]&) nogil
1530
+ void set_one_filtration(const vector[int32_t]&) nogil
1531
+ int prune_above_dimension(int) except + nogil
1532
+
1533
+ vector[int32_t] get_one_filtration()
1534
+ # void compute_persistence(vector[bool]) except+ nogil
1535
+ void compute_persistence(bool) except+ nogil # ignore_inf
1536
+ void compute_persistence() except+ nogil # ignore_inf
1537
+ uint32_t num_generators() nogil
1538
+ uint32_t num_parameters() nogil
1539
+ string to_str() nogil
1540
+ pair[One_critical_filtration[int32_t], One_critical_filtration[int32_t]] get_bounding_box() except + nogil
1541
+ vector[One_critical_filtration[int32_t]] get_filtration_values() nogil
1542
+ vector[int] get_dimensions() nogil
1543
+ vector[vector[uint]] get_boundaries() nogil
1544
+ void coarsen_on_grid_inplace(vector[vector[int32_t]], bool) nogil
1545
+ vector[One_critical_filtration[int32_t]]& get_filtrations() nogil
1546
+ C_Slicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[int32_t]]) nogil
1547
+
1548
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1549
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1550
+
1551
+
1552
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[vector[int32_t]], bool) nogil
1553
+ vector[vector[vector[pair[int32_t, int32_t]]]] persistence_on_lines(vector[pair[vector[int32_t],vector[int32_t]]],bool) nogil
1554
+
1555
+ #------------------------------------------------------------------------------
1556
+ cdef extern from "Persistence_slices_interface.h":
1557
+ cdef cppclass C_Slicer_GudhiCohomology0_i64 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,false,int64_t,Available_columns::INTRUSIVE_SET>":
1558
+ ctypedef int64_t value_type
1559
+
1560
+ C_Slicer_GudhiCohomology0_i64()
1561
+
1562
+ C_Slicer_GudhiCohomology0_i64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[int64_t]]&)
1563
+
1564
+ C_Slicer_GudhiCohomology0_i64& operator=(const C_Slicer_GudhiCohomology0_i64&)
1565
+
1566
+ C_Slicer_GudhiCohomology0_i64 colexical_rearange() except + nogil
1567
+
1568
+ vector[vector[pair[int64_t, int64_t]]] get_barcode() nogil
1569
+ void push_to(const Line[int64_t]&) nogil
1570
+ void set_one_filtration(const vector[int64_t]&) nogil
1571
+ int prune_above_dimension(int) except + nogil
1572
+
1573
+ vector[int64_t] get_one_filtration()
1574
+ # void compute_persistence(vector[bool]) except+ nogil
1575
+ void compute_persistence(bool) except+ nogil # ignore_inf
1576
+ void compute_persistence() except+ nogil # ignore_inf
1577
+ uint32_t num_generators() nogil
1578
+ uint32_t num_parameters() nogil
1579
+ string to_str() nogil
1580
+ pair[One_critical_filtration[int64_t], One_critical_filtration[int64_t]] get_bounding_box() except + nogil
1581
+ vector[One_critical_filtration[int64_t]] get_filtration_values() nogil
1582
+ vector[int] get_dimensions() nogil
1583
+ vector[vector[uint]] get_boundaries() nogil
1584
+ void coarsen_on_grid_inplace(vector[vector[int64_t]], bool) nogil
1585
+ vector[One_critical_filtration[int64_t]]& get_filtrations() nogil
1586
+ C_Slicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[int64_t]]) nogil
1587
+
1588
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1589
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1590
+
1591
+
1592
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[vector[int64_t]], bool) nogil
1593
+ vector[vector[vector[pair[int64_t, int64_t]]]] persistence_on_lines(vector[pair[vector[int64_t],vector[int64_t]]],bool) nogil
1594
+
1595
+ #------------------------------------------------------------------------------
1596
+ cdef extern from "Persistence_slices_interface.h":
1597
+ cdef cppclass C_Slicer_GudhiCohomology0_f32 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,false,float,Available_columns::INTRUSIVE_SET>":
1598
+ ctypedef float value_type
1599
+
1600
+ C_Slicer_GudhiCohomology0_f32()
1601
+
1602
+ C_Slicer_GudhiCohomology0_f32(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[float]]&)
1603
+
1604
+ C_Slicer_GudhiCohomology0_f32& operator=(const C_Slicer_GudhiCohomology0_f32&)
1605
+
1606
+ C_Slicer_GudhiCohomology0_f32 colexical_rearange() except + nogil
1607
+
1608
+ vector[vector[pair[float, float]]] get_barcode() nogil
1609
+ void push_to(const Line[float]&) nogil
1610
+ void set_one_filtration(const vector[float]&) nogil
1611
+ int prune_above_dimension(int) except + nogil
1612
+
1613
+ vector[float] get_one_filtration()
1614
+ # void compute_persistence(vector[bool]) except+ nogil
1615
+ void compute_persistence(bool) except+ nogil # ignore_inf
1616
+ void compute_persistence() except+ nogil # ignore_inf
1617
+ uint32_t num_generators() nogil
1618
+ uint32_t num_parameters() nogil
1619
+ string to_str() nogil
1620
+ pair[One_critical_filtration[float], One_critical_filtration[float]] get_bounding_box() except + nogil
1621
+ vector[One_critical_filtration[float]] get_filtration_values() nogil
1622
+ vector[int] get_dimensions() nogil
1623
+ vector[vector[uint]] get_boundaries() nogil
1624
+ void coarsen_on_grid_inplace(vector[vector[float]], bool) nogil
1625
+ vector[One_critical_filtration[float]]& get_filtrations() nogil
1626
+ C_Slicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[float]]) nogil
1627
+
1628
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1629
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1630
+
1631
+
1632
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[vector[float]], bool) nogil
1633
+ vector[vector[vector[pair[float, float]]]] persistence_on_lines(vector[pair[vector[float],vector[float]]],bool) nogil
1634
+
1635
+ #------------------------------------------------------------------------------
1636
+ cdef extern from "Persistence_slices_interface.h":
1637
+ cdef cppclass C_Slicer_GudhiCohomology0_f64 "TrucPythonInterface<BackendsEnum::GudhiCohomology,false,false,double,Available_columns::INTRUSIVE_SET>":
1638
+ ctypedef double value_type
1639
+
1640
+ C_Slicer_GudhiCohomology0_f64()
1641
+
1642
+ C_Slicer_GudhiCohomology0_f64(const vector[vector[unsigned int]]&, const vector[int]&, const vector[One_critical_filtration[double]]&)
1643
+
1644
+ C_Slicer_GudhiCohomology0_f64& operator=(const C_Slicer_GudhiCohomology0_f64&)
1645
+
1646
+ C_Slicer_GudhiCohomology0_f64 colexical_rearange() except + nogil
1647
+
1648
+ vector[vector[pair[double, double]]] get_barcode() nogil
1649
+ void push_to(const Line[double]&) nogil
1650
+ void set_one_filtration(const vector[double]&) nogil
1651
+ int prune_above_dimension(int) except + nogil
1652
+
1653
+ vector[double] get_one_filtration()
1654
+ # void compute_persistence(vector[bool]) except+ nogil
1655
+ void compute_persistence(bool) except+ nogil # ignore_inf
1656
+ void compute_persistence() except+ nogil # ignore_inf
1657
+ uint32_t num_generators() nogil
1658
+ uint32_t num_parameters() nogil
1659
+ string to_str() nogil
1660
+ pair[One_critical_filtration[double], One_critical_filtration[double]] get_bounding_box() except + nogil
1661
+ vector[One_critical_filtration[double]] get_filtration_values() nogil
1662
+ vector[int] get_dimensions() nogil
1663
+ vector[vector[uint]] get_boundaries() nogil
1664
+ void coarsen_on_grid_inplace(vector[vector[double]], bool) nogil
1665
+ vector[One_critical_filtration[double]]& get_filtrations() nogil
1666
+ C_Slicer_GudhiCohomology0_i32 coarsen_on_grid(vector[vector[double]]) nogil
1667
+
1668
+ void write_to_scc_file(const string&, int, int, bool, bool, bool, bool) nogil
1669
+ void build_from_scc_file(const string&, bool, bool, int) except + nogil
1670
+
1671
+
1672
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[vector[double]], bool) nogil
1673
+ vector[vector[vector[pair[double, double]]]] persistence_on_lines(vector[pair[vector[double],vector[double]]],bool) nogil
1674
+
1675
+
1676
+
1677
+ #### MMA Stuff
1678
+
1679
+ from multipers.mma_structures cimport Module
1680
+ cdef extern from "multiparameter_module_approximation/approximation.h" namespace "Gudhi::multiparameter::mma":
1681
+ Module[float] multiparameter_module_approximation(C_KSlicer_Matrix0_vine_f32&, One_critical_filtration[float]&, float, Box[float]&, bool, bool, bool) except + nogil
1682
+ Module[float] multiparameter_module_approximation(C_KSlicer_Matrix1_vine_f32&, One_critical_filtration[float]&, float, Box[float]&, bool, bool, bool) except + nogil
1683
+ Module[double] multiparameter_module_approximation(C_KSlicer_Matrix0_vine_f64&, One_critical_filtration[double]&, double, Box[double]&, bool, bool, bool) except + nogil
1684
+ Module[double] multiparameter_module_approximation(C_KSlicer_Matrix1_vine_f64&, One_critical_filtration[double]&, double, Box[double]&, bool, bool, bool) except + nogil
1685
+ Module[float] multiparameter_module_approximation(C_Slicer_Matrix0_vine_f32&, One_critical_filtration[float]&, float, Box[float]&, bool, bool, bool) except + nogil
1686
+ Module[float] multiparameter_module_approximation(C_Slicer_Matrix1_vine_f32&, One_critical_filtration[float]&, float, Box[float]&, bool, bool, bool) except + nogil
1687
+ Module[double] multiparameter_module_approximation(C_Slicer_Matrix0_vine_f64&, One_critical_filtration[double]&, double, Box[double]&, bool, bool, bool) except + nogil
1688
+ Module[double] multiparameter_module_approximation(C_Slicer_Matrix1_vine_f64&, One_critical_filtration[double]&, double, Box[double]&, bool, bool, bool) except + nogil
1689
+ pass
1690
+
1691
+
1692
+
1693
+
1694
+ import multipers.slicer as mps
1695
+ from cython.operator cimport dereference
1696
+ cdef inline Module[float] _multiparameter_module_approximation_f32(object slicer, One_critical_filtration[float] direction, float max_error, Box[float] box, bool threshold, bool complete, bool verbose):
1697
+ import multipers.slicer as mps
1698
+ cdef intptr_t slicer_ptr = <intptr_t>(slicer.get_ptr())
1699
+ cdef Module[float] mod
1700
+ if False:
1701
+ pass
1702
+ elif isinstance(slicer, mps._KSlicer_Matrix0_vine_f32):
1703
+ with nogil:
1704
+ mod = multiparameter_module_approximation(dereference(<C_KSlicer_Matrix0_vine_f32*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1705
+ return mod
1706
+ elif isinstance(slicer, mps._KSlicer_Matrix1_vine_f32):
1707
+ with nogil:
1708
+ mod = multiparameter_module_approximation(dereference(<C_KSlicer_Matrix1_vine_f32*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1709
+ return mod
1710
+ elif isinstance(slicer, mps._Slicer_Matrix0_vine_f32):
1711
+ with nogil:
1712
+ mod = multiparameter_module_approximation(dereference(<C_Slicer_Matrix0_vine_f32*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1713
+ return mod
1714
+ elif isinstance(slicer, mps._Slicer_Matrix1_vine_f32):
1715
+ with nogil:
1716
+ mod = multiparameter_module_approximation(dereference(<C_Slicer_Matrix1_vine_f32*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1717
+ return mod
1718
+ else:
1719
+ raise ValueError(f"Unsupported slicer type {type(slicer)}")
1720
+ cdef inline Module[double] _multiparameter_module_approximation_f64(object slicer, One_critical_filtration[double] direction, double max_error, Box[double] box, bool threshold, bool complete, bool verbose):
1721
+ import multipers.slicer as mps
1722
+ cdef intptr_t slicer_ptr = <intptr_t>(slicer.get_ptr())
1723
+ cdef Module[double] mod
1724
+ if False:
1725
+ pass
1726
+ elif isinstance(slicer, mps._KSlicer_Matrix0_vine_f64):
1727
+ with nogil:
1728
+ mod = multiparameter_module_approximation(dereference(<C_KSlicer_Matrix0_vine_f64*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1729
+ return mod
1730
+ elif isinstance(slicer, mps._KSlicer_Matrix1_vine_f64):
1731
+ with nogil:
1732
+ mod = multiparameter_module_approximation(dereference(<C_KSlicer_Matrix1_vine_f64*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1733
+ return mod
1734
+ elif isinstance(slicer, mps._Slicer_Matrix0_vine_f64):
1735
+ with nogil:
1736
+ mod = multiparameter_module_approximation(dereference(<C_Slicer_Matrix0_vine_f64*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1737
+ return mod
1738
+ elif isinstance(slicer, mps._Slicer_Matrix1_vine_f64):
1739
+ with nogil:
1740
+ mod = multiparameter_module_approximation(dereference(<C_Slicer_Matrix1_vine_f64*>(slicer_ptr)), direction, max_error, box, threshold, complete, verbose)
1741
+ return mod
1742
+ else:
1743
+ raise ValueError(f"Unsupported slicer type {type(slicer)}")
1744
+
1745
+ ###### RANK INVARIANT
1746
+ from libc.stdint cimport intptr_t, uint16_t, uint32_t, int32_t, int16_t, int8_t
1747
+ ctypedef int32_t tensor_dtype
1748
+ ctypedef int32_t indices_type
1749
+ python_indices_type=np.int32
1750
+ python_tensor_dtype = np.int32
1751
+
1752
+
1753
+
1754
+ ctypedef pair[vector[vector[indices_type]], vector[tensor_dtype]] signed_measure_type
1755
+
1756
+
1757
+
1758
+ cdef extern from "multi_parameter_rank_invariant/rank_invariant.h" namespace "Gudhi::multiparameter::rank_invariant":
1759
+ ## from slicers
1760
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1761
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1762
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1763
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1764
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1765
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1766
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1767
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1768
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1769
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1770
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1771
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1772
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1773
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1774
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1775
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1776
+ void compute_rank_invariant_python(C_Slicer_Matrix0_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1777
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1778
+ void compute_rank_invariant_python(C_Slicer_Matrix1_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1779
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1780
+ void compute_rank_invariant_python(C_Slicer_Matrix0_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1781
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1782
+ void compute_rank_invariant_python(C_Slicer_Matrix1_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1783
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1784
+ void compute_rank_invariant_python(C_Slicer_Matrix0_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1785
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1786
+ void compute_rank_invariant_python(C_Slicer_Matrix1_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1787
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1788
+ void compute_rank_invariant_python(C_Slicer_Matrix0_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1789
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1790
+ void compute_rank_invariant_python(C_Slicer_Matrix1_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1791
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1792
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1793
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1794
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1795
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1796
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1797
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1798
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1799
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1800
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1801
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1802
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1803
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1804
+ void compute_rank_invariant_python(C_KSlicer_Matrix0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1805
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1806
+ void compute_rank_invariant_python(C_KSlicer_Matrix1_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1807
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_Matrix1_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1808
+ void compute_rank_invariant_python(C_Slicer_Matrix0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1809
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1810
+ void compute_rank_invariant_python(C_Slicer_Matrix1_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1811
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1812
+ void compute_rank_invariant_python(C_Slicer_Matrix0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1813
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1814
+ void compute_rank_invariant_python(C_Slicer_Matrix1_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1815
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1816
+ void compute_rank_invariant_python(C_Slicer_Matrix0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1817
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1818
+ void compute_rank_invariant_python(C_Slicer_Matrix1_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1819
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1820
+ void compute_rank_invariant_python(C_Slicer_Matrix0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1821
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1822
+ void compute_rank_invariant_python(C_Slicer_Matrix1_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1823
+ signed_measure_type compute_rank_signed_measure(C_Slicer_Matrix1_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1824
+ void compute_rank_invariant_python(C_KSlicer_GudhiCohomology0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1825
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_GudhiCohomology0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1826
+ void compute_rank_invariant_python(C_KSlicer_GudhiCohomology0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1827
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_GudhiCohomology0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1828
+ void compute_rank_invariant_python(C_KSlicer_GudhiCohomology0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1829
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_GudhiCohomology0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1830
+ void compute_rank_invariant_python(C_KSlicer_GudhiCohomology0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1831
+ signed_measure_type compute_rank_signed_measure(C_KSlicer_GudhiCohomology0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1832
+ void compute_rank_invariant_python(C_Slicer_GudhiCohomology0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1833
+ signed_measure_type compute_rank_signed_measure(C_Slicer_GudhiCohomology0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1834
+ void compute_rank_invariant_python(C_Slicer_GudhiCohomology0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1835
+ signed_measure_type compute_rank_signed_measure(C_Slicer_GudhiCohomology0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1836
+ void compute_rank_invariant_python(C_Slicer_GudhiCohomology0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1837
+ signed_measure_type compute_rank_signed_measure(C_Slicer_GudhiCohomology0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1838
+ void compute_rank_invariant_python(C_Slicer_GudhiCohomology0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool ignore_inf) except + nogil
1839
+ signed_measure_type compute_rank_signed_measure(C_Slicer_GudhiCohomology0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], indices_type, bool verbose, bool ignore_inf) except + nogil
1840
+
1841
+
1842
+
1843
+
1844
+
1845
+ cdef inline void _compute_rank_invariant(object slicer, tensor_dtype* container_ptr, vector[indices_type] c_grid_shape, vector[indices_type] degrees, int n_jobs, bool ignore_inf):
1846
+ import multipers.slicer as mps
1847
+ cdef intptr_t slicer_ptr = <intptr_t>(slicer.get_ptr())
1848
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_i32):
1849
+ with nogil:
1850
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1851
+ return
1852
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_i32):
1853
+ with nogil:
1854
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1855
+ return
1856
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_i64):
1857
+ with nogil:
1858
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1859
+ return
1860
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_i64):
1861
+ with nogil:
1862
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1863
+ return
1864
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_f32):
1865
+ with nogil:
1866
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1867
+ return
1868
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_f32):
1869
+ with nogil:
1870
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1871
+ return
1872
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_f64):
1873
+ with nogil:
1874
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1875
+ return
1876
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_f64):
1877
+ with nogil:
1878
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1879
+ return
1880
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_i32):
1881
+ with nogil:
1882
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1883
+ return
1884
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_i32):
1885
+ with nogil:
1886
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1887
+ return
1888
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_i64):
1889
+ with nogil:
1890
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1891
+ return
1892
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_i64):
1893
+ with nogil:
1894
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1895
+ return
1896
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_f32):
1897
+ with nogil:
1898
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1899
+ return
1900
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_f32):
1901
+ with nogil:
1902
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1903
+ return
1904
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_f64):
1905
+ with nogil:
1906
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1907
+ return
1908
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_f64):
1909
+ with nogil:
1910
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1911
+ return
1912
+ if isinstance(slicer, mps._KSlicer_Matrix0_i32):
1913
+ with nogil:
1914
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1915
+ return
1916
+ if isinstance(slicer, mps._KSlicer_Matrix1_i32):
1917
+ with nogil:
1918
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1919
+ return
1920
+ if isinstance(slicer, mps._KSlicer_Matrix0_i64):
1921
+ with nogil:
1922
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1923
+ return
1924
+ if isinstance(slicer, mps._KSlicer_Matrix1_i64):
1925
+ with nogil:
1926
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1927
+ return
1928
+ if isinstance(slicer, mps._KSlicer_Matrix0_f32):
1929
+ with nogil:
1930
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1931
+ return
1932
+ if isinstance(slicer, mps._KSlicer_Matrix1_f32):
1933
+ with nogil:
1934
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1935
+ return
1936
+ if isinstance(slicer, mps._KSlicer_Matrix0_f64):
1937
+ with nogil:
1938
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1939
+ return
1940
+ if isinstance(slicer, mps._KSlicer_Matrix1_f64):
1941
+ with nogil:
1942
+ compute_rank_invariant_python(dereference(<C_KSlicer_Matrix1_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1943
+ return
1944
+ if isinstance(slicer, mps._Slicer_Matrix0_i32):
1945
+ with nogil:
1946
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1947
+ return
1948
+ if isinstance(slicer, mps._Slicer_Matrix1_i32):
1949
+ with nogil:
1950
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1951
+ return
1952
+ if isinstance(slicer, mps._Slicer_Matrix0_i64):
1953
+ with nogil:
1954
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1955
+ return
1956
+ if isinstance(slicer, mps._Slicer_Matrix1_i64):
1957
+ with nogil:
1958
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1959
+ return
1960
+ if isinstance(slicer, mps._Slicer_Matrix0_f32):
1961
+ with nogil:
1962
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1963
+ return
1964
+ if isinstance(slicer, mps._Slicer_Matrix1_f32):
1965
+ with nogil:
1966
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1967
+ return
1968
+ if isinstance(slicer, mps._Slicer_Matrix0_f64):
1969
+ with nogil:
1970
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1971
+ return
1972
+ if isinstance(slicer, mps._Slicer_Matrix1_f64):
1973
+ with nogil:
1974
+ compute_rank_invariant_python(dereference(<C_Slicer_Matrix1_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1975
+ return
1976
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_i32):
1977
+ with nogil:
1978
+ compute_rank_invariant_python(dereference(<C_KSlicer_GudhiCohomology0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1979
+ return
1980
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_i64):
1981
+ with nogil:
1982
+ compute_rank_invariant_python(dereference(<C_KSlicer_GudhiCohomology0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1983
+ return
1984
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_f32):
1985
+ with nogil:
1986
+ compute_rank_invariant_python(dereference(<C_KSlicer_GudhiCohomology0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1987
+ return
1988
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_f64):
1989
+ with nogil:
1990
+ compute_rank_invariant_python(dereference(<C_KSlicer_GudhiCohomology0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1991
+ return
1992
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_i32):
1993
+ with nogil:
1994
+ compute_rank_invariant_python(dereference(<C_Slicer_GudhiCohomology0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1995
+ return
1996
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_i64):
1997
+ with nogil:
1998
+ compute_rank_invariant_python(dereference(<C_Slicer_GudhiCohomology0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
1999
+ return
2000
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_f32):
2001
+ with nogil:
2002
+ compute_rank_invariant_python(dereference(<C_Slicer_GudhiCohomology0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
2003
+ return
2004
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_f64):
2005
+ with nogil:
2006
+ compute_rank_invariant_python(dereference(<C_Slicer_GudhiCohomology0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs,ignore_inf)
2007
+ return
2008
+ raise ValueError(f"Unsupported slicer type {type(slicer)}")
2009
+
2010
+
2011
+
2012
+ cdef inline _compute_rank_sm(object slicer, tensor_dtype* container_ptr, vector[indices_type] c_grid_shape, vector[indices_type] degrees, int n_jobs, bool verbose, bool ignore_inf):
2013
+ import multipers.slicer as mps
2014
+ cdef intptr_t slicer_ptr = <intptr_t>(slicer.get_ptr())
2015
+ cdef signed_measure_type sm
2016
+ cdef cnp.ndarray[indices_type, ndim=2] pts
2017
+ cdef cnp.ndarray[tensor_dtype, ndim=1] weights
2018
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_i32):
2019
+ with nogil:
2020
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2021
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2022
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2023
+ return (pts,weights)
2024
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_i32):
2025
+ with nogil:
2026
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2027
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2028
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2029
+ return (pts,weights)
2030
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_i64):
2031
+ with nogil:
2032
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2033
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2034
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2035
+ return (pts,weights)
2036
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_i64):
2037
+ with nogil:
2038
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2039
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2040
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2041
+ return (pts,weights)
2042
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_f32):
2043
+ with nogil:
2044
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2045
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2046
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2047
+ return (pts,weights)
2048
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_f32):
2049
+ with nogil:
2050
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2051
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2052
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2053
+ return (pts,weights)
2054
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_f64):
2055
+ with nogil:
2056
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2057
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2058
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2059
+ return (pts,weights)
2060
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_f64):
2061
+ with nogil:
2062
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2063
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2064
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2065
+ return (pts,weights)
2066
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_i32):
2067
+ with nogil:
2068
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2069
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2070
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2071
+ return (pts,weights)
2072
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_i32):
2073
+ with nogil:
2074
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2075
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2076
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2077
+ return (pts,weights)
2078
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_i64):
2079
+ with nogil:
2080
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2081
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2082
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2083
+ return (pts,weights)
2084
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_i64):
2085
+ with nogil:
2086
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2087
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2088
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2089
+ return (pts,weights)
2090
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_f32):
2091
+ with nogil:
2092
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2093
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2094
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2095
+ return (pts,weights)
2096
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_f32):
2097
+ with nogil:
2098
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2099
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2100
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2101
+ return (pts,weights)
2102
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_f64):
2103
+ with nogil:
2104
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2105
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2106
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2107
+ return (pts,weights)
2108
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_f64):
2109
+ with nogil:
2110
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2111
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2112
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2113
+ return (pts,weights)
2114
+ if isinstance(slicer, mps._KSlicer_Matrix0_i32):
2115
+ with nogil:
2116
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2117
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2118
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2119
+ return (pts,weights)
2120
+ if isinstance(slicer, mps._KSlicer_Matrix1_i32):
2121
+ with nogil:
2122
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2123
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2124
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2125
+ return (pts,weights)
2126
+ if isinstance(slicer, mps._KSlicer_Matrix0_i64):
2127
+ with nogil:
2128
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2129
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2130
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2131
+ return (pts,weights)
2132
+ if isinstance(slicer, mps._KSlicer_Matrix1_i64):
2133
+ with nogil:
2134
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2135
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2136
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2137
+ return (pts,weights)
2138
+ if isinstance(slicer, mps._KSlicer_Matrix0_f32):
2139
+ with nogil:
2140
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2141
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2142
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2143
+ return (pts,weights)
2144
+ if isinstance(slicer, mps._KSlicer_Matrix1_f32):
2145
+ with nogil:
2146
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2147
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2148
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2149
+ return (pts,weights)
2150
+ if isinstance(slicer, mps._KSlicer_Matrix0_f64):
2151
+ with nogil:
2152
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2153
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2154
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2155
+ return (pts,weights)
2156
+ if isinstance(slicer, mps._KSlicer_Matrix1_f64):
2157
+ with nogil:
2158
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_Matrix1_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2159
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2160
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2161
+ return (pts,weights)
2162
+ if isinstance(slicer, mps._Slicer_Matrix0_i32):
2163
+ with nogil:
2164
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2165
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2166
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2167
+ return (pts,weights)
2168
+ if isinstance(slicer, mps._Slicer_Matrix1_i32):
2169
+ with nogil:
2170
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2171
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2172
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2173
+ return (pts,weights)
2174
+ if isinstance(slicer, mps._Slicer_Matrix0_i64):
2175
+ with nogil:
2176
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2177
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2178
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2179
+ return (pts,weights)
2180
+ if isinstance(slicer, mps._Slicer_Matrix1_i64):
2181
+ with nogil:
2182
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2183
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2184
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2185
+ return (pts,weights)
2186
+ if isinstance(slicer, mps._Slicer_Matrix0_f32):
2187
+ with nogil:
2188
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2189
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2190
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2191
+ return (pts,weights)
2192
+ if isinstance(slicer, mps._Slicer_Matrix1_f32):
2193
+ with nogil:
2194
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2195
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2196
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2197
+ return (pts,weights)
2198
+ if isinstance(slicer, mps._Slicer_Matrix0_f64):
2199
+ with nogil:
2200
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2201
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2202
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2203
+ return (pts,weights)
2204
+ if isinstance(slicer, mps._Slicer_Matrix1_f64):
2205
+ with nogil:
2206
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_Matrix1_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2207
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2208
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2209
+ return (pts,weights)
2210
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_i32):
2211
+ with nogil:
2212
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2213
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2214
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2215
+ return (pts,weights)
2216
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_i64):
2217
+ with nogil:
2218
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2219
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2220
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2221
+ return (pts,weights)
2222
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_f32):
2223
+ with nogil:
2224
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2225
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2226
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2227
+ return (pts,weights)
2228
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_f64):
2229
+ with nogil:
2230
+ sm = compute_rank_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2231
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2232
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2233
+ return (pts,weights)
2234
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_i32):
2235
+ with nogil:
2236
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_GudhiCohomology0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2237
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2238
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2239
+ return (pts,weights)
2240
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_i64):
2241
+ with nogil:
2242
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_GudhiCohomology0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2243
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2244
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2245
+ return (pts,weights)
2246
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_f32):
2247
+ with nogil:
2248
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_GudhiCohomology0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2249
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2250
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2251
+ return (pts,weights)
2252
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_f64):
2253
+ with nogil:
2254
+ sm = compute_rank_signed_measure(dereference(<C_Slicer_GudhiCohomology0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, n_jobs, verbose, ignore_inf)
2255
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2256
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2257
+ return (pts,weights)
2258
+ raise ValueError(f"Unsupported slicer type {type(slicer)}")
2259
+
2260
+
2261
+
2262
+ #### Hilbert Function
2263
+
2264
+ cdef extern from "multi_parameter_rank_invariant/hilbert_function.h" namespace "Gudhi::multiparameter::hilbert_function":
2265
+ ## from slicers
2266
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2267
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2268
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2269
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2270
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2271
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2272
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2273
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2274
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2275
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_vine_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2276
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2277
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_vine_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2278
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2279
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_vine_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2280
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2281
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_vine_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2282
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2283
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2284
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2285
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2286
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2287
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2288
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2289
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_Matrix1_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2290
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2291
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2292
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2293
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2294
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2295
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2296
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2297
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_Matrix1_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2298
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_GudhiCohomology0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2299
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_GudhiCohomology0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2300
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_GudhiCohomology0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2301
+ signed_measure_type get_hilbert_signed_measure(C_KSlicer_GudhiCohomology0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2302
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_GudhiCohomology0_i32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2303
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_GudhiCohomology0_i64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2304
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_GudhiCohomology0_f32&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2305
+ signed_measure_type get_hilbert_signed_measure(C_Slicer_GudhiCohomology0_f64&, tensor_dtype* , const vector[indices_type], const vector[indices_type], bool zero_pad,indices_type n_jobs, bool verbose, bool ignore_inf) except + nogil
2306
+ cdef inline _compute_hilbert_sm(object slicer, tensor_dtype* container_ptr, vector[indices_type] c_grid_shape, vector[indices_type] degrees, int n_jobs, bool verbose,bool zero_pad, bool ignore_inf):
2307
+ import multipers.slicer as mps
2308
+ cdef intptr_t slicer_ptr = <intptr_t>(slicer.get_ptr())
2309
+ cdef signed_measure_type sm
2310
+ cdef cnp.ndarray[indices_type, ndim=2] pts
2311
+ cdef cnp.ndarray[tensor_dtype, ndim=1] weights
2312
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_i32):
2313
+ with nogil:
2314
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2315
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2316
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2317
+ return (pts,weights)
2318
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_i32):
2319
+ with nogil:
2320
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2321
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2322
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2323
+ return (pts,weights)
2324
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_i64):
2325
+ with nogil:
2326
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2327
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2328
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2329
+ return (pts,weights)
2330
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_i64):
2331
+ with nogil:
2332
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2333
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2334
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2335
+ return (pts,weights)
2336
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_f32):
2337
+ with nogil:
2338
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2339
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2340
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2341
+ return (pts,weights)
2342
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_f32):
2343
+ with nogil:
2344
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2345
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2346
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2347
+ return (pts,weights)
2348
+ if isinstance(slicer, mps._KSlicer_Matrix0_vine_f64):
2349
+ with nogil:
2350
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2351
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2352
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2353
+ return (pts,weights)
2354
+ if isinstance(slicer, mps._KSlicer_Matrix1_vine_f64):
2355
+ with nogil:
2356
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2357
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2358
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2359
+ return (pts,weights)
2360
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_i32):
2361
+ with nogil:
2362
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2363
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2364
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2365
+ return (pts,weights)
2366
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_i32):
2367
+ with nogil:
2368
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_vine_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2369
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2370
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2371
+ return (pts,weights)
2372
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_i64):
2373
+ with nogil:
2374
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2375
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2376
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2377
+ return (pts,weights)
2378
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_i64):
2379
+ with nogil:
2380
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_vine_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2381
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2382
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2383
+ return (pts,weights)
2384
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_f32):
2385
+ with nogil:
2386
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2387
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2388
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2389
+ return (pts,weights)
2390
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_f32):
2391
+ with nogil:
2392
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_vine_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2393
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2394
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2395
+ return (pts,weights)
2396
+ if isinstance(slicer, mps._Slicer_Matrix0_vine_f64):
2397
+ with nogil:
2398
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2399
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2400
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2401
+ return (pts,weights)
2402
+ if isinstance(slicer, mps._Slicer_Matrix1_vine_f64):
2403
+ with nogil:
2404
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_vine_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2405
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2406
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2407
+ return (pts,weights)
2408
+ if isinstance(slicer, mps._KSlicer_Matrix0_i32):
2409
+ with nogil:
2410
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2411
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2412
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2413
+ return (pts,weights)
2414
+ if isinstance(slicer, mps._KSlicer_Matrix1_i32):
2415
+ with nogil:
2416
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2417
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2418
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2419
+ return (pts,weights)
2420
+ if isinstance(slicer, mps._KSlicer_Matrix0_i64):
2421
+ with nogil:
2422
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2423
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2424
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2425
+ return (pts,weights)
2426
+ if isinstance(slicer, mps._KSlicer_Matrix1_i64):
2427
+ with nogil:
2428
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2429
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2430
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2431
+ return (pts,weights)
2432
+ if isinstance(slicer, mps._KSlicer_Matrix0_f32):
2433
+ with nogil:
2434
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2435
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2436
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2437
+ return (pts,weights)
2438
+ if isinstance(slicer, mps._KSlicer_Matrix1_f32):
2439
+ with nogil:
2440
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2441
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2442
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2443
+ return (pts,weights)
2444
+ if isinstance(slicer, mps._KSlicer_Matrix0_f64):
2445
+ with nogil:
2446
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2447
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2448
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2449
+ return (pts,weights)
2450
+ if isinstance(slicer, mps._KSlicer_Matrix1_f64):
2451
+ with nogil:
2452
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_Matrix1_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2453
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2454
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2455
+ return (pts,weights)
2456
+ if isinstance(slicer, mps._Slicer_Matrix0_i32):
2457
+ with nogil:
2458
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2459
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2460
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2461
+ return (pts,weights)
2462
+ if isinstance(slicer, mps._Slicer_Matrix1_i32):
2463
+ with nogil:
2464
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2465
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2466
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2467
+ return (pts,weights)
2468
+ if isinstance(slicer, mps._Slicer_Matrix0_i64):
2469
+ with nogil:
2470
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2471
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2472
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2473
+ return (pts,weights)
2474
+ if isinstance(slicer, mps._Slicer_Matrix1_i64):
2475
+ with nogil:
2476
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2477
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2478
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2479
+ return (pts,weights)
2480
+ if isinstance(slicer, mps._Slicer_Matrix0_f32):
2481
+ with nogil:
2482
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2483
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2484
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2485
+ return (pts,weights)
2486
+ if isinstance(slicer, mps._Slicer_Matrix1_f32):
2487
+ with nogil:
2488
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2489
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2490
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2491
+ return (pts,weights)
2492
+ if isinstance(slicer, mps._Slicer_Matrix0_f64):
2493
+ with nogil:
2494
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2495
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2496
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2497
+ return (pts,weights)
2498
+ if isinstance(slicer, mps._Slicer_Matrix1_f64):
2499
+ with nogil:
2500
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_Matrix1_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2501
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2502
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2503
+ return (pts,weights)
2504
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_i32):
2505
+ with nogil:
2506
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2507
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2508
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2509
+ return (pts,weights)
2510
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_i64):
2511
+ with nogil:
2512
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2513
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2514
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2515
+ return (pts,weights)
2516
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_f32):
2517
+ with nogil:
2518
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2519
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2520
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2521
+ return (pts,weights)
2522
+ if isinstance(slicer, mps._KSlicer_GudhiCohomology0_f64):
2523
+ with nogil:
2524
+ sm = get_hilbert_signed_measure(dereference(<C_KSlicer_GudhiCohomology0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2525
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2526
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2527
+ return (pts,weights)
2528
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_i32):
2529
+ with nogil:
2530
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_GudhiCohomology0_i32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2531
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2532
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2533
+ return (pts,weights)
2534
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_i64):
2535
+ with nogil:
2536
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_GudhiCohomology0_i64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2537
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2538
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2539
+ return (pts,weights)
2540
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_f32):
2541
+ with nogil:
2542
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_GudhiCohomology0_f32*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2543
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2544
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2545
+ return (pts,weights)
2546
+ if isinstance(slicer, mps._Slicer_GudhiCohomology0_f64):
2547
+ with nogil:
2548
+ sm = get_hilbert_signed_measure(dereference(<C_Slicer_GudhiCohomology0_f64*>(slicer_ptr)),container_ptr, c_grid_shape,degrees, zero_pad, n_jobs, verbose, ignore_inf)
2549
+ pts = np.asarray(sm.first,dtype=python_indices_type)
2550
+ weights = np.asarray(sm.second,dtype=python_tensor_dtype)
2551
+ return (pts,weights)
2552
+ raise ValueError(f"Unsupported slicer type {type(slicer)}")