# Remove\_columns option for .map

**URL:** <https://discuss.huggingface.co/t/remove-columns-option-for-map/20725>\
**Category:** Beginners\
**Created:** [July 22, 2022, 2:33pm UTC](https://discuss.huggingface.co/t/remove-columns-option-for-map/20725 "2022-07-22T14:33:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jrf](https://avatars.discourse-cdn.com/v4/letter/j/3be4f8/32.png) [@jrf](https://discuss.huggingface.co/u/jrf)\
**Post date:** [July 22, 2022, 2:33pm UTC](https://discuss.huggingface.co/t/remove-columns-option-for-map/20725/1 "2022-07-22T14:33:20Z")

</div>

Like many people, I’m working through the tutorial on fine-tuning wav2vec2, adapting it in various ways. I’m considering the following line of code:

timit = timit.map(prepare\_dataset, remove\_columns=timit.column\_names[“train”], num\_proc=4)

My understanding is that the remove\_columns option will first process any columns in the list and then remove them. I also think that, for a datasetDict, the function prepare\_dataset will be applied to all dictionary entries (i.e. ‘train’, ‘test’, etc). So my question: is remove\_columns strictly necessary here? What is its purpose exactly? Is it just removing unnecessary information from memory, or will the function be applied incorrectly if it is not included?

thanks  
Jonathan
