Examples of rowCount()


Examples of ch.akuhn.matrix.SparseMatrix.rowCount()

  public static void main(String... args) {
    Stopwatch.enter();
    Stopwatch.p();
    SparseMatrix A = Matrix.sparse(4000, 10000);
    Random rand = new Random(1);
    for (int i = 0; i < A.rowCount(); i++) {
      for (int j = 0; j < A.columnCount(); j++) {
        if (rand.nextDouble() > 0.2) continue;
        A.put(i, j, rand.nextDouble() * 23);
      }
    }
 
View Full Code Here

Examples of io.crate.action.sql.SQLResponse.rowCount()

    @Test
    public void testXContentInt() throws Exception {
        SQLResponse r = new SQLResponse();
        r.cols(new String[]{"col1", "col2"});
        r.rows(new Object[][]{new Object[]{1, 2}});
        r.rowCount(1L);
        //System.out.println(json(r));
        JSONAssert.assertEquals(
                "{\"cols\":[\"col1\",\"col2\"],\"rows\":[[1,2]],\"rowcount\":1,\"duration\":-1}",
                json(r), true);
    }
View Full Code Here

Examples of io.crate.executor.TaskResult.rowCount()

        task.start();
        TaskResult taskResult = task.result().get(0).get();
        Object[][] rows = taskResult.rows();
        assertThat(rows.length, is(0));
        assertThat(taskResult.rowCount(), is(-1L));

        // verify deletion
        DocTableInfo characters = docSchemaInfo.getTableInfo("characters");
        QueryThenFetchNode searchNode = new QueryThenFetchNode(
                characters.getRouting(WhereClause.MATCH_ALL),
View Full Code Here

Examples of io.crate.executor.transport.task.elasticsearch.facet.InternalUpdateFacet.rowCount()

        @Override
        public void onResponse(SearchResponse searchResponse) {
            InternalUpdateFacet facet = searchResponse.getFacets().facet(InternalUpdateFacet.class, UpdateFacet.TYPE);
            facet.reduce();
            future.set(new RowCountResult(facet.rowCount()));
        }

        @Override
        public void onFailure(Throwable e) {
            future.setException(e);
View Full Code Here

Examples of mikera.matrixx.AMatrix.rowCount()

    mb.append(new double[] {0,1,0});
    mb.append(Vector.of(0,0).join(Vector.of(1)));
   
    AMatrix m= mb.toMatrix();
   
    assertEquals(3,m.rowCount());
    assertTrue(m.isIdentity());
  }
}
View Full Code Here

Examples of mikera.matrixx.Matrix.rowCount()

    private Matrix createSymmetric(int len, double min, double max, Random rand) {
        Matrix A = Matrix.create(len, len);

        double range = max-min;

        int length = A.rowCount();

        for( int i = 0; i < length; i++ ) {
            for( int j = i; j < length; j++ ) {
                double val = rand.nextDouble()*range + min;
                A.set(i,j,val);
View Full Code Here

Examples of mikera.matrixx.impl.AStridedMatrix.rowCount()

      @SuppressWarnings("unused")
      AStridedMatrix tsm = m.subMatrix(1, 1, 1, 1);
    }

    AStridedMatrix sm = m.subMatrix(1, 2, 1, 2);
    assertEquals(2, sm.rowCount());
    assertEquals(2, sm.columnCount());
    assertTrue(sm.data == m.data);

    assertEquals(
        Matrixx.create(new double[][] { { 5.0, 6.0 }, { 9.0, 10.0 } }),
View Full Code Here

Examples of mikera.matrixx.impl.VectorMatrixM3.rowCount()

public class TestVectorMatrix {

  @Test public void testCreateM3() {
    VectorMatrixM3 m=new VectorMatrixM3(0);
    assertEquals(0,m.rowCount());
    assertEquals(3,m.columnCount());
   
    AMatrix mt=m.getTranspose();
    assertEquals(0,mt.columnCount());
  }
View Full Code Here

Examples of mikera.matrixx.impl.VectorMatrixMN.rowCount()

    // general M*N matrix
    VectorMatrixMN mmn=new VectorMatrixMN(6 ,7);

    // permuted matrix
    PermutedMatrix pmm=new PermutedMatrix(mmn,
        Indexz.createRandomPermutation(mmn.rowCount()),
        Indexz.createRandomPermutation(mmn.columnCount()));
    doGenericTests(pmm);
    doGenericTests(pmm.subMatrix(1, 4, 1, 5));
   
 
View Full Code Here

Examples of net.sf.swtbot.widgets.SWTBotTable.rowCount()

   * @since 1.2
   */
  public List getQuickFixes() throws QuickFixNotFoundException {
    SWTBotShell quickFixShell = activateQuickFixShell();
    SWTBotTable quickFixTable = getQuickFixTable(quickFixShell);
    int rowCount = quickFixTable.rowCount();
    List result = new ArrayList();
    for (int i = 0; i < rowCount; i++)
      result.add(quickFixTable.cell(i, 0));
    return result;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.