2022-05-11 18:19:02 +02:00
|
|
|
pipeline {
|
|
|
|
agent {
|
|
|
|
docker {
|
|
|
|
image 's444409-create-dataset'
|
|
|
|
}
|
|
|
|
}
|
2022-05-11 20:19:44 +02:00
|
|
|
parameters {
|
2022-05-11 20:55:34 +02:00
|
|
|
string(
|
2022-05-11 21:16:03 +02:00
|
|
|
defaultValue: '{\\"inputs\\": [[0.51, 0.86], [0.79, 0.79], [0.74, 0.77], [0.66, 0.73]]}',
|
2022-05-11 20:55:34 +02:00
|
|
|
description: 'Input',
|
|
|
|
name: 'INPUT',
|
|
|
|
trim: true
|
|
|
|
)
|
2022-05-11 20:30:33 +02:00
|
|
|
buildSelector(
|
|
|
|
defaultSelector: lastSuccessful(),
|
|
|
|
description: 'Which build to use for copying artifacts',
|
|
|
|
name: 'BUILD_SELECTOR'
|
|
|
|
)
|
2022-05-11 20:19:44 +02:00
|
|
|
}
|
2022-05-11 18:19:02 +02:00
|
|
|
|
|
|
|
stages {
|
|
|
|
stage('Get dataset from artifact') {
|
|
|
|
steps {
|
2022-05-11 20:30:33 +02:00
|
|
|
copyArtifacts projectName: 's444356-training/master', selector: buildParameter('BUILD_SELECTOR')
|
2022-05-11 18:19:02 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
stage('Predict values using model from artifact') {
|
|
|
|
steps {
|
2022-05-11 20:55:34 +02:00
|
|
|
sh "echo ${params.INPUT} > input_example.json"
|
2022-05-11 18:19:02 +02:00
|
|
|
sh "python predict_s444356.py"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|