obliquetree 1.0.3__cp311-cp311-macosx_11_0_arm64.whl → 1.0.4__cp311-cp311-macosx_11_0_arm64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


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

@@ -1,4 +1,4 @@
1
- /* Generated by Cython 3.1.2 */
1
+ /* Generated by Cython 3.1.6 */
2
2
 
3
3
  /* BEGIN: Cython Metadata
4
4
  {
@@ -19,7 +19,7 @@
19
19
  "-std=c++17"
20
20
  ],
21
21
  "include_dirs": [
22
- "/private/var/folders/y6/nj790rtn62lfktb1sh__79hc0000gn/T/build-env-u1q13p6v/lib/python3.11/site-packages/numpy/_core/include"
22
+ "/private/var/folders/xc/cl1fyykn2pj4ryhdw6r1mqtc0000gn/T/build-env-87m8wgod/lib/python3.11/site-packages/numpy/_core/include"
23
23
  ],
24
24
  "language": "c++",
25
25
  "name": "obliquetree.src.metric",
@@ -35,8 +35,16 @@ END: Cython Metadata */
35
35
  #define PY_SSIZE_T_CLEAN
36
36
  #endif /* PY_SSIZE_T_CLEAN */
37
37
  /* InitLimitedAPI */
38
- #if defined(Py_LIMITED_API) && !defined(CYTHON_LIMITED_API)
38
+ #if defined(Py_LIMITED_API)
39
+ #if !defined(CYTHON_LIMITED_API)
39
40
  #define CYTHON_LIMITED_API 1
41
+ #endif
42
+ #elif defined(CYTHON_LIMITED_API)
43
+ #ifdef _MSC_VER
44
+ #pragma message ("Limited API usage is enabled with 'CYTHON_LIMITED_API' but 'Py_LIMITED_API' does not define a Python target version. Consider setting 'Py_LIMITED_API' instead.")
45
+ #else
46
+ #warning Limited API usage is enabled with 'CYTHON_LIMITED_API' but 'Py_LIMITED_API' does not define a Python target version. Consider setting 'Py_LIMITED_API' instead.
47
+ #endif
40
48
  #endif
41
49
 
42
50
  #include "Python.h"
@@ -45,8 +53,8 @@ END: Cython Metadata */
45
53
  #elif PY_VERSION_HEX < 0x03080000
46
54
  #error Cython requires Python 3.8+.
47
55
  #else
48
- #define __PYX_ABI_VERSION "3_1_2"
49
- #define CYTHON_HEX_VERSION 0x030102F0
56
+ #define __PYX_ABI_VERSION "3_1_6"
57
+ #define CYTHON_HEX_VERSION 0x030106F0
50
58
  #define CYTHON_FUTURE_DIVISION 1
51
59
  /* CModulePreamble */
52
60
  #include <stddef.h>
@@ -409,6 +417,9 @@ END: Cython Metadata */
409
417
  enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P == sizeof(void*)) };
410
418
  #endif
411
419
  #endif
420
+ #ifndef CYTHON_LOCK_AND_GIL_DEADLOCK_AVOIDANCE_TIME
421
+ #define CYTHON_LOCK_AND_GIL_DEADLOCK_AVOIDANCE_TIME 100
422
+ #endif
412
423
  #ifndef __has_attribute
413
424
  #define __has_attribute(x) 0
414
425
  #endif
@@ -1317,6 +1328,7 @@ static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject*);
1317
1328
  typedef sdigit __Pyx_compact_pylong;
1318
1329
  typedef digit __Pyx_compact_upylong;
1319
1330
  #endif
1331
+ static CYTHON_INLINE int __Pyx_PyLong_CompactAsLong(PyObject *x, long *return_value);
1320
1332
  #if PY_VERSION_HEX >= 0x030C00A5
1321
1333
  #define __Pyx_PyLong_Digits(x) (((PyLongObject*)x)->long_value.ob_digit)
1322
1334
  #else
@@ -2624,22 +2636,22 @@ static int __Pyx__DelItemOnTypeDict(PyTypeObject *tp, PyObject *k);
2624
2636
  static int __Pyx_setup_reduce(PyObject* type_obj);
2625
2637
 
2626
2638
  /* TypeImport.proto */
2627
- #ifndef __PYX_HAVE_RT_ImportType_proto_3_1_2
2628
- #define __PYX_HAVE_RT_ImportType_proto_3_1_2
2639
+ #ifndef __PYX_HAVE_RT_ImportType_proto_3_1_6
2640
+ #define __PYX_HAVE_RT_ImportType_proto_3_1_6
2629
2641
  #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
2630
2642
  #include <stdalign.h>
2631
2643
  #endif
2632
2644
  #if (defined (__STDC_VERSION__) && __STDC_VERSION__ >= 201112L) || __cplusplus >= 201103L
2633
- #define __PYX_GET_STRUCT_ALIGNMENT_3_1_2(s) alignof(s)
2645
+ #define __PYX_GET_STRUCT_ALIGNMENT_3_1_6(s) alignof(s)
2634
2646
  #else
2635
- #define __PYX_GET_STRUCT_ALIGNMENT_3_1_2(s) sizeof(void*)
2647
+ #define __PYX_GET_STRUCT_ALIGNMENT_3_1_6(s) sizeof(void*)
2636
2648
  #endif
2637
- enum __Pyx_ImportType_CheckSize_3_1_2 {
2638
- __Pyx_ImportType_CheckSize_Error_3_1_2 = 0,
2639
- __Pyx_ImportType_CheckSize_Warn_3_1_2 = 1,
2640
- __Pyx_ImportType_CheckSize_Ignore_3_1_2 = 2
2649
+ enum __Pyx_ImportType_CheckSize_3_1_6 {
2650
+ __Pyx_ImportType_CheckSize_Error_3_1_6 = 0,
2651
+ __Pyx_ImportType_CheckSize_Warn_3_1_6 = 1,
2652
+ __Pyx_ImportType_CheckSize_Ignore_3_1_6 = 2
2641
2653
  };
2642
- static PyTypeObject *__Pyx_ImportType_3_1_2(PyObject* module, const char *module_name, const char *class_name, size_t size, size_t alignment, enum __Pyx_ImportType_CheckSize_3_1_2 check_size);
2654
+ static PyTypeObject *__Pyx_ImportType_3_1_6(PyObject* module, const char *module_name, const char *class_name, size_t size, size_t alignment, enum __Pyx_ImportType_CheckSize_3_1_6 check_size);
2643
2655
  #endif
2644
2656
 
2645
2657
  /* CLineInTraceback.proto */
@@ -2790,7 +2802,7 @@ static int __Pyx_check_binary_version(unsigned long ct_version, unsigned long rt
2790
2802
  static int __Pyx_ExportFunction(const char *name, void (*f)(void), const char *sig);
2791
2803
 
2792
2804
  /* FunctionImport.proto */
2793
- static int __Pyx_ImportFunction_3_1_2(PyObject *module, const char *funcname, void (**f)(void), const char *sig);
2805
+ static int __Pyx_ImportFunction_3_1_6(PyObject *module, const char *funcname, void (**f)(void), const char *sig);
2794
2806
 
2795
2807
  /* MultiPhaseInitModuleState.proto */
2796
2808
  #if CYTHON_PEP489_MULTI_PHASE_INIT && CYTHON_USE_MODULE_STATE
@@ -3444,7 +3456,7 @@ static int __pyx_array___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, P
3444
3456
  default: goto __pyx_L5_argtuple_error;
3445
3457
  }
3446
3458
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
3447
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__cinit__", 0) < 0) __PYX_ERR(1, 129, __pyx_L3_error)
3459
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__cinit__", 0) < (0)) __PYX_ERR(1, 129, __pyx_L3_error)
3448
3460
  if (!values[3]) values[3] = __Pyx_NewRef(((PyObject *)__pyx_mstate_global->__pyx_n_u_c));
3449
3461
  for (Py_ssize_t i = __pyx_nargs; i < 3; i++) {
3450
3462
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 3, 5, i); __PYX_ERR(1, 129, __pyx_L3_error) }
@@ -5058,7 +5070,7 @@ PyObject *__pyx_args, PyObject *__pyx_kwds
5058
5070
  default: goto __pyx_L5_argtuple_error;
5059
5071
  }
5060
5072
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
5061
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < 0) __PYX_ERR(1, 3, __pyx_L3_error)
5073
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < (0)) __PYX_ERR(1, 3, __pyx_L3_error)
5062
5074
  for (Py_ssize_t i = __pyx_nargs; i < 1; i++) {
5063
5075
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, i); __PYX_ERR(1, 3, __pyx_L3_error) }
5064
5076
  }
@@ -5403,7 +5415,7 @@ static struct __pyx_array_obj *__pyx_array_new(PyObject *__pyx_v_shape, Py_ssize
5403
5415
  __pyx_t_4 = 0;
5404
5416
  __pyx_t_4 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 273, __pyx_L1_error)
5405
5417
  __Pyx_GOTREF(__pyx_t_4);
5406
- if (PyDict_SetItem(__pyx_t_4, __pyx_mstate_global->__pyx_n_u_allocate_buffer, Py_False) < 0) __PYX_ERR(1, 273, __pyx_L1_error)
5418
+ if (PyDict_SetItem(__pyx_t_4, __pyx_mstate_global->__pyx_n_u_allocate_buffer, Py_False) < (0)) __PYX_ERR(1, 273, __pyx_L1_error)
5407
5419
  __pyx_t_3 = ((PyObject *)__pyx_tp_new_array(((PyTypeObject *)__pyx_mstate_global->__pyx_array_type), __pyx_t_1, __pyx_t_4)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 273, __pyx_L1_error)
5408
5420
  __Pyx_GOTREF((PyObject *)__pyx_t_3);
5409
5421
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
@@ -5498,7 +5510,7 @@ static int __pyx_MemviewEnum___init__(PyObject *__pyx_v_self, PyObject *__pyx_ar
5498
5510
  default: goto __pyx_L5_argtuple_error;
5499
5511
  }
5500
5512
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
5501
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__init__", 0) < 0) __PYX_ERR(1, 302, __pyx_L3_error)
5513
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__init__", 0) < (0)) __PYX_ERR(1, 302, __pyx_L3_error)
5502
5514
  for (Py_ssize_t i = __pyx_nargs; i < 1; i++) {
5503
5515
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, i); __PYX_ERR(1, 302, __pyx_L3_error) }
5504
5516
  }
@@ -5935,7 +5947,7 @@ PyObject *__pyx_args, PyObject *__pyx_kwds
5935
5947
  default: goto __pyx_L5_argtuple_error;
5936
5948
  }
5937
5949
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
5938
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < 0) __PYX_ERR(1, 16, __pyx_L3_error)
5950
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < (0)) __PYX_ERR(1, 16, __pyx_L3_error)
5939
5951
  for (Py_ssize_t i = __pyx_nargs; i < 1; i++) {
5940
5952
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, i); __PYX_ERR(1, 16, __pyx_L3_error) }
5941
5953
  }
@@ -6060,7 +6072,7 @@ static int __pyx_memoryview___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_ar
6060
6072
  default: goto __pyx_L5_argtuple_error;
6061
6073
  }
6062
6074
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
6063
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__cinit__", 0) < 0) __PYX_ERR(1, 347, __pyx_L3_error)
6075
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__cinit__", 0) < (0)) __PYX_ERR(1, 347, __pyx_L3_error)
6064
6076
  for (Py_ssize_t i = __pyx_nargs; i < 2; i++) {
6065
6077
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 2, 3, i); __PYX_ERR(1, 347, __pyx_L3_error) }
6066
6078
  }
@@ -10377,7 +10389,7 @@ PyObject *__pyx_args, PyObject *__pyx_kwds
10377
10389
  default: goto __pyx_L5_argtuple_error;
10378
10390
  }
10379
10391
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
10380
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < 0) __PYX_ERR(1, 3, __pyx_L3_error)
10392
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < (0)) __PYX_ERR(1, 3, __pyx_L3_error)
10381
10393
  for (Py_ssize_t i = __pyx_nargs; i < 1; i++) {
10382
10394
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, i); __PYX_ERR(1, 3, __pyx_L3_error) }
10383
10395
  }
@@ -13264,7 +13276,7 @@ PyObject *__pyx_args, PyObject *__pyx_kwds
13264
13276
  default: goto __pyx_L5_argtuple_error;
13265
13277
  }
13266
13278
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
13267
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < 0) __PYX_ERR(1, 3, __pyx_L3_error)
13279
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__setstate_cython__", 0) < (0)) __PYX_ERR(1, 3, __pyx_L3_error)
13268
13280
  for (Py_ssize_t i = __pyx_nargs; i < 1; i++) {
13269
13281
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, i); __PYX_ERR(1, 3, __pyx_L3_error) }
13270
13282
  }
@@ -16423,7 +16435,7 @@ PyObject *__pyx_args, PyObject *__pyx_kwds
16423
16435
  default: goto __pyx_L5_argtuple_error;
16424
16436
  }
16425
16437
  const Py_ssize_t kwd_pos_args = __pyx_nargs;
