Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#104] Implement regression tests #109

Merged
merged 8 commits into from
Apr 10, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update command line for regression tests
  • Loading branch information
piotrszul committed Apr 8, 2019
commit 9d17e6c1b60fd3f018561bf432e11f579343bfae
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,4 @@ build
dist
_build
spark-warehouse
.*.crc
Binary file removed src/test/data/regression/.CNAE-9-imp_category.csv.crc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class ImportanceRegressionTest {
// synth_2000_500_fact_3_0.995-imp_cat2.csv
val caseFileRE = """(synth_([^_]+)_([^_]+)_fact_([^_]+)_([^_]+))-imp_([^_]+).csv""".r
caseFile match {
case caseFileRE(prefix,_,_,ivo,_,response) => runRegression(s"importance -if ${synth(prefix)}-wide.csv -ff ${synth(prefix)}-labels.csv -fc ${response} -it csv -ivo ${ivo} -v -rn 100 -rbs 50 -ro -sr 17 -on 100 -sp 4 -of $${outputFile}",
case caseFileRE(prefix,_,_,ivo,_,response) => runRegression(s"""importance -if ${synth(prefix)}-wide.csv -ff ${synth(prefix)}-labels.csv -fc ${response} -it csv -io {"defVariableType":"ORDINAL(${ivo})"} -v -rn 100 -rbs 50 -ro -sr 17 -on 100 -sp 4 -of $${outputFile}""",
caseFile)
}
}
Expand All @@ -79,7 +79,7 @@ class ImportanceRegressionTest {

@Test
def testCNAEImportance() {
runRegression("importance -if data/CNAE-9-wide.csv -it csv -ff data/CNAE-9-labels.csv -fc category -v -ro -rn 100 -rbs 50 -sr 17 -ivo 10 -sp 4 -on 100 -of ${outputFile}",
runRegression("""importance -if data/CNAE-9-wide.csv -it csv -ff data/CNAE-9-labels.csv -fc category -v -ro -rn 100 -rbs 50 -sr 17 -io {"defVariableType":"ORDINAL(10)"} -sp 4 -on 100 -of ${outputFile}""",
"CNAE-9-imp_category.csv")
}

Expand Down