From b9dd9c0be9f4e030bb9abc7f17a9217104ddd644 Mon Sep 17 00:00:00 2001 From: Franck Dary <franck.dary@lis-lab.fr> Date: Mon, 17 Feb 2020 10:28:47 +0100 Subject: [PATCH] Removed Default qualifier for transitions --- UD_any/data/Makefile | 3 +-- UD_any/data/getTransitionSets.py | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/UD_any/data/Makefile b/UD_any/data/Makefile index 5badd10..9fb308c 100644 --- a/UD_any/data/Makefile +++ b/UD_any/data/Makefile @@ -22,7 +22,7 @@ all_no_test.conllu: cat $(TRAIN_FILES) > $@ tokenizer.ts: all_no_test.conllu $(MCD) - echo "Default : IGNORECHAR" > $@ + echo "IGNORECHAR" > $@ $(SCRIPTS)/conllu2splits.py $< $(MCD) >> $@ 2> ambiguities.txt echo "ENDWORD" >> $@ echo "ADDCHARTOWORD" >> $@ @@ -45,7 +45,6 @@ $(FPLM_FILENAME): all_no_test.conllu $(MCD) $(RULES_FILENAME): $(FPLM_FILENAME) macaon_compute_l_rules -f $(FPLM_FILENAME) -e $(EXCEPTIONS_FPLM_FILENAME) -r tmp.txt -t $(THRESHOLD) - cat tmp.txt | sed s/^/RULE\ LEMMA\ ON\ FORM\ /g | sed s/RULE\ LEMMA\ ON\ FORM\ @@$$/Default\ :\ \ RULE\ LEMMA\ ON\ FORM\ @@/g > $@ rm tmp.txt echo -e "Default : NOTHING\nTOLOWER b.0 LEMMA\nTOUPPER b.0 LEMMA" > lemmatizer_case.ts diff --git a/UD_any/data/getTransitionSets.py b/UD_any/data/getTransitionSets.py index 4a057d3..1ee4d74 100755 --- a/UD_any/data/getTransitionSets.py +++ b/UD_any/data/getTransitionSets.py @@ -66,7 +66,7 @@ if __name__ == "__main__" : allPartsList.sort() for part in allPartsList : print("ADD b.0 FEATS " + part, file=output) - print("Default : NOTHING", file=output) + print("NOTHING", file=output) output.close() elif nameCol == "DEPREL" : @@ -87,7 +87,7 @@ if __name__ == "__main__" : print("LEFT " + label, file=output) print("RIGHT " + label, file=output) print("EOS s.0", file=output) - print("Default : SHIFT", file=output) + print("SHIFT", file=output) output.close() output = open("parser.ts", 'w', encoding='utf-8') print("REDUCE", file=output) @@ -105,6 +105,6 @@ if __name__ == "__main__" : for label in labelsList : print("LEFT " + label, file=output) print("RIGHT " + label, file=output) - print("Default : SHIFT", file=output) + print("SHIFT", file=output) output.close() -- GitLab