From cec82e028586ef8e5dc40e5fe4f55f59f51f399a Mon Sep 17 00:00:00 2001 From: Daria Tikhonovich Date: Wed, 4 Oct 2023 17:02:46 +0300 Subject: [PATCH] fixed coverage --- rectools/models/implicit_als.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rectools/models/implicit_als.py b/rectools/models/implicit_als.py index 048bfdf7..0fe4259b 100644 --- a/rectools/models/implicit_als.py +++ b/rectools/models/implicit_als.py @@ -82,7 +82,7 @@ def _fit(self, dataset: Dataset) -> None: # type: ignore self.verbose, ) - if self.use_gpu: + if self.use_gpu: # pragma: no cover user_factors = implicit.gpu.Matrix(user_factors) item_factors = implicit.gpu.Matrix(item_factors) @@ -124,7 +124,7 @@ def get_users_vectors(model: AnyAlternatingLeastSquares) -> np.ndarray: np.ndarray User vectors """ - if isinstance(model, GPUAlternatingLeastSquares): + if isinstance(model, GPUAlternatingLeastSquares): # pragma: no cover return model.user_factors.to_numpy() return model.user_factors @@ -143,7 +143,7 @@ def get_items_vectors(model: AnyAlternatingLeastSquares) -> np.ndarray: np.ndarray Item vectors """ - if isinstance(model, GPUAlternatingLeastSquares): + if isinstance(model, GPUAlternatingLeastSquares): # pragma: no cover return model.item_factors.to_numpy() return model.item_factors