Extract atlas function