Biden heads to Japan after warning on North Korea threat