upgini 1.2.81a3832.dev8__py3-none-any.whl → 1.2.81a3832.dev9__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.
upgini/__about__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "1.2.81a3832.dev8"
1
+ __version__ = "1.2.81a3832.dev9"
@@ -1768,10 +1768,10 @@ class FeaturesEnricher(TransformerMixin):
1768
1768
  df = generator.generate(df)
1769
1769
  generated_features.extend(generator.generated_features)
1770
1770
 
1771
- # normalizer = Normalizer(self.bundle, self.logger)
1772
- # df, search_keys, generated_features = normalizer.normalize(df, search_keys, generated_features)
1773
- # columns_renaming = normalizer.columns_renaming
1774
- columns_renaming = {c: c for c in df.columns}
1771
+ normalizer = Normalizer(self.bundle, self.logger)
1772
+ df, search_keys, generated_features = normalizer.normalize(df, search_keys, generated_features)
1773
+ columns_renaming = normalizer.columns_renaming
1774
+ # columns_renaming = {c: c for c in df.columns}
1775
1775
 
1776
1776
  df, _ = clean_full_duplicates(df, logger=self.logger, bundle=self.bundle)
1777
1777
 
@@ -3881,7 +3881,7 @@ if response.status_code == 200:
3881
3881
  if features_meta is None:
3882
3882
  raise Exception(self.bundle.get("missing_features_meta"))
3883
3883
 
3884
- return [f.name for f in features_meta if f.type == "categorical" and f.shap_value > 0.0]
3884
+ return [f.name for f in features_meta if f.type == "categorical"]
3885
3885
 
