Ginzburg-Landau vortices with pinning functions and self-similar solutions in harmonic maps