Fixed bugs

Data index was not operated on properly for let, throwing syntax erros.
Added Debug output for data_index
Images were not downloaded properly due to unquoted image_name
Changed line 298 to use `file` instead of reading raw data from each
file.