KULeuven-MICAS / stream

Multi-core HW accelerator mapping optimization framework for layer-fused ML workloads.
https://kuleuven-micas.github.io/stream/
MIT License
33 stars 17 forks source link

errors when run : python main_stream.py #31

Closed leaf82318 closed 2 months ago

leaf82318 commented 2 months ago

When running the Python script main_stream.py, an error occurs; awaiting a response. tks!

env is as below:

  1. ubuntu 20.04 and 18.04
  2. python 3.11 and python 3.12

error is as below: Traceback (most recent call last):

File "/home/xx/arch_test/stream/mainstream.py", line 94, in scme, = mainstage.run() ^^^^^^^^^^^^^^^ File "/home/xx/anaconda3/envs/stream/lib/python3.11/site-packages/zigzag/stages/MainStage.py", line 17, in run for cme, extra_info in self.list_of_callables[0](self.list_of_callables[1:], **self.kwargs).run(): File "/home/xx/arch_test/stream/stream/classes/stages/AcceleratorParserStage.py", line 26, in run for cme, extra_info in sub_stage.run(): File "/home/xx/arch_test/stream/stream/classes/stages/ModelParserStage.py", line 43, in run for cme, extra_info in sub_stage.run(): File "/home/xx/arch_test/stream/stream/classes/stages/GenerateCNWorkloadHybridStage.py", line 131, in run for cme, extra_info in sub_stage.run(): File "/home/xx/arch_test/stream/stream/classes/stages/IntraCoreMappingStage.py", line 170, in run for cme, extra_info in sub_stage.run(): File "/home/xx/arch_test/stream/stream/classes/stages/DetermineSchedulingOrderStage.py", line 40, in run for cme, extra_info in sub_stage.run(): File "/home/xx/arch_test/stream/stream/classes/stages/InterCoreMappingStage.py", line 151, in run pop, hof = self.genetic_algorithm.run() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/xx/arch_test/stream/stream/classes/opt/allocation/genetic_algorithm/genetic_algorithm.py", line 125, in run logbook = algorithms.eaMuPlusLambda( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/xx/anaconda3/envs/stream/lib/python3.11/site-packages/deap/algorithms.py", line 302, in eaMuPlusLambda for ind, fit in zip(invalid_ind, fitnesses): File "/home/xx/arch_test/stream/stream/classes/opt/allocation/genetic_algorithm/fitness_evaluator.py", line 63, in get_fitness scme.run() File "/home/xx/arch_test/stream/stream/classes/cost_model/cost_model.py", line 51, in run results = schedule_graph( ^^^^^^^^^^^^^^^ File "/home/xx/arch_test/stream/stream/classes/cost_model/scheduler.py", line 287, in schedule_graph best_candidate, preds_end = get_best_candidate(candidates, scheduling_order) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/xx/arch_test/stream/stream/classes/cost_model/scheduler.py", line 84, in get_best_candidate idxs = [scheduling_order.index((n.id, n.sub_id)) for n in cn_candidates] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/xx/arch_test/stream/stream/classes/cost_model/scheduler.py", line 84, in idxs = [scheduling_order.index((n.id, n.sub_id)) for n in cn_candidates] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ValueError: (0, 0) is not in list

asyms commented 2 months ago

Thanks for bringing this to our attention. This has been fixed.