Skip to content

Commit

Permalink
#443 update, fixed bugs. #469 proof of already considered support.
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolay-r committed May 16, 2023
1 parent 3df53c1 commit 65bf617
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion arekit/common/opinions/annot/algo_based.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def _annot_collection_core(self, parsed_news):
assert(isinstance(parsed_news, ParsedNews))

opinions = self.__get_existed_opinions_func(parsed_news.RelatedDocID)
assert(isinstance(opinions, OpinionCollection))
assert(isinstance(opinions, OpinionCollection) or opinions is None)

annotated_opinions_it = self.__annot_algo.iter_opinions(
parsed_news=parsed_news, existed_opinions=opinions)
Expand Down
2 changes: 1 addition & 1 deletion arekit/contrib/bert/input/providers/cropped_sample.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ def __init__(self, crop_window_size, label_scaler, text_terms_mapper, text_b_tem

super(CroppedBertSampleRowProvider, self).__init__(
crop_window_size=crop_window_size,
label_scaler=MultipleLabelProvider(label_scaler),
label_scaler=label_scaler,
text_provider=text_provider)
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from os.path import join, dirname

from arekit.common.experiment.api.ops_doc import DocumentOperations
from arekit.common.experiment.data_type import DataType
from arekit.common.labels.base import NoLabel
Expand All @@ -11,7 +9,6 @@
from arekit.common.text.parser import BaseTextParser
from arekit.contrib.source.sentinerel.io_utils import SentiNerelVersions, SentiNerelIOUtils
from arekit.contrib.utils.pipelines.sources.sentinerel.doc_ops import SentiNERELDocOperation
from arekit.contrib.utils.pipelines.sources.sentinerel.entity_filter import SentiNerelEntityFilter
from arekit.contrib.utils.pipelines.sources.sentinerel.labels_fmt import SentiNERELSentimentLabelFormatter
from arekit.contrib.utils.pipelines.text_opinion.annot.algo_based import AlgorithmBasedTextOpinionAnnotator
from arekit.contrib.utils.pipelines.text_opinion.annot.predefined import PredefinedTextOpinionAnnotator
Expand All @@ -31,7 +28,7 @@ def create_text_opinion_extraction_pipeline(sentinerel_version,
doc_ops=None,
dist_in_sentences=0,
docs_limit=None,
entity_filter=SentiNerelEntityFilter()):
entity_filter=None):
""" This is a main pipeline which generates the samples for a SentiNEREL documents.
SentiNEREL is a collection that becomes a part of the:
1. Attitude extraction studies (AREkit focused studies):
Expand Down

0 comments on commit 65bf617

Please sign in to comment.