Create bulk insertion file for redis using Python dicts