Did I find the right examples for you? yes no

All Samples(0)  |  Call(0)  |  Derive(0)  |  Import(0)

src/c/e/CellProfiler-HEAD/cellprofiler/modules/tests/test_unmixcolors.py   CellProfiler(Download)
        self.assertEqual(module.outputs[-1].image_name, "RedWine")
        for i, stain in enumerate((
            U.CHOICE_HEMATOXYLIN, U.CHOICE_EOSIN, U.CHOICE_DAB,
            U.CHOICE_FAST_RED, U.CHOICE_FAST_BLUE, U.CHOICE_METHYL_GREEN,
            U.CHOICE_AEC, U.CHOICE_ANILINE_BLUE, U.CHOICE_AZOCARMINE,
    def test_02_01_zeros(self):
        '''Test on an image of all zeros'''
        workspace, module = self.make_workspace(np.zeros((10,20,3)),
                                                [U.CHOICE_HEMATOXYLIN])
        module.run(workspace)
    def test_02_02_ones(self):
        '''Test on an image of all ones'''
        workspace, module = self.make_workspace(np.ones((10,20,3)),
                                                [U.CHOICE_HEMATOXYLIN])
        module.run(workspace)
        expected = np.random.uniform(size=(10,20))
        image = self.make_image(expected, U.ST_HEMATOXYLIN)
        workspace, module = self.make_workspace(image, [U.CHOICE_HEMATOXYLIN])
        module.run(workspace)
        image = workspace.image_set.get_image(output_image_name(0))
        image *= self.make_image(expected_2, U.ST_EOSIN)
        workspace, module = self.make_workspace(image, [
            U.CHOICE_HEMATOXYLIN, U.CHOICE_EOSIN ])
        module.run(workspace)
        image_1 = workspace.image_set.get_image(output_image_name(0))