I have some python code that has many classes. I used cProfile to find that the total time to run the program is 68 seconds. I found that the following function in
cProfile
You're asking for guesses, and mostly you're getting guesses.
There's no need to guess. Here's an example.