当前位置: 首页>>代码示例>>Python>>正文


Python base.WidgetOutputsTestMixin类代码示例

本文整理汇总了Python中Orange.widgets.tests.base.WidgetOutputsTestMixin的典型用法代码示例。如果您正苦于以下问题:Python WidgetOutputsTestMixin类的具体用法?Python WidgetOutputsTestMixin怎么用?Python WidgetOutputsTestMixin使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了WidgetOutputsTestMixin类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.signal_name = "Data"
        cls.signal_data = cls.data
        cls.scorename = "Silhouette ({})".format(cls.data.domain.class_var.name)
开发者ID:lanzagar,项目名称:orange3,代码行数:7,代码来源:test_owsilhouetteplot.py

示例2: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)
        cls.same_input_output_domain = False

        cls.signal_name = "Data"
        cls.signal_data = cls.data
开发者ID:mstrazar,项目名称:orange3,代码行数:7,代码来源:test_owtsne.py

示例3: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.signal_name = "Distances"
        cls.signal_data = Euclidean(cls.data)
        cls.same_input_output_domain = False
开发者ID:biolab,项目名称:orange3,代码行数:7,代码来源:test_owmds.py

示例4: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.signal_name = "Data"
        cls.signal_data = cls.data
        cls.titanic = Table("titanic")
        cls.iris = Table("iris")
开发者ID:biolab,项目名称:orange3,代码行数:8,代码来源:test_owsieve.py

示例5: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.signal_name = "Distances"
        cls.signal_data = Euclidean(cls.data)
        cls.same_input_output_domain = False

        my_dir = os.path.dirname(__file__)
        datasets_dir = os.path.join(my_dir, '..', '..', '..', 'datasets')
        cls.datasets_dir = os.path.realpath(datasets_dir)
开发者ID:PrimozGodec,项目名称:orange3,代码行数:11,代码来源:test_owmds.py

示例6: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.iris = Table("iris")
        cls.zoo = Table("zoo")
        cls.housing = Table("housing")
        cls.titanic = Table("titanic")
        cls.heart = Table("heart_disease")
        cls.data = cls.iris
        cls.signal_name = "Data"
        cls.signal_data = cls.data
开发者ID:lanzagar,项目名称:orange3,代码行数:12,代码来源:test_owboxplot.py

示例7: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.titanic = Table('titanic')
        cls.learner = CN2Learner()
        cls.classifier = cls.learner(cls.titanic)
        # CN2Learner does not add `instances` attribute to the model, but
        # the Rules widget does. We simulate the model we get from the widget.
        cls.classifier.instances = cls.titanic

        cls.signal_name = "Classifier"
        cls.signal_data = cls.classifier
        cls.data = cls.titanic
开发者ID:astaric,项目名称:orange3,代码行数:14,代码来源:test_owruleviewer.py

示例8: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        tree = TreeLearner()
        cls.model = tree(cls.data)
        cls.model.instances = cls.data

        cls.signal_name = "Tree"
        cls.signal_data = cls.model

        # Load a dataset that contains two variables with the same entropy
        data_same_entropy = Table(path.join(
            path.dirname(path.dirname(path.dirname(__file__))), "tests",
            "datasets", "same_entropy.tab"))
        cls.data_same_entropy = tree(data_same_entropy)
        cls.data_same_entropy.instances = data_same_entropy
开发者ID:PrimozGodec,项目名称:orange3,代码行数:17,代码来源:test_owtreegraph.py

示例9: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        # Set up for output tests
        tree = TreeLearner()
        cls.model = tree(cls.data)
        cls.model.instances = cls.data

        cls.signal_name = "Tree"
        cls.signal_data = cls.model

        # Set up for widget tests
        titanic_data = Table('titanic')[::50]
        cls.titanic = TreeLearner(max_depth=1)(titanic_data)
        cls.titanic.instances = titanic_data

        housing_data = Table('housing')[:10]
        cls.housing = TreeLearner(max_depth=1)(housing_data)
        cls.housing.instances = housing_data
开发者ID:astaric,项目名称:orange3,代码行数:20,代码来源:test_owpythagorastree.py

示例10: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.signal_name = "Data"
        cls.signal_data = cls.data
开发者ID:biolab,项目名称:orange3,代码行数:6,代码来源:test_owlineplot.py

示例11: setUpClass

    def setUpClass(cls):
        super().setUpClass()
        WidgetOutputsTestMixin.init(cls)

        cls.signal_name = "Data"
        cls.signal_data = cls.data  # pylint: disable=no-member
开发者ID:PrimozGodec,项目名称:orange3,代码行数:6,代码来源:test_owtable.py


注:本文中的Orange.widgets.tests.base.WidgetOutputsTestMixin类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。