Skip to content
Snippets Groups Projects
Commit 80772d33 authored by Mikael Henriksson's avatar Mikael Henriksson :runner:
Browse files

resources.py: adjusted bar heights and exclusion graph drawing settings

parent 26575b3e
Branches fpl-2023
No related tags found
No related merge requests found
Pipeline #92558 failed
......@@ -146,6 +146,10 @@ def draw_exclusion_graph_coloring(
node_color=node_color_list,
ax=ax,
pos=nx.spring_layout(exclusion_graph, seed=1),
node_size=150,
font_size=4.4,
width=0.4,
linewidths=0.0,
)
......@@ -489,7 +493,7 @@ class ProcessCollection:
_ax = ax
# Lifetime chart left and right padding
PAD_L, PAD_R = 0.05, 0.05
PAD_L, PAD_R = 0.08, 0.08
max_execution_time = max(process.execution_time for process in self._collection)
if max_execution_time > self._schedule_time:
# Schedule time needs to be greater than or equal to the maximum process
......@@ -527,7 +531,7 @@ class ProcessCollection:
if bar_end >= bar_start:
_ax.broken_barh( # type: ignore
[(PAD_L + bar_start, bar_end - bar_start - PAD_L - PAD_R)],
(bar_row + 0.55, 0.9),
(bar_row + 0.58, 0.84),
color=bar_color,
)
else: # bar_end < bar_start
......@@ -538,11 +542,11 @@ class ProcessCollection:
self._schedule_time - bar_start - PAD_L,
)
],
(bar_row + 0.55, 0.9),
(bar_row + 0.58, 0.84),
color=bar_color,
)
_ax.broken_barh( # type: ignore
[(0, bar_end - PAD_R)], (bar_row + 0.55, 0.9), color=bar_color
[(0, bar_end - PAD_R)], (bar_row + 0.58, 0.84), color=bar_color
)
if show_name:
_ax.annotate( # type: ignore
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment