ium_434704/Jenkins_eval
Wojciech Jarmosz f1083d4e7a
Some checks failed
s434704-training/pipeline/head There was a failure building this commit
Add evaluation
2021-05-14 04:01:11 +02:00

42 lines
1.6 KiB
Plaintext

pipeline {
agent {
dockerfile true
}
parameters {
buildSelector(defaultSelector: lastSuccessful(), description: 'Use latest build training', name: 'BUILD_SELECTOR_TRAINING'),
gitParameter branchFilter: 'origin/(.*)', defaultValue: 'master', name: 'branchName', type: 'PT_BRANCH',
}
stages {
stage("Copy artifacts"){
steps {
copyArtifacts fingerprintArtifacts: true, projectName: 's434704-training/${params.branchName}', selector: buildParameter('BUILD_SELECTOR')
copyArtifacts fingerprintArtifacts: true, projectName: 's434704-evaluation', selector: buildParameter(lastSuccessful(), optional: true)
copyArtifacts fingerprintArtifacts: true, projectName: 's434704-create-dataset', selector: buildParameter(lastSuccessful())
}
}
stage("Run evaluation"){
steps {
sh "python3 evaluation.py"
}
}
stage('Archive single metrics') {
steps{
archiveArtifacts 'single_metrics.txt'
}
}
stage('Save metrics to bulk file & create chart') {
steps{
sh "if [ -f "single_metrics.txt" ]; "${env.BUILD_ID} ${cat single_metrics.txt}" >> bulk_metrics.txt fi"
archiveArtifacts 'bulk_metrics.txt'
sh "python3 create_chart.py"
archiveArtifacts 'chart.png'
}
}
}
post {
always {
mail body: "EVALUATION - ${currentBuild.currentResult}", subject: 's434704', to: '26ab8f35.uam.onmicrosoft.com@emea.teams.ms'
}
}
}