3886
3886
  def __prepare_feature_importances(
3887
3887
  self, trace_id: str, df: pd.DataFrame, updated_shaps: Optional[Dict[str, float]] = None, silent=False
upgini/metrics.py CHANGED
@@ -6,7 +6,7 @@ import re
6
6
  from collections import defaultdict
7
7
  from copy import deepcopy
8
8
  from dataclasses import dataclass
9
- from typing import Any, Callable, Dict, List, Optional, Tuple, Union
9
+ from typing import Any, Callable, Dict, List, Literal, Optional, Tuple, Union
10
10
 
11
11
  import lightgbm as lgb
12
12
  import numpy as np
@@ -251,7 +251,7 @@ class _CrossValResults:
251
251
 
252
252
 
253
253
  class EstimatorWrapper:
254
- default_estimator = "catboost"
254
+ default_estimator: Literal["catboost", "lightgbm"] = "catboost"
255
255
 
256
256
  def __init__(
257
257
  self,
@@ -306,6 +306,8 @@ class EstimatorWrapper:
306
306
  else:
307
307
  if x[c].dtype == "category" and x[c].cat.categories.dtype == np.int64:
308
308
  x[c] = x[c].astype(np.int64)
309
+ elif not is_numeric_dtype(x[c]):
310
+ x[c] = x[c].astype(str).astype("category")
309
311
 
310
312
  if not isinstance(y, pd.Series):
311
313
  raise Exception(bundle.get("metrics_unsupported_target_type").format(type(y)))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: upgini
3
- Version: 1.2.81a3832.dev8
3
+ Version: 1.2.81a3832.dev9
4
4
  Summary: Intelligent data search & enrichment for Machine Learning
5
5
  Project-URL: Bug Reports, https://github.com/upgini/upgini/issues
6
6
  Project-URL: Homepage, https://upgini.com/
@@ -1,12 +1,12 @@
1
- upgini/__about__.py,sha256=M1jXitaZAXPLIGnBLF3YC2-DONuCmeKDqyDxngbrHI0,33
1
+ upgini/__about__.py,sha256=wEcwloV3XNyxWA40HLqEb4PIXttvc8pREucBfzAKW0c,33
2
2
  upgini/__init__.py,sha256=LXSfTNU0HnlOkE69VCxkgIKDhWP-JFo_eBQ71OxTr5Y,261
3
3
  upgini/ads.py,sha256=nvuRxRx5MHDMgPr9SiU-fsqRdFaBv8p4_v1oqiysKpc,2714
4
4
  upgini/dataset.py,sha256=aspri7ZAgwkNNUiIgQ1GRXvw8XQii3F4RfNXSrF4wrw,35365
5
5
  upgini/errors.py,sha256=2b_Wbo0OYhLUbrZqdLIx5jBnAsiD1Mcenh-VjR4HCTw,950
6
- upgini/features_enricher.py,sha256=WCX50iuq8_hf9AYuEfs_ZWNR7FbFc44zuXg27Z40r2s,210874
6
+ upgini/features_enricher.py,sha256=ZSSukaq4_mngCkJyQe-XCssXbH8nOD7ByWfSHi9nypc,210847
7
7
  upgini/http.py,sha256=AfaJ3c8z_tK2hZFEehNybDKE0mp1tYcyAP_l0_p8bLQ,43933
8
8
  upgini/metadata.py,sha256=Yd6iW2f7Wz6vUkg5uvR4xylN16ANnCKVKqAsAkap7p8,12354
9
- upgini/metrics.py,sha256=nT5eIVjGZp1U1oZUE82zBSniI9gaZDf6QhRlGKJkmQ4,39831
9
+ upgini/metrics.py,sha256=4ehQO8VEebKLiCuBq2LRqC2QbPIqswoe7b1pnR_-zQA,39985
10
10
  upgini/search_task.py,sha256=RcvAE785yksWTsTNWuZFVNlk32jHElMoEna1T_C5N8Q,17823
11
11
  upgini/spinner.py,sha256=4iMd-eIe_BnkqFEMIliULTbj6rNI2HkN_VJ4qYe0cUc,1118
12
12
  upgini/version_validator.py,sha256=DvbaAvuYFoJqYt0fitpsk6Xcv-H1BYDJYHUMxaKSH_Y,1509
@@ -70,7 +70,7 @@ upgini/utils/target_utils.py,sha256=LRN840dzx78-wg7ftdxAkp2c1eu8-JDvkACiRThm4HE,
70
70
  upgini/utils/track_info.py,sha256=G5Lu1xxakg2_TQjKZk4b5SvrHsATTXNVV3NbvWtT8k8,5663
71
71
  upgini/utils/ts_utils.py,sha256=26vhC0pN7vLXK6R09EEkMK3Lwb9IVPH7LRdqFIQ3kPs,1383
72
72
  upgini/utils/warning_counter.py,sha256=-GRY8EUggEBKODPSuXAkHn9KnEQwAORC0mmz_tim-PM,254
73
- upgini-1.2.81a3832.dev8.dist-info/METADATA,sha256=KxJ6Hfdlki3UGenMTKIc5cc6-VnE9I34zacRVPn9lws,49172
74
- upgini-1.2.81a3832.dev8.dist-info/WHEEL,sha256=1yFddiXMmvYK7QYTqtRNtX66WJ0Mz8PYEiEUoOUUxRY,87
75
- upgini-1.2.81a3832.dev8.dist-info/licenses/LICENSE,sha256=5RRzgvdJUu3BUDfv4bzVU6FqKgwHlIay63pPCSmSgzw,1514
76
- upgini-1.2.81a3832.dev8.dist-info/RECORD,,
73
+ upgini-1.2.81a3832.dev9.dist-info/METADATA,sha256=6jP4TJl2tN98P8wuWIBARzrPtZVRT48uPukgTvZOvlA,49172
74
+ upgini-1.2.81a3832.dev9.dist-info/WHEEL,sha256=1yFddiXMmvYK7QYTqtRNtX66WJ0Mz8PYEiEUoOUUxRY,87
75
+ upgini-1.2.81a3832.dev9.dist-info/licenses/LICENSE,sha256=5RRzgvdJUu3BUDfv4bzVU6FqKgwHlIay63pPCSmSgzw,1514
76
+ upgini-1.2.81a3832.dev9.dist-info/RECORD,,