I am having problems running the generate_image script. I get an error that says TypeError: 'range' object does not support item assignment. Can you help me figure out what I did wrong?