Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

A Graph library written in Rust for implementing your own algorithms in a Pregel fashion

License

NotificationsYou must be signed in to change notification settings

weso/pregel-rs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

86 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CIcodecovlatest_versiondocumentation

pregel-rs is a Graph processing library written in Rust that featuresa Pregel-based Framework for implementing your own algorithms in amessage-passing fashion. It is designed to be efficient and scalable,making it suitable for processing large-scale graphs.

Features

  • Pregel-based framework:pregel-rs is a powerful graph processing modelthat allows users to implement graph algorithms in a message-passing fashion,where computation is performed on vertices and messages are passed along edges.pregel-rs provides a framework that makes it easy to implement graphalgorithms using this model.

  • Rust-based implementation:pregel-rs is implemented in Rust, a systemsprogramming language known for its safety, concurrency, and performance.Rust's strong type system and memory safety features help ensure thatpregel-rsis robust and reliable.

  • Efficient and scalable:pregel-rs designed to be efficient and scalable,making it suitable for processing large-scale graphs. It uses parallelism andoptimization techniques to minimize computation and communication overhead,allowing it to handle graphs with millions or even billions of vertices and edges.For us to achieve this, we have built it on top ofpolarsa blazingly fast DataFrames library implemented in Rust using Apache ArrowColumnar Format as the memory model.

  • Graph abstraction:pregel-rs provides a graph abstraction that makesit easy to represent and manipulate graphs in Rust. It supports both directed andundirected graphs, and provides methods for adding, removing, and querying verticesand edges.

  • Customizable computation:pregel-rs allows users to implement their owncomputation logic by defining vertex computation functions. This gives users theflexibility to implement their own graph algorithms and customize the behaviorofpregel-rs to suit their specific needs.

Getting started

To get started withpregel-rs, you can follow these steps:

  1. Install Rust:pregel-rs requires Rust to be installed on your system.You can install Rust by following the instructions on the official Rust website:https://www.rust-lang.org/tools/install

  2. Create a new Rust project: Once Rust is installed, you can create a new Rustproject using the Cargo package manager, which is included with Rust. You cancreate a new project by running the following command in your terminal:

cargo new my_pregel_project
  1. Addpregel-rs as a dependency: Next, you need to addpregel-rs as adependency in yourCargo.toml file, which is located in the root directoryof your project. You can add the following line to yourCargo.toml file:
[dependencies]pregel-rs ="0.0.13"
  1. Implement your graph algorithm: Now you can start implementing your graphalgorithm using thepregel-rs framework. You can define your vertex computationfunctions and use the graph abstraction provided bypregel-rs to manipulate the graph.

  2. Build and run your project: Once you have implemented your graph algorithm, youcan build and run your project using the Cargo package manager. You can build yourproject by running the following command in your terminal:

You could also run one of the examples to check how this library works:

cargo buildcargo run --example pagerank

Acknowledgments

ReadPregel: A System for Large-Scale Graph Processingfor a reference on how to implement your own Graph processing algorithms in a Pregel fashion. If you want to take someinspiration from some curated-sources, just explore the/examplesfolder of this repository.

Related projects

  1. GraphX is a library enabling Graph processing in the context ofApache Spark.
  2. GraphFrames is the DataFrame-based equivalent to GraphX.

License

Copyright © 2023 Ángel Iglesias Préstamo (angel.iglesias.prestamo@gmail.com)

This program is free software: you can redistribute it and/or modifyit under the terms of the GNU General Public License as published bythe Free Software Foundation, either version 3 of the License, or(at your option) any later version.

This program is distributed in the hope that it will be useful,but WITHOUT ANY WARRANTY; without even the implied warranty ofMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See theGNU General Public License for more details.

You should have received a copy of the GNU General Public Licensealong with this program. If not, seehttps://www.gnu.org/licenses/.

By contributing to this project, you agree to release yourcontributions under the same license.

About

A Graph library written in Rust for implementing your own algorithms in a Pregel fashion

Topics

Resources

License

Stars

Watchers

Forks

Languages


[8]ページ先頭

©2009-2025 Movatter.jp