16426
- if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__pyx_unpickle_Enum", 0) < 0) __PYX_ERR(1, 1, __pyx_L3_error)
16438
+ if (__Pyx_ParseKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values, kwd_pos_args, __pyx_kwds_len, "__pyx_unpickle_Enum", 0) < (0)) __PYX_ERR(1, 1, __pyx_L3_error)
16427
16439
  for (Py_ssize_t i = __pyx_nargs; i < 3; i++) {
16428
16440
  if (unlikely(!values[i])) { __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Enum", 1, 3, 3, i); __PYX_ERR(1, 1, __pyx_L3_error) }
16429
16441
  }
@@ -22318,7 +22330,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22318
22330
  * for j in range(unique_count):
22319
22331
  * if stats[j].class_weights != NULL: # <<<<<<<<<<<<<<
22320
22332
  * free(stats[j].class_weights)
22321
- * with gil:
22333
+ * stats[j].class_weights = NULL
22322
22334
  */
22323
22335
  __pyx_t_1 = ((__pyx_v_stats[__pyx_v_j]).class_weights != NULL);
22324
22336
  if (__pyx_t_1) {
@@ -22327,24 +22339,33 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22327
22339
  * for j in range(unique_count):
22328
22340
  * if stats[j].class_weights != NULL:
22329
22341
  * free(stats[j].class_weights) # <<<<<<<<<<<<<<
22342
+ * stats[j].class_weights = NULL
22330
22343
  * with gil:
22331
- * raise MemoryError()
22332
22344
  */
22333
22345
  free((__pyx_v_stats[__pyx_v_j]).class_weights);
22334
22346
 
22347
+ /* "obliquetree/src/metric.pyx":904
22348
+ * if stats[j].class_weights != NULL:
22349
+ * free(stats[j].class_weights)
22350
+ * stats[j].class_weights = NULL # <<<<<<<<<<<<<<
22351
+ * with gil:
22352
+ * raise MemoryError()
22353
+ */
22354
+ (__pyx_v_stats[__pyx_v_j]).class_weights = NULL;
22355
+
22335
22356
  /* "obliquetree/src/metric.pyx":902
22336
22357
  * # Mevcut tm allocated bellekleri serbest brak
22337
22358
  * for j in range(unique_count):
22338
22359
  * if stats[j].class_weights != NULL: # <<<<<<<<<<<<<<
22339
22360
  * free(stats[j].class_weights)
22340
- * with gil:
22361
+ * stats[j].class_weights = NULL
22341
22362
  */
22342
22363
  }
22343
22364
  }
22344
22365
 
22345
- /* "obliquetree/src/metric.pyx":904
22346
- * if stats[j].class_weights != NULL:
22366
+ /* "obliquetree/src/metric.pyx":905
22347
22367
  * free(stats[j].class_weights)
22368
+ * stats[j].class_weights = NULL
22348
22369
  * with gil: # <<<<<<<<<<<<<<
22349
22370
  * raise MemoryError()
22350
22371
  *
@@ -22353,19 +22374,19 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22353
22374
  PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
22354
22375
  /*try:*/ {
22355
22376
 
22356
- /* "obliquetree/src/metric.pyx":905
22357
- * free(stats[j].class_weights)
22377
+ /* "obliquetree/src/metric.pyx":906
22378
+ * stats[j].class_weights = NULL
22358
22379
  * with gil:
22359
22380
  * raise MemoryError() # <<<<<<<<<<<<<<
22360
22381
  *
22361
22382
  * memset(current_stat.class_weights, 0, n_classes * sizeof(double))
22362
22383
  */
22363
- PyErr_NoMemory(); __PYX_ERR(0, 905, __pyx_L31_error)
22384
+ PyErr_NoMemory(); __PYX_ERR(0, 906, __pyx_L31_error)
22364
22385
  }
22365
22386
 
22366
- /* "obliquetree/src/metric.pyx":904
22367
- * if stats[j].class_weights != NULL:
22387
+ /* "obliquetree/src/metric.pyx":905
22368
22388
  * free(stats[j].class_weights)
22389
+ * stats[j].class_weights = NULL
22369
22390
  * with gil: # <<<<<<<<<<<<<<
22370
22391
  * raise MemoryError()
22371
22392
  *
@@ -22387,7 +22408,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22387
22408
  */
22388
22409
  }
22389
22410
 
22390
- /* "obliquetree/src/metric.pyx":907
22411
+ /* "obliquetree/src/metric.pyx":908
22391
22412
  * raise MemoryError()
22392
22413
  *
22393
22414
  * memset(current_stat.class_weights, 0, n_classes * sizeof(double)) # <<<<<<<<<<<<<<
@@ -22396,7 +22417,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22396
22417
  */
22397
22418
  (void)(memset(__pyx_v_current_stat->class_weights, 0, (__pyx_v_n_classes * (sizeof(double)))));
22398
22419
 
22399
- /* "obliquetree/src/metric.pyx":908
22420
+ /* "obliquetree/src/metric.pyx":909
22400
22421
  *
22401
22422
  * memset(current_stat.class_weights, 0, n_classes * sizeof(double))
22402
22423
  * current_stat.class_weights[class_idx] = w # <<<<<<<<<<<<<<
@@ -22405,7 +22426,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22405
22426
  */
22406
22427
  (__pyx_v_current_stat->class_weights[__pyx_v_class_idx]) = __pyx_v_w;
22407
22428
 
22408
- /* "obliquetree/src/metric.pyx":909
22429
+ /* "obliquetree/src/metric.pyx":910
22409
22430
  * memset(current_stat.class_weights, 0, n_classes * sizeof(double))
22410
22431
  * current_stat.class_weights[class_idx] = w
22411
22432
  * current_stat.weight = w # <<<<<<<<<<<<<<
@@ -22414,7 +22435,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22414
22435
  */
22415
22436
  __pyx_v_current_stat->weight = __pyx_v_w;
22416
22437
 
22417
- /* "obliquetree/src/metric.pyx":910
22438
+ /* "obliquetree/src/metric.pyx":911
22418
22439
  * current_stat.class_weights[class_idx] = w
22419
22440
  * current_stat.weight = w
22420
22441
  * current_stat.count = 1 # <<<<<<<<<<<<<<
@@ -22423,7 +22444,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22423
22444
  */
22424
22445
  __pyx_v_current_stat->count = 1;
22425
22446
 
22426
- /* "obliquetree/src/metric.pyx":912
22447
+ /* "obliquetree/src/metric.pyx":913
22427
22448
  * current_stat.count = 1
22428
22449
  *
22429
22450
  * unique_count += 1 # <<<<<<<<<<<<<<
@@ -22432,7 +22453,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22432
22453
  */
22433
22454
  __pyx_v_unique_count = (__pyx_v_unique_count + 1);
22434
22455
 
22435
- /* "obliquetree/src/metric.pyx":913
22456
+ /* "obliquetree/src/metric.pyx":914
22436
22457
  *
22437
22458
  * unique_count += 1
22438
22459
  * prev_value = current_value # <<<<<<<<<<<<<<
@@ -22451,7 +22472,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22451
22472
  goto __pyx_L23;
22452
22473
  }
22453
22474
 
22454
- /* "obliquetree/src/metric.pyx":916
22475
+ /* "obliquetree/src/metric.pyx":917
22455
22476
  * else:
22456
22477
  * # Ayn kategoriye ekle
22457
22478
  * current_stat.class_weights[class_idx] += w # <<<<<<<<<<<<<<
@@ -22462,7 +22483,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22462
22483
  __pyx_t_6 = __pyx_v_class_idx;
22463
22484
  (__pyx_v_current_stat->class_weights[__pyx_t_6]) = ((__pyx_v_current_stat->class_weights[__pyx_t_6]) + __pyx_v_w);
22464
22485
 
22465
- /* "obliquetree/src/metric.pyx":917
22486
+ /* "obliquetree/src/metric.pyx":918
22466
22487
  * # Ayn kategoriye ekle
22467
22488
  * current_stat.class_weights[class_idx] += w
22468
22489
  * current_stat.weight += w # <<<<<<<<<<<<<<
@@ -22471,7 +22492,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22471
22492
  */
22472
22493
  __pyx_v_current_stat->weight = (__pyx_v_current_stat->weight + __pyx_v_w);
22473
22494
 
22474
- /* "obliquetree/src/metric.pyx":918
22495
+ /* "obliquetree/src/metric.pyx":919
22475
22496
  * current_stat.class_weights[class_idx] += w
22476
22497
  * current_stat.weight += w
22477
22498
  * current_stat.count += 1 # <<<<<<<<<<<<<<
@@ -22482,7 +22503,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22482
22503
  }
22483
22504
  __pyx_L23:;
22484
22505
 
22485
- /* "obliquetree/src/metric.pyx":920
22506
+ /* "obliquetree/src/metric.pyx":921
22486
22507
  * current_stat.count += 1
22487
22508
  *
22488
22509
  * total_class_weights[class_idx] += w # <<<<<<<<<<<<<<
@@ -22492,7 +22513,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22492
22513
  __pyx_t_6 = __pyx_v_class_idx;
22493
22514
  (__pyx_v_total_class_weights[__pyx_t_6]) = ((__pyx_v_total_class_weights[__pyx_t_6]) + __pyx_v_w);
22494
22515
 
22495
- /* "obliquetree/src/metric.pyx":921
22516
+ /* "obliquetree/src/metric.pyx":922
22496
22517
  *
22497
22518
  * total_class_weights[class_idx] += w
22498
22519
  * total_weight += w # <<<<<<<<<<<<<<
@@ -22502,7 +22523,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22502
22523
  __pyx_v_total_weight = (__pyx_v_total_weight + __pyx_v_w);
22503
22524
  }
22504
22525
 
22505
- /* "obliquetree/src/metric.pyx":923
22526
+ /* "obliquetree/src/metric.pyx":924
22506
22527
  * total_weight += w
22507
22528
  *
22508
22529
  * max_cat = 0 # <<<<<<<<<<<<<<
@@ -22511,7 +22532,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22511
22532
  */
22512
22533
  __pyx_v_max_cat = 0;
22513
22534
 
22514
- /* "obliquetree/src/metric.pyx":924
22535
+ /* "obliquetree/src/metric.pyx":925
22515
22536
  *
22516
22537
  * max_cat = 0
22517
22538
  * for i in range(unique_count): # <<<<<<<<<<<<<<
@@ -22523,7 +22544,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22523
22544
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
22524
22545
  __pyx_v_i = __pyx_t_5;
22525
22546
 
22526
- /* "obliquetree/src/metric.pyx":925
22547
+ /* "obliquetree/src/metric.pyx":926
22527
22548
  * max_cat = 0
22528
22549
  * for i in range(unique_count):
22529
22550
  * stats_val = <int>stats[i].value # <<<<<<<<<<<<<<
@@ -22532,7 +22553,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22532
22553
  */
22533
22554
  __pyx_v_stats_val = ((int)(__pyx_v_stats[__pyx_v_i]).value);
22534
22555
 
22535
- /* "obliquetree/src/metric.pyx":926
22556
+ /* "obliquetree/src/metric.pyx":927
22536
22557
  * for i in range(unique_count):
22537
22558
  * stats_val = <int>stats[i].value
22538
22559
  * if stats_val > max_cat: # <<<<<<<<<<<<<<
@@ -22542,7 +22563,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22542
22563
  __pyx_t_1 = (__pyx_v_stats_val > __pyx_v_max_cat);
22543
22564
  if (__pyx_t_1) {
22544
22565
 
22545
- /* "obliquetree/src/metric.pyx":927
22566
+ /* "obliquetree/src/metric.pyx":928
22546
22567
  * stats_val = <int>stats[i].value
22547
22568
  * if stats_val > max_cat:
22548
22569
  * max_cat = stats_val # <<<<<<<<<<<<<<
@@ -22551,7 +22572,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22551
22572
  */
22552
22573
  __pyx_v_max_cat = __pyx_v_stats_val;
22553
22574
 
22554
- /* "obliquetree/src/metric.pyx":926
22575
+ /* "obliquetree/src/metric.pyx":927
22555
22576
  * for i in range(unique_count):
22556
22577
  * stats_val = <int>stats[i].value
22557
22578
  * if stats_val > max_cat: # <<<<<<<<<<<<<<
@@ -22561,7 +22582,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22561
22582
  }
22562
22583
  }
22563
22584
 
22564
- /* "obliquetree/src/metric.pyx":930
22585
+ /* "obliquetree/src/metric.pyx":931
22565
22586
  *
22566
22587
  * # Kategori dizililerinin cumsum hesaplamas iin
22567
22588
  * stats_count = <int*>calloc(max_cat + 1, sizeof(int)) # <<<<<<<<<<<<<<
@@ -22570,7 +22591,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22570
22591
  */
22571
22592
  __pyx_v_stats_count = ((int *)calloc((__pyx_v_max_cat + 1), (sizeof(int))));
22572
22593
 
22573
- /* "obliquetree/src/metric.pyx":931
22594
+ /* "obliquetree/src/metric.pyx":932
22574
22595
  * # Kategori dizililerinin cumsum hesaplamas iin
22575
22596
  * stats_count = <int*>calloc(max_cat + 1, sizeof(int))
22576
22597
  * if stats_count == NULL: # <<<<<<<<<<<<<<
@@ -22580,7 +22601,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22580
22601
  __pyx_t_1 = (__pyx_v_stats_count == NULL);
22581
22602
  if (unlikely(__pyx_t_1)) {
22582
22603
 
22583
- /* "obliquetree/src/metric.pyx":932
22604
+ /* "obliquetree/src/metric.pyx":933
22584
22605
  * stats_count = <int*>calloc(max_cat + 1, sizeof(int))
22585
22606
  * if stats_count == NULL:
22586
22607
  * with gil: # <<<<<<<<<<<<<<
@@ -22591,17 +22612,17 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22591
22612
  PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
22592
22613
  /*try:*/ {
22593
22614
 
22594
- /* "obliquetree/src/metric.pyx":933
22615
+ /* "obliquetree/src/metric.pyx":934
22595
22616
  * if stats_count == NULL:
22596
22617
  * with gil:
22597
22618
  * raise MemoryError() # <<<<<<<<<<<<<<
22598
22619
  *
22599
22620
  * new_indices = <int*>calloc(n_samples - n_nans, sizeof(int))
22600
22621
  */
22601
- PyErr_NoMemory(); __PYX_ERR(0, 933, __pyx_L38_error)
22622
+ PyErr_NoMemory(); __PYX_ERR(0, 934, __pyx_L38_error)
22602
22623
  }
22603
22624
 
