vectorized ann updates