Snakemake 集群配置结合 DRMMA
Snakemake cluster config in combination with DRMMA
我有一个与 drmma 和 snakemake 中的集群配置文件相关的问题。
目前我有一个管道,我通过以下命令使用 drmma 将作业提交到集群:
snakemake --drmaa " -q short.q -pe smp 8 -l membycore=4G" --jobs 100 -p file1/out file2/out file3/out
问题是某些 rules/jobs 需要更少或更多的资源。我虽然认为如果我使用 json 集群文件我将能够提交具有不同资源的作业。我的 json 文件如下所示:
{
"__default__":
{
"-q":"short.q",
"-pe":"smp 1",
"-l":"membycore=4G"
},
"job1":
{
"-q":"short.q",
"-pe":"smp 8",
"-l":"membycore=4G"
},
"job2":
{
"-q":"short.q",
"-pe":"smp 8",
"-l":"membycore=4G"
}
}
当我 运行 以下命令时,我的作业(job1 和 job2)使用默认选项而不是自定义选项提交:
snakemake --jobs 100 --cluster-config cluster.json --drmaa -p file1/out file2/out file3/out
我做错了什么?是我不能将 drmaa 选项与 cluster-config 文件结合使用吗?
集群配置文件只允许您根据定义的占位符定义稍后在 --cluster/--cluster-sync/--drmaa
中使用的变量。这里没有涉及 DRMAA 特定的魔法。再看看the corresponding section in the documentation。
也许举个例子更清楚:
集群配置:
{
"__default__":
{
"time" : "02:00:00",
"mem" : 1G,
},
# more rule specific definitions here...
}
使用上述参数的示例 snakemake 参数:
--drmaa " -pe OpenMP {threads} -l mem_free={cluster.mem} -l h_rt={cluster.time}"
或
--cluster-sync "qsub -sync y -pe OpenMP {threads} -l mem_free={cluster.mem} -l h_rt={cluster.time}"
cluster.time
和 cluster.mem
将根据规则进行相应替换。
安德烈亚斯
我有一个与 drmma 和 snakemake 中的集群配置文件相关的问题。
目前我有一个管道,我通过以下命令使用 drmma 将作业提交到集群:
snakemake --drmaa " -q short.q -pe smp 8 -l membycore=4G" --jobs 100 -p file1/out file2/out file3/out
问题是某些 rules/jobs 需要更少或更多的资源。我虽然认为如果我使用 json 集群文件我将能够提交具有不同资源的作业。我的 json 文件如下所示:
{
"__default__":
{
"-q":"short.q",
"-pe":"smp 1",
"-l":"membycore=4G"
},
"job1":
{
"-q":"short.q",
"-pe":"smp 8",
"-l":"membycore=4G"
},
"job2":
{
"-q":"short.q",
"-pe":"smp 8",
"-l":"membycore=4G"
}
}
当我 运行 以下命令时,我的作业(job1 和 job2)使用默认选项而不是自定义选项提交:
snakemake --jobs 100 --cluster-config cluster.json --drmaa -p file1/out file2/out file3/out
我做错了什么?是我不能将 drmaa 选项与 cluster-config 文件结合使用吗?
集群配置文件只允许您根据定义的占位符定义稍后在 --cluster/--cluster-sync/--drmaa
中使用的变量。这里没有涉及 DRMAA 特定的魔法。再看看the corresponding section in the documentation。
也许举个例子更清楚:
集群配置:
{
"__default__":
{
"time" : "02:00:00",
"mem" : 1G,
},
# more rule specific definitions here...
}
使用上述参数的示例 snakemake 参数:
--drmaa " -pe OpenMP {threads} -l mem_free={cluster.mem} -l h_rt={cluster.time}"
或
--cluster-sync "qsub -sync y -pe OpenMP {threads} -l mem_free={cluster.mem} -l h_rt={cluster.time}"
cluster.time
和 cluster.mem
将根据规则进行相应替换。
安德烈亚斯