Wraped indexing with error expeptation since it it eating up memory