Update Jenkinsfiles, bash scripts ver 1.7
This commit is contained in:
parent
acdb4cb429
commit
70f3a128f5
44
Jenkinsfile_2
Normal file
44
Jenkinsfile_2
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
pipeline {
|
||||||
|
agent any
|
||||||
|
parameters {
|
||||||
|
string(
|
||||||
|
defaultValue: 'kamilab0bkowska',
|
||||||
|
description: 'kaggle username',
|
||||||
|
name: 'KAGGLE_USERNAME',
|
||||||
|
trim: false
|
||||||
|
)
|
||||||
|
password(
|
||||||
|
defaultValue: '',
|
||||||
|
description: 'kaggle passowrd',
|
||||||
|
name: 'KAGGLE_KEY'
|
||||||
|
)
|
||||||
|
buildSelector(
|
||||||
|
defaultSelector: lastSuccessful(),
|
||||||
|
description: 'Which build to use for copying artifacts',
|
||||||
|
name: 'BUILD_SELECTOR'
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
stages {
|
||||||
|
stage('Stage 1') {
|
||||||
|
steps {
|
||||||
|
echo 'Hello world but for the second time!'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('Copy and proceed') {
|
||||||
|
steps {
|
||||||
|
copyArtifacts fingerprintArtifacts: true, projectName: 's444517-create-dataset', selector: buildParameter('BUILD_SELECTOR')
|
||||||
|
sh 'chmod +x -R ./data_stats.sh'
|
||||||
|
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
||||||
|
"KAGGLE_KEY=${params.KAGGLE_KEY}"]) {
|
||||||
|
sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME'
|
||||||
|
sh './data_stats.sh'
|
||||||
|
archiveArtifacts artifacts: 'apps_train.csv, apps_test.csv, apps_validate.csv'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
#kaggle datasets download -d lava18/google-play-store-apps
|
kaggle datasets download -d lava18/google-play-store-apps
|
||||||
unzip -o google-play-store-apps.zip
|
unzip -o google-play-store-apps.zip
|
||||||
sed -i '1d' googleplaystore.csv
|
sed -i '1d' googleplaystore.csv
|
||||||
shuf googleplaystore.csv > apps_shuf_.csv
|
shuf googleplaystore.csv > apps_shuf_.csv
|
||||||
@ -19,6 +19,3 @@ head -n $train_val_set apps_shuf.csv > apps_test.csv
|
|||||||
lines="1,$train_val_set"
|
lines="1,$train_val_set"
|
||||||
sed -i "$lines"'d' apps_shuf.csv
|
sed -i "$lines"'d' apps_shuf.csv
|
||||||
head -n $train_val_set apps_shuf.csv > apps_validate.csv
|
head -n $train_val_set apps_shuf.csv > apps_validate.csv
|
||||||
wc -l apps_train.csv
|
|
||||||
wc -l apps_test.csv
|
|
||||||
wc -l apps_validate.csv
|
|
3
data_stats.sh
Normal file
3
data_stats.sh
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
wc -l apps_train.csv > stats.txt
|
||||||
|
wc -l apps_test.csv >> stats.txt
|
||||||
|
wc -l apps_validate.csv >> stats.txt
|
Loading…
Reference in New Issue
Block a user