Graph breaks are a fact of life, and that's fine. You can't really expect your entire end to end training to never touch the python runtime. It doesn't mean that you should try to somehow reinvent Python compilation from scratch however.
Graph Breaks in AI Training: Python Runtime Considerations
By
–