  We study the energy convergence of the Karhunen-Lo\`eve decomposition of the
turbulent velocity field in a high-Reynolds-number pressure-driven boundary
layer as a function of the number of modes. An energy-optimal Karhunen-Lo\`eve
(KL) decomposition is obtained from wall-modeled large-eddy simulations at
"infinite" Reynolds number. By explicitly using Fourier modes for the
horizontal homogeneous directions, we are able to construct a basis of full
rank, and we demonstrate that our results have reached statistical convergence.
The KL dimension, corresponding to the number of modes per unit volume required
to capture 90% of the total turbulent kinetic energy, is found to be $2.4
\times 10^5 |\Omega|/H^3$ (with $|\Omega|$ the domain volume and $H$ the
boundary layer height). This is significantly higher than current estimates,
which are mostly based on the method of snapshots. In our analysis, we
carefully correct for the effect of subgrid scales on these estimates.
