


fut = torch.futures.Future()
         >>> # The inserted callback will print the return value when
         >>> # receiving the response from "worker1"
         >>> cb_fut = fut.then(callback)
         >>> chain_cb_fut = cb_fut.then(
         ...     lambda x : print(f"Chained cb done. {x.wait()}")
         ... )
         >>> fut.set_result(5)
         RPC return value is 5.
         Chained cb done. None



value()
  Obtain the value of an already-completed future.

  This method should only be called after a call to "wait()" has
  completed, or inside a callback function passed to "then()". In
  other cases this "Future" may not yet hold a value and calling
  "value()" could fail.

  If the value contains tensors that reside on GPUs, then this
  method will *not* perform any additional synchronization. This
  should be done beforehand, separately, through a call to
  "wait()" (except within callbacks, for which it's already being
