Factory defaults would restore the OS which the machine came with. Is that what you want? If so run HP Recovery partition from boot..
If you want to clean reinstall Windows 7 here are the steps to get a purrfect reinstall:
re-install windows 7
MS made good on Digital River not initially providing an ISO with the Student Deal
here.
You can clean reinstall with your Windows 7 upgrade installer by leaving the Product Key blank during install, then after install doing the quick registry workaround given here to allow use of Upgrade version on a blank HD:
Clean Install with a Upgrade Windows 7 Version
If you previously did an inferior in-place Upgrade of Windows 7 from Vista you may still be able to make your Vista Recovery Disks before wiping the HD to clean reinstall Windows 7. This will also wipe away all of the useless HP factory utilities which have better versions built into Windows 7.
If you only want to reinstall an in-place Upgrade you could try running a
Repair Install but this may transfer over corruption imported from Vista anyway.
Your best bet is to finally wipe away all of the HP bloatware by zeroing the HD to clean reinstall which is better than getting a new computer with the bloatware larded on today.