Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
9965ed1
This commit introduces a significant refactoring of how nodes are ide…
bikuta6 Jun 27, 2025
272ffca
Update _plot_resource_task_graph.py
bikuta6 Jun 30, 2025
d361520
Disjunctive graph issue solved
bikuta6 Jul 1, 2025
99a19dd
Update _job_shop_graph.py
bikuta6 Jul 2, 2025
8779b9c
Update _job_shop_graph.py
bikuta6 Jul 2, 2025
fa9c790
Update README.md
bikuta6 Jul 2, 2025
dc5b758
Minor job shop graph update
bikuta6 Jul 2, 2025
d5c9743
adjacency list for jobshopgraph
bikuta6 Jul 7, 2025
425af5d
incoming and outgoing edges lists
bikuta6 Jul 7, 2025
60504d8
progress on jobshopgraph and env
bikuta6 Aug 13, 2025
0636fcf
Merge branch 'main' into v2.0.0
bikuta6 Aug 13, 2025
1697907
edge_index dict method added + style
bikuta6 Aug 14, 2025
4770be0
Fix + method movement
bikuta6 Aug 18, 2025
4e46838
Update _types_and_constants.py
bikuta6 Aug 18, 2025
09d8938
updated plot for new edgetypes
bikuta6 Aug 18, 2025
bf855c7
all test complete, skips made on irrelevant
bikuta6 Aug 20, 2025
12e7623
Refactor observation structure to use nested node features dict
bikuta6 Aug 21, 2025
084f999
Updated available operation tuples on RL environment
bikuta6 Aug 30, 2025
01326a3
Unify node type naming and add action mask to observations
bikuta6 Aug 31, 2025
a7bb799
Updated documentation (not fully))
bikuta6 Sep 1, 2025
172d149
New observation test for single env
bikuta6 Sep 2, 2025
d296a85
Fix node removal mask and enhance operation feature tests
bikuta6 Sep 3, 2025
8d75f9f
Add comprehensive observation integrity test
bikuta6 Sep 4, 2025
1fe59e3
Refactor observation space and improve test debugging
bikuta6 Sep 6, 2025
34483e9
Observation space tests passed
bikuta6 Sep 7, 2025
aba9e18
Deleted observation wrapper and tests
bikuta6 Sep 7, 2025
d7b7c05
Update _single_job_shop_graph_env.py
bikuta6 Sep 7, 2025
8196d22
[Feature] PR #65 and #67: Add simulated annealing (#60)
Pabloo22 Aug 17, 2025
44d5f40
[Docs] Fix typos in docstrings
Pabloo22 Aug 17, 2025
1c68954
[Docs] Update README with links
Pabloo22 Aug 18, 2025
ea1a212
[Chore] Bump version to 1.6.0
Pabloo22 Aug 18, 2025
354d9a5
[Refactor] PR #71: Improve efficiency in `Schedule.critical_path` (#68)
MattJezza02 Aug 22, 2025
0b9b892
[BugFix] ortools set to ">=9.9,<9.13" (#73)
Pabloo22 Aug 22, 2025
8e00e75
[Chore] Bump version to 1.6.1
Pabloo22 Aug 22, 2025
99d0b7c
[Refactor] Rename `durations_matrix` to `duration_matrix` for consist…
Pabloo22 Sep 10, 2025
5055673
[Feature] Add `load_benchmark_group` function to load benchmark insta…
Pabloo22 Sep 10, 2025
c0a9000
[Feature] Add support for generating instances with extra constraints…
Pabloo22 Sep 10, 2025
1109ecd
[Docs] Add tutorial for new generation module and update SA tutorial
Pabloo22 Sep 10, 2025
8c527b6
[Refactor] Use `duration_matrix_array`
Pabloo22 Sep 10, 2025
bc7660b
[BugFix] BREAKING CHANGES: Correct `generate_machine_matrix_with_reci…
Pabloo22 Sep 11, 2025
6e64b01
[BugFix] Adress comments
Pabloo22 Sep 11, 2025
f1c0172
[BugFix] Adress comments
Pabloo22 Sep 11, 2025
eabc8a6
[Feature] Add `RewardWithPenalties` class and penalty functions
Pabloo22 Sep 11, 2025
992ea6c
[Tests] Add tests for RL utils and reward observers
Pabloo22 Sep 12, 2025
d2fa213
[Tests] Add comprehensive tests for objective functions and penalties
Pabloo22 Sep 13, 2025
179723d
[Docs] Fix `RewardWithPenalties` class documentation
Pabloo22 Sep 13, 2025
25b0a55
This commit introduces a significant refactoring of how nodes are ide…
bikuta6 Jun 27, 2025
b363701
Deleted observation wrapper and tests
bikuta6 Sep 7, 2025
7407496
Merge branch 'main' into v2.0.0
Pabloo22 Sep 13, 2025
d41e446
Bump version to 1.7.0 in __init__.py and pyproject.toml
Pabloo22 Sep 13, 2025
bedff6b
This commit introduces a significant refactoring of how nodes are ide…
bikuta6 Jun 27, 2025
0db2b0d
progress on jobshopgraph and env
bikuta6 Aug 13, 2025
f2f9aab
Deleted observation wrapper and tests
bikuta6 Sep 7, 2025
89b770c
[Refactor] Solves small issues
Pabloo22 Sep 24, 2025
eba0196
[Tests] Refactor Resource-Task Graph tests to use a fixture (#79)
Pabloo22 Sep 24, 2025
d84a38d
[Tests] Add tolerance=10 to visualization
Pabloo22 Oct 2, 2025
0d53d26
[Refactor] `JobShopGraph.graph` into `get_networkx_graph()`
Pabloo22 Oct 2, 2025
4cb5ed9
[Tests] Increase tolerance and refactor kwargs into a constant
Pabloo22 Oct 2, 2025
00e2ef3
[Refactor] Adjust handling of removed operation nodes in JobShopGraph
Pabloo22 Oct 2, 2025
8e31b36
[Tests] Fix `test_all_nodes_are_removed`
Pabloo22 Oct 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -257,17 +257,17 @@ disjunctive_graph = build_disjunctive_graph(instance)

>>> disjunctive_graph.nodes_by_type
defaultdict(list,
{<NodeType.OPERATION: 1>: [Node(node_type=OPERATION, value=O(m=0, d=1, j=0, p=0), id=0),
Node(node_type=OPERATION, value=O(m=1, d=1, j=0, p=1), id=1),
Node(node_type=OPERATION, value=O(m=2, d=7, j=0, p=2), id=2),
Node(node_type=OPERATION, value=O(m=1, d=5, j=1, p=0), id=3),
Node(node_type=OPERATION, value=O(m=2, d=1, j=1, p=1), id=4),
Node(node_type=OPERATION, value=O(m=0, d=1, j=1, p=2), id=5),
Node(node_type=OPERATION, value=O(m=2, d=1, j=2, p=0), id=6),
Node(node_type=OPERATION, value=O(m=0, d=3, j=2, p=1), id=7),
Node(node_type=OPERATION, value=O(m=1, d=2, j=2, p=2), id=8)],
<NodeType.SOURCE: 5>: [Node(node_type=SOURCE, value=None, id=9)],
<NodeType.SINK: 6>: [Node(node_type=SINK, value=None, id=10)]})
{<NodeType.OPERATION: 1>: [Node(node_type=OPERATION, value=O(m=0, d=1, j=0, p=0), id=("OPERATION", 0)),
Node(node_type=OPERATION, value=O(m=1, d=1, j=0, p=1), id=("OPERATION", 1)),
Node(node_type=OPERATION, value=O(m=2, d=7, j=0, p=2), id=("OPERATION", 2)),
Node(node_type=OPERATION, value=O(m=1, d=5, j=1, p=0), id=("OPERATION", 3)),
Node(node_type=OPERATION, value=O(m=2, d=1, j=1, p=1), id=("OPERATION", 4)),
Node(node_type=OPERATION, value=O(m=0, d=1, j=1, p=2), id=("OPERATION", 5)),
Node(node_type=OPERATION, value=O(m=2, d=1, j=2, p=0), id=("OPERATION", 6)),
Node(node_type=OPERATION, value=O(m=0, d=3, j=2, p=1), id=("OPERATION", 7)),
Node(node_type=OPERATION, value=O(m=1, d=2, j=2, p=2), id=("OPERATION", 8))],
<NodeType.SOURCE: 5>: [Node(node_type=SOURCE, value=None, id=('SOURCE', 0))],
<NodeType.SINK: 6>: [Node(node_type=SINK, value=None, id=('SINK', 0))]})
```

Other attributes include:
Expand Down
1 change: 1 addition & 0 deletions docs/source/examples/05-Load-Benchmark-Instances.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@
],
"source": [
"import numpy as np\n",
"\n",
"np.array(ft06.durations_matrix)"
]
},
Expand Down
8 changes: 4 additions & 4 deletions docs/source/examples/09-SingleJobShopGraphEnv.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,7 @@
" feature_observer_configs=feature_observer_configs,\n",
" reward_function_config=DispatcherObserverConfig(IdleTimeReward),\n",
" render_mode=\"human\", # Try \"save_video\"\n",
" render_config={\n",
" \"video_config\": {\"fps\": 4}\n",
" }\n",
" render_config={\"video_config\": {\"fps\": 4}},\n",
")"
]
},
Expand Down Expand Up @@ -252,7 +250,9 @@
"import numpy as np\n",
"\n",
"rewards = np.array(env.reward_function.rewards)\n",
"print(f\"{len(list(filter(lambda x: x != 0, rewards)))} zeros out of {len(rewards)}\")"
"print(\n",
" f\"{len(list(filter(lambda x: x != 0, rewards)))} zeros out of {len(rewards)}\"\n",
")"
]
},
{
Expand Down
12 changes: 10 additions & 2 deletions docs/source/examples/12-ReadyOperationsFilter.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,13 @@
" df = print_makespans_for_optimizations(ta01, pdr)\n",
" print()\n",
" # Chamge the number of xticks to 10\n",
" df.sort_values(by=\"Makespan\", ascending=False).plot.barh(x=\"Filter Combination\", y=\"Makespan\", title=pdr.name, xlim=(1500, 2000), xticks=range(1500, 2001, 50))\n",
" df.sort_values(by=\"Makespan\", ascending=False).plot.barh(\n",
" x=\"Filter Combination\",\n",
" y=\"Makespan\",\n",
" title=pdr.name,\n",
" xlim=(1500, 2000),\n",
" xticks=range(1500, 2001, 50),\n",
" )\n",
" dfs.append(df)"
]
},
Expand Down Expand Up @@ -408,7 +414,9 @@
"source": [
"df_combined = pd.concat(dfs, keys=[pdr.name for pdr in DispatchingRuleType])\n",
"\n",
"df_combined.groupby(\"Filter Combination\").agg(\"mean\").sort_values(by=\"Makespan\", ascending=False).plot.barh(title=\"Average Makespan\")"
"df_combined.groupby(\"Filter Combination\").agg(\"mean\").sort_values(\n",
" by=\"Makespan\", ascending=False\n",
").plot.barh(title=\"Average Makespan\")"
]
},
{
Expand Down
Binary file added job_shop_lib/.DS_Store
Binary file not shown.
2 changes: 1 addition & 1 deletion job_shop_lib/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from job_shop_lib._base_solver import BaseSolver, Solver


__version__ = "1.6.1"
__version__ = "1.7.0"

__all__ = [
"Operation",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,7 @@ def update(self, scheduled_operation: ScheduledOperation):
elapsed_time = current_time - self._previous_current_time
self._previous_current_time = current_time
cols = [
self._attribute_map[attr]
for attr in self.attributes_to_observe
self._attribute_map[attr] for attr in self.attributes_to_observe
]
self.features[FeatureType.OPERATIONS][:, cols] -= elapsed_time

Expand Down
8 changes: 6 additions & 2 deletions job_shop_lib/graphs/_build_disjunctive_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,12 @@ def build_solved_disjunctive_graph(schedule: Schedule) -> JobShopGraph:
break
next_scheduled_operation = machine_schedule[i + 1]
graph.add_edge(
scheduled_operation.operation.operation_id,
next_scheduled_operation.operation.operation_id,
graph.get_operation_node(
scheduled_operation.operation.operation_id
),
graph.get_operation_node(
next_scheduled_operation.operation.operation_id
),
type=EdgeType.DISJUNCTIVE,
)

Expand Down
Loading