FLAML 2.3.2__tar.gz → 2.3.3__tar.gz

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.
Files changed (120) hide show
  1. {flaml-2.3.2 → flaml-2.3.3}/FLAML.egg-info/PKG-INFO +1 -1
  2. {flaml-2.3.2 → flaml-2.3.3}/PKG-INFO +1 -1
  3. {flaml-2.3.2 → flaml-2.3.3}/flaml/__init__.py +4 -2
  4. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/automl.py +3 -3
  5. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/model.py +2 -2
  6. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/task/generic_task.py +2 -2
  7. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/task/task.py +1 -1
  8. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/tune.py +10 -0
  9. flaml-2.3.3/flaml/version.py +1 -0
  10. flaml-2.3.2/flaml/version.py +0 -1
  11. {flaml-2.3.2 → flaml-2.3.3}/FLAML.egg-info/SOURCES.txt +0 -0
  12. {flaml-2.3.2 → flaml-2.3.3}/FLAML.egg-info/dependency_links.txt +0 -0
  13. {flaml-2.3.2 → flaml-2.3.3}/FLAML.egg-info/requires.txt +0 -0
  14. {flaml-2.3.2 → flaml-2.3.3}/FLAML.egg-info/top_level.txt +0 -0
  15. {flaml-2.3.2 → flaml-2.3.3}/LICENSE +0 -0
  16. {flaml-2.3.2 → flaml-2.3.3}/NOTICE.md +0 -0
  17. {flaml-2.3.2 → flaml-2.3.3}/README.md +0 -0
  18. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/__init__.py +0 -0
  19. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/agentchat/__init__.py +0 -0
  20. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/agentchat/agent.py +0 -0
  21. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/agentchat/assistant_agent.py +0 -0
  22. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/agentchat/conversable_agent.py +0 -0
  23. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/agentchat/groupchat.py +0 -0
  24. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/agentchat/user_proxy_agent.py +0 -0
  25. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/code_utils.py +0 -0
  26. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/extensions/__init__.py +0 -0
  27. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/math_utils.py +0 -0
  28. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/oai/__init__.py +0 -0
  29. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/oai/completion.py +0 -0
  30. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/oai/openai_utils.py +0 -0
  31. {flaml-2.3.2 → flaml-2.3.3}/flaml/autogen/retrieve_utils.py +0 -0
  32. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/__init__.py +0 -0
  33. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/contrib/__init__.py +0 -0
  34. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/contrib/histgb.py +0 -0
  35. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/data.py +0 -0
  36. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/logger.py +0 -0
  37. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/ml.py +0 -0
  38. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/__init__.py +0 -0
  39. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/huggingface/__init__.py +0 -0
  40. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/huggingface/data_collator.py +0 -0
  41. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/huggingface/trainer.py +0 -0
  42. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/huggingface/training_args.py +0 -0
  43. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/huggingface/utils.py +0 -0
  44. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/nlp/utils.py +0 -0
  45. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/spark/__init__.py +0 -0
  46. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/spark/metrics.py +0 -0
  47. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/spark/utils.py +0 -0
  48. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/state.py +0 -0
  49. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/task/__init__.py +0 -0
  50. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/task/factory.py +0 -0
  51. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/task/time_series_task.py +0 -0
  52. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/__init__.py +0 -0
  53. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/feature.py +0 -0
  54. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/sklearn.py +0 -0
  55. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/tcn.py +0 -0
  56. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/tft.py +0 -0
  57. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/ts_data.py +0 -0
  58. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/time_series/ts_model.py +0 -0
  59. {flaml-2.3.2 → flaml-2.3.3}/flaml/automl/training_log.py +0 -0
  60. {flaml-2.3.2 → flaml-2.3.3}/flaml/config.py +0 -0
  61. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/__init__.py +0 -0
  62. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/all/binary.json +0 -0
  63. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/all/multiclass.json +0 -0
  64. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/all/regression.json +0 -0
  65. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/estimator.py +0 -0
  66. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/extra_tree/binary.json +0 -0
  67. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/extra_tree/multiclass.json +0 -0
  68. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/extra_tree/regression.json +0 -0
  69. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/greedy.py +0 -0
  70. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/lgbm/binary.json +0 -0
  71. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/lgbm/multiclass.json +0 -0
  72. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/lgbm/regression.json +0 -0
  73. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/portfolio.py +0 -0
  74. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/regret.py +0 -0
  75. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/rf/binary.json +0 -0
  76. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/rf/multiclass.json +0 -0
  77. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/rf/regression.json +0 -0
  78. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/suggest.py +0 -0
  79. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/xgb_limitdepth/binary.json +0 -0
  80. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/xgb_limitdepth/multiclass.json +0 -0
  81. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/xgb_limitdepth/regression.json +0 -0
  82. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/xgboost/binary.json +0 -0
  83. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/xgboost/multiclass.json +0 -0
  84. {flaml-2.3.2 → flaml-2.3.3}/flaml/default/xgboost/regression.json +0 -0
  85. {flaml-2.3.2 → flaml-2.3.3}/flaml/fabric/__init__.py +0 -0
  86. {flaml-2.3.2 → flaml-2.3.3}/flaml/fabric/mlflow.py +0 -0
  87. {flaml-2.3.2 → flaml-2.3.3}/flaml/ml.py +0 -0
  88. {flaml-2.3.2 → flaml-2.3.3}/flaml/onlineml/__init__.py +0 -0
  89. {flaml-2.3.2 → flaml-2.3.3}/flaml/onlineml/autovw.py +0 -0
  90. {flaml-2.3.2 → flaml-2.3.3}/flaml/onlineml/trial.py +0 -0
  91. {flaml-2.3.2 → flaml-2.3.3}/flaml/onlineml/trial_runner.py +0 -0
  92. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/__init__.py +0 -0
  93. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/analysis.py +0 -0
  94. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/result.py +0 -0
  95. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/sample.py +0 -0
  96. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/scheduler/__init__.py +0 -0
  97. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/scheduler/online_scheduler.py +0 -0
  98. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/scheduler/trial_scheduler.py +0 -0
  99. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/__init__.py +0 -0
  100. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/blendsearch.py +0 -0
  101. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/cfo_cat.py +0 -0
  102. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/flow2.py +0 -0
  103. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/online_searcher.py +0 -0
  104. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/search_thread.py +0 -0
  105. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/suggestion.py +0 -0
  106. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/searcher/variant_generator.py +0 -0
  107. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/space.py +0 -0
  108. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/spark/__init__.py +0 -0
  109. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/spark/utils.py +0 -0
  110. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/trial.py +0 -0
  111. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/trial_runner.py +0 -0
  112. {flaml-2.3.2 → flaml-2.3.3}/flaml/tune/utils.py +0 -0
  113. {flaml-2.3.2 → flaml-2.3.3}/pyproject.toml +0 -0
  114. {flaml-2.3.2 → flaml-2.3.3}/setup.cfg +0 -0
  115. {flaml-2.3.2 → flaml-2.3.3}/setup.py +0 -0
  116. {flaml-2.3.2 → flaml-2.3.3}/test/test_autovw.py +0 -0
  117. {flaml-2.3.2 → flaml-2.3.3}/test/test_conda_distribution.py +0 -0
  118. {flaml-2.3.2 → flaml-2.3.3}/test/test_gpu.py +0 -0
  119. {flaml-2.3.2 → flaml-2.3.3}/test/test_model.py +0 -0
  120. {flaml-2.3.2 → flaml-2.3.3}/test/test_version.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: FLAML
