Efficient clustering and matching for object glass