dragon-ml-toolbox 13.3.0__py3-none-any.whl → 16.2.0__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.
Files changed (48) hide show
  1. {dragon_ml_toolbox-13.3.0.dist-info → dragon_ml_toolbox-16.2.0.dist-info}/METADATA +20 -6
  2. dragon_ml_toolbox-16.2.0.dist-info/RECORD +51 -0
  3. {dragon_ml_toolbox-13.3.0.dist-info → dragon_ml_toolbox-16.2.0.dist-info}/licenses/LICENSE-THIRD-PARTY.md +10 -0
  4. ml_tools/ETL_cleaning.py +20 -20
  5. ml_tools/ETL_engineering.py +23 -25
  6. ml_tools/GUI_tools.py +20 -20
  7. ml_tools/MICE_imputation.py +207 -5
  8. ml_tools/ML_callbacks.py +43 -26
  9. ml_tools/ML_configuration.py +788 -0
  10. ml_tools/ML_datasetmaster.py +303 -448
  11. ml_tools/ML_evaluation.py +351 -93
  12. ml_tools/ML_evaluation_multi.py +139 -42
  13. ml_tools/ML_inference.py +290 -209
  14. ml_tools/ML_models.py +33 -106
  15. ml_tools/ML_models_advanced.py +323 -0
  16. ml_tools/ML_optimization.py +12 -12
  17. ml_tools/ML_scaler.py +11 -11
  18. ml_tools/ML_sequence_datasetmaster.py +341 -0
  19. ml_tools/ML_sequence_evaluation.py +219 -0
  20. ml_tools/ML_sequence_inference.py +391 -0
  21. ml_tools/ML_sequence_models.py +139 -0
  22. ml_tools/ML_trainer.py +1604 -179
  23. ml_tools/ML_utilities.py +351 -4
  24. ml_tools/ML_vision_datasetmaster.py +1540 -0
  25. ml_tools/ML_vision_evaluation.py +284 -0
  26. ml_tools/ML_vision_inference.py +405 -0
  27. ml_tools/ML_vision_models.py +641 -0
  28. ml_tools/ML_vision_transformers.py +284 -0
  29. ml_tools/PSO_optimization.py +6 -6
  30. ml_tools/SQL.py +4 -4
  31. ml_tools/_keys.py +171 -0
  32. ml_tools/_schema.py +1 -1
  33. ml_tools/custom_logger.py +37 -14
  34. ml_tools/data_exploration.py +502 -93
  35. ml_tools/ensemble_evaluation.py +54 -11
  36. ml_tools/ensemble_inference.py +7 -33
  37. ml_tools/ensemble_learning.py +1 -1
  38. ml_tools/math_utilities.py +1 -1
  39. ml_tools/optimization_tools.py +2 -2
  40. ml_tools/path_manager.py +5 -5
  41. ml_tools/serde.py +2 -2
  42. ml_tools/utilities.py +192 -4
  43. dragon_ml_toolbox-13.3.0.dist-info/RECORD +0 -41
  44. ml_tools/RNN_forecast.py +0 -56
  45. ml_tools/keys.py +0 -87
  46. {dragon_ml_toolbox-13.3.0.dist-info → dragon_ml_toolbox-16.2.0.dist-info}/WHEEL +0 -0
  47. {dragon_ml_toolbox-13.3.0.dist-info → dragon_ml_toolbox-16.2.0.dist-info}/licenses/LICENSE +0 -0
  48. {dragon_ml_toolbox-13.3.0.dist-info → dragon_ml_toolbox-16.2.0.dist-info}/top_level.txt +0 -0
ml_tools/keys.py DELETED
@@ -1,87 +0,0 @@
1
- class PyTorchLogKeys:
2
- """
3
- Used internally for ML scripts module.
4
-
5
- Centralized keys for logging and history.
6
- """
7
- # --- Epoch Level ---
8
- TRAIN_LOSS = 'train_loss'
9
- VAL_LOSS = 'val_loss'
10
-
11
- # --- Batch Level ---
12
- BATCH_LOSS = 'loss'
13
- BATCH_INDEX = 'batch'
14
- BATCH_SIZE = 'size'
15
-
16
-
17
- class EnsembleKeys:
18
- """
19
- Used internally by ensemble_learning.
20
- """
21
- # Serializing a trained model metadata.
22
- MODEL = "model"
23
- FEATURES = "feature_names"
24
- TARGET = "target_name"
25
-
26
- # Classification keys
27
- CLASSIFICATION_LABEL = "labels"
28
- CLASSIFICATION_PROBABILITIES = "probabilities"
29
-
30
-
31
- class PyTorchInferenceKeys:
32
- """Keys for the output dictionaries of PyTorchInferenceHandler."""
33
- # For regression tasks
34
- PREDICTIONS = "predictions"
35
-
36
- # For classification tasks
37
- LABELS = "labels"
38
- PROBABILITIES = "probabilities"
39
-
40
-
41
- class PytorchModelArchitectureKeys:
42
- """Keys for saving and loading model architecture."""
43
- MODEL = 'model_class'
44
- CONFIG = "config"
45
- SAVENAME = "architecture"
46
-
47
-
48
- class PytorchArtifactPathKeys:
49
- """Keys for model artifact paths."""
50
- FEATURES_PATH = "feature_names_path"
51
- TARGETS_PATH = "target_names_path"
52
- ARCHITECTURE_PATH = "model_architecture_path"
53
- WEIGHTS_PATH = "model_weights_path"
54
- SCALER_PATH = "scaler_path"
55
-
56
-
57
- class DatasetKeys:
58
- """Keys for saving dataset artifacts. Also used by FeatureSchema"""
59
- FEATURE_NAMES = "feature_names"
60
- TARGET_NAMES = "target_names"
61
- SCALER_PREFIX = "scaler_"
62
- # Feature Schema
63
- CONTINUOUS_NAMES = "continuous_feature_names"
64
- CATEGORICAL_NAMES = "categorical_feature_names"
65
-
66
-
67
- class SHAPKeys:
68
- """Keys for SHAP functions"""
69
- FEATURE_COLUMN = "feature"
70
- SHAP_VALUE_COLUMN = "mean_abs_shap_value"
71
- SAVENAME = "shap_summary"
72
-
73
-
74
- class PyTorchCheckpointKeys:
75
- """Keys for saving/loading a training checkpoint dictionary."""
76
- MODEL_STATE = "model_state_dict"
77
- OPTIMIZER_STATE = "optimizer_state_dict"
78
- SCHEDULER_STATE = "scheduler_state_dict"
79
- EPOCH = "epoch"
80
- BEST_SCORE = "best_score"
81
-
82
-
83
- class _OneHotOtherPlaceholder:
84
- """Used internally by GUI_tools."""
85
- OTHER_GUI = "OTHER"
86
- OTHER_MODEL = "one hot OTHER placeholder"
87
- OTHER_DICT = {OTHER_GUI: OTHER_MODEL}