22604
- /* "obliquetree/src/metric.pyx":932
22625
+ /* "obliquetree/src/metric.pyx":933
22605
22626
  * stats_count = <int*>calloc(max_cat + 1, sizeof(int))
22606
22627
  * if stats_count == NULL:
22607
22628
  * with gil: # <<<<<<<<<<<<<<
@@ -22616,7 +22637,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22616
22637
  }
22617
22638
  }
22618
22639
 
22619
- /* "obliquetree/src/metric.pyx":931
22640
+ /* "obliquetree/src/metric.pyx":932
22620
22641
  * # Kategori dizililerinin cumsum hesaplamas iin
22621
22642
  * stats_count = <int*>calloc(max_cat + 1, sizeof(int))
22622
22643
  * if stats_count == NULL: # <<<<<<<<<<<<<<
@@ -22625,7 +22646,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22625
22646
  */
22626
22647
  }
22627
22648
 
22628
- /* "obliquetree/src/metric.pyx":935
22649
+ /* "obliquetree/src/metric.pyx":936
22629
22650
  * raise MemoryError()
22630
22651
  *
22631
22652
  * new_indices = <int*>calloc(n_samples - n_nans, sizeof(int)) # <<<<<<<<<<<<<<
@@ -22634,7 +22655,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22634
22655
  */
22635
22656
  __pyx_v_new_indices = ((int *)calloc((__pyx_v_n_samples - __pyx_v_n_nans), (sizeof(int))));
22636
22657
 
22637
- /* "obliquetree/src/metric.pyx":936
22658
+ /* "obliquetree/src/metric.pyx":937
22638
22659
  *
22639
22660
  * new_indices = <int*>calloc(n_samples - n_nans, sizeof(int))
22640
22661
  * if new_indices == NULL: # <<<<<<<<<<<<<<
@@ -22644,7 +22665,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22644
22665
  __pyx_t_1 = (__pyx_v_new_indices == NULL);
22645
22666
  if (unlikely(__pyx_t_1)) {
22646
22667
 
22647
- /* "obliquetree/src/metric.pyx":937
22668
+ /* "obliquetree/src/metric.pyx":938
22648
22669
  * new_indices = <int*>calloc(n_samples - n_nans, sizeof(int))
22649
22670
  * if new_indices == NULL:
22650
22671
  * with gil: # <<<<<<<<<<<<<<
@@ -22655,17 +22676,17 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22655
22676
  PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
22656
22677
  /*try:*/ {
22657
22678
 
22658
- /* "obliquetree/src/metric.pyx":938
22679
+ /* "obliquetree/src/metric.pyx":939
22659
22680
  * if new_indices == NULL:
22660
22681
  * with gil:
22661
22682
  * raise MemoryError() # <<<<<<<<<<<<<<
22662
22683
  *
22663
22684
  * best_stats = <CategoryStat*>malloc(unique_count * sizeof(CategoryStat))
22664
22685
  */
22665
- PyErr_NoMemory(); __PYX_ERR(0, 938, __pyx_L42_error)
22686
+ PyErr_NoMemory(); __PYX_ERR(0, 939, __pyx_L42_error)
22666
22687
  }
22667
22688
 
22668
- /* "obliquetree/src/metric.pyx":937
22689
+ /* "obliquetree/src/metric.pyx":938
22669
22690
  * new_indices = <int*>calloc(n_samples - n_nans, sizeof(int))
22670
22691
  * if new_indices == NULL:
22671
22692
  * with gil: # <<<<<<<<<<<<<<
@@ -22680,7 +22701,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22680
22701
  }
22681
22702
  }
22682
22703
 
22683
- /* "obliquetree/src/metric.pyx":936
22704
+ /* "obliquetree/src/metric.pyx":937
22684
22705
  *
22685
22706
  * new_indices = <int*>calloc(n_samples - n_nans, sizeof(int))
22686
22707
  * if new_indices == NULL: # <<<<<<<<<<<<<<
@@ -22689,7 +22710,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22689
22710
  */
22690
22711
  }
22691
22712
 
22692
- /* "obliquetree/src/metric.pyx":940
22713
+ /* "obliquetree/src/metric.pyx":941
22693
22714
  * raise MemoryError()
22694
22715
  *
22695
22716
  * best_stats = <CategoryStat*>malloc(unique_count * sizeof(CategoryStat)) # <<<<<<<<<<<<<<
@@ -22698,7 +22719,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22698
22719
  */
22699
22720
  __pyx_v_best_stats = ((struct __pyx_t_11obliquetree_3src_4tree_CategoryStat *)malloc((__pyx_v_unique_count * (sizeof(struct __pyx_t_11obliquetree_3src_4tree_CategoryStat)))));
22700
22721
 
22701
- /* "obliquetree/src/metric.pyx":941
22722
+ /* "obliquetree/src/metric.pyx":942
22702
22723
  *
22703
22724
  * best_stats = <CategoryStat*>malloc(unique_count * sizeof(CategoryStat))
22704
22725
  * if best_stats == NULL: # <<<<<<<<<<<<<<
@@ -22708,7 +22729,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22708
22729
  __pyx_t_1 = (__pyx_v_best_stats == NULL);
22709
22730
  if (unlikely(__pyx_t_1)) {
22710
22731
 
22711
- /* "obliquetree/src/metric.pyx":942
22732
+ /* "obliquetree/src/metric.pyx":943
22712
22733
  * best_stats = <CategoryStat*>malloc(unique_count * sizeof(CategoryStat))
22713
22734
  * if best_stats == NULL:
22714
22735
  * with gil: # <<<<<<<<<<<<<<
@@ -22719,17 +22740,17 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22719
22740
  PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
22720
22741
  /*try:*/ {
22721
22742
 
22722
- /* "obliquetree/src/metric.pyx":943
22743
+ /* "obliquetree/src/metric.pyx":944
22723
22744
  * if best_stats == NULL:
22724
22745
  * with gil:
22725
22746
  * raise MemoryError() # <<<<<<<<<<<<<<
22726
22747
  * # Initialize
22727
22748
  * memcpy(best_stats, stats, unique_count * sizeof(CategoryStat))
22728
22749
  */
22729
- PyErr_NoMemory(); __PYX_ERR(0, 943, __pyx_L46_error)
22750
+ PyErr_NoMemory(); __PYX_ERR(0, 944, __pyx_L46_error)
22730
22751
  }
22731
22752
 
22732
- /* "obliquetree/src/metric.pyx":942
22753
+ /* "obliquetree/src/metric.pyx":943
22733
22754
  * best_stats = <CategoryStat*>malloc(unique_count * sizeof(CategoryStat))
22734
22755
  * if best_stats == NULL:
22735
22756
  * with gil: # <<<<<<<<<<<<<<
@@ -22744,7 +22765,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22744
22765
  }
22745
22766
  }
22746
22767
 
22747
- /* "obliquetree/src/metric.pyx":941
22768
+ /* "obliquetree/src/metric.pyx":942
22748
22769
  *
22749
22770
  * best_stats = <CategoryStat*>malloc(unique_count * sizeof(CategoryStat))
22750
22771
  * if best_stats == NULL: # <<<<<<<<<<<<<<
@@ -22753,7 +22774,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22753
22774
  */
22754
22775
  }
22755
22776
 
22756
- /* "obliquetree/src/metric.pyx":945
22777
+ /* "obliquetree/src/metric.pyx":946
22757
22778
  * raise MemoryError()
22758
22779
  * # Initialize
22759
22780
  * memcpy(best_stats, stats, unique_count * sizeof(CategoryStat)) # <<<<<<<<<<<<<<
@@ -22762,7 +22783,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22762
22783
  */
22763
22784
  (void)(memcpy(__pyx_v_best_stats, __pyx_v_stats, (__pyx_v_unique_count * (sizeof(struct __pyx_t_11obliquetree_3src_4tree_CategoryStat)))));
22764
22785
 
22765
- /* "obliquetree/src/metric.pyx":948
22786
+ /* "obliquetree/src/metric.pyx":949
22766
22787
  *
22767
22788
  * # Tm permtasyonlar ret
22768
22789
  * perm_orders = generate_permutations(n_classes, &perm_count) # <<<<<<<<<<<<<<
@@ -22771,7 +22792,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22771
22792
  */
22772
22793
  __pyx_v_perm_orders = __pyx_f_11obliquetree_3src_5utils_generate_permutations(__pyx_v_n_classes, (&__pyx_v_perm_count));
22773
22794
 
22774
- /* "obliquetree/src/metric.pyx":950
22795
+ /* "obliquetree/src/metric.pyx":951
22775
22796
  * perm_orders = generate_permutations(n_classes, &perm_count)
22776
22797
  *
22777
22798
  * for k in range(perm_count): # <<<<<<<<<<<<<<
@@ -22783,7 +22804,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22783
22804
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
22784
22805
  __pyx_v_k = __pyx_t_5;
22785
22806
 
22786
- /* "obliquetree/src/metric.pyx":951
22807
+ /* "obliquetree/src/metric.pyx":952
22787
22808
  *
22788
22809
  * for k in range(perm_count):
22789
22810
  * sort_category_stats_multiclass(stats, perm_orders[k], unique_count, n_classes) # <<<<<<<<<<<<<<
@@ -22792,7 +22813,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22792
22813
  */
22793
22814
  __pyx_f_11obliquetree_3src_5utils_sort_category_stats_multiclass(__pyx_v_stats, (__pyx_v_perm_orders[__pyx_v_k]), __pyx_v_unique_count, __pyx_v_n_classes);
22794
22815
 
22795
- /* "obliquetree/src/metric.pyx":953
22816
+ /* "obliquetree/src/metric.pyx":954
22796
22817
  * sort_category_stats_multiclass(stats, perm_orders[k], unique_count, n_classes)
22797
22818
  *
22798
22819
  * min_impurity = category_impurity_multiclass( # <<<<<<<<<<<<<<
@@ -22801,7 +22822,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22801
22822
  */
22802
22823
  __pyx_v_min_impurity = __pyx_f_11obliquetree_3src_6metric_category_impurity_multiclass(__pyx_v_unique_count, __pyx_v_total_class_weights, __pyx_v_total_weight, __pyx_v_nan_class_weights, __pyx_v_nan_weight, __pyx_v_stats, __pyx_v_n_samples, __pyx_v_n_nans, __pyx_v_min_samples_leaf, __pyx_v_n_classes, (&__pyx_v_out_threshold_c), (&__pyx_v_out_left_count_c), (&__pyx_v_out_missing_go_left_c));
22803
22824
 
22804
- /* "obliquetree/src/metric.pyx":970
22825
+ /* "obliquetree/src/metric.pyx":971
22805
22826
  *
22806
22827
  * # Daha iyi bir split bulursak gncelle
22807
22828
  * if min_impurity < best_impurity: # <<<<<<<<<<<<<<
@@ -22811,7 +22832,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22811
22832
  __pyx_t_1 = (__pyx_v_min_impurity < __pyx_v_best_impurity);
22812
22833
  if (__pyx_t_1) {
22813
22834
 
22814
- /* "obliquetree/src/metric.pyx":971
22835
+ /* "obliquetree/src/metric.pyx":972
22815
22836
  * # Daha iyi bir split bulursak gncelle
22816
22837
  * if min_impurity < best_impurity:
22817
22838
  * out_threshold[0] = out_threshold_c # <<<<<<<<<<<<<<
@@ -22820,7 +22841,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22820
22841
  */
22821
22842
  (__pyx_v_out_threshold[0]) = __pyx_v_out_threshold_c;
22822
22843
 
22823
- /* "obliquetree/src/metric.pyx":972
22844
+ /* "obliquetree/src/metric.pyx":973
22824
22845
  * if min_impurity < best_impurity:
22825
22846
  * out_threshold[0] = out_threshold_c
22826
22847
  * out_left_count[0] = out_left_count_c # <<<<<<<<<<<<<<
@@ -22829,7 +22850,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22829
22850
  */
22830
22851
  (__pyx_v_out_left_count[0]) = __pyx_v_out_left_count_c;
22831
22852
 
22832
- /* "obliquetree/src/metric.pyx":973
22853
+ /* "obliquetree/src/metric.pyx":974
22833
22854
  * out_threshold[0] = out_threshold_c
22834
22855
  * out_left_count[0] = out_left_count_c
22835
22856
  * out_missing_go_left[0] = out_missing_go_left_c # <<<<<<<<<<<<<<
@@ -22838,7 +22859,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22838
22859
  */
22839
22860
  (__pyx_v_out_missing_go_left[0]) = __pyx_v_out_missing_go_left_c;
22840
22861
 
22841
- /* "obliquetree/src/metric.pyx":974
22862
+ /* "obliquetree/src/metric.pyx":975
22842
22863
  * out_left_count[0] = out_left_count_c
22843
22864
  * out_missing_go_left[0] = out_missing_go_left_c
22844
22865
  * best_impurity = min_impurity # <<<<<<<<<<<<<<
@@ -22847,7 +22868,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22847
22868
  */
22848
22869
  __pyx_v_best_impurity = __pyx_v_min_impurity;
22849
22870
 
22850
- /* "obliquetree/src/metric.pyx":976
22871
+ /* "obliquetree/src/metric.pyx":977
22851
22872
  * best_impurity = min_impurity
22852
22873
  *
22853
22874
  * memcpy(best_stats, stats, unique_count * sizeof(CategoryStat)) # <<<<<<<<<<<<<<
@@ -22856,7 +22877,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22856
22877
  */
22857
22878
  (void)(memcpy(__pyx_v_best_stats, __pyx_v_stats, (__pyx_v_unique_count * (sizeof(struct __pyx_t_11obliquetree_3src_4tree_CategoryStat)))));
22858
22879
 
22859
- /* "obliquetree/src/metric.pyx":970
22880
+ /* "obliquetree/src/metric.pyx":971
22860
22881
  *
22861
22882
  * # Daha iyi bir split bulursak gncelle
22862
22883
  * if min_impurity < best_impurity: # <<<<<<<<<<<<<<
@@ -22866,7 +22887,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22866
22887
  }
22867
22888
  }
22868
22889
 
22869
- /* "obliquetree/src/metric.pyx":978
22890
+ /* "obliquetree/src/metric.pyx":979
22870
22891
  * memcpy(best_stats, stats, unique_count * sizeof(CategoryStat))
22871
22892
  *
22872
22893
  * cumsum = 0 # <<<<<<<<<<<<<<
@@ -22875,7 +22896,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22875
22896
  */
