Package edu.cmu.graphchi.queries

Examples of edu.cmu.graphchi.queries.VertexQuery$Shard


        // Each thread need to have a local query service so the file descriptors don't clash.
        final ThreadLocal<VertexQuery> queryService = new ThreadLocal<VertexQuery>() {
            @Override
            protected VertexQuery initialValue() {
                try {
                    return new VertexQuery(baseFilename, numShards);
                } catch (IOException ioe) {
                    ioe.printStackTrace();
                    throw new RuntimeException(ioe);
                }
            }
View Full Code Here


    public static void main(String[] args) throws  Exception {
        String graphName = args[0];
        int nShards = Integer.parseInt(args[1]);

        CircleOfTrustSalsa csalsa = new CircleOfTrustSalsa(new VertexQuery(graphName, nShards), 10000);

        VertexIdTranslate vertexTrans = VertexIdTranslate.fromFile(new File(ChiFilenames.getVertexTranslateDefFile(graphName, nShards)));

        BufferedReader cmdIn = new BufferedReader(new InputStreamReader(System.in));
        while(true) {
View Full Code Here

     * @param numShards number of shards
     * @param weightByPagerank whether to weight sampling by pagerank
     * @throws IOException
     */
    public FriendsOfFriends(String baseFilename, int numShards, boolean weightByPagerank) throws IOException {
        this.queryEngine = new VertexQuery(baseFilename, numShards);
        this.baseFilename = baseFilename;
        this.weightByPagerank = weightByPagerank;
        this.numShards = numShards;
        this.translator = VertexIdTranslate.fromFile(new File(ChiFilenames.getVertexTranslateDefFile(baseFilename, numShards)));

View Full Code Here

TOP

Related Classes of edu.cmu.graphchi.queries.VertexQuery$Shard

Copyright © 2018 www.massapicom. 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.