Commit 2128e7e
authored
Unnest compound mode search loops and clean up inter search (#5343)
This change includes the following cleanups
- Unnest JMVD scale factor, CWP, and RefineMV loops in
handle_compound_inter_prediction to avoid redundant motion search and
skip invalid tool combinations. The new search order is 1) base mode, 2)
refine MV, 3) CWP, 4) JMVD scale. This search order is intended to allow
potential early termination in the future
- Remove unused variables, unnecessary checks, redundant mbmi field
re-assignments, and move the update of common variable outside of search
loops.
- Use reset_inter_mode_info helper to unify mode_info field resets
STATS_CHANGED
Results tested with RA 33 frames based on 18a0096
```
1) Speed 0
+------------+-------+-------+-------+-------+-------+-------+
| Class | Y | Cb | Cr | wAvg | Enc% | Dec% |
+------------+-------+-------+-------+-------+-------+-------+
| A1 | -0.01 | +0.02 | +0.12 | -0.01 | 100.8 | 99.4 |
| A2 | -0.00 | +0.06 | +0.01 | +0.00 | 100.2 | 99.4 |
+------------+-------+-------+-------+-------+-------+-------+
2) Speed 1
+------------+-------+-------+-------+-------+-------+-------+
| Class | Y | Cb | Cr | wAvg | Enc% | Dec% |
+------------+-------+-------+-------+-------+-------+-------+
| A1 | +0.00 | +0.02 | +0.03 | +0.01 | 100.9 | 101.4 |
| A2 | +0.01 | +0.01 | -0.07 | +0.01 | 100.7 | 100.5 |
+------------+-------+-------+-------+-------+-------+-------+
3) Speed 2
+------------+-------+-------+-------+-------+-------+-------+
| Class | Y | Cb | Cr | wAvg | Enc% | Dec% |
+------------+-------+-------+-------+-------+-------+-------+
| A1 | -0.01 | +0.00 | -0.02 | -0.01 | 101.0 | 101.6 |
| A2 | +0.01 | +0.02 | -0.01 | +0.01 | 100.5 | 100.7 |
+------------+-------+-------+-------+-------+-------+-------+
```1 parent 2ab55a5 commit 2128e7e
1 file changed
Lines changed: 328 additions & 221 deletions
0 commit comments