Metadata-Version: 2.1
Name: parq
Version: 0.3.0
Summary: A multi-process job queue
Author-email: Rob Moss <rgmoss@unimelb.edu.au>
Maintainer-email: Rob Moss <rgmoss@unimelb.edu.au>
License: Copyright (c) 2016-2023, Rob Moss
        All rights reserved.
        
        Redistribution and use in source and binary forms, with or without
        modification, are permitted provided that the following conditions are met:
        
        1. Redistributions of source code must retain the above copyright notice, this
           list of conditions and the following disclaimer.
        
        2. Redistributions in binary form must reproduce the above copyright notice,
           this list of conditions and the following disclaimer in the documentation
           and/or other materials provided with the distribution.
        
        3. Neither the name of the copyright holder nor the names of its contributors
           may be used to endorse or promote products derived from this software
           without specific prior written permission.
        
        THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
        AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
        IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
        DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
        FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
        DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
        SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
        CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
        OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
        OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        
Project-URL: homepage, https://bitbucket.org/robmoss/job-queue/
Project-URL: repository, https://bitbucket.org/robmoss/job-queue/
Project-URL: documentation, https://parq.readthedocs.io/en/latest/
Project-URL: changelog, https://parq.readthedocs.io/en/latest/changelog.html
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Scientific/Engineering :: Mathematics
Requires-Python: >=3.8
Description-Content-Type: text/x-rst
License-File: LICENSE
Provides-Extra: tests
Requires-Dist: pytest ; extra == 'tests'
Requires-Dist: pytest-cov (~=4.0) ; extra == 'tests'

A multi-process job queue
=========================

|version| |docs| |tests| |coverage|

Description
-----------

This package implements a queue that distributes jobs over multiple processes.

License
-------

The code is distributed under the terms of the `BSD 3-Clause license <https://opensource.org/licenses/BSD-3-Clause>`_ (see
``LICENSE``), and the documentation is distributed under the terms of the
`Creative Commons BY-SA 4.0 license
<http://creativecommons.org/licenses/by-sa/4.0/>`_.

Usage
-----

.. code-block:: python

   import parq

   # Define a job that prints its input argument.
   def my_job(n):
       print(f'Running job #{n}')

   # Define the input argument for each job.
   job_inputs = [(i,) for i in range(10)]

   # Run these 10 jobs using 4 processes.
   success = parq.run(my_job, job_inputs, n_proc=4)
   assert success

See the `online documentation <https://parq.readthedocs.io/en/latest/>`_ for further details.

Installation
------------

To install the latest release::

    pip install parq

To install the latest development version, clone this repository and run::

    pip install .

.. |version| image:: https://badge.fury.io/py/parq.svg
   :alt: Latest version
   :target: https://pypi.org/project/parq/

.. |docs| image::  https://readthedocs.org/projects/parq/badge/
   :alt: Documentation
   :target: https://parq.readthedocs.io/

.. |tests| image:: https://gitlab.unimelb.edu.au/rgmoss/job-queue/badges/master/pipeline.svg
   :alt: Test cases
   :target: https://gitlab.unimelb.edu.au/rgmoss/job-queue

.. |coverage| image:: https://gitlab.unimelb.edu.au/rgmoss/job-queue/badges/master/coverage.svg
   :alt: Test coverage
   :target: https://gitlab.unimelb.edu.au/rgmoss/job-queue
