dragon-ml-toolbox 20.4.0__tar.gz → 20.5.0__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 (148) hide show
  1. {dragon_ml_toolbox-20.4.0/dragon_ml_toolbox.egg-info → dragon_ml_toolbox-20.5.0}/PKG-INFO +1 -1
  2. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0/dragon_ml_toolbox.egg-info}/PKG-INFO +1 -1
  3. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_optimization/_multi_dragon.py +43 -36
  4. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/data_exploration/__init__.py +2 -0
  5. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/data_exploration/_schema_ops.py +107 -8
  6. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/schema/_feature_schema.py +30 -4
  7. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/pyproject.toml +1 -1
  8. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/LICENSE +0 -0
  9. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/LICENSE-THIRD-PARTY.md +0 -0
  10. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/README.md +0 -0
  11. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/dragon_ml_toolbox.egg-info/SOURCES.txt +0 -0
  12. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/dragon_ml_toolbox.egg-info/dependency_links.txt +0 -0
  13. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/dragon_ml_toolbox.egg-info/requires.txt +0 -0
  14. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/dragon_ml_toolbox.egg-info/top_level.txt +0 -0
  15. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_cleaning/__init__.py +0 -0
  16. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_cleaning/_basic_clean.py +0 -0
  17. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_cleaning/_clean_tools.py +0 -0
  18. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_cleaning/_dragon_cleaner.py +0 -0
  19. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_engineering/__init__.py +0 -0
  20. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_engineering/_dragon_engineering.py +0 -0
  21. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ETL_engineering/_transforms.py +0 -0
  22. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/GUI_tools/_GUI_tools.py +0 -0
  23. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/GUI_tools/__init__.py +0 -0
  24. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/IO_tools/_IO_loggers.py +0 -0
  25. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/IO_tools/_IO_save_load.py +0 -0
  26. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/IO_tools/_IO_utils.py +0 -0
  27. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/IO_tools/__init__.py +0 -0
  28. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/MICE/_MICE_imputation.py +0 -0
  29. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/MICE/__init__.py +0 -0
  30. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/MICE/_dragon_mice.py +0 -0
  31. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_callbacks/__init__.py +0 -0
  32. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_callbacks/_base.py +0 -0
  33. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_callbacks/_checkpoint.py +0 -0
  34. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_callbacks/_early_stop.py +0 -0
  35. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_callbacks/_scheduler.py +0 -0
  36. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_chain/__init__.py +0 -0
  37. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_chain/_chaining_tools.py +0 -0
  38. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_chain/_dragon_chain.py +0 -0
  39. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_chain/_update_schema.py +0 -0
  40. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_configuration/__init__.py +0 -0
  41. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_configuration/_base_model_config.py +0 -0
  42. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_configuration/_finalize.py +0 -0
  43. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_configuration/_metrics.py +0 -0
  44. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_configuration/_models.py +0 -0
  45. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_configuration/_training.py +0 -0
  46. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_datasetmaster/__init__.py +0 -0
  47. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_datasetmaster/_base_datasetmaster.py +0 -0
  48. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_datasetmaster/_datasetmaster.py +0 -0
  49. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_datasetmaster/_sequence_datasetmaster.py +0 -0
  50. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_datasetmaster/_vision_datasetmaster.py +0 -0
  51. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/__init__.py +0 -0
  52. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/_classification.py +0 -0
  53. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/_feature_importance.py +0 -0
  54. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/_loss.py +0 -0
  55. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/_regression.py +0 -0
  56. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/_sequence.py +0 -0
  57. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation/_vision.py +0 -0
  58. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation_captum/_ML_evaluation_captum.py +0 -0
  59. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_evaluation_captum/__init__.py +0 -0
  60. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_finalize_handler/_ML_finalize_handler.py +0 -0
  61. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_finalize_handler/__init__.py +0 -0
  62. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference/__init__.py +0 -0
  63. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference/_base_inference.py +0 -0
  64. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference/_chain_inference.py +0 -0
  65. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference/_dragon_inference.py +0 -0
  66. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference/_multi_inference.py +0 -0
  67. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference_sequence/__init__.py +0 -0
  68. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference_sequence/_sequence_inference.py +0 -0
  69. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference_vision/__init__.py +0 -0
  70. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_inference_vision/_vision_inference.py +0 -0
  71. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/__init__.py +0 -0
  72. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_base_mlp_attention.py +0 -0
  73. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_base_save_load.py +0 -0
  74. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_dragon_autoint.py +0 -0
  75. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_dragon_gate.py +0 -0
  76. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_dragon_node.py +0 -0
  77. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_dragon_tabnet.py +0 -0
  78. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_dragon_tabular.py +0 -0
  79. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_mlp_attention.py +0 -0
  80. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models/_models_advanced_helpers.py +0 -0
  81. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_sequence/__init__.py +0 -0
  82. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_sequence/_sequence_models.py +0 -0
  83. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_vision/__init__.py +0 -0
  84. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_vision/_base_wrapper.py +0 -0
  85. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_vision/_image_classification.py +0 -0
  86. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_vision/_image_segmentation.py +0 -0
  87. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_models_vision/_object_detection.py +0 -0
  88. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_optimization/__init__.py +0 -0
  89. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_optimization/_single_dragon.py +0 -0
  90. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_optimization/_single_manual.py +0 -0
  91. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_scaler/_ML_scaler.py +0 -0
  92. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_scaler/__init__.py +0 -0
  93. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_trainer/__init__.py +0 -0
  94. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_trainer/_base_trainer.py +0 -0
  95. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_trainer/_dragon_detection_trainer.py +0 -0
  96. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_trainer/_dragon_sequence_trainer.py +0 -0
  97. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_trainer/_dragon_trainer.py +0 -0
  98. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_utilities/__init__.py +0 -0
  99. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_utilities/_artifact_finder.py +0 -0
  100. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_utilities/_inspection.py +0 -0
  101. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_utilities/_train_tools.py +0 -0
  102. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_vision_transformers/__init__.py +0 -0
  103. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_vision_transformers/_core_transforms.py +0 -0
  104. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ML_vision_transformers/_offline_augmentation.py +0 -0
  105. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/PSO_optimization/_PSO.py +0 -0
  106. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/PSO_optimization/__init__.py +0 -0
  107. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/SQL/__init__.py +0 -0
  108. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/SQL/_dragon_SQL.py +0 -0
  109. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/VIF/_VIF_factor.py +0 -0
  110. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/VIF/__init__.py +0 -0
  111. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/__init__.py +0 -0
  112. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/_core/__init__.py +0 -0
  113. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/_core/_logger.py +0 -0
  114. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/_core/_schema_load_ops.py +0 -0
  115. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/_core/_script_info.py +0 -0
  116. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/constants.py +0 -0
  117. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/data_exploration/_analysis.py +0 -0
  118. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/data_exploration/_cleaning.py +0 -0
  119. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/data_exploration/_features.py +0 -0
  120. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/data_exploration/_plotting.py +0 -0
  121. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ensemble_evaluation/__init__.py +0 -0
  122. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ensemble_evaluation/_ensemble_evaluation.py +0 -0
  123. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ensemble_inference/__init__.py +0 -0
  124. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ensemble_inference/_ensemble_inference.py +0 -0
  125. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ensemble_learning/__init__.py +0 -0
  126. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/ensemble_learning/_ensemble_learning.py +0 -0
  127. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/excel_handler/__init__.py +0 -0
  128. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/excel_handler/_excel_handler.py +0 -0
  129. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/keys/__init__.py +0 -0
  130. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/keys/_keys.py +0 -0
  131. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/math_utilities/__init__.py +0 -0
  132. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/math_utilities/_math_utilities.py +0 -0
  133. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/optimization_tools/__init__.py +0 -0
  134. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/optimization_tools/_optimization_bounds.py +0 -0
  135. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/optimization_tools/_optimization_plots.py +0 -0
  136. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/path_manager/__init__.py +0 -0
  137. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/path_manager/_dragonmanager.py +0 -0
  138. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/path_manager/_path_tools.py +0 -0
  139. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/plot_fonts/__init__.py +0 -0
  140. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/plot_fonts/_plot_fonts.py +0 -0
  141. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/schema/__init__.py +0 -0
  142. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/schema/_gui_schema.py +0 -0
  143. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/serde/__init__.py +0 -0
  144. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/serde/_serde.py +0 -0
  145. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/utilities/__init__.py +0 -0
  146. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/utilities/_utility_save_load.py +0 -0
  147. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/ml_tools/utilities/_utility_tools.py +0 -0
  148. {dragon_ml_toolbox-20.4.0 → dragon_ml_toolbox-20.5.0}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dragon-ml-toolbox
