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