Make frame normalization converge faster

Adapt the iteration algorithm to make the frame level normalization
calculation converge faster. On a single thread at low QPs, this
makes the dq3 mode 5-10% faster for 4K resolution.

BUG=b/257074966

Change-Id: Ib4a8ed952d02bf3bb409cc0cdba16eb5c69f3784
diff --git a/av1/encoder/allintra_vis.c b/av1/encoder/allintra_vis.c
index a3e3e69..1fbb7d4 100644
--- a/av1/encoder/allintra_vis.c
+++ b/av1/encoder/allintra_vis.c
@@ -454,10 +454,12 @@
         double beta = (double)cpi->norm_wiener_variance / sb_wiener_var;
         double min_max_scale = AOMMAX(
             1.0, get_max_scale(cpi, cm->seq_params->sb_size, mi_row, mi_col));
-        beta = 1.0 / AOMMIN(1.0 / beta, min_max_scale);
+
         beta = AOMMIN(beta, 4);
         beta = AOMMAX(beta, 0.25);
 
+        if (beta < 1 / min_max_scale) continue;
+
         sb_wiener_var = (int)(cpi->norm_wiener_variance / beta);
 
         int64_t satd = get_satd(cpi, norm_block_size, mi_row, mi_col);