Converting to indexSet