npInv: accurate detection and genotyping of inversions using long read sub-alignment