It looks like you added two additional atoms positions of
2 0.5 0.5 0.5
3 0 0 0.5
When you did that, it looks like you forgot to change the arrays for mat, lc, and hc:
# mat, lc, and hc
mat = array([0,0],dtype=int)
lc = array([0,0],dtype=int)
hc = array([0,0],dtype=int)
To remove the error, you would need to add two additional mat, lc, and hc values to the arrays:
# mat, lc, and hc
mat = array([0,0,0,0],dtype=int)
lc = array([0,0,0,0],dtype=int)
hc = array([0,0,0,0],dtype=int)
The script as is will output all mat, lc, and hc values as 0 by default, and the script is not able set the proper values for those. So you have to manually change those either in the arrays above in the script or in the outputted file (my_file.ucf) to appropriate values for your simulation.
Kind Regards,
Gavin
VAMPIRE user