code: def done(self):
          
          return (not hasattr(self, '_future')) or (not hasattr(self._future, 'done')) or self._future.done()
docs: Return True if a pending computation is done.
  
          Used when a :class:`SampleSet` is constructed with :meth:`SampleSet.from_future`.
  
          Examples:
              This example uses a :class:`~concurrent.futures.Future` object directly. Typically
              a :class:`~concurrent.futures.Executor` sets the result of the future
              (see documentation for :mod:`concurrent.futures`).
  
              >>> import dimod
              >>> from concurrent.futures import Future
              ...
              >>> future = Future()
              >>> sampleset = dimod.SampleSet.from_future(future)
              >>> future.done()
              False
              >>> future.set_result(dimod.ExactSolver().sample_ising({0: -1}, {}))
              >>> future.done()
              True
              >>> sampleset.record.sample
              array([[-1],
                     [ 1]], dtype=int8)