Skip to main content

Ant colony scheduling optimisation package

Project description

Dynamic Job Shop Scheduling with Ant Colony Optimisation

This repository implements a Min–Max Ant System (MMAS) solver for the Dynamic Job Shop Scheduling Problem (DJSSP).
It is designed to model real-world scheduling environments (e.g. hospitals, manufacturing plants) where:

  • Jobs arrive dynamically over time.
  • Some operations are already underway and cannot be rescheduled.
  • Schedules must balance makespan minimisation with disruption minimisation.

Prerequisites

  • Python 3.13+
  • NumPy
  • Matplotlib (for plotting)
  • pytest (for testing)

Installation

uv pip install aco-djssp

Alternatively, cloning the repo and then running

uv run tests/test_sim.py

should also work and create a local .venv/, a python virtual environment with the package installed.

Running an example

There are several ways of running the package. The most common method will be the one found in tests/test_sim.py. Note that this assumes that some benchmarked static JSSP are downloaded. The ones used for testing can be found here. This test will run a simulation with a dynamic job arrival, and then save the resulting schedule in /tmp/. If using Windows, this path will need to be changed. A more involved and complicated example can be found in tests/test_hospital.py. The way this example works is a little unusual due to plotting requirements, and I would recommend following the approach set out in test_sim.py, but it is a good showcase of what can be done. Feel free to hack away at the code if the desired functionality is not present!

Testing

Tests can be found in tests/ and can be run with

uv run pytest

or can be manually selected by specifying the file name after uv run pytest.

License

This project is licensed under the MIT license. See LICENSE.MD for details.

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

aco_djssp-0.1.0.tar.gz (869.0 kB view details)

Uploaded Source

File details

Details for the file aco_djssp-0.1.0.tar.gz.

File metadata

  • Download URL: aco_djssp-0.1.0.tar.gz
  • Upload date:
  • Size: 869.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for aco_djssp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d210107510d4732ca227f7cb127326db596c1b25ed81b7d236509574211a9424
MD5 ad8fe83817ea1df83993ee88f7533b7b
BLAKE2b-256 a3c734a11c3beebc574cf039b50e50a8c20936956f10a0c7abb24588bb5d22b0

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