diff --git a/lab8/Jenkinsfile_predict_artifact b/lab8/Jenkinsfile_predict_artifact index 52d9e0c..800f17b 100644 --- a/lab8/Jenkinsfile_predict_artifact +++ b/lab8/Jenkinsfile_predict_artifact @@ -6,7 +6,7 @@ pipeline { } parameters { string( - defaultValue: '{\\"inputs\\": [[]]}', + defaultValue: '{\\"inputs\\": [0, 0, 2, 904.129525, 1, 1, 20.098413, 79.10786]}', description: 'Input example in json format', name: 'INPUT' ) @@ -20,11 +20,12 @@ pipeline { stage('Stage 1') { steps { echo 'Copying model from s444417-training...' - copyArtifacts projectName: 's444417-training/master', selector: buildParameter('BUILD_SELECTOR') + copyArtifacts filter: 'mlruns.tar.gz', projectName: 's444417-training/master', selector: buildParameter('BUILD_SELECTOR') + sh 'mkdir mlruns_s444417 && tar xvzf mlruns.tar.gz -C mlruns_s444417 --strip-components 1' echo 'Model copied' echo 'Making a prediction...' sh 'echo ${params.INPUT} > input_example.json' - sh 'python3 predict_s444356.py' + sh 'python3 predict_artifact.py' echo 'Prediction made' } }