A library to synchronize multiple processes in a distributed system.
Project description
Synchronizer
This is a synchronization library used to synchronize multiple processes in distributed systems.
Install
You can install this package with pip using the following command:
pip install multiprocess-synchronizer
Usage
from synchronizer import FileSystemSynchronizer
from multiprocessing import Process
def main(num_processes):
fs_sync = FileSystemSynchronizer('test', rank, world_size)
fs_sync.barrier()
if __name__ == "__main__":
main()
FileSystemSynchronizer
FileSystemSynchronizer(shared_dir, rank, world_size)
Parameters:
- shared_dir: A directory on a shared file system that can be accessed by all processes; this directory must be empty.
- rank: Rank id of the current process
- world_size: Total number of processes.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file multiprocess_synchronizer-0.0.1rc0.tar.gz
.
File metadata
- Download URL: multiprocess_synchronizer-0.0.1rc0.tar.gz
- Upload date:
- Size: 7.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 327cbc0d483a351ad8f776b9f77fe9109a6596be54c63c3b1c34a8ddc28f6be8 |
|
MD5 | 071119058bdafca935670c1bd13acd82 |
|
BLAKE2b-256 | 40a4f86ffe29548aef79a5b7805aea9fdf312ca75038052d6fced8c1687cda81 |
File details
Details for the file multiprocess_synchronizer-0.0.1rc0-py3-none-any.whl
.
File metadata
- Download URL: multiprocess_synchronizer-0.0.1rc0-py3-none-any.whl
- Upload date:
- Size: 8.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ddc8a287604d12ba3e70d3315a2b2cc6c9fcb3b36ddde44a000e36ac18424976 |
|
MD5 | d4b240cd55a3eb7b00a3b25361575c76 |
|
BLAKE2b-256 | ca6d9218dfc54592fcac7a017dd579b143db77f2a9c34e33299d6e5fb79b6c9c |