Fix final checkpoint export dtype conversion (#4166)