update jenkinsfile_train-sacred, predict.py
Some checks failed
s444356-evaluation/pipeline/head This commit looks good
s444356-training/pipeline/head There was a failure building this commit

This commit is contained in:
Maciej Czajka 2022-05-11 20:36:54 +02:00
parent b16fce0beb
commit 3d2efac477
2 changed files with 2 additions and 1 deletions

View File

@ -17,6 +17,7 @@ pipeline {
stage('Script'){ stage('Script'){
steps { steps {
copyArtifacts filter: '*', projectName: 's444356-create-dataset' copyArtifacts filter: '*', projectName: 's444356-create-dataset'
sh 'rm -rf my_model'
sh "python Biblioteka_DL/dllib-mlflow.py $EPOCHS" sh "python Biblioteka_DL/dllib-mlflow.py $EPOCHS"
archiveArtifacts artifacts: 'games_model.pkl' archiveArtifacts artifacts: 'games_model.pkl'
archiveArtifacts artifacts: 'mlruns/**' archiveArtifacts artifacts: 'mlruns/**'

View File

@ -13,4 +13,4 @@ with open(f'{logged_model}/'+input) as f:
data = json.load(f) data = json.load(f)
input_example = np.array([data['inputs'][0]], dtype=np.float32) input_example = np.array([data['inputs'][0]], dtype=np.float32)
loaded_model.predict(input_example) print(f'Prediction: {loaded_model.predict(input_example)}')