22876
22897
  __pyx_v_cumsum = 0;
22877
22898
 
22878
- /* "obliquetree/src/metric.pyx":979
22899
+ /* "obliquetree/src/metric.pyx":980
22879
22900
  *
22880
22901
  * cumsum = 0
22881
22902
  * for i in range(unique_count): # <<<<<<<<<<<<<<
@@ -22887,7 +22908,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22887
22908
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
22888
22909
  __pyx_v_i = __pyx_t_5;
22889
22910
 
22890
- /* "obliquetree/src/metric.pyx":980
22911
+ /* "obliquetree/src/metric.pyx":981
22891
22912
  * cumsum = 0
22892
22913
  * for i in range(unique_count):
22893
22914
  * stats_val = <int>best_stats[i].value # <<<<<<<<<<<<<<
@@ -22896,7 +22917,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22896
22917
  */
22897
22918
  __pyx_v_stats_val = ((int)(__pyx_v_best_stats[__pyx_v_i]).value);
22898
22919
 
22899
- /* "obliquetree/src/metric.pyx":981
22920
+ /* "obliquetree/src/metric.pyx":982
22900
22921
  * for i in range(unique_count):
22901
22922
  * stats_val = <int>best_stats[i].value
22902
22923
  * stats_count[stats_val] = cumsum # <<<<<<<<<<<<<<
@@ -22905,7 +22926,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22905
22926
  */
22906
22927
  (__pyx_v_stats_count[__pyx_v_stats_val]) = __pyx_v_cumsum;
22907
22928
 
22908
- /* "obliquetree/src/metric.pyx":982
22929
+ /* "obliquetree/src/metric.pyx":983
22909
22930
  * stats_val = <int>best_stats[i].value
22910
22931
  * stats_count[stats_val] = cumsum
22911
22932
  * cumsum += best_stats[i].count # <<<<<<<<<<<<<<
@@ -22915,7 +22936,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22915
22936
  __pyx_v_cumsum = (__pyx_v_cumsum + (__pyx_v_best_stats[__pyx_v_i]).count);
22916
22937
  }
22917
22938
 
22918
- /* "obliquetree/src/metric.pyx":985
22939
+ /* "obliquetree/src/metric.pyx":986
22919
22940
  *
22920
22941
  * # Yeni sralamaya gre indeksleri diz
22921
22942
  * for j in range(n_samples - n_nans): # <<<<<<<<<<<<<<
@@ -22927,7 +22948,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22927
22948
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
22928
22949
  __pyx_v_j = __pyx_t_5;
22929
22950
 
22930
- /* "obliquetree/src/metric.pyx":986
22951
+ /* "obliquetree/src/metric.pyx":987
22931
22952
  * # Yeni sralamaya gre indeksleri diz
22932
22953
  * for j in range(n_samples - n_nans):
22933
22954
  * curr_val = <int>sort_buffer[j].value # <<<<<<<<<<<<<<
@@ -22936,7 +22957,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22936
22957
  */
22937
22958
  __pyx_v_curr_val = ((int)(__pyx_v_sort_buffer[__pyx_v_j]).value);
22938
22959
 
22939
- /* "obliquetree/src/metric.pyx":987
22960
+ /* "obliquetree/src/metric.pyx":988
22940
22961
  * for j in range(n_samples - n_nans):
22941
22962
  * curr_val = <int>sort_buffer[j].value
22942
22963
  * new_indices[stats_count[curr_val]] = sort_buffer[j].index # <<<<<<<<<<<<<<
@@ -22946,7 +22967,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22946
22967
  __pyx_t_6 = (__pyx_v_sort_buffer[__pyx_v_j]).index;
22947
22968
  (__pyx_v_new_indices[(__pyx_v_stats_count[__pyx_v_curr_val])]) = __pyx_t_6;
22948
22969
 
22949
- /* "obliquetree/src/metric.pyx":988
22970
+ /* "obliquetree/src/metric.pyx":989
22950
22971
  * curr_val = <int>sort_buffer[j].value
22951
22972
  * new_indices[stats_count[curr_val]] = sort_buffer[j].index
22952
22973
  * stats_count[curr_val] += 1 # <<<<<<<<<<<<<<
@@ -22957,7 +22978,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22957
22978
  (__pyx_v_stats_count[__pyx_t_6]) = ((__pyx_v_stats_count[__pyx_t_6]) + 1);
22958
22979
  }
22959
22980
 
22960
- /* "obliquetree/src/metric.pyx":990
22981
+ /* "obliquetree/src/metric.pyx":991
22961
22982
  * stats_count[curr_val] += 1
22962
22983
  *
22963
22984
  * for i in range(n_samples - n_nans): # <<<<<<<<<<<<<<
@@ -22969,7 +22990,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22969
22990
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
22970
22991
  __pyx_v_i = __pyx_t_5;
22971
22992
 
22972
- /* "obliquetree/src/metric.pyx":991
22993
+ /* "obliquetree/src/metric.pyx":992
22973
22994
  *
22974
22995
  * for i in range(n_samples - n_nans):
22975
22996
  * sort_buffer[i].index = new_indices[i] # <<<<<<<<<<<<<<
@@ -22979,7 +23000,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22979
23000
  (__pyx_v_sort_buffer[__pyx_v_i]).index = (__pyx_v_new_indices[__pyx_v_i]);
22980
23001
  }
22981
23002
 
22982
- /* "obliquetree/src/metric.pyx":993
23003
+ /* "obliquetree/src/metric.pyx":994
22983
23004
  * sort_buffer[i].index = new_indices[i]
22984
23005
  *
22985
23006
  * memcpy(stats, best_stats, unique_count * sizeof(CategoryStat)) # <<<<<<<<<<<<<<
@@ -22998,7 +23019,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
22998
23019
  }
22999
23020
  }
23000
23021
 
23001
- /* "obliquetree/src/metric.pyx":998
23022
+ /* "obliquetree/src/metric.pyx":999
23002
23023
  *
23003
23024
  * # Fonksiyonun sonunda toplu free
23004
23025
  * free(total_class_weights) # <<<<<<<<<<<<<<
@@ -23009,7 +23030,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23009
23030
  /*normal exit:*/{
23010
23031
  free(__pyx_v_total_class_weights);
23011
23032
 
23012
- /* "obliquetree/src/metric.pyx":999
23033
+ /* "obliquetree/src/metric.pyx":1000
23013
23034
  * # Fonksiyonun sonunda toplu free
23014
23035
  * free(total_class_weights)
23015
23036
  * free(nan_class_weights) # <<<<<<<<<<<<<<
@@ -23018,7 +23039,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23018
23039
  */
23019
23040
  free(__pyx_v_nan_class_weights);
23020
23041
 
23021
- /* "obliquetree/src/metric.pyx":1001
23042
+ /* "obliquetree/src/metric.pyx":1002
23022
23043
  * free(nan_class_weights)
23023
23044
  *
23024
23045
  * if stats_count != NULL: # <<<<<<<<<<<<<<
@@ -23028,7 +23049,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23028
23049
  __pyx_t_1 = (__pyx_v_stats_count != NULL);
23029
23050
  if (__pyx_t_1) {
23030
23051
 
23031
- /* "obliquetree/src/metric.pyx":1002
23052
+ /* "obliquetree/src/metric.pyx":1003
23032
23053
  *
23033
23054
  * if stats_count != NULL:
23034
23055
  * free(stats_count) # <<<<<<<<<<<<<<
@@ -23037,7 +23058,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23037
23058
  */
23038
23059
  free(__pyx_v_stats_count);
23039
23060
 
23040
- /* "obliquetree/src/metric.pyx":1001
23061
+ /* "obliquetree/src/metric.pyx":1002
23041
23062
  * free(nan_class_weights)
23042
23063
  *
23043
23064
  * if stats_count != NULL: # <<<<<<<<<<<<<<
@@ -23046,7 +23067,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23046
23067
  */
23047
23068
  }
23048
23069
 
23049
- /* "obliquetree/src/metric.pyx":1003
23070
+ /* "obliquetree/src/metric.pyx":1004
23050
23071
  * if stats_count != NULL:
23051
23072
  * free(stats_count)
23052
23073
  * if new_indices != NULL: # <<<<<<<<<<<<<<
@@ -23056,7 +23077,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23056
23077
  __pyx_t_1 = (__pyx_v_new_indices != NULL);
23057
23078
  if (__pyx_t_1) {
23058
23079
 
23059
- /* "obliquetree/src/metric.pyx":1004
23080
+ /* "obliquetree/src/metric.pyx":1005
23060
23081
  * free(stats_count)
23061
23082
  * if new_indices != NULL:
23062
23083
  * free(new_indices) # <<<<<<<<<<<<<<
@@ -23065,7 +23086,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23065
23086
  */
23066
23087
  free(__pyx_v_new_indices);
23067
23088
 
23068
- /* "obliquetree/src/metric.pyx":1003
23089
+ /* "obliquetree/src/metric.pyx":1004
23069
23090
  * if stats_count != NULL:
23070
23091
  * free(stats_count)
23071
23092
  * if new_indices != NULL: # <<<<<<<<<<<<<<
@@ -23074,7 +23095,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23074
23095
  */
23075
23096
  }
23076
23097
 
23077
- /* "obliquetree/src/metric.pyx":1005
23098
+ /* "obliquetree/src/metric.pyx":1006
23078
23099
  * if new_indices != NULL:
23079
23100
  * free(new_indices)
23080
23101
  * if best_stats != NULL: # <<<<<<<<<<<<<<
@@ -23084,7 +23105,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23084
23105
  __pyx_t_1 = (__pyx_v_best_stats != NULL);
23085
23106
  if (__pyx_t_1) {
23086
23107
 
23087
- /* "obliquetree/src/metric.pyx":1006
23108
+ /* "obliquetree/src/metric.pyx":1007
23088
23109
  * free(new_indices)
23089
23110
  * if best_stats != NULL:
23090
23111
  * free(best_stats) # <<<<<<<<<<<<<<
@@ -23093,7 +23114,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23093
23114
  */
23094
23115
  free(__pyx_v_best_stats);
23095
23116
 
23096
- /* "obliquetree/src/metric.pyx":1005
23117
+ /* "obliquetree/src/metric.pyx":1006
23097
23118
  * if new_indices != NULL:
23098
23119
  * free(new_indices)
23099
23120
  * if best_stats != NULL: # <<<<<<<<<<<<<<
@@ -23102,7 +23123,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23102
23123
  */
23103
23124
  }
23104
23125
 
23105
- /* "obliquetree/src/metric.pyx":1009
23126
+ /* "obliquetree/src/metric.pyx":1010
23106
23127
  *
23107
23128
  * # class_weights belleklerini serbest brak
23108
23129
  * if stats != NULL: # <<<<<<<<<<<<<<
@@ -23112,7 +23133,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23112
23133
  __pyx_t_1 = (__pyx_v_stats != NULL);
23113
23134
  if (__pyx_t_1) {
23114
23135
 
23115
- /* "obliquetree/src/metric.pyx":1010
23136
+ /* "obliquetree/src/metric.pyx":1011
23116
23137
  * # class_weights belleklerini serbest brak
23117
23138
  * if stats != NULL:
23118
23139
  * for i in range(unique_count): # <<<<<<<<<<<<<<
@@ -23124,7 +23145,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23124
23145
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
23125
23146
  __pyx_v_i = __pyx_t_5;
23126
23147
 
23127
- /* "obliquetree/src/metric.pyx":1011
23148
+ /* "obliquetree/src/metric.pyx":1012
23128
23149
  * if stats != NULL:
23129
23150
  * for i in range(unique_count):
23130
23151
  * if stats[i].class_weights != NULL: # <<<<<<<<<<<<<<
@@ -23134,7 +23155,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23134
23155
  __pyx_t_1 = ((__pyx_v_stats[__pyx_v_i]).class_weights != NULL);
23135
23156
  if (__pyx_t_1) {
23136
23157
 
23137
- /* "obliquetree/src/metric.pyx":1012
23158
+ /* "obliquetree/src/metric.pyx":1013
23138
23159
  * for i in range(unique_count):
23139
23160
  * if stats[i].class_weights != NULL:
23140
23161
  * free(stats[i].class_weights) # <<<<<<<<<<<<<<
@@ -23143,7 +23164,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23143
23164
  */
23144
23165
  free((__pyx_v_stats[__pyx_v_i]).class_weights);
23145
23166
 
23146
- /* "obliquetree/src/metric.pyx":1013
23167
+ /* "obliquetree/src/metric.pyx":1014
23147
23168
  * if stats[i].class_weights != NULL:
23148
23169
  * free(stats[i].class_weights)
23149
23170
  * stats[i].class_weights = NULL # <<<<<<<<<<<<<<
@@ -23152,7 +23173,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23152
23173
  */
23153
23174
  (__pyx_v_stats[__pyx_v_i]).class_weights = NULL;
23154
23175
 
23155
- /* "obliquetree/src/metric.pyx":1011
23176
+ /* "obliquetree/src/metric.pyx":1012
23156
23177
  * if stats != NULL:
23157
23178
  * for i in range(unique_count):
23158
23179
  * if stats[i].class_weights != NULL: # <<<<<<<<<<<<<<
@@ -23162,7 +23183,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23162
23183
  }
23163
23184
  }
23164
23185
 
23165
- /* "obliquetree/src/metric.pyx":1009
23186
+ /* "obliquetree/src/metric.pyx":1010
23166
23187
  *
23167
23188
  * # class_weights belleklerini serbest brak
23168
23189
  * if stats != NULL: # <<<<<<<<<<<<<<
@@ -23171,7 +23192,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23171
23192
  */
23172
23193
  }
23173
23194
 
