class_docstr: Wrapper around a ``torch._C.Future`` which encapsulates an asynchronous
  execution of a callable, e.g. :meth:`~torch.distributed.rpc.rpc_async`. It
  also exposes a set of APIs to add callback functions and set results.
  
  .. warning:: GPU support is a beta feature, subject to changes.
class_docstr_tok: ["Wrapper","around","a","``","torch._C.Future","``","which","encapsulates","an","asynchronous","execution","of","a","callable",",","e.g",".",":","meth",":","`","~torch.distributed.rpc.rpc_async","`",".","It","also","exposes","a","set","of","APIs","to","add","callback","functions","and","set","results",".","..","warning",":",":","GPU","support","is","a","beta","feature",",","subject","to","changes","."]
docstr: Obtain the value of an already-completed future.
  
  This method should only be called after a call to :meth:`wait` has
  completed, or inside a callback function passed to :meth:`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 :meth:`wait` (except within
  callbacks, for which it's already being taken care of by :meth:`then`).
  
  Returns:
      The value held by this ``Future``. If the function (callback or RPC)
      creating the value has thrown an error, this ``value()`` method will
      also throw an error.
docstr_tok: ["Obtain","the","value","of","an","already-completed","future",".","This","method","should","only","be","called","after","a","call","to",":","meth",":","`","wait","`","has","completed",",","or","inside","a","callback","function","passed","to",":","meth",":","`","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",":","meth",":","`","wait","`","(","except","within","callbacks",",","for","which","it","'s","already","being","taken","care","of","by",":","meth",":","`","then","`",")",".","Returns",":","The","value","held","by","this","``","Future","``",".","If","the","function","(","callback","or","RPC",")","creating","the","value","has","thrown","an","error",",","this","``","value","(",")","``","method","will","also","throw","an","error","."]
code: def value(self) -> T:
      r"""
      Obtain the value of an already-completed future.
  
      This method should only be called after a call to :meth:`wait` has
      completed, or inside a callback function passed to :meth:`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 :meth:`wait` (except within
      callbacks, for which it's already being taken care of by :meth:`then`).
  
      Returns:
          The value held by this ``Future``. If the function (callback or RPC)
          creating the value has thrown an error, this ``value()`` method will
          also throw an error.
      """
      return super().value()
  
file_path: pytorch/torch/futures/__init__.py
imports: from __future__ import annotations
  from typing import cast, Callable, Generic, List, Optional, Type, TypeVar, Union
  import torch
label_desc: Use image node_id 4 for calling the Future obj's underlying member method code with example usage: obj.value() and returns: super