DatasetLoader

Trait DatasetLoader 

Source
pub trait DatasetLoader<T> {
    type Error: Error + Send + Sync + 'static;

    // Required methods
    fn load<'life0, 'async_trait>(
        &'life0 self,
        source: T,
    ) -> Pin<Box<dyn Future<Output = Result<Dataset, Self::Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn load_with_preprocessing<'life0, 'life1, 'async_trait>(
        &'life0 self,
        source: T,
        preprocessing: &'life1 PreprocessingConfig,
    ) -> Pin<Box<dyn Future<Output = Result<Dataset, Self::Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

Async trait for dataset loading operations

Required Associated Types§

Source

type Error: Error + Send + Sync + 'static

Required Methods§

Source

fn load<'life0, 'async_trait>( &'life0 self, source: T, ) -> Pin<Box<dyn Future<Output = Result<Dataset, Self::Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Load a dataset from the given source

Source

fn load_with_preprocessing<'life0, 'life1, 'async_trait>( &'life0 self, source: T, preprocessing: &'life1 PreprocessingConfig, ) -> Pin<Box<dyn Future<Output = Result<Dataset, Self::Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Load a dataset with custom preprocessing options

Implementors§