added function to retrieve bag of words for a scene