diff --git a/TweetSentQuant/experiments.py b/TweetSentQuant/experiments.py index 5867255..e31d15e 100644 --- a/TweetSentQuant/experiments.py +++ b/TweetSentQuant/experiments.py @@ -16,9 +16,7 @@ import argparse import torch import shutil - -DEBUG = False - +qp.environ['SAMPLE_SIZE'] = settings.SAMPLE_SIZE def newLR(): return LogisticRegression(max_iter=1000, solver='lbfgs', n_jobs=-1) @@ -118,8 +116,6 @@ def save_results(dataset_name, model_name, optim_loss, *results): def run(experiment): - qp.environ['SAMPLE_SIZE'] = settings.SAMPLE_SIZE - optim_loss, dataset_name, (model_name, model, hyperparams) = experiment if is_already_computed(dataset_name, model_name, optim_loss=optim_loss): diff --git a/TweetSentQuant/gen_tables.py b/TweetSentQuant/gen_tables.py index 16dadee..b68b733 100644 --- a/TweetSentQuant/gen_tables.py +++ b/TweetSentQuant/gen_tables.py @@ -33,6 +33,7 @@ nice = { 'hdy': 'HDy', 'dys': 'DyS', 'epaccmaeptr': 'E(PACC)$_\mathrm{Ptr}$', + 'epaccmaemae': 'E(PACC)$_\mathrm{AE}$', 'svmperf':'', 'sanders': 'Sanders', 'semeval13': 'SemEval13', @@ -117,7 +118,7 @@ if __name__ == '__main__': datasets = qp.datasets.TWITTER_SENTIMENT_DATASETS_TEST evaluation_measures = [qp.error.ae, qp.error.rae] gao_seb_methods = ['cc', 'acc', 'pcc', 'pacc', 'sld', 'svmq', 'svmkld', 'svmnkld'] - new_methods = ['hdy', 'quanet', 'epaccptr'] + new_methods = ['hdy', 'quanet', 'epaccmaeptr', 'epaccmaemae'] gao_seb_ranks, gao_seb_results = get_ranks_from_Gao_Sebastiani() diff --git a/quapy/method/aggregative.py b/quapy/method/aggregative.py index 0053767..850a141 100644 --- a/quapy/method/aggregative.py +++ b/quapy/method/aggregative.py @@ -367,7 +367,8 @@ class EMQ(AggregativeProbabilisticQuantifier): s += 1 if not converged: - raise UserWarning('the method has reached the maximum number of iterations; it might have not converged') + #raise UserWarning('the method has reached the maximum number of iterations; it might have not converged') + print('[warning] the method has reached the maximum number of iterations; it might have not converged') return qs, ps