@@ -171,8 +171,8 @@ def test_predict_loop_single_output(self):
171171 with patch ("im2deep._model_ops.track" , return_value = mock_data ):
172172 predictions = _model_ops ._predict_loop (
173173 model = model ,
174- data_loader = mock_data ,
175- device = "cpu" , # type: ignore
174+ data_loader = mock_data , # type: ignore[unknown-arg]
175+ device = "cpu" ,
176176 )
177177
178178 assert isinstance (predictions , torch .Tensor )
@@ -194,8 +194,8 @@ def test_predict_loop_multi_output(self):
194194 with patch ("im2deep._model_ops.track" , return_value = mock_data ):
195195 predictions = _model_ops ._predict_loop (
196196 model = model ,
197- data_loader = mock_data ,
198- device = "cpu" , # type: ignore
197+ data_loader = mock_data , # type: ignore[unknown-arg]
198+ device = "cpu" ,
199199 )
200200
201201 assert isinstance (predictions , torch .Tensor )
@@ -217,8 +217,8 @@ def test_predict_loop_no_grad(self):
217217 with patch ("im2deep._model_ops.track" , return_value = mock_data ):
218218 predictions = _model_ops ._predict_loop (
219219 model = model ,
220- data_loader = mock_data ,
221- device = "cpu" , # type: ignore
220+ data_loader = mock_data , # type: ignore[unknown-arg]
221+ device = "cpu" ,
222222 )
223223
224224 assert not predictions .requires_grad
@@ -262,7 +262,7 @@ class TestGetLossFunction:
262262 def test_get_loss_function_single (self ):
263263 """Test getting single-output loss function."""
264264 loss = _model_ops ._get_loss_function (multi = False )
265- assert isinstance (loss , torch .nn .modules .loss ._Loss )
265+ assert isinstance (loss , torch .nn .modules .loss ._Loss ) # type: ignore[unresolved-attr]
266266
267267 @patch ("im2deep._model_ops.FlexibleLossSorted" )
268268 def test_get_loss_function_multi (self , mock_loss ):
0 commit comments