ACO now supports operators scheduling rules. Further testing required

parent a74ba7f3
...@@ -8,6 +8,7 @@ import operator ...@@ -8,6 +8,7 @@ import operator
import xmlrpclib import xmlrpclib
from dream.simulation.Queue import Queue from dream.simulation.Queue import Queue
from dream.simulation.Operator import Operator
from dream.simulation.Globals import getClassFromName from dream.simulation.Globals import getClassFromName
class ACO(plugin.ExecutionPlugin): class ACO(plugin.ExecutionPlugin):
...@@ -47,7 +48,7 @@ class ACO(plugin.ExecutionPlugin): ...@@ -47,7 +48,7 @@ class ACO(plugin.ExecutionPlugin):
collated = dict() collated = dict()
for node_id, node in data['graph']['node'].items(): for node_id, node in data['graph']['node'].items():
node_class = getClassFromName(node['_class']) node_class = getClassFromName(node['_class'])
if issubclass(node_class, Queue): if issubclass(node_class, Queue) or issubclass(node_class, Operator):
collated[node_id] = list(node_class.getSupportedSchedulingRules()) collated[node_id] = list(node_class.getSupportedSchedulingRules())
assert collated assert collated
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment