dfm-python 0.2.9__py3-none-any.whl → 0.3.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.
- dfm_python/__init__.py +10 -8
- dfm_python/api.py +699 -67
- dfm_python/config.py +5 -70
- dfm_python/config_sources.py +148 -115
- dfm_python/core/diagnostics.py +39 -30
- dfm_python/core/em.py +72 -52
- dfm_python/core/helpers.py +307 -44
- dfm_python/core/numeric.py +2 -2
- dfm_python/core/time.py +775 -0
- dfm_python/{utils.py → core/utils.py} +68 -3
- dfm_python/data.py +256 -52
- dfm_python/dfm.py +67 -25
- dfm_python/nowcast.py +1519 -0
- {dfm_python-0.2.9.dist-info → dfm_python-0.3.0.dist-info}/METADATA +423 -49
- dfm_python-0.3.0.dist-info/RECORD +19 -0
- dfm_python/news.py +0 -774
- dfm_python-0.2.9.dist-info/RECORD +0 -18
- {dfm_python-0.2.9.dist-info → dfm_python-0.3.0.dist-info}/WHEEL +0 -0
- {dfm_python-0.2.9.dist-info → dfm_python-0.3.0.dist-info}/licenses/LICENSE +0 -0
dfm_python/__init__.py
CHANGED
|
@@ -50,11 +50,11 @@ Example (Low-level API - For advanced usage):
|
|
|
50
50
|
For detailed documentation, see the README.md file and the tutorial notebooks/scripts.
|
|
51
51
|
"""
|
|
52
52
|
|
|
53
|
-
__version__ = "0.
|
|
53
|
+
__version__ = "0.3.0"
|
|
54
54
|
|
|
55
55
|
from .config import (
|
|
56
56
|
DFMConfig, SeriesConfig, BlockConfig, Params, DEFAULT_GLOBAL_BLOCK_NAME,
|
|
57
|
-
ConfigSource, YamlSource, DictSource,
|
|
57
|
+
ConfigSource, YamlSource, DictSource, HydraSource,
|
|
58
58
|
MergedConfigSource, make_config_source,
|
|
59
59
|
)
|
|
60
60
|
from .data import transform_data
|
|
@@ -62,13 +62,13 @@ from .dfm import DFMResult
|
|
|
62
62
|
from .core import calculate_rmse, diagnose_series, print_series_diagnosis
|
|
63
63
|
from .dfm import DFMCore # Core DFM class from dfm.py
|
|
64
64
|
from .kalman import run_kf, skf, fis, miss_data
|
|
65
|
-
from .
|
|
65
|
+
from .nowcast import Nowcast, para_const, NowcastResult, NewsDecompResult, BacktestResult
|
|
66
66
|
|
|
67
67
|
# Import high-level API (extends core DFM with convenience methods)
|
|
68
68
|
# Import module-level convenience functions directly from api.py to avoid duplication
|
|
69
69
|
from .api import (
|
|
70
70
|
DFM, _dfm_instance, from_yaml, from_spec, from_spec_df, from_dict,
|
|
71
|
-
load_config, load_data, train, predict, plot, reset
|
|
71
|
+
load_config, load_data, load_pickle, train, predict, plot, reset
|
|
72
72
|
)
|
|
73
73
|
|
|
74
74
|
# Expose properties as module-level attributes
|
|
@@ -97,15 +97,17 @@ def get_original_data():
|
|
|
97
97
|
|
|
98
98
|
__all__ = [
|
|
99
99
|
# Core classes
|
|
100
|
-
'DFMConfig', 'SeriesConfig', 'BlockConfig', 'Params', 'DFM', 'DFMCore',
|
|
100
|
+
'DFMConfig', 'SeriesConfig', 'BlockConfig', 'Params', 'DFM', 'DFMCore', 'Nowcast',
|
|
101
|
+
# Nowcast result classes
|
|
102
|
+
'NowcastResult', 'NewsDecompResult', 'BacktestResult',
|
|
101
103
|
# Constants
|
|
102
104
|
'DEFAULT_GLOBAL_BLOCK_NAME',
|
|
103
105
|
# Config sources
|
|
104
|
-
'ConfigSource', 'YamlSource', 'DictSource', '
|
|
106
|
+
'ConfigSource', 'YamlSource', 'DictSource', 'HydraSource',
|
|
105
107
|
'MergedConfigSource', 'make_config_source',
|
|
106
108
|
# High-level API (module-level - recommended)
|
|
107
109
|
'load_config',
|
|
108
|
-
'load_data', 'train', 'predict', 'plot', 'reset',
|
|
110
|
+
'load_data', 'load_pickle', 'train', 'predict', 'plot', 'reset',
|
|
109
111
|
'get_config', 'get_data', 'get_time', 'get_result', 'get_original_data',
|
|
110
112
|
# Convenience constructors (cleaner API)
|
|
111
113
|
'from_yaml', 'from_spec', 'from_spec_df', 'from_dict',
|
|
@@ -113,6 +115,6 @@ __all__ = [
|
|
|
113
115
|
'transform_data',
|
|
114
116
|
'DFMResult', 'calculate_rmse', 'diagnose_series', 'print_series_diagnosis',
|
|
115
117
|
'run_kf', 'skf', 'fis', 'miss_data',
|
|
116
|
-
'
|
|
118
|
+
'para_const', # Internal utility, kept for backward compatibility
|
|
117
119
|
]
|
|
118
120
|
|