sbmf 0.1.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.
sbmf/__init__.py ADDED
@@ -0,0 +1,38 @@
1
+ """sbmf -- sparse and semi-binary matrix factorization.
2
+
3
+ Binary autoencoder / binary matrix factorization models (SemiBMF, JBMF, BiPCA,
4
+ SCPD, RRBMF, KernelBMF), their compiled E-step kernels and priors, and the
5
+ simulation / analysis utilities in `df_util` and `bae_util`.
6
+
7
+ Submodules load lazily on first access, so `import sbmf` is instant:
8
+
9
+ from sbmf.bae_models import BiPCA, SemiBMF
10
+ from sbmf.bae_util import impcv, bicv
11
+ from sbmf import df_util
12
+
13
+ Import cost (heaviest dependency each pulls in):
14
+ util, numba_util, bae_search, bae_priors numpy / scipy / networkx / numba
15
+ bae_weights, bae_models + torch
16
+ df_util, bae_util + torch, cvxpy, scikit-learn
17
+ """
18
+
19
+ import importlib
20
+
21
+ __version__ = "0.1.0"
22
+
23
+ _SUBMODULES = (
24
+ "bae_models", "bae_weights", "bae_priors", "bae_search", "numba_util",
25
+ "bae_util", "df_util", "util",
26
+ )
27
+
28
+ __all__ = list(_SUBMODULES)
29
+
30
+
31
+ def __getattr__(name):
32
+ if name in _SUBMODULES:
33
+ return importlib.import_module(f".{name}", __name__)
34
+ raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
35
+
36
+
37
+ def __dir__():
38
+ return sorted(list(globals()) + list(_SUBMODULES))