Marcin Kostrzewski
46d7831b98
All checks were successful
s444409-training/pipeline/head This commit looks good
58 lines
1.4 KiB
Plaintext
58 lines
1.4 KiB
Plaintext
pipeline {
|
|
parameters {
|
|
string(
|
|
defaultValue: '64',
|
|
description: 'Batch size used in ADAM',
|
|
name: 'BATCHSIZE',
|
|
trim: true
|
|
)
|
|
string(
|
|
defaultValue: '5',
|
|
description: 'Number of iterations',
|
|
name: 'EPOCHS',
|
|
trim: true
|
|
)
|
|
}
|
|
|
|
agent {
|
|
docker {
|
|
image 's444409-create-dataset'
|
|
}
|
|
}
|
|
|
|
stages {
|
|
stage('Train model') {
|
|
steps {
|
|
sh "python train_model.py -e ${params.EPOCHS} -b ${params.BATCHSIZE}"
|
|
}
|
|
}
|
|
}
|
|
|
|
environment {
|
|
NOTIFICATION_ADDRESS = 'e19191c5.uam.onmicrosoft.com@emea.teams.ms'
|
|
}
|
|
|
|
post {
|
|
always {
|
|
archiveArtifacts artifacts: 'model_out',
|
|
onlyIfSuccessful: true
|
|
}
|
|
|
|
success {
|
|
emailext body: 'SUCCESS', subject: "${env.JOB_NAME}", to: "${env.NOTIFICATION_ADDRESS}"
|
|
}
|
|
|
|
failure {
|
|
emailext body: 'FAILURE', subject: "${env.JOB_NAME}", to: "${env.NOTIFICATION_ADDRESS}"
|
|
}
|
|
|
|
unstable {
|
|
emailext body: 'UNSTABLE', subject: "${env.JOB_NAME}", to: "${env.NOTIFICATION_ADDRESS}"
|
|
}
|
|
|
|
changed {
|
|
emailext body: 'CHANGED', subject: "${env.JOB_NAME}", to: "${env.NOTIFICATION_ADDRESS}"
|
|
}
|
|
}
|
|
}
|