diff --git a/demo/semantic_role_labeling/api_train_v2.py b/demo/semantic_role_labeling/api_train_v2.py index c323046407f42804646b8d9f07f167344b992168..f9c1fa80dacf98a7beedf07885daf221d2481190 100644 --- a/demo/semantic_role_labeling/api_train_v2.py +++ b/demo/semantic_role_labeling/api_train_v2.py @@ -6,9 +6,6 @@ import paddle.v2.dataset.conll05 as conll05 import paddle.v2.evaluator as evaluator import paddle.v2 as paddle -logger = logging.getLogger('paddle') -logger.setLevel(logging.WARN) - word_dict, verb_dict, label_dict = conll05.get_dict() word_dict_len = len(word_dict) label_dict_len = len(label_dict) @@ -155,11 +152,6 @@ def main(is_predict=False): label=target, param_attr=paddle.attr.Param(name='crfw')) evaluator.sum(input=crf_dec) - evaluator.chunk( - input=crf_dec, - label=target, - chunk_scheme="IOB", - num_chunk_types=label_dict_len / 2) # create parameters parameters = paddle.parameters.create(crf_cost) @@ -250,4 +242,4 @@ def main(is_predict=False): if __name__ == '__main__': - main(is_predict=True) + main(is_predict=False)