Updated the vectorization utils + added tests