简体   繁体   English

是否可以在 HTCondor 中检索 python 脚本的输出?

[英]Is it possible to retrieve the output of python scripts in HTCondor?

I would like to run some python scripts that return some dictionaries on a cluster managed by HTCondor.我想运行一些 python 脚本,这些脚本在 HTCondor 管理的集群上返回一些字典。 I run the same on another cluster running MPI/Slurm and mpi4py and I was able to collect the output without saving files and transfer them to the main node.我在另一个运行 MPI/Slurm 和 mpi4py 的集群上运行相同的程序,我能够在不保存文件的情况下收集输出并将它们传输到主节点。 I cannot understand how to do it in HTCondor (even using python wrappers).我无法理解如何在 HTCondor 中执行此操作(即使使用 python 包装器)。

Is it possible to retrieve the output of python scripts in HTCondor?是否可以在 HTCondor 中检索 python 脚本的输出? Do i need to use the schedd.retrieve("ClusterId == %d" % cluster) command?我需要使用schedd.retrieve("ClusterId == %d" % cluster)命令吗? if so an example will be really appreciated.如果是这样,将不胜感激。

Thanks!谢谢!

You may specify a file to which you want to save your stdout in your submit file (see also Condor output file updating ).您可以在提交文件中指定要将标准输出保存到的文件(另请参阅Condor 输出文件更新)。

You can watch the output using htcondor_tail (not sure what the equivalent is in the python api).您可以使用htcondor_tail查看输出(不确定 python api 中的等效项是什么)。

Slightly off-topic: If you run python you can also use eg Dask to do your remote python stuff (see also Dask with HTCondor scheduler )稍微偏离主题:如果你运行 python,你也可以使用例如 Dask 来做你的远程 python 事情(另请参见Dask with HTCondor scheduler

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM