You can burn iso file to CD and boot from it.
With USB it's a bit more complicated.
You need HP USB format tool
https://hp-usb-disk-storage-format-tool.en.softonic.com/
Download magic boot disk with mhdd (from mhdd page) and mount it.
Use HP USB format tool to create DOS startup disk on USB flash drive using files from mounted iso image. It copies only DOS system files.
Copy files from mounted iso image to USB flash drive (don't overwrite anything or result will not be bootable).
Boot from USB flash drive.
run mhdd.exe
use commands:
port - to select drive to operate on
scan - to scan the drive selected (from options choose relocate on)
scan will run for several hours depending on size of the drive and will relocate pending sectors.