3
- Version: 2.3.2
3
+ Version: 2.3.3
4
4
  Summary: A fast library for automated machine learning and tuning
5
5
  Home-page: https://github.com/microsoft/FLAML
6
6
  Author: Microsoft Corporation
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: FLAML
3
- Version: 2.3.2
3
+ Version: 2.3.3
4
4
  Summary: A fast library for automated machine learning and tuning
5
5
  Home-page: https://github.com/microsoft/FLAML
6
6
  Author: Microsoft Corporation
@@ -1,4 +1,5 @@
1
1
  import logging
2
+ import warnings
2
3
 
3
4
  try:
4
5
  from flaml.automl import AutoML, logger_formatter
@@ -12,7 +13,8 @@ from flaml.version import __version__
12
13
 
13
14
  # Set the root logger.
14
15
  logger = logging.getLogger(__name__)
15
- logger.setLevel(logging.INFO)
16
+ if logger.level == logging.NOTSET:
17
+ logger.setLevel(logging.INFO)
16
18
 
17
19
  if not has_automl:
18
- logger.warning("flaml.automl is not available. Please install flaml[automl] to enable AutoML functionalities.")
20
+ warnings.warn("flaml.automl is not available. Please install flaml[automl] to enable AutoML functionalities.")
@@ -203,7 +203,7 @@ class AutoML(BaseEstimator):
203
203
  * Valid str options depend on different tasks.
204
204
  For classification tasks, valid choices are
205
205
  ["auto", 'stratified', 'uniform', 'time', 'group']. "auto" -> stratified.
206
- For regression tasks, valid choices are ["auto", 'uniform', 'time'].
206
+ For regression tasks, valid choices are ["auto", 'uniform', 'time', 'group'].
207
207
  "auto" -> uniform.
208
208
  For time series forecast tasks, must be "auto" or 'time'.
209
209
  For ranking task, must be "auto" or 'group'.
@@ -739,7 +739,7 @@ class AutoML(BaseEstimator):
739
739
  * Valid str options depend on different tasks.
740
740
  For classification tasks, valid choices are
741
741
  ["auto", 'stratified', 'uniform', 'time', 'group']. "auto" -> stratified.
