Package java.io

Examples of java.io.DataOutputStream.writeDouble()


        for (String word : words) {
            dos.writeUTF(word);
        Vector v = sspace.getVector(word);
        for (int i = 0; i < v.length(); ++i) {
            dos.writeDouble(v.getValue(i).doubleValue());
            }
        }
        dos.close();
    }
View Full Code Here


                    SparseDoubleVector sdv = (SparseDoubleVector)vector;
                    int[] nz = sdv.getNonZeroIndices();
                    dos.writeInt(nz.length);
                    for (int i : nz) {
                        dos.writeInt(i);
                        dos.writeDouble(sdv.get(i));
                    }
                }
                else {
                    SparseVector sv = (SparseVector)vector;
                    int[] nz = sv.getNonZeroIndices();
View Full Code Here

                    SparseVector sv = (SparseVector)vector;
                    int[] nz = sv.getNonZeroIndices();
                    dos.writeInt(nz.length);
                    for (int i : nz) {
                        dos.writeInt(i);
                        dos.writeDouble(sv.getValue(i).doubleValue());
                    }
                }
            }
            else {
                // count how many are non-zero
View Full Code Here

                dos.writeInt(nonZero);
                for (int i = 0; i < vector.length(); ++i) {
                    double d = vector.getValue(i).doubleValue();
                    if (d != 0d) {
                        dos.writeInt(i);
                        dos.writeDouble(d);
                    }
                }
            }
        }
        dos.close();
View Full Code Here

        dos.writeInt(d1);
        dos.writeInt(d2);
        dos.writeInt(d3);
        dos.writeInt(B);
        dos.writeInt(basisType);
        dos.writeDouble(beta);
        dos.writeDouble(normBound);
        dos.writeDouble(keyNormBound);
        dos.writeInt(signFailTolerance);
        dos.writeBoolean(primeCheck);
        dos.writeBoolean(sparse);
View Full Code Here

        dos.writeInt(d2);
        dos.writeInt(d3);
        dos.writeInt(B);
        dos.writeInt(basisType);
        dos.writeDouble(beta);
        dos.writeDouble(normBound);
        dos.writeDouble(keyNormBound);
        dos.writeInt(signFailTolerance);
        dos.writeBoolean(primeCheck);
        dos.writeBoolean(sparse);
        dos.writeInt(bitsF);
View Full Code Here

        dos.writeInt(d3);
        dos.writeInt(B);
        dos.writeInt(basisType);
        dos.writeDouble(beta);
        dos.writeDouble(normBound);
        dos.writeDouble(keyNormBound);
        dos.writeInt(signFailTolerance);
        dos.writeBoolean(primeCheck);
        dos.writeBoolean(sparse);
        dos.writeInt(bitsF);
        dos.write(keyGenAlg);
View Full Code Here

    ByteArrayOutputStream bs = new ByteArrayOutputStream();
    DataOutputStream ds = new DataOutputStream(bs);

    ds.writeInt(m_rootID);
    ds.writeInt(m_treeVariant);
    ds.writeDouble(m_fillFactor);
    ds.writeInt(m_indexCapacity);
    ds.writeInt(m_leafCapacity);
    ds.writeInt(m_nearMinimumOverlapFactor);
    ds.writeDouble(m_splitDistributionFactor);
    ds.writeDouble(m_reinsertFactor);
View Full Code Here

    ds.writeInt(m_treeVariant);
    ds.writeDouble(m_fillFactor);
    ds.writeInt(m_indexCapacity);
    ds.writeInt(m_leafCapacity);
    ds.writeInt(m_nearMinimumOverlapFactor);
    ds.writeDouble(m_splitDistributionFactor);
    ds.writeDouble(m_reinsertFactor);
    ds.writeInt(m_dimension);
    ds.writeLong(m_stats.m_nodes);
    ds.writeLong(m_stats.m_data);
    ds.writeInt(m_stats.m_treeHeight);
View Full Code Here

    ds.writeDouble(m_fillFactor);
    ds.writeInt(m_indexCapacity);
    ds.writeInt(m_leafCapacity);
    ds.writeInt(m_nearMinimumOverlapFactor);
    ds.writeDouble(m_splitDistributionFactor);
    ds.writeDouble(m_reinsertFactor);
    ds.writeInt(m_dimension);
    ds.writeLong(m_stats.m_nodes);
    ds.writeLong(m_stats.m_data);
    ds.writeInt(m_stats.m_treeHeight);
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.