MCPcopy Index your code
hub / github.com/dmlc/dgl / _next_threaded

Method _next_threaded

python/dgl/dataloading/dataloader.py:693–707  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

691 return batch, feats, stream_event
692
693 def _next_threaded(self):
694 try:
695 batch, feats, stream_event, exception = self.queue.get(
696 timeout=prefetcher_timeout
697 )
698 except Empty:
699 raise RuntimeError(
700 f"Prefetcher thread timed out at {prefetcher_timeout} seconds."
701 )
702 if batch is None:
703 self.thread.join()
704 if exception is None:
705 raise StopIteration
706 exception.reraise()
707 return batch, feats, stream_event
708
709 def __next__(self):
710 batch, feats, stream_event = (

Callers 1

__next__Method · 0.95

Calls 3

reraiseMethod · 0.80
getMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected