<jupyter_start><jupyter_text><jupyter_code>from graphviz import Source

data = """
digraph G {
    graph [rankdir="LR" labelfontcolor=red fontname="arial" size="10,10"]
    node [fixedsize=true  width="0.8" nodesep="0.2" fontname="arial" fontsize=12]
    edge [fontname="arial" color="grey" fontsize=11]
    
    S0 [label="(S0)\\nHold" shape="circle"]
    S1 [label="(S1)\\nGenerate" shape="circle"]
    S2 [label="(S2)\\nHold" shape="circle"]
    S3 [label="(S3)\\nFill" shape="circle"]
    S4 [label="(S4)\\nHold" shape="circle"]

    S0 -> S1 [label="h > h_start", constraint=true]
    S1 -> S2 [label="n11 > n11_max", constraint=true]
    S2 -> S3 [label="h < 0", constraint=true]
    S3 -> S4 [label="h > 0", constraint=true]
    S4 -> S1 [label="h > h_start", constraint=false]
}
"""
gv = Source(data, engine="dot")
gv.format='svg'
gv.render( 'EbbOperation_FSM' )
gv<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.20155038759689922, 'fraction_numerical': 0.042081949058693245, 'mean_word_length': 4.4787878787878785, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 14, '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}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '441516', 'license': 'MIT', 'n_tokens_mistral': 376, 'n_tokens_neox': 358, 'n_words': 69, 'path': 'BarrageExamples/Figures/EbbOperationGraphViz.ipynb', 'repo_name': 'joaochenriques/2021-code-smells', 'size': '903'}