![]() |
Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
|
The Pipeline class represents an execution pipeline. More...

Public Member Functions | |
| PipelineExecutor (ClientContext &context, Pipeline &pipeline) | |
| PipelineExecuteResult | Execute () |
| Fully execute a pipeline with a source and a sink until the source is completely exhausted. | |
| PipelineExecuteResult | Execute (idx_t max_chunks) |
| PipelineExecuteResult | PushFinalize () |
| bool | RemainingSinkChunk () const |
| void | InitializeChunk (DataChunk &chunk) |
| Initializes a chunk with the types that will flow out of the chunk. | |
| void | SetTaskForInterrupts (weak_ptr< Task > current_task) |
| Registers the task in the interrupt_state to allow Source/Sink operators to block the task. | |
Private Member Functions | |
| void | StartOperator (PhysicalOperator &op) |
| void | EndOperator (PhysicalOperator &op, optional_ptr< DataChunk > chunk) |
| void | GoToSource (idx_t ¤t_idx, idx_t initial_idx) |
| Reset the operator index to the first operator. | |
| SourceResultType | FetchFromSource (DataChunk &result) |
| void | FinishProcessing (int32_t operator_idx=-1) |
| bool | IsFinished () |
| SourceResultType | GetData (DataChunk &chunk, OperatorSourceInput &input) |
| Wrappers for sink/source calls to respective operators. | |
| SinkResultType | Sink (DataChunk &chunk, OperatorSinkInput &input) |
| OperatorResultType | ExecutePushInternal (DataChunk &input, ExecutionBudget &chunk_budget, idx_t initial_idx=0) |
| OperatorResultType | Execute (DataChunk &input, DataChunk &result, idx_t initial_index=0) |
| SinkNextBatchType | NextBatch (DataChunk &source_chunk, const bool have_more_output) |
| Notifies the sink that a new batch has started. | |
| bool | TryFlushCachingOperators (ExecutionBudget &chunk_budget) |
| void | CacheChunk (DataChunk &input, idx_t operator_idx) |
Static Private Member Functions | |
| static bool | CanCacheType (const LogicalType &type) |
Private Attributes | |
| Pipeline & | pipeline |
| The pipeline to process. | |
| ThreadContext | thread |
| The thread context of this executor. | |
| ExecutionContext | context |
| The total execution context of this executor. | |
| vector< unique_ptr< DataChunk > > | intermediate_chunks |
| Intermediate chunks for the operators. | |
| vector< unique_ptr< OperatorState > > | intermediate_states |
| Intermediate states for the operators. | |
| unique_ptr< LocalSourceState > | local_source_state |
| The local source state. | |
| unique_ptr< LocalSinkState > | local_sink_state |
| The local sink state (if any). | |
| InterruptState | interrupt_state |
| The interrupt state, holding required information for sink/source operators to block. | |
| DataChunk | final_chunk |
| The final chunk used for moving data into the sink. | |
| stack< idx_t > | in_process_operators |
| bool | finalized = false |
| Whether or not the pipeline has been finalized (used for verification only). | |
| int32_t | finished_processing_idx = -1 |
| Whether or not the pipeline has finished processing. | |
| OperatorPartitionInfo | required_partition_info |
| Partition info that is used by this executor. | |
| bool | exhausted_pipeline = false |
| Source or intermediate operator indicated that there is no more output possible. | |
| bool | started_flushing = false |
| Flushing of intermediate operators has started. | |
| bool | done_flushing = false |
| Flushing of caching operators is done. | |
| bool | remaining_sink_chunk = false |
| This flag is set when the pipeline gets interrupted by the Sink -> the final_chunk should be re-sink-ed. | |
| bool | next_batch_blocked = false |
| idx_t | flushing_idx |
| Current operator being flushed. | |
| bool | should_flush_current_idx = true |
| Whether the current flushing_idx should be flushed: this needs to be stored to make flushing code re-entrant. | |
The Pipeline class represents an execution pipeline.
| duckdb::PipelineExecutor::PipelineExecutor | ( | ClientContext & | context, |
| Pipeline & | pipeline ) |
| PipelineExecuteResult duckdb::PipelineExecutor::Execute | ( | ) |
Fully execute a pipeline with a source and a sink until the source is completely exhausted.


| PipelineExecuteResult duckdb::PipelineExecutor::Execute | ( | idx_t | max_chunks | ) |
Execute a pipeline with a source and a sink until finished, or until max_chunks were processed from the source Returns true if execution is finished, false if Execute should be called again

| PipelineExecuteResult duckdb::PipelineExecutor::PushFinalize | ( | ) |
Called after depleting the source: finalizes the execution of this pipeline executor This should only be called once per PipelineExecutor.

| bool duckdb::PipelineExecutor::RemainingSinkChunk | ( | ) | const |
| void duckdb::PipelineExecutor::InitializeChunk | ( | DataChunk & | chunk | ) |
Initializes a chunk with the types that will flow out of the chunk.

Registers the task in the interrupt_state to allow Source/Sink operators to block the task.
Execute a pipeline without a sink, and retrieve a single DataChunk Returns an empty chunk when finished.
|
private |
|
private |
Reset the operator index to the first operator.

|
private |
|
private |
|
private |
|
private |
Wrappers for sink/source calls to respective operators.
Testing feature to enable async source on every operator
|
private |
Testing feature to enable async sink on every operator
|
private |
|
private |
Pushes a chunk through the pipeline and returns a single result chunk Returns whether or not a new input chunk is needed, or whether or not we are finished

|
private |
Notifies the sink that a new batch has started.

|
private |
Tries to flush all state from intermediate operators. Will return true if all state is flushed, false in the case of a blocked sink.

|
private |
The operators that are not yet finished executing and have data remaining If the stack of in_process_operators is empty, we fetch from the source instead
|
private |
This flag is set when the pipeline gets interrupted by NextBatch -> NextBatch should be called again and the source_chunk should be sent through the pipeline