Merge pull request #166 from ppasupat/run-file-hotfix

Run file hotfix
This commit is contained in:
Panupong (Ice) Pasupat 2018-01-11 16:08:22 -08:00 committed by GitHub
commit 490ba9e29b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 4 deletions

7
run
View File

@ -551,7 +551,6 @@ addMode('overnight', 'Overnight semantic parsing', l(
#o('initialization', 'paraphrase :: match,1', 'paraphrase :: size,-0.1', 'paraphrase :: ppdb,0.3',
# 'paraphrase :: skip-bigram,0.8', 'paraphrase :: skip-ppdb,0.2','denotation :: error,-1000'),
o('coarsePrune'),
o('OvernightDerivationPruningComputer.applyHardConstraints'),
sel(2,
l(), # no reg
l(o('Params.l1Reg','lazy'),o('Params.l1RegCoeff',0)),
@ -573,6 +572,7 @@ addMode('overnight', 'Overnight semantic parsing', l(
o('phraseAlignmentPath', lambda { |e| 'lib/data/overnight/' + e[:domain] + '.phrase_alignments' }),
o('PPDBModel.ppdbModelPath', lambda { |e| 'lib/data/overnight/' + e[:domain] + '-ppdb.txt' }),
o('DerivationPruner.pruningComputers', ['overnight.OvernightDerivationPruningComputer']),
o('DerivationPruner.pruningStrategies', ['violateHardConstraints']),
o('Dataset.inPaths',
lambda { |e| 'train:lib/data/overnight/' + e[:domain] + '.paraphrases.train.examples' },
lambda { |e| 'test:lib/data/overnight/' + e[:domain] + '.paraphrases.test.examples' }),
@ -937,7 +937,10 @@ def tablesDataPaths
# That's it!
l(
o('TableKnowledgeGraph.baseCSVDir', csvDir),
o('TableValuePreprocessor.taggedFiles', "#{csvDir}/tagged/data/"),
# Default: use the normalized values from the tagged file, which were checked by hand.
# To turn this off, use @useTaggedFile=0
letDefault(:useTaggedFile, 1),
selo(:useTaggedFile, 'TableValuePreprocessor.taggedFiles', '', "#{csvDir}/tagged/data/"),
sel(:data, datasets),
nil)
}

View File

@ -31,11 +31,11 @@ Running the code
3. The following command train and test on 100 development examples:
./run @mode=tables @data=u-1 @feat=all @train=1 -maxex train,100 dev,100
./run @mode=tables @data=u-1 @feat=all @train=1 -maxExamples train:100 dev:100
The command should take less than 30 minutes.
* To train on the complete development set, remove `-maxex train,100 dev,100`
* To train on the complete development set, remove `-maxExamples train:100 dev:100`
* The command above uses `u-1` (80:20 split of the development data).
Other available sets include `u-2`, ..., `u-5` (four other development splits)