MAINT: avoid an overflow in rice pdf