Skip to main content

Solving scheduling problems with constraint programming.

Project description

PyJobShop logo

PyPI License CI DOC Codecov

PyJobShop is a Python library for solving scheduling problems with constraint programming. It currently supports the following scheduling problems:

  • Resource environments: single machines, parallel machines, hybrid flow shops, open shops, job shops, flexible job shops, distributed shops, renewable resources and consumable resources.
  • Constraints: release dates, deadlines, due dates, multiple modes, permutations, sequence-dependent setup times, no-wait, no-idle, blocking, breaks, optional task selection, and arbitrary precedence constraints.
  • Objective functions: minimizing makespan, total flow time, number of tardy jobs, total tardiness, total earliness, maximum tardiness, and total setup times.

You can find PyJobShop on the Python Package Index under the name pyjobshop. To install it, simply run:

pip install pyjobshop

The documentation is available here.

Constraint programming solvers

PyJobShop uses OR-Tools' CP-SAT solver as its default constraint programming solver. We also provide support for CP Optimizer. See our documentation for instructions on how to install PyJobShop with CP Optimizer.

Examples

We provide example notebooks that show how PyJobShop may be used to solve scheduling problems.

  • A short tutorial and introduction to PyJobShop's modeling interface, available here. This is a great way to get started with PyJobShop.
  • Notebooks solving the classical machine scheduling problems such as the flexible job shop problem (here), the hybrid flow shop (here), and the permutation flow shop (here).
  • A notebook showing how to solve different project scheduling problems, here.
  • A notebook showing how to solve scheduling problems with optional tasks, here.
  • A notebook showing how to solve scheduling problems with resource breaks, here.
  • An overview of supported objective functions, here.

If you are new to scheduling or constraint programming, you might benefit from first reading the introduction to scheduling and introduction to constraint programming pages.

Contributing

We are very grateful for any contributions you are willing to make. Please have a look here to get started. If you aim to make a large change, it is helpful to discuss the change first in a new GitHub issue. Feel free to open one!

Getting help

Feel free to open an issue or a new discussion thread here on GitHub. Please do not e-mail us with questions, modeling issues, or code examples. Those are much easier to discuss via GitHub than over e-mail. When writing your issue or discussion, please follow the instructions here.

How to cite PyJobShop

If you use PyJobShop in your research, please consider citing the following paper:

Lan, L., and Berkhout, J. (2025). PyJobShop: Solving scheduling problems with constraint programming in Python. https://arxiv.org/abs/2502.13483

Or, using the following BibTeX entry:

@misc{Lan_Berkhout_2025,
      title={{PyJobShop}: Solving scheduling problems with constraint programming in {Python}}, 
      author={Leon Lan and Joost Berkhout},
      year={2025},
      url={https://arxiv.org/abs/2502.13483}, 
      archivePrefix="arXiv",
      eprint={2502.13483},
}

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

pyjobshop-0.0.8.tar.gz (42.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyjobshop-0.0.8-py3-none-any.whl (54.6 kB view details)

Uploaded Python 3

File details

Details for the file pyjobshop-0.0.8.tar.gz.

File metadata

  • Download URL: pyjobshop-0.0.8.tar.gz
  • Upload date:
  • Size: 42.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.10

File hashes

Hashes for pyjobshop-0.0.8.tar.gz
Algorithm Hash digest
SHA256 e877faa89bdb7ae77e2919e40922a794c149eba33238460a810529a6940e400c
MD5 97bf3ff0a96f10a7f089476164d65f00
BLAKE2b-256 da1cd732873162da3baa0c546b927d12fe5c5c19d501799c3bdbb61dde7fb053

See more details on using hashes here.

File details

Details for the file pyjobshop-0.0.8-py3-none-any.whl.

File metadata

  • Download URL: pyjobshop-0.0.8-py3-none-any.whl
  • Upload date:
  • Size: 54.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.10

File hashes

Hashes for pyjobshop-0.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 6de8fbb719d5bd06521dbc4d8583170d1f8d4ea9d5f3944c67faf46483e827f4
MD5 4d43c8191299102ae86269bba49dbd34
BLAKE2b-256 763a31453bde9f2149e409e531a60b3ee86d33ebf2234e82c327def1a9687697

See more details on using hashes here.

Supported by

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