Script for extracting training samples for DLM
Using iterators to better deal with big files in extract_words_dlm.py