我开始与kubeflow合作,并创建了第一个小管道。不幸的是,它不起作用,所以当我尝试用我的管道创建一个运行时,什么都没有发生。它既不创建Kubernetes pod,也不改变运行状态(它一直说“未知状态”)。我也看不到所属的图形或运行输出。你知道吗
我的管道代码如下所示:
import kfp
from kfp import components
from kfp import dsl
from kfp import onprem
import sys
def train_op(
epochs,
validations,
workers,
trainset,
input,
filenames,
target,
train_size,
learn_rate,
):
return dsl.ContainerOp(
name='Train',
image='pascalschroeder/ml-train-test',
arguments=[
'--epochs', epochs,
'--validations', validations,
'--workers', workers,
'--trainset', trainset,
'--input', input,
'--filenames', filenames,
'--target', target,
'--train_size', train_size,
'--learn_rate', learn_rate,
],
file_outputs={
'model': 'path/to/model',
}
)
def load_op(
workers,
testset,
input,
filenames,
target,
model,
output
):
return dsl.ContainerOp(
name='Load',
image='pascalschroeder/ml-load-test',
arguments=[
'--workers', workers,
'--testset', testset,
'--input', input,
'--filenames', filenames,
'--target', target,
'--model', model,
'--output', output,
],
file_outputs={
'result': 'path/to/result.txt',
}
)
@dsl.pipeline(
name='ML Test Pipeline',
description='Test'
)
def train_pipeline(
output,
epochs=30,
validations=10,
trainset='path/to/trainset',
testset='path/to/testset',
input='path/to/csv',
filenames='id',
target='has_scratch',
train_size=0.8,
learn_rate=0.0001,
workers=2,
):
train = train_op(epochs,
validations,
workers,
trainset,
input,
filenames,
target,
train_size,
learn_rate)
load = load_op(workers,
testset,
input,
filenames,
target,
train.outputs['model'],
output)
if __name__ == '__main__':
import kfp.compiler as compiler
compiler.Compiler().compile(train_pipeline, __file__ + '.zip')
我正在一个安装了MicroK8s和Kubeflow的Ubuntu系统上工作。你知道吗
当我输入kubectl get pods --namespace=kubeflow
时,在我开始运行管道之后,没有新的pod出现。你知道吗
在kubeflow仪表板中,我可以在“所有运行”部分看到运行,但没有状态(未知状态)和持续时间。你知道吗
当我点击run并进入Config时,我得到以下配置:
Run details
Status
Description
Created at 5/22/2019, 11:14:46 AM
Started at -
Finished at -
Duration -
Run parameters
output
epochs 30
validations 10
trainset /path/to/trainset
testset /path/to/testset
input /path/to/csv
filenames id
target has_scratch
train-size 0.8
learn-rate 0.0001
workers 2
你们能帮帮我吗?你知道吗
谢谢你!你知道吗
目前没有回答
相关问题 更多 >
编程相关推荐