ML Training is often bottenecked at the dataloader stage.
create_worker_cache
function. This enables caching of a dataset to local SSD, which has significantly faster read speeds versus network.
create_worker_cache
allows users to cache the directory on the worker node. It looks at the src directory, and caches this directory on the worker_cache if it doesn’t exist and there is enough space on the cache (shouldn’t exceed 80% after the directory is cached). It returns the path to the directory on the worker_cache.
Users just need to replace the returned directory with the original data_dir
in the dataloader.
Users just need to replace the returned directory with the original data_dir
in the dataloader.
create_worker_cache
should be called only for the worker task.