Changeset 7828:c4ceb0495698 in orange


Ignore:
Timestamp:
04/11/11 11:14:56 (3 years ago)
Author:
markotoplak
Branch:
default
Convert:
8c40f4c4a89bee88c0325543b9379040ed9263fa
Message:

Modified main init: a bug in a single module does not prevent the whole Orange to load.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orange/Orange/__init__.py

    r7660 r7828  
    88sys.modules["orange"] = orange 
    99 
    10 import data 
    11 import data.io 
    12 import data.sample 
    13 import data.variable 
     10import warnings 
    1411 
    15 import network 
     12def _import(name): 
     13    try: 
     14        __import__(name, globals(), locals(), [], -1) 
     15    except: 
     16        warnings.warn("Could not import: " + name, UserWarning, 2) 
    1617 
    17 import stat 
     18_import("data") 
     19_import("data.io") 
     20_import("data.sample") 
     21_import("data.variable") 
    1822 
    19 import statistics 
    20 import statistics.estimate 
    21 import statistics.contingency 
    22 import statistics.distribution 
    23 import statistics.basic 
    24 import statistics.evd 
     23_import("network") 
    2524 
    26 import classification 
    27 import classification.tree 
    28 import classification.rules 
    29 import classification.lookup 
    30 import classification.bayes 
    31 import classification.svm 
    32 import classification.logreg 
    33 import classification.knn 
    34 import classification.majority 
     25_import("stat") 
    3526 
    36 import optimization 
     27_import("statistics") 
     28_import("statistics.estimate") 
     29_import("statistics.contingency") 
     30_import("statistics.distribution") 
     31_import("statistics.basic") 
     32_import("statistics.evd") 
    3733 
    38 import projection 
    39 import projection.mds 
    40 import projection.som 
     34_import("classification") 
     35_import("classification.tree") 
    4136 
    42 import ensemble 
    43 import ensemble.bagging 
    44 import ensemble.boosting 
    45 import ensemble.forest 
     37_import("classification.rules") 
    4638 
    47 import regression 
    48 import regression.mean 
     39_import("classification.lookup") 
     40_import("classification.bayes") 
     41_import("classification.svm") 
     42_import("classification.logreg") 
     43_import("classification.knn") 
     44_import("classification.majority") 
    4945 
    50 import associate 
     46_import("optimization") 
    5147 
    52 import preprocess 
     48_import("projection") 
     49_import("projection.mds") 
     50_import("projection.som") 
     51 
     52_import("ensemble") 
     53_import("ensemble.bagging") 
     54_import("ensemble.boosting") 
     55_import("ensemble.forest") 
     56 
     57_import("regression") 
     58_import("regression.mean") 
     59 
     60_import("associate") 
     61 
     62_import("preprocess") 
    5363#import preprocess.value 
    5464#import preprocess.data 
    5565 
    56 import distances 
     66_import("distances") 
    5767 
    58 import wrappers 
     68_import("wrappers") 
    5969 
    60 import featureConstruction 
    61 import featureConstruction.univariate 
    62 import featureConstruction.functionDecomposition 
     70_import("featureConstruction") 
     71_import("featureConstruction.univariate") 
     72_import("featureConstruction.functionDecomposition") 
    6373 
    64 import evaluation 
    65 import evaluation.scoring 
    66 import evaluation.testing 
     74_import("evaluation") 
     75_import("evaluation.scoring") 
     76_import("evaluation.testing") 
    6777 
    68 import clustering 
    69 import clustering.kmeans 
    70 import clustering.hierarchical 
     78_import("clustering") 
     79_import("clustering.kmeans") 
     80_import("clustering.hierarchical") 
    7181 
    7282import misc 
Note: See TracChangeset for help on using the changeset viewer.