source: orange/Orange/__init__.py @ 10546:f9e50d3e9e2d

Revision 10546:f9e50d3e9e2d, 3.3 KB checked in by anzeh <anze.staric@…>, 2 years ago (diff)

Updated location of preprocess module.

Line 
1from __future__ import absolute_import
2
3__version__ = "2.5a4"
4
5from . import orange
6
7# Definitely ugly, but I see no other workaround.
8# When, e.g. data.io executes "from orange import ExampleTable"
9# orange gets imported again since it is not in sys.modules
10# before this entire file is executed
11import sys
12sys.modules["orange"] = orange
13
14import warnings
15
16alreadyWarned = False
17disabledMsg = "Some features will be disabled due to failing modules\n"
18def _import(name):
19    global alreadyWarned
20    try:
21        __import__(name, globals(), locals(), [], -1)
22    except ImportError, err:
23        warnings.warn("%sImporting '%s' failed: %s" %
24            (disabledMsg if not alreadyWarned else "", name, err),
25            UserWarning, 2)
26        alreadyWarned = True
27
28_import("misc")
29_import("data")
30_import("data.io")
31_import("data.sample")
32_import("data.outliers")
33_import("data.preprocess")
34_import("data.preprocess.scaling")
35_import("data.utils")
36_import("data.discretization")
37_import("data.continuization")
38_import("data.filter")
39_import("data.imputation")
40
41_import("feature")
42_import("feature.construction")
43_import("feature.construction.functionDecomposition")
44_import("feature.construction.univariate")
45_import("feature.discretization")
46_import("feature.imputation")
47_import("feature.scoring")
48_import("feature.selection")
49
50_import("network")
51
52_import("stat")
53
54_import("statistics")
55_import("statistics.estimate")
56_import("statistics.contingency")
57_import("statistics.distribution")
58_import("statistics.basic")
59_import("statistics.evd")
60
61_import("classification")
62_import("classification.tree")
63
64_import("classification.rules")
65
66_import("classification.lookup")
67_import("classification.bayes")
68_import("classification.svm")
69_import("classification.logreg")
70_import("classification.knn")
71_import("classification.majority")
72
73_import("optimization")
74
75_import("projection")
76_import("projection.linear")
77_import("projection.mds")
78_import("projection.som")
79
80_import("ensemble")
81_import("ensemble.bagging")
82_import("ensemble.boosting")
83_import("ensemble.forest")
84
85_import("regression")
86_import("regression.base")
87_import("regression.earth")
88_import("regression.lasso")
89_import("regression.linear")
90_import("regression.mean")
91_import("regression.pls")
92_import("regression.tree")
93
94_import("multitarget")
95_import("multitarget.tree")
96
97_import("multilabel")
98_import("multilabel.multibase")
99_import("multilabel.br")
100_import("multilabel.lp")
101_import("multilabel.mlknn")
102_import("multilabel.brknn")
103_import("multilabel.mulan")
104
105_import("associate")
106
107_import("distance")
108
109_import("wrappers")
110
111_import("featureConstruction")
112_import("featureConstruction.univariate")
113_import("featureConstruction.functionDecomposition")
114
115_import("evaluation")
116_import("evaluation.scoring")
117_import("evaluation.testing")
118_import("evaluation.reliability")
119
120_import("clustering")
121_import("clustering.kmeans")
122_import("clustering.hierarchical")
123_import("clustering.consensus")
124
125_import("misc")
126_import("misc.environ")
127_import("misc.counters")
128_import("misc.addons")
129_import("misc.render")
130_import("misc.selection")
131_import("misc.serverfiles")
132#_import("misc.r")
133
134try:
135    from . import version
136    # Always use short_version here (see PEP 386)
137    __version__ = version.short_version
138    __hg_revision__ = version.hg_revision
139except ImportError:
140    # Leave the default version defined at the top.
141    pass
142
Note: See TracBrowser for help on using the repository browser.