Label groups of vertices in a graph in an efficient manner without BFS/DFS
As you highlight in your comments, a reasonable approach is to delete all edges with weight $\ge T$, then compute the connected components of the resulting graph (using any standard algorithm for computing connected components).