I'm trying to load multiple images and want to automate the variable naming to make the variable name = the file input name.
For example:
image1=read_binary('image1.img',DATA_START=0,DATA_TYPE=1,DATA_DIMS=[450, 750,3], ENDIAN=native)
Just wondering if this is possible and how?
You could put all of the image names in a string array and loop over that. If your images are .png then I would suggest that you use the read_png function. This may not be the most efficient, but if the images all have the same size then it is easy to stack them all in a cube like:
Now you have all of the images in a cube where the last dimension is the image number.