I have a python script that requires input from the user, but since i need to run this around 300 times, I was looking for a way to feed the input via bash code. My python code is in the form
import sys
inFile = eval(raw_input(sys.argv[1]))
outFile1 = eval(raw_input(sys.argv[2]))
finalfit = eval(raw_input(sys.argv[3]))
and then I go on doing my thing.
In the bash script i just wrote
python filename.py arg1 arg2 arg3
but when I try to run this, it just retuns a line with arg1, and if i hit enter, it gives me an error in the form
Traceback (most recent call last): File "narrowtry.py", line 69, in inFile = eval(raw_input(sys.argv[1]))
File "", line 0
^ SyntaxError: unexpected EOF while parsing
since the input shoud be a string, i tried using