23174
- /* "obliquetree/src/metric.pyx":1016
23195
+ /* "obliquetree/src/metric.pyx":1017
23175
23196
  *
23176
23197
  * # permtasyon belleklerini serbest brak
23177
23198
  * if perm_orders != NULL: # <<<<<<<<<<<<<<
@@ -23181,7 +23202,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23181
23202
  __pyx_t_1 = (__pyx_v_perm_orders != NULL);
23182
23203
  if (__pyx_t_1) {
23183
23204
 
23184
- /* "obliquetree/src/metric.pyx":1017
23205
+ /* "obliquetree/src/metric.pyx":1018
23185
23206
  * # permtasyon belleklerini serbest brak
23186
23207
  * if perm_orders != NULL:
23187
23208
  * for i in range(perm_count): # <<<<<<<<<<<<<<
@@ -23193,7 +23214,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23193
23214
  for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
23194
23215
  __pyx_v_i = __pyx_t_5;
23195
23216
 
23196
- /* "obliquetree/src/metric.pyx":1018
23217
+ /* "obliquetree/src/metric.pyx":1019
23197
23218
  * if perm_orders != NULL:
23198
23219
  * for i in range(perm_count):
23199
23220
  * if perm_orders[i] != NULL: # <<<<<<<<<<<<<<
@@ -23203,7 +23224,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23203
23224
  __pyx_t_1 = ((__pyx_v_perm_orders[__pyx_v_i]) != NULL);
23204
23225
  if (__pyx_t_1) {
23205
23226
 
23206
- /* "obliquetree/src/metric.pyx":1019
23227
+ /* "obliquetree/src/metric.pyx":1020
23207
23228
  * for i in range(perm_count):
23208
23229
  * if perm_orders[i] != NULL:
23209
23230
  * free(perm_orders[i]) # <<<<<<<<<<<<<<
@@ -23212,7 +23233,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23212
23233
  */
23213
23234
  free((__pyx_v_perm_orders[__pyx_v_i]));
23214
23235
 
23215
- /* "obliquetree/src/metric.pyx":1018
23236
+ /* "obliquetree/src/metric.pyx":1019
23216
23237
  * if perm_orders != NULL:
23217
23238
  * for i in range(perm_count):
23218
23239
  * if perm_orders[i] != NULL: # <<<<<<<<<<<<<<
@@ -23222,7 +23243,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23222
23243
  }
23223
23244
  }
23224
23245
 
23225
- /* "obliquetree/src/metric.pyx":1020
23246
+ /* "obliquetree/src/metric.pyx":1021
23226
23247
  * if perm_orders[i] != NULL:
23227
23248
  * free(perm_orders[i])
23228
23249
  * free(perm_orders) # <<<<<<<<<<<<<<
@@ -23231,7 +23252,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23231
23252
  */
23232
23253
  free(__pyx_v_perm_orders);
23233
23254
 
23234
- /* "obliquetree/src/metric.pyx":1016
23255
+ /* "obliquetree/src/metric.pyx":1017
23235
23256
  *
23236
23257
  * # permtasyon belleklerini serbest brak
23237
23258
  * if perm_orders != NULL: # <<<<<<<<<<<<<<
@@ -23260,7 +23281,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23260
23281
  __Pyx_PyGILState_Release(__pyx_gilstate_save);
23261
23282
  {
23262
23283
 
23263
- /* "obliquetree/src/metric.pyx":998
23284
+ /* "obliquetree/src/metric.pyx":999
23264
23285
  *
23265
23286
  * # Fonksiyonun sonunda toplu free
23266
23287
  * free(total_class_weights) # <<<<<<<<<<<<<<
@@ -23269,7 +23290,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23269
23290
  */
23270
23291
  free(__pyx_v_total_class_weights);
23271
23292
 
23272
- /* "obliquetree/src/metric.pyx":999
23293
+ /* "obliquetree/src/metric.pyx":1000
23273
23294
  * # Fonksiyonun sonunda toplu free
23274
23295
  * free(total_class_weights)
23275
23296
  * free(nan_class_weights) # <<<<<<<<<<<<<<
@@ -23278,7 +23299,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23278
23299
  */
23279
23300
  free(__pyx_v_nan_class_weights);
23280
23301
 
23281
- /* "obliquetree/src/metric.pyx":1001
23302
+ /* "obliquetree/src/metric.pyx":1002
23282
23303
  * free(nan_class_weights)
23283
23304
  *
23284
23305
  * if stats_count != NULL: # <<<<<<<<<<<<<<
@@ -23288,7 +23309,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23288
23309
  __pyx_t_1 = (__pyx_v_stats_count != NULL);
23289
23310
  if (__pyx_t_1) {
23290
23311
 
23291
- /* "obliquetree/src/metric.pyx":1002
23312
+ /* "obliquetree/src/metric.pyx":1003
23292
23313
  *
23293
23314
  * if stats_count != NULL:
23294
23315
  * free(stats_count) # <<<<<<<<<<<<<<
@@ -23297,7 +23318,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23297
23318
  */
23298
23319
  free(__pyx_v_stats_count);
23299
23320
 
23300
- /* "obliquetree/src/metric.pyx":1001
23321
+ /* "obliquetree/src/metric.pyx":1002
23301
23322
  * free(nan_class_weights)
23302
23323
  *
23303
23324
  * if stats_count != NULL: # <<<<<<<<<<<<<<
@@ -23306,7 +23327,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23306
23327
  */
23307
23328
  }
23308
23329
 
23309
- /* "obliquetree/src/metric.pyx":1003
23330
+ /* "obliquetree/src/metric.pyx":1004
23310
23331
  * if stats_count != NULL:
23311
23332
  * free(stats_count)
23312
23333
  * if new_indices != NULL: # <<<<<<<<<<<<<<
@@ -23316,7 +23337,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23316
23337
  __pyx_t_1 = (__pyx_v_new_indices != NULL);
23317
23338
  if (__pyx_t_1) {
23318
23339
 
23319
- /* "obliquetree/src/metric.pyx":1004
23340
+ /* "obliquetree/src/metric.pyx":1005
23320
23341
  * free(stats_count)
23321
23342
  * if new_indices != NULL:
23322
23343
  * free(new_indices) # <<<<<<<<<<<<<<
@@ -23325,7 +23346,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23325
23346
  */
23326
23347
  free(__pyx_v_new_indices);
23327
23348
 
23328
- /* "obliquetree/src/metric.pyx":1003
23349
+ /* "obliquetree/src/metric.pyx":1004
23329
23350
  * if stats_count != NULL:
23330
23351
  * free(stats_count)
23331
23352
  * if new_indices != NULL: # <<<<<<<<<<<<<<
@@ -23334,7 +23355,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23334
23355
  */
23335
23356
  }
23336
23357
 
23337
- /* "obliquetree/src/metric.pyx":1005
23358
+ /* "obliquetree/src/metric.pyx":1006
23338
23359
  * if new_indices != NULL:
23339
23360
  * free(new_indices)
23340
23361
  * if best_stats != NULL: # <<<<<<<<<<<<<<
@@ -23344,7 +23365,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23344
23365
  __pyx_t_1 = (__pyx_v_best_stats != NULL);
23345
23366
  if (__pyx_t_1) {
23346
23367
 
23347
- /* "obliquetree/src/metric.pyx":1006
23368
+ /* "obliquetree/src/metric.pyx":1007
23348
23369
  * free(new_indices)
23349
23370
  * if best_stats != NULL:
23350
23371
  * free(best_stats) # <<<<<<<<<<<<<<
@@ -23353,7 +23374,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23353
23374
  */
23354
23375
  free(__pyx_v_best_stats);
23355
23376
 
23356
- /* "obliquetree/src/metric.pyx":1005
23377
+ /* "obliquetree/src/metric.pyx":1006
23357
23378
  * if new_indices != NULL:
23358
23379
  * free(new_indices)
23359
23380
  * if best_stats != NULL: # <<<<<<<<<<<<<<
@@ -23362,7 +23383,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23362
23383
  */
23363
23384
  }
23364
23385
 
23365
- /* "obliquetree/src/metric.pyx":1009
23386
+ /* "obliquetree/src/metric.pyx":1010
23366
23387
  *
23367
23388
  * # class_weights belleklerini serbest brak
23368
23389
  * if stats != NULL: # <<<<<<<<<<<<<<
@@ -23372,7 +23393,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23372
23393
  __pyx_t_1 = (__pyx_v_stats != NULL);
23373
23394
  if (__pyx_t_1) {
23374
23395
 
23375
- /* "obliquetree/src/metric.pyx":1010
23396
+ /* "obliquetree/src/metric.pyx":1011
23376
23397
  * # class_weights belleklerini serbest brak
23377
23398
  * if stats != NULL:
23378
23399
  * for i in range(unique_count): # <<<<<<<<<<<<<<
@@ -23384,7 +23405,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23384
23405
  for (__pyx_t_8 = 0; __pyx_t_8 < __pyx_t_6; __pyx_t_8+=1) {
23385
23406
  __pyx_v_i = __pyx_t_8;
23386
23407
 
23387
- /* "obliquetree/src/metric.pyx":1011
23408
+ /* "obliquetree/src/metric.pyx":1012
23388
23409
  * if stats != NULL:
23389
23410
  * for i in range(unique_count):
23390
23411
  * if stats[i].class_weights != NULL: # <<<<<<<<<<<<<<
@@ -23394,7 +23415,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23394
23415
  __pyx_t_1 = ((__pyx_v_stats[__pyx_v_i]).class_weights != NULL);
23395
23416
  if (__pyx_t_1) {
23396
23417
 
23397
- /* "obliquetree/src/metric.pyx":1012
23418
+ /* "obliquetree/src/metric.pyx":1013
23398
23419
  * for i in range(unique_count):
23399
23420
  * if stats[i].class_weights != NULL:
23400
23421
  * free(stats[i].class_weights) # <<<<<<<<<<<<<<
@@ -23403,7 +23424,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23403
23424
  */
23404
23425
  free((__pyx_v_stats[__pyx_v_i]).class_weights);
23405
23426
 
23406
- /* "obliquetree/src/metric.pyx":1013
23427
+ /* "obliquetree/src/metric.pyx":1014
23407
23428
  * if stats[i].class_weights != NULL:
23408
23429
  * free(stats[i].class_weights)
23409
23430
  * stats[i].class_weights = NULL # <<<<<<<<<<<<<<
@@ -23412,7 +23433,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23412
23433
  */
23413
23434
  (__pyx_v_stats[__pyx_v_i]).class_weights = NULL;
23414
23435
 
23415
- /* "obliquetree/src/metric.pyx":1011
23436
+ /* "obliquetree/src/metric.pyx":1012
23416
23437
  * if stats != NULL:
23417
23438
  * for i in range(unique_count):
23418
23439
  * if stats[i].class_weights != NULL: # <<<<<<<<<<<<<<
@@ -23422,7 +23443,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23422
23443
  }
23423
23444
  }
23424
23445
 
23425
- /* "obliquetree/src/metric.pyx":1009
23446
+ /* "obliquetree/src/metric.pyx":1010
23426
23447
  *
23427
23448
  * # class_weights belleklerini serbest brak
23428
23449
  * if stats != NULL: # <<<<<<<<<<<<<<
@@ -23431,7 +23452,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23431
23452
  */
23432
23453
  }
23433
23454
 
23434
- /* "obliquetree/src/metric.pyx":1016
23455
+ /* "obliquetree/src/metric.pyx":1017
23435
23456
  *
23436
23457
  * # permtasyon belleklerini serbest brak
23437
23458
  * if perm_orders != NULL: # <<<<<<<<<<<<<<
@@ -23441,7 +23462,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23441
23462
  __pyx_t_1 = (__pyx_v_perm_orders != NULL);
23442
23463
  if (__pyx_t_1) {
23443
23464
 
23444
- /* "obliquetree/src/metric.pyx":1017
23465
+ /* "obliquetree/src/metric.pyx":1018
23445
23466
  * # permtasyon belleklerini serbest brak
23446
23467
  * if perm_orders != NULL:
23447
23468
  * for i in range(perm_count): # <<<<<<<<<<<<<<
@@ -23453,7 +23474,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23453
23474
  for (__pyx_t_8 = 0; __pyx_t_8 < __pyx_t_6; __pyx_t_8+=1) {
23454
23475
  __pyx_v_i = __pyx_t_8;
23455
23476
 
23456
- /* "obliquetree/src/metric.pyx":1018
23477
+ /* "obliquetree/src/metric.pyx":1019
23457
23478
  * if perm_orders != NULL:
23458
23479
  * for i in range(perm_count):
23459
23480
  * if perm_orders[i] != NULL: # <<<<<<<<<<<<<<
@@ -23463,7 +23484,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23463
23484
  __pyx_t_1 = ((__pyx_v_perm_orders[__pyx_v_i]) != NULL);
23464
23485
  if (__pyx_t_1) {
23465
23486
 
23466
- /* "obliquetree/src/metric.pyx":1019
23487
+ /* "obliquetree/src/metric.pyx":1020
23467
23488
  * for i in range(perm_count):
23468
23489
  * if perm_orders[i] != NULL:
23469
23490
  * free(perm_orders[i]) # <<<<<<<<<<<<<<
@@ -23472,7 +23493,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23472
23493
  */
23473
23494
  free((__pyx_v_perm_orders[__pyx_v_i]));
23474
23495
 
23475
- /* "obliquetree/src/metric.pyx":1018
23496
+ /* "obliquetree/src/metric.pyx":1019
23476
23497
  * if perm_orders != NULL:
23477
23498
  * for i in range(perm_count):
23478
23499
  * if perm_orders[i] != NULL: # <<<<<<<<<<<<<<
@@ -23482,7 +23503,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23482
23503
  }
23483
23504
  }
23484
23505
 
23485
- /* "obliquetree/src/metric.pyx":1020
23506
+ /* "obliquetree/src/metric.pyx":1021
23486
23507
  * if perm_orders[i] != NULL:
23487
23508
  * free(perm_orders[i])
23488
23509
  * free(perm_orders) # <<<<<<<<<<<<<<
@@ -23491,7 +23512,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23491
23512
  */
23492
23513
  free(__pyx_v_perm_orders);
