66import uuid
77from typing import (
88 TYPE_CHECKING ,
9- Any ,
109 AsyncIterator ,
11- Coroutine ,
1210 Dict ,
1311 List ,
1412 Optional ,
@@ -190,7 +188,7 @@ async def get_load_async(host: str, port: int, timeout: float = 5) -> Optional[G
190188
191189async def get_loads_async (
192190 hosts_and_ports : Sequence [Tuple [str , int ]], * , timeout : float = 5
193- ) -> Sequence [Optional [GetLoadResult ]]:
191+ ) -> List [Optional [GetLoadResult ]]:
194192 """Retrieve load information from all servers that respond within a timeout.
195193
196194 Parameters
@@ -366,18 +364,18 @@ def __del__(self):
366364 del _privates [_id ]
367365 return
368366
369- def __call__ (self , * inputs : Sequence [np .ndarray ]) -> Sequence [np .ndarray ]:
367+ def __call__ (self , * inputs : Sequence [np .ndarray ]) -> List [np .ndarray ]:
370368 """Alias for ``.evaluate(*inputs)``."""
371369 return self .evaluate (* inputs )
372370
373- def evaluate (self , * inputs : Sequence [np .ndarray ], ** kwargs ) -> Sequence [np .ndarray ]:
371+ def evaluate (self , * inputs : Sequence [np .ndarray ], ** kwargs ) -> List [np .ndarray ]:
374372 loop = get_useful_event_loop ()
375373 eval_coro = self .evaluate_async (* inputs , ** kwargs )
376374 return loop .run_until_complete (eval_coro )
377375
378376 async def evaluate_async (
379377 self , * inputs : Sequence [np .ndarray ], use_stream : bool = True , retries : int = 2
380- ) -> Sequence [np .ndarray ]:
378+ ) -> List [np .ndarray ]:
381379 """Evaluate the federated compute function on inputs.
382380
383381 Parameters
@@ -390,8 +388,8 @@ async def evaluate_async(
390388
391389 Returns
392390 -------
393- * outputs
394- Sequence of ``ndarray``s returned by the federated compute function.
391+ outputs
392+ List of ``ndarray``s returned by the federated compute function.
395393 """
396394 if retries < 0 :
397395 raise ValueError ("Number of retries must be >= 0." )
0 commit comments