pointer_summarizer icon indicating copy to clipboard operation
pointer_summarizer copied to clipboard

Error: -bash: log/training_log: Is a directory

Open Ethanscuter opened this issue 6 years ago • 2 comments

In the start_train.sh, there is python training_ptr_gen/train.py >& log/training_log & When I bash run start_train.sh, the terminal shows -bash: log/training_log: Is a directory. So, I want to ask what's the meaning of >& log/training_log & In your config.py. the log directory should exist in ptr_nw/log. Thx.

Ethanscuter avatar Jun 04 '18 11:06 Ethanscuter

>& log/training_log simply redirect the output to the file 'log/training_log' & at the end is for running the program in background. You might have training_log directory created in log directory. You can simply change >& log/training_log & to >& log/training_log.txt & and it will work if there is no other errors.

atulkum avatar Jun 04 '18 15:06 atulkum

export PYTHONPATH=pwd python training_ptr_gen/train.py >& ../log/training_log.txt &

我将train.sh文件中修改成这样后,运行 sh start_train.sh 报错:start_train.sh: 3: start_train.sh: Syntax error: Bad fd number 是什么出问题了吗? 我是自己在log目录下创建了一个txt文件

dajuzi123 avatar Dec 19 '18 09:12 dajuzi123