MCPcopy Create free account
hub / github.com/Oneflow-Inc/oneflow / create_fetcher

Method create_fetcher

python/oneflow/utils/data/dataloader.py:67–75  ·  view source on GitHub ↗
(kind, dataset, auto_collation, collate_fn, drop_last)

Source from the content-addressed store, hash-verified

65
66 @staticmethod
67 def create_fetcher(kind, dataset, auto_collation, collate_fn, drop_last):
68 if kind == _DatasetKind.Map:
69 return _utils.fetch._MapDatasetFetcher(
70 dataset, auto_collation, collate_fn, drop_last
71 )
72 else:
73 return _utils.fetch._IterableDatasetFetcher(
74 dataset, auto_collation, collate_fn, drop_last
75 )
76
77
78class _InfiniteConstantSampler(Sampler):

Callers 2

__init__Method · 0.80
_worker_loopFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected