Skip to main content

A library to parallelize the execution of a function in python

Project description

This library provides an easy way to parallelize the execution of a function in python using the concurrent.futures library. It allows you to run multiple instances of a function simultaneously, making your code run faster and more efficiently. It also provides a simple API for managing the process, allowing you to cancel or wait for the completion of a task. With this library, you can easily take advantage of the power of parallel processing in python.

Here’s an example of how you can use the library to parallelize the execution of the print function:

`from tfrq import pyrallel_process` `params = ["Hello", "World", "!"]` `func = print` `pyrallel_process(func=func, params=params, num_cores=3)`

This code will call the print function in parallel with the given parameters and use 3 cores, so it will print the given parameters in parallel.

Tfrq is an arabic word meaning “To Split”, which is the purpose of this simple method, to split the work of a single function into multiple processes as easy as possible.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tfrq-2.0.1.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

tfrq-2.0.1-py3-none-any.whl (6.4 kB view details)

Uploaded Python 3

File details

Details for the file tfrq-2.0.1.tar.gz.

File metadata

  • Download URL: tfrq-2.0.1.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for tfrq-2.0.1.tar.gz
Algorithm Hash digest
SHA256 441bd7c13f703a8a69beaa25e02ae34fa35da3211ef6d7dc7a69ce7a3c28b113
MD5 29c155f6ea08a2bd7a37b94afbafac4a
BLAKE2b-256 417166613bd17bb53212e3af4e4a678f07a64adeacbcc5ff123a3d30d228e90f

See more details on using hashes here.

File details

Details for the file tfrq-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: tfrq-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 6.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for tfrq-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2a6b6433e6c6671ba4417ad6fb02e9bc79b3392f55a5b9a88414b6ce97a24f88
MD5 d1a13d96e53b34ce71372d4b84903ed3
BLAKE2b-256 973400af2087c0b6cda8263db452bca81e9022f4900bac452868332027a30648

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page