Shortcuts

CacheTimeout

class torchdata.dataloader2.adapter.CacheTimeout(timeout=None)

CacheTimeout DataPipes adapter allows control over timeouts of all existing EndOnDiskCacheHolder (end_caching) in the graph. Useful when cached pipeline takes too long to execute (ex. slow file downloading).

Parameters:

timeout – int - amount of seconds parallel processes will wait for cached files to appear.

Example

>>>  dl = DataLoader2(dp, [CacheTimeout(600)])

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources