Skip to main content

GA Scheduler

Overview

GA Scheduler is a Python library for modeling, optimizing, and visualizing machine scheduling problems using genetic algorithms and multiobjective evolutionary optimization. It supports a broad range of scheduling environments, including single-machine, parallel-machine, flow shop, flexible flow shop / hybrid flow shop, job shop, flexible job shop, and alternative-machine routing problems. The library can optimize several performance criteria, including makespan, weighted tardiness, sequence-dependent setup time, sequence-dependent setup waste, total completion time, and number of late jobs. It also provides interactive Gantt chart visualizations to help users inspect, interpret, and communicate scheduling solutions.

Citation

Yigit F.; Basilio M.P; Pereira V. (2024). A Hybrid Approach for the Multi-Criteria-Based Optimization of Sequence-Dependent Setup-Based Flow Shop Scheduling. Mathematics. 12(13):2007. doi: https://doi.org/10.3390/math12132007

Features

  • Scheduling Machine Environments: Supports single-machine, parallel-machine, flow shop, flexible flow shop / hybrid flow shop, job shop, flexible job shop, and alternative-machine routing problems.
  • Many-Objective / Multi-Objective Optimization: Supports optimization for multiple objectives including makespan, weighted tardiness, sequence-dependent setup time, sequence-dependent setup waste, total completion time, and number of late jobs.
  • Genetic Algorithm Integration: Utilizes a Genetic Algorithm (GA) to efficiently explore the solution space and find optimal or near-optimal job sequences.
  • Brute Force Search: For small problem instances, brute force search can be used to find the optimal job sequence. It is intentionally disabled for flexible sequences because the search space combines operation-dispatch permutations and machine-choice combinations.
  • Customizability: Allows customization of job sequences, machine alternatives, setup times, setup waste, due dates, job weights, objective weights, and other scheduling parameters.
  • Sequence-Dependent Job Setup Times: Supports setup times between jobs through a setup_time_matrix, where the setup time depends on the previously processed job and the next job.
  • Sequence-Dependent Setup Waste: Supports setup waste between jobs through a setup_waste_matrix, allowing the model to penalize material loss, cleaning waste, scrap, or other changeover-related waste.
  • Machine-to-Machine Setup Times: Supports setup or transfer times between machines through a machine_setup_time_matrix. This is useful when moving a job from one machine to another requires transportation, preparation, tooling change, calibration, cleaning, or other machine-transition activities.
  • Machine Blocking Constraints: Supports machine blocking groups through machine_block_groups. Machines in the same blocking group cannot operate simultaneously. This is useful for modeling shared operators, shared tools, shared cranes, shared physical space, shared power sources, or other shared resources.
  • Machine Maintenance Constraints: Supports predefined machine maintenance requirements through machine_maintenance. Maintenance activities can be assigned to specific machines with an earliest start time, duration, and optional label.
  • Flexible Maintenance Scheduling: Maintenance does not need to start exactly at its earliest time. The scheduler can delay maintenance to the next feasible time if the machine is busy, as long as the maintenance requirement is respected.
  • Conditional Maintenance Visibility: If a maintenance activity is only required after a certain time and the final schedule finishes before that point, the maintenance may be omitted from the Gantt chart while still being reported in the maintenance summary.
  • Alternative Machine Routing: Each operation can have multiple possible machines with different processing times, allowing the GA to optimize both the job sequence and the machine choices.
  • Continuous Processing and Setup Times: Processing times, setup times, due dates, machine setup times, and maintenance durations may be decimal values such as 2.1 or 2.05; exact continuous-time events are available through get_schedule_events().
  • Custom Sequence Evaluation: Allows the user to provide a custom job sequence instead of relying only on the GA-generated sequence. This is useful for testing, benchmarking, validating heuristics, or comparing human-designed schedules.
  • Objective Weighting: Allows the user to assign different weights to each objective, making it possible to emphasize makespan, tardiness, setup time, waste, completion time, or late jobs according to the decision-maker's priorities.
  • Pareto Front Generation: When enabled, the scheduler can return a set of non-dominated solutions instead of a single weighted solution, supporting trade-off analysis among conflicting objectives.
  • Visualization: Generates Gantt charts to visualize the scheduling of jobs, setup times, machine-to-machine setups, maintenance periods, and machine usage across the planning horizon.

Usage

  1. Install
pip install ga_scheduler
  1. Try it in Colab:

a) Multiobjective - Weighted

  • Parallel Machines Scheduling - Brute Force ( Colab Demo )
  • Parallel Machines Scheduling - Genetic Algorithm ( Colab Demo )
  • Flow Shop Machines Scheduling - Brute Force ( Colab Demo )
  • Flow Shop Machines Scheduling - Genetic Algorithm ( Colab Demo )
  • Job Shop Machines Scheduling - Brute Force ( Colab Demo )
  • Job Shop Machines Scheduling - Genetic Algorithm ( Colab Demo )

b) Multiobjective - Pareto Front

c) Flexible Sequences (GA = Enabled; NSGA3 = Enabled; Brute Force = Disabled)

d) Machine Setup Time, Machine Block Groups, Machine Maintenance

  • Machine Setup Time, Block Groups & Maintenance - ( Colab Demo )

Metadata

Release files for ga-scheduler 2.8.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ga-scheduler 2.8.5
File Size Uploaded
ga_scheduler-2.8.5.tar.gz 31.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ga-scheduler 2.8.5
File Interpreter ABI Platform
ga_scheduler-2.8.5-py3-none-any.whl Python 3 none any Details

Total release size: 61.1 kB

Release files / ga_scheduler-2.8.5.tar.gz

Download URL ga_scheduler-2.8.5.tar.gz
Size 31.0 kB
Tags Source
SHA-256 checksum
How to use checksums
32ec58a038eb4804a84d8afe8f004dd185fa1f52acbd7ef2e391a6574c890b9a
BLAKE2b-256 checksum
How to use checksums
fd5a339106e0c75700d1ee7f97f1c92e5f2aa85315a8420f25dd554ef769e345
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Release files / ga_scheduler-2.8.5-py3-none-any.whl

Download URL ga_scheduler-2.8.5-py3-none-any.whl
Size 30.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e5a65a6d7aa5072d4b4ba3593c9d31dfc0ac4afc7427cd4298b724b6131c702e
BLAKE2b-256 checksum
How to use checksums
a5f10cac749a948e2fa612078d8e8d90466697f0a3444b053be8fcd8bc9c1e59
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Release history Release notifications | RSS feed

This release

2.8.5 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page