3
- Version: 20.4.0
3
+ Version: 20.5.0
4
4
  Summary: Complete pipelines and helper tools for data science and machine learning projects.
5
5
  Author-email: Karl Luigi Loza Vidaurre <luigiloza@gmail.com>
6
6
  License-Expression: MIT
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dragon-ml-toolbox
3
- Version: 20.4.0
3
+ Version: 20.5.0
4
4
  Summary: Complete pipelines and helper tools for data science and machine learning projects.
5
5
  Author-email: Karl Luigi Loza Vidaurre <luigiloza@gmail.com>
6
6
  License-Expression: MIT
@@ -170,9 +170,13 @@ class DragonParetoOptimizer:
170
170
  re_evaluate=False # model is deterministic
171
171
  )
172
172
 
173
- def run(self) -> pd.DataFrame:
173
+ def run(self,
174
+ plots_and_log: bool=True) -> pd.DataFrame:
174
175
  """
175
176
  Execute the optimization with progress tracking and periodic logging.
177
+
178
+ Args:
179
+ plots_and_log (bool): If True, generates plots and logs during optimization. Disable for multi-run scenarios.
176
180
 
177
181
  Returns:
178
182
  pd.DataFrame: A DataFrame containing the non-dominated solutions (Pareto Front).
@@ -189,9 +193,10 @@ class DragonParetoOptimizer:
189
193
  _LOGGER.info(f"🧬 Starting NSGA-II (GeneticAlgorithm) for {generations} generations...")
190
194
 
191
195
  # Initialize log file
192
- with open(log_file, "w") as f:
193
- f.write(f"Pareto Optimization Log - {generations} Generations\n")
194
- f.write("=" * 60 + "\n")
196
+ if plots_and_log:
197
+ with open(log_file, "w") as f:
198
+ f.write(f"Pareto Optimization Log - {generations} Generations\n")
199
+ f.write("=" * 60 + "\n")
195
200
 
196
201
  # History tracking for visualization
197
202
  history_records = []
@@ -201,43 +206,44 @@ class DragonParetoOptimizer:
201
206
  for gen in range(1, generations + 1):
202
207
  self.algorithm.step()
203
208
 
204
- # Capture stats for history (every generation for smooth plots)
205
- current_evals = self.algorithm.population.evals.clone() # type: ignore
206
-
207
- gen_stats = {}
208
- for i, target_name in enumerate(self.ordered_target_names):
209
- vals = current_evals[:, i]
210
- v_mean = float(vals.mean())
211
- v_min = float(vals.min())
212
- v_max = float(vals.max())
213
-
214
- # Store for plotting
215
- history_records.append({
216
- "Generation": gen,
217
- "Target": target_name,
218
- "Mean": v_mean,
219
- "Min": v_min,
220
- "Max": v_max
221
- })
222
-
223
- gen_stats[target_name] = (v_mean, v_min, v_max)
224
-
225
- # Periodic Logging of Population Stats to FILE
226
- if gen % log_interval == 0 or gen == generations:
227
- stats_msg = [f"Gen {gen}:"]
228
- for t_name, (v_mean, v_min, v_max) in gen_stats.items():
229
- stats_msg.append(f"{t_name}: {v_mean:.3f} (Range: {v_min:.3f}-{v_max:.3f})")
209
+ if plots_and_log:
210
+ # Capture stats for history (every generation for smooth plots)
211
+ current_evals = self.algorithm.population.evals.clone() # type: ignore
230
212
 
231
- log_line = " | ".join(stats_msg)
213
+ gen_stats = {}
214
+ for i, target_name in enumerate(self.ordered_target_names):
215
+ vals = current_evals[:, i]
216
+ v_mean = float(vals.mean())
217
+ v_min = float(vals.min())
218
+ v_max = float(vals.max())
219
+
220
+ # Store for plotting
221
+ history_records.append({
222
+ "Generation": gen,
223
+ "Target": target_name,
224
+ "Mean": v_mean,
225
+ "Min": v_min,
226
+ "Max": v_max
227
+ })
228
+
229
+ gen_stats[target_name] = (v_mean, v_min, v_max)
232
230
 
233
- # Write to file
234
- with open(log_file, "a") as f:
235
- f.write(log_line + "\n")
231
+ # Periodic Logging of Population Stats to FILE
232
+ if gen % log_interval == 0 or gen == generations:
233
+ stats_msg = [f"Gen {gen}:"]
234
+ for t_name, (v_mean, v_min, v_max) in gen_stats.items():
235
+ stats_msg.append(f"{t_name}: {v_mean:.3f} (Range: {v_min:.3f}-{v_max:.3f})")
236
+
237
+ log_line = " | ".join(stats_msg)
238
+
239
+ # Write to file
240
+ with open(log_file, "a") as f:
241
+ f.write(log_line + "\n")
236
242
 
237
243
  pbar.update(1)
238
244
 
239
245
  # --- Post-Optimization Visualization ---
240
- if history_records:
246
+ if plots_and_log and history_records:
241
247
  _LOGGER.debug("Generating optimization history plots...")
242
248
  history_df = pd.DataFrame(history_records)
243
249
  self._plot_optimization_history(history_df, save_path)
@@ -308,7 +314,8 @@ class DragonParetoOptimizer:
308
314
  _LOGGER.info(f"Optimization complete. Found {len(pareto_df)} non-dominated solutions.")
309
315
 
310
316
  # --- Plotting ---
311
- self._generate_plots(pareto_df, save_path)
317
+ if plots_and_log:
318
+ self._generate_plots(pareto_df, save_path)
312
319
 
313
320
  return pareto_df
314
321
 
@@ -36,6 +36,7 @@ from ._features import (
36
36
  from ._schema_ops import (
37
37
  finalize_feature_schema,
38
38
  apply_feature_schema,
39
+ reconstruct_from_schema
39
40
  )
40
41
 
41
42
  from .._core import _imprimir_disponibles
@@ -62,6 +63,7 @@ __all__ = [
62
63
  "encode_categorical_features",
63
64
  "finalize_feature_schema",
64
65
  "apply_feature_schema",
66
+ "reconstruct_from_schema",
65
67
  "match_and_filter_columns_by_regex",
66
68
  "standardize_percentages",
67
69
  "reconstruct_one_hot",
@@ -9,6 +9,13 @@ from .._core import get_logger
9
9
  _LOGGER = get_logger("Data Exploration: Schema Ops")
10
10
 
11
11
 
12
+ __all__ = [
13
+ "finalize_feature_schema",
14
+ "apply_feature_schema",
15
+ "reconstruct_from_schema",
16
+ ]
17
+
18
+
12
19
  def finalize_feature_schema(
13
20
  df_features: pd.DataFrame,
14
21
  categorical_mappings: Optional[dict[str, dict[str, int]]]
@@ -86,7 +93,7 @@ def apply_feature_schema(
86
93
  schema: FeatureSchema,
87
94
  targets: Optional[list[str]] = None,
88
95
  unknown_value: int = 99999,
89
- verbose: bool = True
96
+ verbose: int = 3
90
97
  ) -> pd.DataFrame:
91
98
  """
