# -*- encoding = gb18030 -*- # package importing start import os import sys sys.path.append(os.path.abspath(os.path.dirname(__file__) + '/../..')) from bowlr.run import Corpus # package importing end # run this script train_path = sys.argv[1] test_path = sys.argv[2] train_set = sys.argv[3] test_set = sys.argv[4] output_path = sys.argv[5] corpus = Corpus() corpus.run_classify(train_path, test_path, train_set, test_set, output_path)
# -*- encoding = gb18030 -*- # package importing start import os import sys sys.path.append(os.path.abspath(os.path.dirname(__file__) + '/../..')) from bowlr.run import Corpus # package importing end # run this script article_market_path = sys.argv[1] dictionary_path = sys.argv[2] dict_set = sys.argv[3] corpus = Corpus() corpus.run_create_dictionary(article_market_path, dictionary_path, dict_set)
# -*- encoding = gb18030 -*- # package importing start import os import sys sys.path.append(os.path.abspath(os.path.dirname(__file__) + '/../..')) from bowlr.run import Corpus # package importing end # run this script article_market_path = sys.argv[1] dictionary_path = sys.argv[2] feature_market_path = sys.argv[3] corpus = Corpus() corpus.run_feature_select(article_market_path, dictionary_path, feature_market_path)