updated maptoreferecence count to use alignvec