Skip to content

Commit

Permalink
iter
Browse files Browse the repository at this point in the history
  • Loading branch information
glemaitre committed Apr 19, 2024
1 parent 87ed6e9 commit 723c57c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ragger_duck/embedding/_sentence_transformer.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import time

from sentence_transformers import SentenceTransformer as SentenceTransformerBase
from sklearn.base import BaseEstimator, TransformerMixin
from sklearn.base import BaseEstimator, TransformerMixin, _fit_context

logger = logging.getLogger(__name__)

Expand Down Expand Up @@ -71,6 +71,7 @@ def __init__(
self.batch_size = batch_size
self.show_progress_bar = show_progress_bar

@_fit_context(prefer_skip_nested_validation=False)
def fit(self, X=None, y=None):
"""No-op operation, only validate parameters.
Expand All @@ -87,7 +88,6 @@ def fit(self, X=None, y=None):
self
The fitted estimator.
"""
self._validate_params()
self._embedding = SentenceTransformerBase(
model_name_or_path=self.model_name_or_path,
modules=self.modules,
Expand Down

0 comments on commit 723c57c

Please sign in to comment.