Trait TrainingSource

Source
pub trait TrainingSource: Send {
    // Required methods
    fn scan_ordered_chunks<'async_trait>(
        self: Box<Self>,
        chunk_size: u32,
    ) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream>> + Send + 'async_trait>>
       where Self: 'async_trait;
    fn scan_unordered_chunks<'async_trait>(
        self: Box<Self>,
        chunk_size: u32,
    ) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream>> + Send + 'async_trait>>
       where Self: 'async_trait;
}

Required Methods§

Source

fn scan_ordered_chunks<'async_trait>( self: Box<Self>, chunk_size: u32, ) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream>> + Send + 'async_trait>>
where Self: 'async_trait,

Returns a stream of batches, ordered by the value column (in ascending order)

Each batch should have chunk_size rows

The schema for the batch is slightly flexible. The first column may have any name or type, these are the values to index The second column must be the row ids which must be UInt64Type

Source

fn scan_unordered_chunks<'async_trait>( self: Box<Self>, chunk_size: u32, ) -> Pin<Box<dyn Future<Output = Result<SendableRecordBatchStream>> + Send + 'async_trait>>
where Self: 'async_trait,

Returns a stream of batches

Each batch should have chunk_size rows

The schema for the batch is slightly flexible. The first column may have any name or type, these are the values to index The second column must be the row ids which must be UInt64Type

Implementors§