High-precision astrometry with VVV - I. An independent reduction pipeline for VIRCAM@VISTA