23493
23514
 
23494
- /* "obliquetree/src/metric.pyx":1016
23515
+ /* "obliquetree/src/metric.pyx":1017
23495
23516
  *
23496
23517
  * # permtasyon belleklerini serbest brak
23497
23518
  * if perm_orders != NULL: # <<<<<<<<<<<<<<
@@ -23518,7 +23539,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23518
23539
  __pyx_L13:;
23519
23540
  }
23520
23541
 
23521
- /* "obliquetree/src/metric.pyx":1022
23542
+ /* "obliquetree/src/metric.pyx":1023
23522
23543
  * free(perm_orders)
23523
23544
  *
23524
23545
  * return best_impurity # <<<<<<<<<<<<<<
@@ -23547,7 +23568,7 @@ static double __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical
23547
23568
  return __pyx_r;
23548
23569
  }
23549
23570
 
23550
- /* "obliquetree/src/metric.pyx":1025
23571
+ /* "obliquetree/src/metric.pyx":1026
23551
23572
  *
23552
23573
  *
23553
23574
  * cdef double calculate_impurity( # <<<<<<<<<<<<<<
@@ -23560,7 +23581,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23560
23581
  double __pyx_r;
23561
23582
  int __pyx_t_1;
23562
23583
 
23563
- /* "obliquetree/src/metric.pyx":1043
23584
+ /* "obliquetree/src/metric.pyx":1044
23564
23585
  * cdef double impurity_c
23565
23586
  *
23566
23587
  * if is_categorical: # <<<<<<<<<<<<<<
@@ -23570,7 +23591,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23570
23591
  __pyx_t_1 = (__pyx_v_is_categorical != 0);
23571
23592
  if (__pyx_t_1) {
23572
23593
 
23573
- /* "obliquetree/src/metric.pyx":1044
23594
+ /* "obliquetree/src/metric.pyx":1045
23574
23595
  *
23575
23596
  * if is_categorical:
23576
23597
  * if n_classes > 2: # <<<<<<<<<<<<<<
@@ -23580,7 +23601,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23580
23601
  __pyx_t_1 = (__pyx_v_n_classes > 2);
23581
23602
  if (__pyx_t_1) {
23582
23603
 
23583
- /* "obliquetree/src/metric.pyx":1045
23604
+ /* "obliquetree/src/metric.pyx":1046
23584
23605
  * if is_categorical:
23585
23606
  * if n_classes > 2:
23586
23607
  * impurity_c = find_best_split_for_categorical_multiclass( # <<<<<<<<<<<<<<
@@ -23589,7 +23610,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23589
23610
  */
23590
23611
  __pyx_v_impurity_c = __pyx_f_11obliquetree_3src_6metric_find_best_split_for_categorical_multiclass(__pyx_v_sort_buffer, __pyx_v_sample_weight, __pyx_v_y, __pyx_v_nan_indices, __pyx_v_categorical_stats, __pyx_v_n_samples, __pyx_v_n_nans, __pyx_v_min_samples_leaf, __pyx_v_n_classes, __pyx_v_threshold_c, __pyx_v_left_count_c, __pyx_v_missing_go_left);
23591
23612
 
23592
- /* "obliquetree/src/metric.pyx":1044
23613
+ /* "obliquetree/src/metric.pyx":1045
23593
23614
  *
23594
23615
  * if is_categorical:
23595
23616
  * if n_classes > 2: # <<<<<<<<<<<<<<
@@ -23599,7 +23620,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23599
23620
  goto __pyx_L4;
23600
23621
  }
23601
23622
 
23602
- /* "obliquetree/src/metric.pyx":1062
23623
+ /* "obliquetree/src/metric.pyx":1063
23603
23624
  *
23604
23625
  * else:
23605
23626
  * impurity_c = find_best_split_for_categorical( # <<<<<<<<<<<<<<
@@ -23608,7 +23629,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23608
23629
  */
