How about putting the pizza in your checked luggage and xferring the lost volume to your carryon luggage where you wanted to put the pizza and avoiding any hassle.
Technically if the pizza is frozen solid, it is not a liquid. You can take solid ice in a cup through. But, the catch is it must be completely solid at time of inspection.