Added CUTOFF parameter
This commit is contained in:
parent
ae8779f171
commit
e9ce9ea17f
10
Jenkinsfile
vendored
10
Jenkinsfile
vendored
@ -12,6 +12,11 @@ pipeline {
|
||||
description: 'Kaggle token taken from kaggle.json file, as described in https://github.com/Kaggle/kaggle-api#api-credentials',
|
||||
name: 'KAGGLE_KEY'
|
||||
)
|
||||
string(
|
||||
defaultValue: "260000",
|
||||
description: 'Use CUTOFF random examples from dataset',
|
||||
name: 'CUTOFF'
|
||||
)
|
||||
}
|
||||
stages {
|
||||
stage('Hello') {
|
||||
@ -27,8 +32,9 @@ pipeline {
|
||||
stage("Download data") {
|
||||
steps {
|
||||
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
||||
"KAGGLE_KEY=${params.KAGGLE_KEY}"]) {
|
||||
sh "./download_data.sh"
|
||||
"KAGGLE_KEY=${params.KAGGLE_KEY}",
|
||||
"CUTOFF=%{params.CUTOFF}"]) {
|
||||
sh "./download_data.sh $CUTOFF"
|
||||
archiveArtifacts artifacts: "crime.test, crime.dev, crime.train", onlyIfSuccessful: true
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
kaggle datasets download -d AnalyzeBoston/crimes-in-boston
|
||||
unzip crimes-in-boston.zip
|
||||
shuf crime.csv > crime.shuf
|
||||
shuf crime.csv | head -n $1 > crime.shuf
|
||||
head -n 30000 crime.shuf > crime.test
|
||||
head -n 60000 crime.shuf | tail -n 30000 > crime.dev
|
||||
tail -n +60001 crime.shuf > crime.train
|
||||
|
Loading…
Reference in New Issue
Block a user