Skip to main content

Threading and Multiprocessing for every project.

Project description

lox

https://img.shields.io/pypi/v/lox.svg https://img.shields.io/travis/BrianPugh/lox.svg Documentation Status Updates

Threading made easy.

Installation

pip install git+https://github.com/BrianPugh/lox#egg=lox

Features

  • Powerful, intuitive multithreading in just 2 additional lines of code

  • Advanced thread synchronization, communication, and resource management tools

Examples

Easy Multithreading

>>> import lox
>>> @lox.pool(3) # Maximum of 3 concurrent threads
>>> def multiply(a,b):
>>>    return a*b
>>> multiply(3,4) # Function works as normal
12
>>> xs = [1,2,3,4,5,]
>>> ys = [6,7,7,8,9,]
>>> [multiply.scatter(x,y) for x,y in zip(xs,ys)]
>>> multiply.gather()
[ 6, 14, 21, 32, 45 ]

Contributing

Install the library in editable mode:

pip3 install -e .

All new features must have unit tests.

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

History

0.2.0 (2019-05-24)

  • Added QLock

  • Documentation syntax fixes

0.1.1 (2019-05-24)

  • CICD test

0.1.0 (2019-05-24)

  • First release on PyPI.

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

lox-0.2.0.tar.gz (12.1 kB view details)

Uploaded Source

Built Distribution

lox-0.2.0-py2.py3-none-any.whl (3.6 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file lox-0.2.0.tar.gz.

File metadata

  • Download URL: lox-0.2.0.tar.gz
  • Upload date:
  • Size: 12.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.3

File hashes

Hashes for lox-0.2.0.tar.gz
Algorithm Hash digest
SHA256 08c7b053364c3fd0e156a11b2a72436c5316e276eaf6753dacc88211ea8406d8
MD5 548fdc272ca139f1abaeb846109614f3
BLAKE2b-256 e47f62876f466b7e60e582a01aaac42bf445289e70bd27fa84e076b27e4a27c4

See more details on using hashes here.

File details

Details for the file lox-0.2.0-py2.py3-none-any.whl.

File metadata

  • Download URL: lox-0.2.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.3

File hashes

Hashes for lox-0.2.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 c221625031c1b9bf6d2e5b9970a9f0361e61cc685321ad730f438dcc280c9dcc
MD5 6752040731102b82c5f62a09e62e5782
BLAKE2b-256 14d4b124fe7030fa4af42abd18882a9c77732f0b814f046f7eab3e640301bb00

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