Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/316.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
运行python脚本时-S-cwd-r-j-l是什么意思?_Python_Bash_Command - Fatal编程技术网

运行python脚本时-S-cwd-r-j-l是什么意思?

运行python脚本时-S-cwd-r-j-l是什么意思?,python,bash,command,Python,Bash,Command,我正在尝试运行一个同事提供的python脚本。开头有以下几行: #$ -S /usr/bin/python #$ -cwd #$ -r yes #$ -j y #$ -l h_rt=10:00:00 #$ -l arch=lx24-amd64 显然,它应该是“改变我的本地环境”。我试着用谷歌搜索,但我不知道这些命令是什么意思。我假设它告诉了我的shell一些事情,但我不知道它们在本文中的含义。它们看起来像是将此作为作业提交给Sun Grid引擎的命令参数: 如果脚本行的前两个字符 匹配“#$”

我正在尝试运行一个同事提供的python脚本。开头有以下几行:

#$ -S /usr/bin/python
#$ -cwd
#$ -r yes
#$ -j y
#$ -l h_rt=10:00:00
#$ -l arch=lx24-amd64
显然,它应该是“改变我的本地环境”。我试着用谷歌搜索,但我不知道这些命令是什么意思。我假设它告诉了我的shell一些事情,但我不知道它们在本文中的含义。

它们看起来像是将此作为作业提交给Sun Grid引擎的命令参数:

如果脚本行的前两个字符 匹配“#$”或等于定义的前缀字符串 使用下面描述的-C选项,该行将被解析为 嵌入式命令标志

以下是这名男子的摘录:

-S [[hostname]:]pathname,...
      Specifies the interpreting shell for the job. 

-l resource=value,...
      Launch the job in a Sun Grid Engine queue  meeting  the
      given  resource  request  list.

-j y[es]|n[o]
      Specifies whether or not the standard error  stream  of
      the job is merged into the standard output stream.

 -r y[es]|n[o]
      Identifies the ability of a job to be rerun or not.  If
      the  value of -r is 'yes', the job will be rerun if the
      job was  aborted  without  leaving  a  consistent  exit
      state.

 -cwd 
      Execute the job from  the  current  working  directory.

感谢assist@chepnerAhh,这很有意义,脚本是在Sun Grid集群上运行的。非常感谢。NP-我只是觉得它们很熟悉,因为我碰巧和一个使用它的客户一起工作。