Black hole microstates in AdS$_4$ and AdS$_5$ from supersymmetric partition functions IPhT 09/04/2024