def test_PCA(self): iris_v = ['Iris-setosa', 'Iris-virginica', 'Iris-versicolor'] table = SqlTable(self.conn, self.iris, type_hints=Domain([], DiscreteVariable("iris", values=iris_v))) for batch_size in (50, 500): rpca = RemotePCA(table, batch_size, 20) self.assertEqual(rpca.components_.shape, (4, 4))
def start(self): if 'Abort' in self.start_button.text(): self.rpca.abort() self.__timer.stop() self.start_button.setText("Start remote computation") else: self.address = self.addresstext.text() with remote.server(self.address): from Orange.projection.pca import RemotePCA maxiter = (1e5 + self.data.approx_len()) / self.batch_size * 3 self.rpca = RemotePCA(self.data, self.batch_size, int(maxiter)) self.update_model() self.start_button.setText("Abort remote computation")
def test_PCA(self): table = SqlTable(connection_params(), 'iris', type_hints=Domain([], DiscreteVariable( "iris", values=[ 'Iris-setosa', 'Iris-virginica', 'Iris-versicolor' ]))) for batch_size in (50, 500): rpca = RemotePCA(table, batch_size, 10) self.assertEqual(rpca.components_.shape, (4, 4))