23609
23630
  /*else*/ {
23610
23631
 
23611
- /* "obliquetree/src/metric.pyx":1074
23632
+ /* "obliquetree/src/metric.pyx":1075
23612
23633
  * threshold_c,
23613
23634
  * left_count_c,
23614
23635
  * missing_go_left, # <<<<<<<<<<<<<<
@@ -23619,7 +23640,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23619
23640
  }
23620
23641
  __pyx_L4:;
23621
23642
 
23622
- /* "obliquetree/src/metric.pyx":1043
23643
+ /* "obliquetree/src/metric.pyx":1044
23623
23644
  * cdef double impurity_c
23624
23645
  *
23625
23646
  * if is_categorical: # <<<<<<<<<<<<<<
@@ -23629,7 +23650,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23629
23650
  goto __pyx_L3;
23630
23651
  }
23631
23652
 
23632
- /* "obliquetree/src/metric.pyx":1078
23653
+ /* "obliquetree/src/metric.pyx":1079
23633
23654
  *
23634
23655
  * else:
23635
23656
  * if n_classes > 2: # <<<<<<<<<<<<<<
@@ -23640,7 +23661,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23640
23661
  __pyx_t_1 = (__pyx_v_n_classes > 2);
23641
23662
  if (__pyx_t_1) {
23642
23663
 
23643
- /* "obliquetree/src/metric.pyx":1079
23664
+ /* "obliquetree/src/metric.pyx":1080
23644
23665
  * else:
23645
23666
  * if n_classes > 2:
23646
23667
  * impurity_c = find_best_split_for_feature_multiclass( # <<<<<<<<<<<<<<
@@ -23649,7 +23670,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23649
23670
  */
23650
23671
  __pyx_v_impurity_c = __pyx_f_11obliquetree_3src_6metric_find_best_split_for_feature_multiclass(__pyx_v_sort_buffer, __pyx_v_sample_weight, __pyx_v_y, __pyx_v_nan_indices, __pyx_v_n_samples, __pyx_v_n_nans, __pyx_v_min_samples_leaf, __pyx_v_n_classes, __pyx_v_threshold_c, __pyx_v_left_count_c, __pyx_v_missing_go_left);
23651
23672
 
23652
- /* "obliquetree/src/metric.pyx":1078
23673
+ /* "obliquetree/src/metric.pyx":1079
23653
23674
  *
23654
23675
  * else:
23655
23676
  * if n_classes > 2: # <<<<<<<<<<<<<<
@@ -23659,7 +23680,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23659
23680
  goto __pyx_L5;
23660
23681
  }
23661
23682
 
23662
- /* "obliquetree/src/metric.pyx":1094
23683
+ /* "obliquetree/src/metric.pyx":1095
23663
23684
  *
23664
23685
  * else:
23665
23686
  * impurity_c = find_best_split_for_feature( # <<<<<<<<<<<<<<
@@ -23668,7 +23689,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23668
23689
  */
23669
23690
  /*else*/ {
23670
23691
 
23671
- /* "obliquetree/src/metric.pyx":1105
23692
+ /* "obliquetree/src/metric.pyx":1106
23672
23693
  * threshold_c,
23673
23694
  * left_count_c,
23674
23695
  * missing_go_left, # <<<<<<<<<<<<<<
@@ -23681,7 +23702,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23681
23702
  }
23682
23703
  __pyx_L3:;
23683
23704
 
23684
- /* "obliquetree/src/metric.pyx":1107
23705
+ /* "obliquetree/src/metric.pyx":1108
23685
23706
  * missing_go_left,
23686
23707
  * )
23687
23708
  * return impurity_c # <<<<<<<<<<<<<<
@@ -23689,7 +23710,7 @@ static double __pyx_f_11obliquetree_3src_6metric_calculate_impurity(int const __
23689
23710
  __pyx_r = __pyx_v_impurity_c;
23690
23711
  goto __pyx_L0;
23691
23712
 
23692
- /* "obliquetree/src/metric.pyx":1025
23713
+ /* "obliquetree/src/metric.pyx":1026
23693
23714
  *
23694
23715
  *
23695
23716
  * cdef double calculate_impurity( # <<<<<<<<<<<<<<
@@ -24682,35 +24703,35 @@ static int __Pyx_modinit_type_init_code(__pyx_mstatetype *__pyx_mstate) {
24682
24703
  #else
24683
24704
  #warning "The buffer protocol is not supported in the Limited C-API < 3.11."
24684
24705
  #endif
24685
- if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_array_spec, __pyx_mstate->__pyx_array_type) < 0) __PYX_ERR(1, 110, __pyx_L1_error)
24706
+ if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_array_spec, __pyx_mstate->__pyx_array_type) < (0)) __PYX_ERR(1, 110, __pyx_L1_error)
24686
24707
  #else
24687
24708
  __pyx_mstate->__pyx_array_type = &__pyx_type___pyx_array;
24688
24709
  #endif
24689
24710
  #if !CYTHON_COMPILING_IN_LIMITED_API
24690
24711
  #endif
24691
24712
  #if !CYTHON_USE_TYPE_SPECS
24692
- if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_array_type) < 0) __PYX_ERR(1, 110, __pyx_L1_error)
24713
+ if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_array_type) < (0)) __PYX_ERR(1, 110, __pyx_L1_error)
24693
24714
  #endif
24694
- if (__Pyx_SetVtable(__pyx_mstate->__pyx_array_type, __pyx_vtabptr_array) < 0) __PYX_ERR(1, 110, __pyx_L1_error)
24695
- if (__Pyx_MergeVtables(__pyx_mstate->__pyx_array_type) < 0) __PYX_ERR(1, 110, __pyx_L1_error)
24696
- if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_array_type) < 0) __PYX_ERR(1, 110, __pyx_L1_error)
24715
+ if (__Pyx_SetVtable(__pyx_mstate->__pyx_array_type, __pyx_vtabptr_array) < (0)) __PYX_ERR(1, 110, __pyx_L1_error)
24716
+ if (__Pyx_MergeVtables(__pyx_mstate->__pyx_array_type) < (0)) __PYX_ERR(1, 110, __pyx_L1_error)
24717
+ if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_array_type) < (0)) __PYX_ERR(1, 110, __pyx_L1_error)
24697
24718
  #if CYTHON_USE_TYPE_SPECS
24698
24719
  __pyx_mstate->__pyx_MemviewEnum_type = (PyTypeObject *) __Pyx_PyType_FromModuleAndSpec(__pyx_m, &__pyx_type___pyx_MemviewEnum_spec, NULL); if (unlikely(!__pyx_mstate->__pyx_MemviewEnum_type)) __PYX_ERR(1, 299, __pyx_L1_error)
24699
- if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_MemviewEnum_spec, __pyx_mstate->__pyx_MemviewEnum_type) < 0) __PYX_ERR(1, 299, __pyx_L1_error)
24720
+ if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_MemviewEnum_spec, __pyx_mstate->__pyx_MemviewEnum_type) < (0)) __PYX_ERR(1, 299, __pyx_L1_error)
24700
24721
  #else
24701
24722
  __pyx_mstate->__pyx_MemviewEnum_type = &__pyx_type___pyx_MemviewEnum;
24702
24723
  #endif
24703
24724
  #if !CYTHON_COMPILING_IN_LIMITED_API
24704
24725
  #endif
24705
24726
  #if !CYTHON_USE_TYPE_SPECS
24706
- if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_MemviewEnum_type) < 0) __PYX_ERR(1, 299, __pyx_L1_error)
24727
+ if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_MemviewEnum_type) < (0)) __PYX_ERR(1, 299, __pyx_L1_error)
24707
24728
  #endif
24708
24729
  #if !CYTHON_COMPILING_IN_LIMITED_API
24709
24730
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_mstate->__pyx_MemviewEnum_type->tp_dictoffset && __pyx_mstate->__pyx_MemviewEnum_type->tp_getattro == PyObject_GenericGetAttr)) {
24710
24731
  __pyx_mstate->__pyx_MemviewEnum_type->tp_getattro = PyObject_GenericGetAttr;
24711
24732
  }
24712
24733
  #endif
24713
- if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_MemviewEnum_type) < 0) __PYX_ERR(1, 299, __pyx_L1_error)
24734
+ if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_MemviewEnum_type) < (0)) __PYX_ERR(1, 299, __pyx_L1_error)
24714
24735
  __pyx_vtabptr_memoryview = &__pyx_vtable_memoryview;
24715
24736
  __pyx_vtable_memoryview.get_item_pointer = (char *(*)(struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_get_item_pointer;
24716
24737
  __pyx_vtable_memoryview.is_slice = (PyObject *(*)(struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_is_slice;
@@ -24734,23 +24755,23 @@ static int __Pyx_modinit_type_init_code(__pyx_mstatetype *__pyx_mstate) {
24734
24755
  #else
24735
24756
  #warning "The buffer protocol is not supported in the Limited C-API < 3.11."
24736
24757
  #endif
24737
- if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_memoryview_spec, __pyx_mstate->__pyx_memoryview_type) < 0) __PYX_ERR(1, 334, __pyx_L1_error)
24758
+ if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_memoryview_spec, __pyx_mstate->__pyx_memoryview_type) < (0)) __PYX_ERR(1, 334, __pyx_L1_error)
24738
24759
  #else
24739
24760
  __pyx_mstate->__pyx_memoryview_type = &__pyx_type___pyx_memoryview;
24740
24761
  #endif
24741
24762
  #if !CYTHON_COMPILING_IN_LIMITED_API
24742
24763
  #endif
24743
24764
  #if !CYTHON_USE_TYPE_SPECS
24744
- if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_memoryview_type) < 0) __PYX_ERR(1, 334, __pyx_L1_error)
24765
+ if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_memoryview_type) < (0)) __PYX_ERR(1, 334, __pyx_L1_error)
24745
24766
  #endif
24746
24767
  #if !CYTHON_COMPILING_IN_LIMITED_API
24747
24768
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_mstate->__pyx_memoryview_type->tp_dictoffset && __pyx_mstate->__pyx_memoryview_type->tp_getattro == PyObject_GenericGetAttr)) {
24748
24769
  __pyx_mstate->__pyx_memoryview_type->tp_getattro = PyObject_GenericGetAttr;
24749
24770
  }
24750
24771
  #endif
24751
- if (__Pyx_SetVtable(__pyx_mstate->__pyx_memoryview_type, __pyx_vtabptr_memoryview) < 0) __PYX_ERR(1, 334, __pyx_L1_error)
24752
- if (__Pyx_MergeVtables(__pyx_mstate->__pyx_memoryview_type) < 0) __PYX_ERR(1, 334, __pyx_L1_error)
24753
- if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_memoryview_type) < 0) __PYX_ERR(1, 334, __pyx_L1_error)
24772
+ if (__Pyx_SetVtable(__pyx_mstate->__pyx_memoryview_type, __pyx_vtabptr_memoryview) < (0)) __PYX_ERR(1, 334, __pyx_L1_error)
24773
+ if (__Pyx_MergeVtables(__pyx_mstate->__pyx_memoryview_type) < (0)) __PYX_ERR(1, 334, __pyx_L1_error)
24774
+ if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_memoryview_type) < (0)) __PYX_ERR(1, 334, __pyx_L1_error)
24754
24775
  __pyx_vtabptr__memoryviewslice = &__pyx_vtable__memoryviewslice;
24755
24776
  __pyx_vtable__memoryviewslice.__pyx_base = *__pyx_vtabptr_memoryview;
24756
24777
  __pyx_vtable__memoryviewslice.__pyx_base.convert_item_to_object = (PyObject *(*)(struct __pyx_memoryview_obj *, char *))__pyx_memoryviewslice_convert_item_to_object;
@@ -24762,7 +24783,7 @@ static int __Pyx_modinit_type_init_code(__pyx_mstatetype *__pyx_mstate) {
24762
24783
  __pyx_mstate->__pyx_memoryviewslice_type = (PyTypeObject *) __Pyx_PyType_FromModuleAndSpec(__pyx_m, &__pyx_type___pyx_memoryviewslice_spec, __pyx_t_1);
24763
24784
  __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
24764
24785
  if (unlikely(!__pyx_mstate->__pyx_memoryviewslice_type)) __PYX_ERR(1, 950, __pyx_L1_error)
24765
- if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_memoryviewslice_spec, __pyx_mstate->__pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 950, __pyx_L1_error)
24786
+ if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_memoryviewslice_spec, __pyx_mstate->__pyx_memoryviewslice_type) < (0)) __PYX_ERR(1, 950, __pyx_L1_error)
24766
24787
  #else
24767
24788
  __pyx_mstate->__pyx_memoryviewslice_type = &__pyx_type___pyx_memoryviewslice;
24768
24789
  #endif
@@ -24770,16 +24791,16 @@ static int __Pyx_modinit_type_init_code(__pyx_mstatetype *__pyx_mstate) {
24770
24791
  __pyx_mstate_global->__pyx_memoryviewslice_type->tp_base = __pyx_mstate_global->__pyx_memoryview_type;
24771
24792
  #endif
24772
24793
  #if !CYTHON_USE_TYPE_SPECS
24773
- if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 950, __pyx_L1_error)
24794
+ if (__Pyx_PyType_Ready(__pyx_mstate->__pyx_memoryviewslice_type) < (0)) __PYX_ERR(1, 950, __pyx_L1_error)
24774
24795
  #endif
24775
24796
  #if !CYTHON_COMPILING_IN_LIMITED_API
24776
24797
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_mstate->__pyx_memoryviewslice_type->tp_dictoffset && __pyx_mstate->__pyx_memoryviewslice_type->tp_getattro == PyObject_GenericGetAttr)) {
24777
24798
  __pyx_mstate->__pyx_memoryviewslice_type->tp_getattro = PyObject_GenericGetAttr;
24778
24799
  }
24779
24800
  #endif
24780
- if (__Pyx_SetVtable(__pyx_mstate->__pyx_memoryviewslice_type, __pyx_vtabptr__memoryviewslice) < 0) __PYX_ERR(1, 950, __pyx_L1_error)
24781
- if (__Pyx_MergeVtables(__pyx_mstate->__pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 950, __pyx_L1_error)
24782
- if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 950, __pyx_L1_error)
24801
+ if (__Pyx_SetVtable(__pyx_mstate->__pyx_memoryviewslice_type, __pyx_vtabptr__memoryviewslice) < (0)) __PYX_ERR(1, 950, __pyx_L1_error)
24802
+ if (__Pyx_MergeVtables(__pyx_mstate->__pyx_memoryviewslice_type) < (0)) __PYX_ERR(1, 950, __pyx_L1_error)
24803
+ if (__Pyx_setup_reduce((PyObject *) __pyx_mstate->__pyx_memoryviewslice_type) < (0)) __PYX_ERR(1, 950, __pyx_L1_error)
24783
24804
  __Pyx_RefNannyFinishContext();
24784
24805
  return 0;
24785
24806
  __pyx_L1_error:;
@@ -24799,15 +24820,15 @@ static int __Pyx_modinit_type_import_code(__pyx_mstatetype *__pyx_mstate) {
24799
24820
  /*--- Type import code ---*/
24800
24821
  __pyx_t_1 = PyImport_ImportModule("obliquetree.src.base"); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 4, __pyx_L1_error)
24801
24822
  __Pyx_GOTREF(__pyx_t_1);
24802
- __pyx_mstate->__pyx_ptype_11obliquetree_3src_4base_TreeClassifier = __Pyx_ImportType_3_1_2(__pyx_t_1, "obliquetree.src.base", "TreeClassifier",
24823
+ __pyx_mstate->__pyx_ptype_11obliquetree_3src_4base_TreeClassifier = __Pyx_ImportType_3_1_6(__pyx_t_1, "obliquetree.src.base", "TreeClassifier",
24803
24824
  #if defined(PYPY_VERSION_NUM) && PYPY_VERSION_NUM < 0x050B0000
24804
- sizeof(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier), __PYX_GET_STRUCT_ALIGNMENT_3_1_2(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier),
24825
+ sizeof(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier), __PYX_GET_STRUCT_ALIGNMENT_3_1_6(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier),
24805
24826
  #elif CYTHON_COMPILING_IN_LIMITED_API
24806
- sizeof(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier), __PYX_GET_STRUCT_ALIGNMENT_3_1_2(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier),
24827
+ sizeof(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier), __PYX_GET_STRUCT_ALIGNMENT_3_1_6(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier),
24807
24828
  #else
24808
- sizeof(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier), __PYX_GET_STRUCT_ALIGNMENT_3_1_2(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier),
24829
+ sizeof(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier), __PYX_GET_STRUCT_ALIGNMENT_3_1_6(struct __pyx_obj_11obliquetree_3src_4base_TreeClassifier),
24809
24830
  #endif
24810
- __Pyx_ImportType_CheckSize_Warn_3_1_2); if (!__pyx_mstate->__pyx_ptype_11obliquetree_3src_4base_TreeClassifier) __PYX_ERR(2, 4, __pyx_L1_error)
24831
+ __Pyx_ImportType_CheckSize_Warn_3_1_6); if (!__pyx_mstate->__pyx_ptype_11obliquetree_3src_4base_TreeClassifier) __PYX_ERR(2, 4, __pyx_L1_error)
24811
24832
  __pyx_vtabptr_11obliquetree_3src_4base_TreeClassifier = (struct __pyx_vtabstruct_11obliquetree_3src_4base_TreeClassifier*)__Pyx_GetVtable(__pyx_mstate->__pyx_ptype_11obliquetree_3src_4base_TreeClassifier); if (unlikely(!__pyx_vtabptr_11obliquetree_3src_4base_TreeClassifier)) __PYX_ERR(2, 4, __pyx_L1_error)
24812
24833
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
24813
24834
  __Pyx_RefNannyFinishContext();
@@ -24838,9 +24859,9 @@ static int __Pyx_modinit_function_import_code(__pyx_mstatetype *__pyx_mstate) {
24838
24859
  /*--- Function import code ---*/
24839
24860
  __pyx_t_1 = PyImport_ImportModule("obliquetree.src.utils"); if (!__pyx_t_1) __PYX_ERR(0, 1, __pyx_L1_error)
24840
24861
  __Pyx_GOTREF(__pyx_t_1);
24841
- if (__Pyx_ImportFunction_3_1_2(__pyx_t_1, "sort_category_stats", (void (**)(void))&__pyx_f_11obliquetree_3src_5utils_sort_category_stats, "void (struct __pyx_t_11obliquetree_3src_4tree_CategoryStat *, int const )") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
24842
- if (__Pyx_ImportFunction_3_1_2(__pyx_t_1, "sort_category_stats_multiclass", (void (**)(void))&__pyx_f_11obliquetree_3src_5utils_sort_category_stats_multiclass, "void (struct __pyx_t_11obliquetree_3src_4tree_CategoryStat *, int const *, int const , int const )") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
24843
- if (__Pyx_ImportFunction_3_1_2(__pyx_t_1, "generate_permutations", (void (**)(void))&__pyx_f_11obliquetree_3src_5utils_generate_permutations, "int **(int const , int *)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
24862
+ if (__Pyx_ImportFunction_3_1_6(__pyx_t_1, "sort_category_stats", (void (**)(void))&__pyx_f_11obliquetree_3src_5utils_sort_category_stats, "void (struct __pyx_t_11obliquetree_3src_4tree_CategoryStat *, int const )") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
24863
+ if (__Pyx_ImportFunction_3_1_6(__pyx_t_1, "sort_category_stats_multiclass", (void (**)(void))&__pyx_f_11obliquetree_3src_5utils_sort_category_stats_multiclass, "void (struct __pyx_t_11obliquetree_3src_4tree_CategoryStat *, int const *, int const , int const )") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
24864
+ if (__Pyx_ImportFunction_3_1_6(__pyx_t_1, "generate_permutations", (void (**)(void))&__pyx_f_11obliquetree_3src_5utils_generate_permutations, "int **(int const , int *)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
24844
24865
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
24845
24866
  __Pyx_RefNannyFinishContext();
24846
24867
  return 0;
@@ -25085,7 +25106,7 @@ if (!__Pyx_RefNanny) {
25085
25106
  #endif
25086
25107
 
25087
25108
  __Pyx_RefNannySetupContext("PyInit_metric", 0);
25088
- if (__Pyx_check_binary_version(__PYX_LIMITED_VERSION_HEX, __Pyx_get_runtime_version(), CYTHON_COMPILING_IN_LIMITED_API) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25109
+ if (__Pyx_check_binary_version(__PYX_LIMITED_VERSION_HEX, __Pyx_get_runtime_version(), CYTHON_COMPILING_IN_LIMITED_API) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25089
25110
  #ifdef __Pxy_PyFrame_Initialize_Offsets
25090
25111
  __Pxy_PyFrame_Initialize_Offsets();
25091
25112
  #endif
@@ -25093,30 +25114,30 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25093
25114
  __pyx_mstate->__pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_mstate->__pyx_empty_bytes)) __PYX_ERR(0, 1, __pyx_L1_error)
25094
25115
  __pyx_mstate->__pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_mstate->__pyx_empty_unicode)) __PYX_ERR(0, 1, __pyx_L1_error)
25095
25116
  /*--- Initialize various global constants etc. ---*/
25096
- if (__Pyx_InitConstants(__pyx_mstate) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25117
+ if (__Pyx_InitConstants(__pyx_mstate) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25097
25118
  stringtab_initialized = 1;
25098
- if (__Pyx_InitGlobals() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25119
+ if (__Pyx_InitGlobals() < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25099
25120
  #if 0 || defined(__Pyx_CyFunction_USED) || defined(__Pyx_FusedFunction_USED) || defined(__Pyx_Coroutine_USED) || defined(__Pyx_Generator_USED) || defined(__Pyx_AsyncGen_USED)
25100
- if (__pyx_CommonTypesMetaclass_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25121
+ if (__pyx_CommonTypesMetaclass_init(__pyx_m) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25101
25122
  #endif
25102
25123
  #ifdef __Pyx_CyFunction_USED
25103
- if (__pyx_CyFunction_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25124
+ if (__pyx_CyFunction_init(__pyx_m) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25104
25125
  #endif
25105
25126
  #ifdef __Pyx_FusedFunction_USED
25106
- if (__pyx_FusedFunction_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25127
+ if (__pyx_FusedFunction_init(__pyx_m) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25107
25128
  #endif
25108
25129
  #ifdef __Pyx_Coroutine_USED
25109
- if (__pyx_Coroutine_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25130
+ if (__pyx_Coroutine_init(__pyx_m) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25110
25131
  #endif
25111
25132
  #ifdef __Pyx_Generator_USED
25112
- if (__pyx_Generator_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25133
+ if (__pyx_Generator_init(__pyx_m) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25113
25134
  #endif
25114
25135
  #ifdef __Pyx_AsyncGen_USED
25115
- if (__pyx_AsyncGen_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25136
+ if (__pyx_AsyncGen_init(__pyx_m) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25116
25137
  #endif
25117
25138
  /*--- Library function declarations ---*/
25118
25139
  if (__pyx_module_is_main_obliquetree__src__metric) {
25119
- if (PyObject_SetAttr(__pyx_m, __pyx_mstate_global->__pyx_n_u_name_2, __pyx_mstate_global->__pyx_n_u_main) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25140
+ if (PyObject_SetAttr(__pyx_m, __pyx_mstate_global->__pyx_n_u_name_2, __pyx_mstate_global->__pyx_n_u_main) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25120
25141
  }
25121
25142
  {
25122
25143
  PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(0, 1, __pyx_L1_error)
@@ -25125,10 +25146,10 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25125
25146
  }
25126
25147
  }
25127
25148
  /*--- Builtin init code ---*/
25128
- if (__Pyx_InitCachedBuiltins(__pyx_mstate) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25149
+ if (__Pyx_InitCachedBuiltins(__pyx_mstate) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25129
25150
  /*--- Constants init code ---*/
25130
- if (__Pyx_InitCachedConstants(__pyx_mstate) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25131
- if (__Pyx_CreateCodeObjects(__pyx_mstate) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25151
+ if (__Pyx_InitCachedConstants(__pyx_mstate) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25152
+ if (__Pyx_CreateCodeObjects(__pyx_mstate) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25132
25153
  /*--- Global type/function init code ---*/
25133
25154
  (void)__Pyx_modinit_global_init_code(__pyx_mstate);
25134
25155
  (void)__Pyx_modinit_variable_export_code(__pyx_mstate);
@@ -25279,7 +25300,7 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25279
25300
  */
25280
25301
  __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_mstate_global->__pyx_n_u_count); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 240, __pyx_L10_error)
25281
25302
  __Pyx_GOTREF(__pyx_t_5);
25282
- if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_array_type, __pyx_mstate_global->__pyx_n_u_count, __pyx_t_5) < 0) __PYX_ERR(1, 240, __pyx_L10_error)
25303
+ if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_array_type, __pyx_mstate_global->__pyx_n_u_count, __pyx_t_5) < (0)) __PYX_ERR(1, 240, __pyx_L10_error)
25283
25304
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25284
25305
 
25285
25306
  /* "View.MemoryView":241
@@ -25291,7 +25312,7 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25291
25312
  */
25292
25313
  __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_mstate_global->__pyx_n_u_index); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 241, __pyx_L10_error)
25293
25314
  __Pyx_GOTREF(__pyx_t_5);
25294
- if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_array_type, __pyx_mstate_global->__pyx_n_u_index, __pyx_t_5) < 0) __PYX_ERR(1, 241, __pyx_L10_error)
25315
+ if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_array_type, __pyx_mstate_global->__pyx_n_u_index, __pyx_t_5) < (0)) __PYX_ERR(1, 241, __pyx_L10_error)
25295
25316
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25296
25317
 
25297
25318
  /* "View.MemoryView":239
@@ -25501,7 +25522,7 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25501
25522
  */
25502
25523
  __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_mstate_global->__pyx_n_u_count); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 983, __pyx_L18_error)
25503
25524
  __Pyx_GOTREF(__pyx_t_5);
25504
- if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_memoryviewslice_type, __pyx_mstate_global->__pyx_n_u_count, __pyx_t_5) < 0) __PYX_ERR(1, 983, __pyx_L18_error)
25525
+ if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_memoryviewslice_type, __pyx_mstate_global->__pyx_n_u_count, __pyx_t_5) < (0)) __PYX_ERR(1, 983, __pyx_L18_error)
25505
25526
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25506
25527
 
25507
25528
  /* "View.MemoryView":984
@@ -25513,7 +25534,7 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25513
25534
  */
25514
25535
  __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_mstate_global->__pyx_n_u_index); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 984, __pyx_L18_error)
25515
25536
  __Pyx_GOTREF(__pyx_t_5);
25516
- if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_memoryviewslice_type, __pyx_mstate_global->__pyx_n_u_index, __pyx_t_5) < 0) __PYX_ERR(1, 984, __pyx_L18_error)
25537
+ if (__Pyx_SetItemOnTypeDict(__pyx_mstate_global->__pyx_memoryviewslice_type, __pyx_mstate_global->__pyx_n_u_index, __pyx_t_5) < (0)) __PYX_ERR(1, 984, __pyx_L18_error)
25517
25538
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25518
25539
 
25519
25540
  /* "View.MemoryView":982
@@ -25668,7 +25689,7 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25668
25689
  */
25669
25690
  __pyx_t_5 = PyCFunction_NewEx(&__pyx_mdef_15View_dot_MemoryView_1__pyx_unpickle_Enum, NULL, __pyx_mstate_global->__pyx_n_u_View_MemoryView); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1, __pyx_L1_error)
25670
25691
  __Pyx_GOTREF(__pyx_t_5);
25671
- if (PyDict_SetItem(__pyx_mstate_global->__pyx_d, __pyx_mstate_global->__pyx_n_u_pyx_unpickle_Enum, __pyx_t_5) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
25692
+ if (PyDict_SetItem(__pyx_mstate_global->__pyx_d, __pyx_mstate_global->__pyx_n_u_pyx_unpickle_Enum, __pyx_t_5) < (0)) __PYX_ERR(1, 1, __pyx_L1_error)
25672
25693
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25673
25694
 
25674
25695
  /* "obliquetree/src/metric.pyx":1
@@ -25678,7 +25699,7 @@ __Pyx_RefNannySetupContext("PyInit_metric", 0);
25678
25699
  */
25679
25700
  __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1, __pyx_L1_error)
25680
25701
  __Pyx_GOTREF(__pyx_t_5);
25681
- if (PyDict_SetItem(__pyx_mstate_global->__pyx_d, __pyx_mstate_global->__pyx_n_u_test, __pyx_t_5) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
25702
+ if (PyDict_SetItem(__pyx_mstate_global->__pyx_d, __pyx_mstate_global->__pyx_n_u_test, __pyx_t_5) < (0)) __PYX_ERR(0, 1, __pyx_L1_error)
25682
25703
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25683
25704
 
25684
25705
  /*--- Wrapped vars code ---*/
@@ -26164,7 +26185,7 @@ __Pyx_PyTuple_FromArray(PyObject *const *src, Py_ssize_t n)
26164
26185
  res = PyTuple_New(n);
26165
26186
  if (unlikely(res == NULL)) return NULL;
26166
26187
  for (i = 0; i < n; i++) {
26167
- if (unlikely(__Pyx_PyTuple_SET_ITEM(res, i, src[i]) < 0)) {
26188
+ if (unlikely(__Pyx_PyTuple_SET_ITEM(res, i, src[i]) < (0))) {
26168
26189
  Py_DECREF(res);
26169
26190
  return NULL;
26170
26191
  }
@@ -28902,6 +28923,7 @@ static int __Pyx_fix_up_extension_type_from_spec(PyType_Spec *spec, PyTypeObject
28902
28923
  changed = 1;
28903
28924
  }
28904
28925
  #endif // CYTHON_METH_FASTCALL
28926
+ #if !CYTHON_COMPILING_IN_PYPY
28905
28927
  else if (strcmp(memb->name, "__module__") == 0) {
28906
28928
  PyObject *descr;
28907
28929
  assert(memb->type == T_OBJECT);
@@ -28916,11 +28938,13 @@ static int __Pyx_fix_up_extension_type_from_spec(PyType_Spec *spec, PyTypeObject
28916
28938
  }
28917
28939
  changed = 1;
28918
28940
  }
28941
+ #endif // !CYTHON_COMPILING_IN_PYPY
28919
28942
  }
28920
28943
  memb++;
28921
28944
  }
28922
28945
  }
28923
28946
  #endif // !CYTHON_COMPILING_IN_LIMITED_API
28947
+ #if !CYTHON_COMPILING_IN_PYPY
28924
28948
  slot = spec->slots;
28925
28949
  while (slot && slot->slot && slot->slot != Py_tp_getset)
28926
28950
  slot++;
@@ -28952,6 +28976,7 @@ static int __Pyx_fix_up_extension_type_from_spec(PyType_Spec *spec, PyTypeObject
28952
28976
  ++getset;
28953
28977
  }
28954
28978
  }
28979
+ #endif // !CYTHON_COMPILING_IN_PYPY
28955
28980
  if (changed)
28956
28981
  PyType_Modified(type);
28957
28982
  #endif // PY_VERSION_HEX > 0x030900B1
@@ -29056,6 +29081,13 @@ try_unpack:
29056
29081
 
29057
29082
  /* PyObjectCallMethod0 */
29058
29083
  static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name) {
29084
+ #if CYTHON_VECTORCALL && (__PYX_LIMITED_VERSION_HEX >= 0x030C0000 || (!CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX >= 0x03090000))
29085
+ PyObject *args[1] = {obj};
29086
+ (void) __Pyx_PyObject_GetMethod;
29087
+ (void) __Pyx_PyObject_CallOneArg;
29088
+ (void) __Pyx_PyObject_CallNoArg;
29089
+ return PyObject_VectorcallMethod(method_name, args, 1 | PY_VECTORCALL_ARGUMENTS_OFFSET, NULL);
29090
+ #else
29059
29091
  PyObject *method = NULL, *result = NULL;
29060
29092
  int is_method = __Pyx_PyObject_GetMethod(obj, method_name, &method);
29061
29093
  if (likely(is_method)) {
@@ -29068,6 +29100,7 @@ static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name
29068
29100
  Py_DECREF(method);
29069
29101
  bad:
29070
29102
  return result;
29103
+ #endif
29071
29104
  }
29072
29105
 
29073
29106
  /* ValidateBasesTuple */
@@ -29497,15 +29530,15 @@ __PYX_GOOD:
29497
29530
  }
29498
29531
 
29499
29532
  /* TypeImport */
29500
- #ifndef __PYX_HAVE_RT_ImportType_3_1_2
29501
- #define __PYX_HAVE_RT_ImportType_3_1_2
29502
- static PyTypeObject *__Pyx_ImportType_3_1_2(PyObject *module, const char *module_name, const char *class_name,
29503
- size_t size, size_t alignment, enum __Pyx_ImportType_CheckSize_3_1_2 check_size)
29533
+ #ifndef __PYX_HAVE_RT_ImportType_3_1_6
29534
+ #define __PYX_HAVE_RT_ImportType_3_1_6
29535
+ static PyTypeObject *__Pyx_ImportType_3_1_6(PyObject *module, const char *module_name, const char *class_name,
29536
+ size_t size, size_t alignment, enum __Pyx_ImportType_CheckSize_3_1_6 check_size)
29504
29537
  {
29505
29538
  PyObject *result = 0;
29506
29539
  Py_ssize_t basicsize;
29507
29540
  Py_ssize_t itemsize;
29508
- #if CYTHON_COMPILING_IN_LIMITED_API
29541
+ #if defined(Py_LIMITED_API) || (defined(CYTHON_COMPILING_IN_LIMITED_API) && CYTHON_COMPILING_IN_LIMITED_API)
29509
29542
  PyObject *py_basicsize;
29510
29543
  PyObject *py_itemsize;
29511
29544
  #endif
@@ -29518,7 +29551,7 @@ static PyTypeObject *__Pyx_ImportType_3_1_2(PyObject *module, const char *module
29518
29551
  module_name, class_name);
29519
29552
  goto bad;
29520
29553
  }
29521
- #if !CYTHON_COMPILING_IN_LIMITED_API
29554
+ #if !( defined(Py_LIMITED_API) || (defined(CYTHON_COMPILING_IN_LIMITED_API) && CYTHON_COMPILING_IN_LIMITED_API) )
29522
29555
  basicsize = ((PyTypeObject *)result)->tp_basicsize;
29523
29556
  itemsize = ((PyTypeObject *)result)->tp_itemsize;
29524
29557
  #else
@@ -29556,7 +29589,7 @@ static PyTypeObject *__Pyx_ImportType_3_1_2(PyObject *module, const char *module
29556
29589
  module_name, class_name, size, basicsize+itemsize);
29557
29590
  goto bad;
29558
29591
  }
29559
- if (check_size == __Pyx_ImportType_CheckSize_Error_3_1_2 &&
29592
+ if (check_size == __Pyx_ImportType_CheckSize_Error_3_1_6 &&
29560
29593
  ((size_t)basicsize > size || (size_t)(basicsize + itemsize) < size)) {
29561
29594
  PyErr_Format(PyExc_ValueError,
29562
29595
  "%.200s.%.200s size changed, may indicate binary incompatibility. "
@@ -29564,7 +29597,7 @@ static PyTypeObject *__Pyx_ImportType_3_1_2(PyObject *module, const char *module
29564
29597
  module_name, class_name, size, basicsize, basicsize+itemsize);
29565
29598
  goto bad;
29566
29599
  }
29567
- else if (check_size == __Pyx_ImportType_CheckSize_Warn_3_1_2 && (size_t)basicsize > size) {
29600
+ else if (check_size == __Pyx_ImportType_CheckSize_Warn_3_1_6 && (size_t)basicsize > size) {
29568
29601
  if (PyErr_WarnFormat(NULL, 0,
29569
29602
  "%.200s.%.200s size changed, may indicate binary incompatibility. "
29570
29603
  "Expected %zd from C header, got %zd from PyObject",
@@ -31231,9 +31264,9 @@ bad:
31231
31264
  }
31232
31265
 
31233
31266
  /* FunctionImport */
31234
- #ifndef __PYX_HAVE_RT_ImportFunction_3_1_2
31235
- #define __PYX_HAVE_RT_ImportFunction_3_1_2
31236
- static int __Pyx_ImportFunction_3_1_2(PyObject *module, const char *funcname, void (**f)(void), const char *sig) {
31267
+ #ifndef __PYX_HAVE_RT_ImportFunction_3_1_6
31268
+ #define __PYX_HAVE_RT_ImportFunction_3_1_6
31269
+ static int __Pyx_ImportFunction_3_1_6(PyObject *module, const char *funcname, void (**f)(void), const char *sig) {
31237
31270
  PyObject *d = 0;
31238
31271
  PyObject *cobj = 0;
31239
31272
  union {
@@ -31525,6 +31558,17 @@ static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b) {
31525
31558
  static CYTHON_INLINE PyObject * __Pyx_PyLong_FromSize_t(size_t ival) {
31526
31559
  return PyLong_FromSize_t(ival);
31527
31560
  }
31561
+ #if CYTHON_USE_PYLONG_INTERNALS
31562
+ static CYTHON_INLINE int __Pyx_PyLong_CompactAsLong(PyObject *x, long *return_value) {
31563
+ if (unlikely(!__Pyx_PyLong_IsCompact(x)))
31564
+ return 0;
31565
+ Py_ssize_t value = __Pyx_PyLong_CompactValue(x);
31566
+ if ((sizeof(long) < sizeof(Py_ssize_t)) && unlikely(value != (long) value))
31567
+ return 0;
31568
+ *return_value = (long) value;
31569
+ return 1;
31570
+ }
31571
+ #endif
31528
31572
 
31529
31573
 
31530
31574
  /* MultiPhaseInitModuleState */