742
- For regression tasks, valid choices are ["auto", 'uniform', 'time'].
742
+ For regression tasks, valid choices are ["auto", 'uniform', 'time', 'group'].
743
743
  "auto" -> uniform.
744
744
  For time series forecast tasks, must be "auto" or 'time'.
745
745
  For ranking task, must be "auto" or 'group'.
@@ -1358,7 +1358,7 @@ class AutoML(BaseEstimator):
1358
1358
  * Valid str options depend on different tasks.
1359
1359
  For classification tasks, valid choices are
1360
1360
  ["auto", 'stratified', 'uniform', 'time', 'group']. "auto" -> stratified.
1361
- For regression tasks, valid choices are ["auto", 'uniform', 'time'].
1361
+ For regression tasks, valid choices are ["auto", 'uniform', 'time', 'group'].
1362
1362
  "auto" -> uniform.
1363
1363
  For time series forecast tasks, must be "auto" or 'time'.
1364
1364
  For ranking task, must be "auto" or 'group'.
@@ -2066,8 +2066,8 @@ class CatBoostEstimator(BaseEstimator):
2066
2066
  self.estimator_class = CatBoostRegressor
2067
2067
 
2068
2068
  def fit(self, X_train, y_train, budget=None, free_mem_ratio=0, **kwargs):
2069
- if "is_retrain" in kwargs:
2070
- kwargs.pop("is_retrain")
2069
+ kwargs.pop("is_retrain", None)
2070
+ kwargs.pop("groups", None)
2071
2071
  start_time = time.time()
2072
2072
  deadline = start_time + budget if budget else np.inf
2073
2073
  train_dir = f"catboost_{str(start_time)}"
@@ -442,8 +442,8 @@ class GenericTask(Task):
442
442
  X_train_all, y_train_all = shuffle(X_train_all, y_train_all, random_state=RANDOM_SEED)
443
443
  if data_is_df:
444
444
  X_train_all.reset_index(drop=True, inplace=True)
445
- if isinstance(y_train_all, pd.Series):
446
- y_train_all.reset_index(drop=True, inplace=True)
445
+ if isinstance(y_train_all, pd.Series):
446
+ y_train_all.reset_index(drop=True, inplace=True)
447
447
 
448
448
  X_train, y_train = X_train_all, y_train_all
449
449
  state.groups_all = state.groups
@@ -192,7 +192,7 @@ class Task(ABC):
192
192
  * Valid str options depend on different tasks.
193
193
  For classification tasks, valid choices are
194
194
  ["auto", 'stratified', 'uniform', 'time', 'group']. "auto" -> stratified.
195
- For regression tasks, valid choices are ["auto", 'uniform', 'time'].
195
+ For regression tasks, valid choices are ["auto", 'uniform', 'time', 'group'].
196
196
  "auto" -> uniform.
197
197
  For time series forecast tasks, must be "auto" or 'time'.
198
198
  For ranking task, must be "auto" or 'group'.
@@ -260,6 +260,8 @@ def run(
260
260
  mlflow_exp_name: Optional[str] = None,
261
261
  automl_info: Optional[Tuple[float]] = None,
262
262
  extra_tag: Optional[dict] = None,
263
+ cost_attr: Optional[str] = "auto",
264
+ cost_budget: Optional[float] = None,
263
265
  **ray_args,
264
266
  ):
265
267
  """The function-based way of performing HPO.
@@ -462,6 +464,12 @@ def run(
462
464
  overwritten by the value of `n_concurrent_trials` in AutoML. When <= 0, the concurrent trials
463
465
  will be set to the number of executors.
464
466
  extra_tag: dict, default=None | Extra tags to be added to the mlflow runs created by autologging.
467
+ cost_attr: None or str to specify the attribute to evaluate the cost of different trials.
468
+ Default is "auto", which means that we will automatically choose the cost attribute to use (depending
469
+ on the nature of the resource budget). When cost_attr is set to None, cost differences between different trials will be omitted
470
+ in our search algorithm. When cost_attr is set to a str different from "auto" and "time_total_s",
471
+ this cost_attr must be available in the result dict of the trial.
472
+ cost_budget: A float of the cost budget. Only valid when cost_attr is a str different from "auto" and "time_total_s".
465
473
  **ray_args: keyword arguments to pass to ray.tune.run().
466
474
  Only valid when use_ray=True.
467
475
  """
@@ -600,6 +608,8 @@ def run(
600
608
  metric_constraints=metric_constraints,
601
609
  use_incumbent_result_in_evaluation=use_incumbent_result_in_evaluation,
602
610
  lexico_objectives=lexico_objectives,
611
+ cost_attr=cost_attr,
612
+ cost_budget=cost_budget,
603
613
  )
604
614
  else:
605
615
  if metric is None or mode is None:
@@ -0,0 +1 @@
1
+ __version__ = "2.3.3"
@@ -1 +0,0 @@
1
- __version__ = "2.3.2"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes