psyke 1.0.3.dev4__py3-none-any.whl → 1.0.4__py3-none-any.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 psyke might be problematic. Click here for more details.

@@ -22,7 +22,7 @@ class CartPredictor:
22
22
  self.discretization = discretization
23
23
  self.normalization = normalization
24
24
 
25
- def __get_constraints(self, nodes: Iterable[(int, bool)]) -> LeafConstraints:
25
+ def __get_constraints(self, nodes: Iterable[tuple[int, bool]]) -> LeafConstraints:
26
26
  thresholds = [self._predictor.tree_.threshold[i[0]] for i in nodes]
27
27
  features = [self._predictor.feature_names_in_[self._predictor.tree_.feature[node[0]]] for node in nodes]
28
28
  conditions = [node[1] for node in nodes]
@@ -52,7 +52,7 @@ class CartPredictor:
52
52
  else:
53
53
  return self._predictor.tree_.value[node]
54
54
 
55
- def __path(self, node: int, path=None) -> Iterable[(int, bool)]:
55
+ def __path(self, node: int, path=None) -> Iterable[tuple[int, bool]]:
56
56
  path = [] if path is None else path
57
57
  if node == 0:
58
58
  return path
@@ -90,7 +90,7 @@ class CartPredictor:
90
90
  isinstance(condition, GreaterThan)))
91
91
  return results
92
92
 
93
- def create_theory(self, data: pd.DataFrame, simplify: True) -> Theory:
93
+ def create_theory(self, data: pd.DataFrame, simplify: bool = True) -> Theory:
94
94
  new_theory = mutable_theory()
95
95
  nodes = [node for node in self]
96
96
  nodes = self._simplify_nodes(nodes) if simplify else nodes
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: psyke
3
- Version: 1.0.3.dev4
3
+ Version: 1.0.4
4
4
  Summary: Python-based implementation of PSyKE, i.e. a Platform for Symbolic Knowledge Extraction
5
5
  Home-page: https://github.com/psykei/psyke-python
6
6
  Author: Matteo Magnini
@@ -5,7 +5,7 @@ psyke/clustering/utils.py,sha256=BqMPKJ-r6CdxXwyk-2AvkPV4DBnZF5WUNz2fKiXbhlw,159
5
5
  psyke/clustering/cream/__init__.py,sha256=TtUd5IyfavSUZeSuSAr06ZftVhK30ZLZGUUfH3ZQG2w,2799
6
6
  psyke/clustering/exact/__init__.py,sha256=OMMxc_lIKHouZTpbLF7dt4dOA3chL4XFpjOCyc6GTTY,5545
7
7
  psyke/extraction/__init__.py,sha256=6wR6HA6lmgv1CCfi41pjQPPQoCghDcOJRNwK3lQh-Mc,903
8
- psyke/extraction/cart/CartPredictor.py,sha256=OIkxUXH2IEIy690-pqNymO9vZkSsaRwB64Wbpj1fMks,5747
8
+ psyke/extraction/cart/CartPredictor.py,sha256=AA7g8P-SbuiXc-iqTgTe8naJi3rHMXs8_a_ti-v9pxU,5764
9
9
  psyke/extraction/cart/FairTree.py,sha256=mccoLDrSNy6iivqFZ23m33hxIB_kPXa3mNL1ukfb5Ls,7624
10
10
  psyke/extraction/cart/FairTreePredictor.py,sha256=7z4oLqflkRMqqVW_UIlrGsQrvROM4sXUfY7LPQJ662g,2321
11
11
  psyke/extraction/cart/__init__.py,sha256=SsjAJiL4n6q_GNR6H8PNfhTkAZ67Ka7NRvVRxCULBhQ,3191
@@ -39,8 +39,8 @@ psyke/utils/logic.py,sha256=ioP25WMTYNYEzaRDNDe3kGNWqZ6DA_63t19d-ky_2kM,12227
39
39
  psyke/utils/metrics.py,sha256=Oo5BOonOSfo0qYsXWT5dmypZ7jiStByFC2MKEU0uMHg,2250
40
40
  psyke/utils/plot.py,sha256=dE8JJ6tQ0Ezosid-r2jqAisREjFe5LqExRzsVi5Ns-c,7785
41
41
  psyke/utils/sorted.py,sha256=C3CPW2JisND30BRk5c1sAAHs3Lb_wsRB2qZrYFuRnfM,678
42
- psyke-1.0.3.dev4.dist-info/licenses/LICENSE,sha256=G3mPaubObvkBXbsgTTeYGLk_pNEW8tc7HZr4u_wLEpU,11398
43
- psyke-1.0.3.dev4.dist-info/METADATA,sha256=Y-cNCi3arjSdW3-XHFEIhXLkmzp9qNVk6Fmv1QcGmF4,8388
44
- psyke-1.0.3.dev4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
45
- psyke-1.0.3.dev4.dist-info/top_level.txt,sha256=q1HglxOqqoIRukFtyis_ZNHczZg4gANRUPWkD7HAUTU,6
46
- psyke-1.0.3.dev4.dist-info/RECORD,,
42
+ psyke-1.0.4.dist-info/licenses/LICENSE,sha256=G3mPaubObvkBXbsgTTeYGLk_pNEW8tc7HZr4u_wLEpU,11398
43
+ psyke-1.0.4.dist-info/METADATA,sha256=3BOsxzVrtzU_1nO2jM2Qa_rvOTHQd0YyJGxUZcu3ATQ,8383
44
+ psyke-1.0.4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
45
+ psyke-1.0.4.dist-info/top_level.txt,sha256=q1HglxOqqoIRukFtyis_ZNHczZg4gANRUPWkD7HAUTU,6
46
+ psyke-1.0.4.dist-info/RECORD,,