An accurate localization method for subsea pipelines by using external magnetic fields