Skip to content

Commit 4e6a359

Browse files
authored
release: v2.0.0
Merge release/v2.0.0 into main. DeepTab v2.0.0: new split-config sklearn-compatible API, renamed config classes, updated import/data layers, and the .deeptab save/load/serve flow. See CHANGELOG.md for full details.
2 parents 603618d + 0becce8 commit 4e6a359

73 files changed

Lines changed: 4313 additions & 1575 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/publish-pypi.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@ jobs:
1919
publish:
2020
runs-on: ubuntu-latest
2121
environment: pypi-publish
22+
# The "v*.*.*" trigger also matches RC tags (e.g. v2.0.0rc2), so guard
23+
# against publishing pre-releases to real PyPI. RC tags are handled by
24+
# publish-testpypi.yml instead.
25+
if: ${{ !contains(github.ref_name, 'rc') }}
2226

2327
steps:
2428
- name: Checkout code

CHANGELOG.md

Lines changed: 127 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,133 @@ Going forward, this file is updated automatically by `cz bump` on each release.
99

1010
---
1111

12+
## v2.0.0 (2026-06-24)
13+
14+
### BREAKING CHANGE
15+
16+
- internal package layout, configuration objects, and import
17+
paths have changed. See the migration guide for details.
18+
19+
### Feat
20+
21+
- DeepTab v2 API with split-config design (#400)
22+
- **config**: warn on misplaced config slots
23+
- **training**: add unregister_optimizer, unregister_scheduler with built-in protection
24+
- **inspection**: expose public read-only task_model property
25+
- **models**: thread observability_config through all estimators
26+
- **core**: add ObservabilityConfig
27+
- **models**: expose ObservabilityConfig on base estimator constructor
28+
- **models**: add observability mixin wiring ObservabilityConfig to base estimators
29+
- **models**: integrate ObservabilityConfig into fit mixin
30+
- **training**: rewrite configure_optimizers, add contrastive pretraining fixes, and cleanup
31+
- introduce IDataModule/ITaskModel protocols and default factories, wire into SklearnBase
32+
- **configs**: add optimizer/scheduler fields to TrainerConfig and InferenceModel support
33+
- **training**: wire optimizer/scheduler registry into LightningModule and extend losses
34+
- **training**: add optimizer/scheduler registry with all torch.optim classes
35+
- **api**: export exception and warning types from deeptab and deeptab.core
36+
- **configs,models**: add **post_init** validation using typed exceptions
37+
- **core**: add exception hierarchy and message factories
38+
- **models**: wire evaluate() in lss_base, regressor_base, and classifier_base to new deeptab.metrics registry
39+
- **metrics**: add deeptab metrics ABC, regression, classification, lss
40+
- add tweedie, inflated poissons, log normal etc. distribution
41+
- light weight inference wrapper
42+
- **serialization**: warn when save/load path lacks .deeptab extension
43+
- **inspection**: add profile() method for pre-training dry-run diagnostics
44+
- **training**: add class-imbalance loss registry and weighted sampling
45+
- **core**: add set_seed/seed_context reproducibility helpers
46+
- **core**: add sklearn_compat module and update serialization/core exports
47+
- add rich model artifact serialization metadata
48+
- model inspection api added
49+
- **data**: add optional TabularBatch return mode
50+
- **data**: add stratified splitting for classification and schema property
51+
- **data**: add FeatureSchema and TabularBatch typed containers
52+
- **configs**: add SplitConfig for train/validation splitting parameters
53+
- **root**: expose configs, data, distributions, metrics, models in top-level **init**
54+
- **models**: add \_docstring helper to centralize generate_docstring for all models
55+
- **models**: expose stable classes in **all** and add **getattr** shim for experimental
56+
- **models**: add split base classes for classifier, regressor, and LSS task variants
57+
- **configs**: add configs/core.py with shared base configuration definitions
58+
- **configs**: add configs/experimental sub module for ModernNCA, Tangos, Trompt
59+
- **configs**: add configs sub module with per-model config modules
60+
- **hpo**: add hpo module with get_search_space mapper
61+
- **metrics**: add metrics module stubs for classification, regression, distributional
62+
- **distributions**: add distributions module with 12 distribution classes
63+
- **data**: add data module with MambularDataModule, MambularDataset, batch, schema, split
64+
- **training**: add training module with lightning module, losses, optimizers, schedulers
65+
- **core**: add core module with BaseModel, registry, embeddings, pooling, serialization
66+
- **architectures**: add experimental sub-package with ModernNCA, Tangos, Trompt
67+
- **architectures**: add architectures module with all stable model definitions
68+
- **nn**: add nn module with blocks, normalization, and initialization
69+
- **config**: split config into trainer, model and preprocessing config
70+
- **sklearn_parent**: implement split-config path in SklearnBase.**init**, get_params, set_params
71+
- **models**: add split config **init** to all Classifier and Regressor wrappers
72+
- **base_models**: replace DefaultXXConfig with XXConfig in all base model constructors
73+
- **configs**: add \*Config for all architectures
74+
- **configs**: add ENODEConfig architecture only config
75+
- **hardware**: add print_hardware_info for CPU/CUDA/MPS detection
76+
77+
### Fix
78+
79+
- **sklearn_compat**: satisfy pandas typing in ensure_dataframe
80+
- **training**: register custom torchmetrics via nn.ModuleDict so state moves to device
81+
- **sklearn_compat**: cast pandas category columns to object in ensure_dataframe
82+
- **modernnca**: support LSS prediction and add experimental model tests
83+
- **models**: adapt child class to use class var, update docstring example
84+
- **transformer**: use batch_first attention to prevent cross-sample leakage
85+
- **hpo**: rebuild model per trial and map activation names to modules
86+
- save default artificats to <run_dir>/artifacts/model.deeptab
87+
- **base**: add **sklearn_is_fitted**, use check_is_fitted
88+
- **sklearn_compat**: raise ValueError for 1D array input in ensure_dataframe
89+
- **exceptions**: inherit EmptyDataError and ColumnCountError from ValueError for sklearn compat
90+
- add seed to DataLoader/sampler generators
91+
- data validation for parameters
92+
- **models**: read optimizer_type and preprocessor live from config in \_build_model
93+
- **test**: add typed error, fix preprocessing config
94+
- **architectures,distributions**: replace ValueError with typed exceptions
95+
- **docs**: remove dead cross-reference links and fix tables
96+
- **training**: apply distribution parameter transform before passing predictions to metrics
97+
- use r2 metric for regresion as default
98+
- use getattr for task_model access in InspectionMixin
99+
- enable side bar navigation for api reference
100+
- **tests**: update flat-kwarg error assertions to match native TypeError message
101+
- **tests**: update config lookup to search configs.models and configs.experimental
102+
- training parameter added
103+
- modernca config and model update
104+
- **lss**: use getattr fallback for lr/weight_decay in SklearnBaseLSS.fit()
105+
106+
### Refactor
107+
108+
- **models**: drop legacy flat-kwargs constructor
109+
- **core**: centralize optional-dependency
110+
- replace SplitConfig with TrainerConfig.stratify and refresh docs
111+
- **models**: adopt declarative class variable estimator pattern
112+
- **hpo**: rename mapper.py to search_space.py and fix lss_base error
113+
- **core**: update inspection and serialization for \_ attribute rename
114+
- **models**: prefix non-constructor attributes with \_ for sklearn compliance
115+
- extract \_FitMixin, \_PredictMixin, \_SerializationMixin, \_HyperparameterMixin, \_ObservabilityMixin from SklearnBase
116+
- **configs**: remove legacy BaseConfig class
117+
- **distributions**: separate dist classes, add registry
118+
- consolidate save/load into core.serialization helpers
119+
- **models**: update base classifier/regressor/lss model internals
120+
- **data**: update datamodule and dataset internals
121+
- **models**: update imports to use TabularDataModule
122+
- **data**: rename to TabularDataset/TabularDataModule and move task-specific label logic to DataModule
123+
- **models**: replace \*\*kwargs with explicit signatures in stable model constructors
124+
- **hpo**: add missing exports to hpo/**init**.py
125+
- **models**: update training and hpo imports to go through package boundaries
126+
- **architectures**: update core imports to go through package boundary
127+
- **architectures**: add lazy **getattr** boundary with TYPE_CHECKING guards
128+
- **nn**: expose public API via nn/**init**.py boundary
129+
- **training**: expose public API via training/**init**.py boundary
130+
- **core**: expose public API via core/**init**.py boundary
131+
- **architectures**: update config imports to use configs/models/ and configs/experimental/
132+
- **models**: update config imports to use configs/models/, configs/experimental/, and configs/core
133+
- **configs**: update **init** to import from core, models/, and experimental/
134+
- **configs**: remove deprecated flat config files superseded by models/ and experimental/
135+
- **models**: update import paths in experimental ModernNCA, Tangos, Trompt modules
136+
- **models**: update import paths in ndtf, node, resnet, saint, tabm, tabr, tabtransformer, tabularnn
137+
- **modules**: remove legacy arch_utils, base_models, data_utils, utils
138+
12139
## v1.8.0 (2026-05-24)
13140

14141
### Feat

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2024 BASF
3+
Copyright (c) 2024 OpenTabular
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
## Why DeepTab?
2525

2626
- **Familiar interface.** A scikit-learn `fit`/`predict`/`evaluate` API that drops into existing pipelines, including `GridSearchCV`.
27-
- **Automatic preprocessing.** Feature-type detection, encoding, scaling, and missing-value handling are built in.
27+
- **Automatic preprocessing.** Feature-type detection, encoding, scaling, and missing-value handling are powered by [PreTab](https://github.com/OpenTabular/PreTab) and applied for you.
2828
- **One model, three tasks.** Every architecture ships as a classifier, a regressor, and a distributional (`LSS`) variant for uncertainty quantification.
2929
- **A broad model zoo.** 15 stable architectures plus experimental models, all behind the same interface, with [selection guidance](https://deeptab.readthedocs.io/en/latest/model_zoo/index.html).
3030
- **Built for real data.** Mixed feature types, class imbalance, GPU acceleration, and early stopping work out of the box.

deeptab/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
NotFittedError,
99
PerformanceWarning,
1010
)
11+
from .core.hardware import print_hardware_info
1112
from .core.inference import InferenceModel
1213
from .core.reproducibility import seed_context, set_seed
1314

@@ -25,6 +26,7 @@
2526
"distributions",
2627
"metrics",
2728
"models",
29+
"print_hardware_info",
2830
"seed_context",
2931
"set_seed",
3032
]

deeptab/configs/experimental/tangos_config.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ class TangosConfig(BaseModelConfig):
2525
skip_connections : bool, default=False
2626
Whether to use skip connections in the TANGOS.
2727
lamda1 : float, default=0.5
28-
Weight on the task-specific orthogonality regularisation term.
28+
Weight on the specialization regularisation term (multiplies ``spec_loss``).
2929
lamda2 : float, default=0.1
30-
Weight on the cross-task specialisation regularisation term.
30+
Weight on the orthogonalization regularisation term (multiplies ``orth_loss``).
3131
subsample : float, default=0.5
3232
Fraction of features subsampled for regularisation estimation.
3333
"""

deeptab/core/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
NotFittedError,
1919
PerformanceWarning,
2020
)
21+
from .hardware import print_hardware_info
2122
from .inference import InferenceModel
2223
from .inspection import ImportanceGetter, InspectionMixin, get_feature_dimensions
2324
from .registry import MODEL_REGISTRY, ModelInfo
@@ -67,6 +68,7 @@
6768
"get_feature_dimensions",
6869
"load_state_dict",
6970
"make_random_batches",
71+
"print_hardware_info",
7072
"restore_loaded_metadata",
7173
"save_state_dict",
7274
"seed_context",

0 commit comments

Comments
 (0)