MCPcopy Create free account
hub / github.com/apple/axlearn / map_source

Method map_source

axlearn/common/input_grain_test.py:406–411  ·  view source on GitHub ↗
(dispatch_config)

Source from the content-addressed store, hash-verified

404
405 # Test against map ds.
406 def map_source(dispatch_config):
407 map_ds = fake_grain_source(list(range(10)))
408 map_ds = map_ds.map(lambda x: x + 1)
409 return per_feed_batch(
410 map_ds, global_batch_size=10, dispatch_config=dispatch_config, drop_remainder=False
411 )
412
413 # Configure dispatch.
414 cfg = Input.default_config().set(source=map_source, input_dispatcher=input_dispatcher)

Callers

nothing calls this directly

Calls 3

fake_grain_sourceFunction · 0.90
per_feed_batchFunction · 0.90
mapMethod · 0.80

Tested by

no test coverage detected