如何从组件内部获取运行ID? [英] How to get the id of the run from within a component?
问题描述
我正在对Kubeflow管道进行一些试验,并且我有兴趣检索要保存的运行ID以及有关管道执行的一些元数据.我可以通过ContainerOp
之类的组件来做到这一点吗?
I'm doing some experimentation with Kubeflow Pipelines and I'm interested in retrieving the run id to save along with some metadata about the pipeline execution. Is there any way I can do so from a component like a ContainerOp
?
推荐答案
I tried to do this using the Python's DSL but seems that isn't possible right now.
The only option that I found is to use the method that they used in this sample code. You basically declare a string containing {{workflow.uid}}
. It will be replaced with the actual value during execution time.
您也可以执行此操作以获取广告连播名称,该名称为{{pod.name}}
.
You can also do this in order to get the pod name, it would be {{pod.name}}
.
这篇关于如何从组件内部获取运行ID?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!