order_visualization #5
@ -52,6 +52,7 @@ class GameModel(Model):
|
|||||||
self.client_delivery: PatchAgent = None
|
self.client_delivery: PatchAgent = None
|
||||||
self.drop_off: PatchAgent = None
|
self.drop_off: PatchAgent = None
|
||||||
self.graph = graph
|
self.graph = graph
|
||||||
|
self.cut_orders : List[Order] = []
|
||||||
|
|
||||||
self.game_constants = GameConstants(
|
self.game_constants = GameConstants(
|
||||||
width,
|
width,
|
||||||
|
@ -84,4 +84,6 @@ class InitialStateFactory:
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def __generate_item() -> Item:
|
def __generate_item() -> Item:
|
||||||
randomly_picked_type = random.choice(list(ItemType))
|
randomly_picked_type = random.choice(list(ItemType))
|
||||||
return Item(randomly_picked_type, PathByEnum.get_random_path(randomly_picked_type))
|
item = Item(randomly_picked_type, PathByEnum.get_random_path(randomly_picked_type))
|
||||||
|
item.guessed_type = item.real_type
|
||||||
|
return item
|
||||||
|
4
main.py
4
main.py
@ -112,11 +112,13 @@ if __name__ == '__main__':
|
|||||||
current_item = DisplayAttributeElement("current_item")
|
current_item = DisplayAttributeElement("current_item")
|
||||||
ordersText = DisplayOrderList("orderList")
|
ordersText = DisplayOrderList("orderList")
|
||||||
fulfilled_orders = DisplayOrderList("fulfilled_orders")
|
fulfilled_orders = DisplayOrderList("fulfilled_orders")
|
||||||
|
cut_orders = DisplayOrderList("cut_orders") # MTR!
|
||||||
|
|
||||||
model = keras.models.load_model("imageClasification/my_model")
|
model = keras.models.load_model("imageClasification/my_model")
|
||||||
|
|
||||||
server = ModularServer(GameModel,
|
server = ModularServer(GameModel,
|
||||||
[grid, readyText, current_item, current_order, fulfilled_orders, ordersText],
|
[grid, readyText, current_item, current_order, fulfilled_orders, ordersText, provided_itesm,
|
||||||
|
recognised_items, cut_orders],
|
||||||
"Automatyczny Wózek Widłowy",
|
"Automatyczny Wózek Widłowy",
|
||||||
dict(width=gridHeight, height=gridWidth, graph=diagram, items=60, orders=20,
|
dict(width=gridHeight, height=gridWidth, graph=diagram, items=60, orders=20,
|
||||||
classificator=model, item_display_pos=display_items))
|
classificator=model, item_display_pos=display_items))
|
||||||
|
Loading…
Reference in New Issue
Block a user