Class ParallelBatchLoaderConfig
Configuration for parallel batch loading.
public class ParallelBatchLoaderConfig
- Inheritance
-
ParallelBatchLoaderConfig
- Inherited Members
Properties
NumWorkers
Gets or sets the number of worker threads.
public int NumWorkers { get; set; }
Property Value
Remarks
More workers can improve throughput but use more CPU and memory. Recommended: 2-8 workers depending on CPU cores and batch preparation time.
PersistentWorkers
Gets or sets whether to use persistent workers that stay alive between epochs.
public bool PersistentWorkers { get; set; }
Property Value
Remarks
Persistent workers avoid thread creation overhead but use more memory.
PinMemory
Gets or sets whether to pin memory for faster CPU-to-GPU transfer.
public bool PinMemory { get; set; }
Property Value
Remarks
Only applicable when using GPU acceleration.
PrefetchCount
Gets or sets the number of batches to prefetch.
public int PrefetchCount { get; set; }
Property Value
Remarks
Higher prefetch counts reduce GPU idle time but increase memory usage. Recommended: 2-4 batches per worker.
WorkerTimeoutMs
Gets or sets the timeout for worker operations in milliseconds.
public int WorkerTimeoutMs { get; set; }