nshaud/DeepHyperX

Parallelize data loading

nshaud opened this issue · 0 comments

Currently, the torch DataLoader uses blocking data loading. Although loading is very fast (we store the NumPy arrays in-memory), transfer to GPU and data augmentation (which is done on CPU) can slow things done.

Using workers > 0 would make data loading asynchronous and workers > 1 could increase speed somewhat.

TODO:

  • Benchmark speed gain using asynchronous data loading
  • Implement asynchronous data loading for all DataLoader objects
  • Add a user-input option to define the number of jobs