92
99
  Aligns the input DataFrame with the provided FeatureSchema.
@@ -100,7 +107,7 @@ def apply_feature_schema(
100
107
  targets (list[str] | None): Optional list of target column names.
101
108
  unknown_value (int): Integer value to assign to unknown categorical levels.
102
109
  Defaults to 99999 to avoid collision with existing categories.
103
- verbose (bool): If True, logs info about dropped extra columns.
110
+ verbose (int): Verbosity level for logging. Higher values produce more detailed logs.
104
111
 
105
112
  Returns:
106
113
  pd.DataFrame: A new DataFrame with the exact column order and encoding defined by the schema.
@@ -147,7 +154,8 @@ def apply_feature_schema(
147
154
  # Handle Unknown Categories
148
155
  if df_processed[col_name].isnull().any():
149
156
  n_missing = df_processed[col_name].isnull().sum()
150
- _LOGGER.warning(f"Feature '{col_name}': Found {n_missing} unknown categories. Mapping to {unknown_value}.")
157
+ if verbose >= 1:
158
+ _LOGGER.warning(f"Feature '{col_name}': Found {n_missing} unknown categories. Mapping to {unknown_value}.")
151
159
 
152
160
  # Fill unknowns with the specified integer
153
161
  df_processed[col_name] = df_processed[col_name].fillna(unknown_value)
@@ -159,14 +167,13 @@ def apply_feature_schema(
159
167
 
160
168
  extra_cols = set(df_processed.columns) - set(final_column_order)
161
169
  if extra_cols:
162
- _LOGGER.info(f"Dropping {len(extra_cols)} extra columns not present in schema.")
163
- if verbose:
164
- for extra_column in extra_cols:
165
- print(f" - Dropping column: '{extra_column}'")
170
+ if verbose >= 1:
171
+ _LOGGER.warning(f"Dropping {len(extra_cols)} extra columns not present in schema: {extra_cols}")
166
172
 
167
173
  df_final = df_processed[final_column_order]
168
174
 
169
- _LOGGER.info(f"Schema applied successfully. Final shape: {df_final.shape}")
175
+ if verbose >= 2:
176
+ _LOGGER.info(f"Schema applied successfully. Final shape: {df_final.shape}")
170
177
 
171
178
  # df_final should be a dataframe
172
179
  if isinstance(df_final, pd.Series):
@@ -174,3 +181,95 @@ def apply_feature_schema(
174
181
 
175
182
  return df_final
176
183
 
184
+
185
+ def reconstruct_from_schema(
186
+ df: pd.DataFrame,
187
+ schema: FeatureSchema,
188
+ targets: Optional[list[str]] = None,
189
+ verbose: int = 3
190
+ ) -> pd.DataFrame:
191
+ """
192
+ Reverses the schema application to make data human-readable.
193
+
194
+ This function decodes categorical features back to their string representations
195
+ using the schema's mappings. It strictly enforces the schema structure,
196
+ ignoring extra columns (unless they are specified as targets).
197
+
198
+ Args:
199
+ df (pd.DataFrame): The input DataFrame containing encoded features.
200
+ schema (FeatureSchema): The schema defining feature names and reverse mappings.
201
+ targets (list[str] | None): Optional list of target column names to preserve. These are not decoded and kept in the order specified here.
202
+ verbose (int): Verbosity level for logging info about the process.
203
+
204
+ Returns:
205
+ pd.DataFrame: A new DataFrame with the exact column order (features + targets),
206
+ with categorical features decoded to strings.
207
+
208
+ Raises:
209
+ ValueError: If any required feature or target column is missing.
210
+ """
211
+ # 1. Setup
212
+ df_decoded = df.copy()
213
+ targets = targets if targets is not None else []
214
+
215
+ # 2. Validation: Strict Column Presence
216
+ # Check Features
217
+ missing_features = [col for col in schema.feature_names if col not in df_decoded.columns]
218
+ if missing_features:
219
+ _LOGGER.error(f"Schema Reconstruction Mismatch: Missing required features: {missing_features}")
220
+ raise ValueError()
221
+
222
+ # Check Targets
223
+ if targets:
224
+ missing_targets = [col for col in targets if col not in df_decoded.columns]
225
+ if missing_targets:
226
+ _LOGGER.error(f"Schema Reconstruction Mismatch: Missing required targets: {missing_targets}")
227
+ raise ValueError()
228
+
229
+ # 3. Reorder and Filter (Drop extra columns early)
230
+ # The valid columns are Features + Targets
231
+ valid_columns = list(schema.feature_names) + targets
232
+
233
+ extra_cols = set(df_decoded.columns) - set(valid_columns)
234
+ if extra_cols:
235
+ if verbose >= 1:
236
+ _LOGGER.warning(f"Dropping extra columns not present in schema or targets: {extra_cols}")
237
+
238
+ # Enforce order: Features first, then Targets
239
+ df_decoded = df_decoded[valid_columns]
240
+
241
+ # 4. Reverse Categorical Encoding
242
+ if schema.categorical_feature_names and schema.categorical_mappings:
243
+ for col_name in schema.categorical_feature_names:
244
+ if col_name not in schema.categorical_mappings:
245
+ continue
246
+
247
+ forward_mapping = schema.categorical_mappings[col_name]
248
+ # Create reverse map: {int: str}
249
+ reverse_mapping = {v: k for k, v in forward_mapping.items()}
250
+
251
+ # --- SAFE TYPE CASTING ---
252
+ # Ensure values are Integers before mapping (handle 5.0 vs 5).
253
+ try:
254
+ if pd.api.types.is_numeric_dtype(df_decoded[col_name]):
255
+ df_decoded[col_name] = df_decoded[col_name].astype("Int64")
256
+ except (TypeError, ValueError):
257
+ # casted to NaN later during mapping
258
+ pass
259
+ # -------------------------
260
+
261
+ # Check for unknown codes before mapping
262
+ if verbose >= 1:
263
+ unique_codes = df_decoded[col_name].dropna().unique()
264
+ unknown_codes = [code for code in unique_codes if code not in reverse_mapping]
265
+ if unknown_codes:
266
+ _LOGGER.warning(f"Feature '{col_name}': Found unknown encoded values {unknown_codes}. These will be mapped to NaN.")
267
+
268
+ # Apply reverse mapping
269
+ df_decoded[col_name] = df_decoded[col_name].map(reverse_mapping)
270
+
271
+ if verbose >= 2:
272
+ _LOGGER.info(f"Schema reconstruction successful. Final shape: {df_decoded.shape}")
273
+
274
+ return df_decoded
275
+
@@ -202,13 +202,39 @@ class FeatureSchema(NamedTuple):
202
202
  filename=DatasetKeys.CATEGORICAL_NAMES,
203
203
  verbose=verbose)
204
204
 
205
- def save_artifacts(self, directory: Union[str,Path]):
205
+ def save_description(self, directory: Union[str, Path], verbose: bool = False) -> None:
206
+ """
207
+ Saves the schema's description to a .txt file.
208
+
209
+ Args:
210
+ directory: The directory where the file will be saved.
211
+ verbose: If True, prints a confirmation message upon saving.
212
+ """
213
+ dir_path = make_fullpath(directory, make=True, enforce="directory")
214
+ filename = "FeatureSchema-description.txt"
215
+ file_path = dir_path / filename
216
+
217
+ try:
218
+ with open(file_path, "w", encoding="utf-8") as f:
219
+ f.write(str(self))
220
+
221
+ if verbose:
222
+ _LOGGER.info(f"Schema description saved to '{dir_path.name}/{filename}'")
223
+ except IOError as e:
224
+ _LOGGER.error(f"Failed to save schema description: {e}")
225
+ raise e
226
+
227
+ def save_artifacts(self, directory: Union[str,Path], verbose: bool=True):
206
228
  """
207
229
  Saves feature names, categorical feature names, continuous feature names to separate text files.
208
230
  """
209
- self.save_all_features(directory=directory, verbose=True)
210
- self.save_continuous_features(directory=directory, verbose=True)
211
- self.save_categorical_features(directory=directory, verbose=True)
231
+ self.save_all_features(directory=directory, verbose=False)
232
+ self.save_continuous_features(directory=directory, verbose=False)
233
+ self.save_categorical_features(directory=directory, verbose=False)
234
+ self.save_description(directory=directory, verbose=False)
235
+
236
+ if verbose:
237
+ _LOGGER.info(f"All FeatureSchema artifacts saved to directory: '{directory}'")
212
238
 
213
239
  def __repr__(self) -> str:
214
240
  """Returns a concise representation of the schema's contents."""
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "dragon-ml-toolbox"
3
- version = "20.4.0"
3
+ version = "20.5.0"
4
4
  description = "Complete pipelines and helper tools for data science and machine learning projects."
5
5
  authors = [
6
6
  { name = "Karl Luigi Loza Vidaurre", email = "luigiloza@gmail.com" }