Python Code To Diagram Generator