<commit_before>from itertools import chain
from math import ceil
from typing import Dict, Tuple

from hwtHls.clk_math import start_clk
from hwtHls.hlsPipeline import HlsPipeline
from hwtHls.netlist.nodes.ops import HlsConst, AbstractHlsOp
from hwtHls.scheduler.asap import asap


# from hwtHls.scheduler.alap import alap
class HlsScheduler():

    def __init__(self, parentHls: HlsPipeline):
        self.parentHls = parentHls

    def apply_scheduelization_dict(self, sched: Dict[AbstractHlsOp, Tuple[float, float]]):
        """
        :pram sched: dict {node: (startTime, endTime)}
        """<commit_msg>HlsScheduler: rm direct dependency on HlsPipeline class<commit_after>from itertools import chain
from math import ceil
from typing import Dict, Tuple

from hwtHls.clk_math import start_clk
from hwtHls.netlist.nodes.ops import HlsConst, AbstractHlsOp
from hwtHls.scheduler.asap import asap


# from hwtHls.scheduler.alap import alap
class HlsScheduler():

    def __init__(self, parentHls: "HlsPipeline"):
        self.parentHls = parentHls

    def apply_scheduelization_dict(self, sched: Dict[AbstractHlsOp, Tuple[float, float]]):
        """
        :pram sched: dict {node: (startTime, endTime)}
        """
{'fraction_non_alphanumeric': 0.08367514356029532, 'fraction_numerical': 0.0, 'mean_word_length': 4.398230088495575, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4599731', 'n_tokens_mistral': 408, 'n_tokens_neox': 402, 'n_words': 110}