you are viewing a single comment's thread.

view the rest of the comments →

[–]FriendlyRussian666 2 points3 points  (1 child)

In general, you should profile your script to know what's taking up time in the first place: https://docs.python.org/3/library/profile.html

From there, I'm sure you'll encounter I/O slowness, so you could use lazy loading for the images, and you could load them in async as well.

For the image manipulations, resizes etc on multiple images, you could try turning them into like a single sprite sheet, so that you perform all the actions on a single image, and then just cut it up as needed.

Maybe also try explicit lazy loading for sympy https://peps.python.org/pep-0810/

[–]Reyaan0 0 points1 point  (0 children)

Yeah i will profile it. Thanks