Nice vid, have a sub. As a noob at python id really appreciate a vid on turning .py into an .exe for general python projects and tkinter based stuff if different. Hint hint 😊
This is a very misleading tutorial, using threads in python to speed up your program is a lot more complicated than this tutorial pretends (test it for yourself, copy this program and test how long it takes to count to 1000, then add a second thread to the program that also counts to 1000 and time how long that takes, I did that and it took twice as long) When writing multi-threaded programs it is usually very important to make sure that two different threads can't work with the same variables at once (because this can cause nasty bugs) This is not necessary in Python though, because it has the Global Interpreter Lock (GIL for short), which only lets one one thread have access at the same time, preventing such bugs The downside of the GIL is that different threads will be waiting for the GIL to let them do their thing, so your program does not get any faster. There are ways in which your program can be sped up using threads, because not all operations are limited by the GIL (the numpy library for number crunching for example is mostly not affected). Threads can also be useful for handling things that would otherwise block your program (like something big being downloaded from the internet, if a separate thread handles that the entire program won't freeze up until that is done). So while threading is not useless this tutorial does not show the benefits or how to use it well at all TL;DR using threads in Python does not make your program faster in most cases and it takes a more in depth tutorial to explain when it actually does and why it does that
Great video, you helped me understand how easy and efficient threading can be. Thank you 🤙🤙🤙
Thank you for watching and I'm glad I could help! :)
Thanks Bro
Nice vid, have a sub. As a noob at python id really appreciate a vid on turning .py into an .exe for general python projects and tkinter based stuff if different. Hint hint 😊
Thanks for the idea! :)
omg you use arch !?
@@TaylorsSoftware cool
This is a very misleading tutorial, using threads in python to speed up your program is a lot more complicated than this tutorial pretends (test it for yourself, copy this program and test how long it takes to count to 1000, then add a second thread to the program that also counts to 1000 and time how long that takes, I did that and it took twice as long)
When writing multi-threaded programs it is usually very important to make sure that two different threads can't work with the same variables at once (because this can cause nasty bugs)
This is not necessary in Python though, because it has the Global Interpreter Lock (GIL for short), which only lets one one thread have access at the same time, preventing such bugs
The downside of the GIL is that different threads will be waiting for the GIL to let them do their thing, so your program does not get any faster.
There are ways in which your program can be sped up using threads, because not all operations are limited by the GIL (the numpy library for number crunching for example is mostly not affected).
Threads can also be useful for handling things that would otherwise block your program (like something big being downloaded from the internet, if a separate thread handles that the entire program won't freeze up until that is done).
So while threading is not useless this tutorial does not show the benefits or how to use it well at all
TL;DR using threads in Python does not make your program faster in most cases and it takes a more in depth tutorial to explain when it actually does and why it does that