The algorithm in latex will always go to the top of the next page, not the current page.
I am using a two-column environment, and I can't add htb, but I will still go to the next page, resulting in a lot of blanks on the current page.
Solution:
This is solved by adding an H after I set the odd and double columns.
As shown in FIG. Change the algorithm float format to H.