Skip to main content

predict_batch_parallel

Function predict_batch_parallel 

Source
pub fn predict_batch_parallel(
    source: &(dyn ObservableEphemerisSource + Sync),
    requests: &[PredictRequest],
    options: PredictOptions,
) -> Vec<Result<PredictedObservables, ObservablesError>>
Expand description

Predict observables for many (satellite, receiver, epoch) requests, fanning the independent requests across a rayon thread pool.

Each request is evaluated by the same scalar predict kernel and the indexed parallel collect preserves input order, so element i is byte-for-byte identical to element i of predict_batch: the requests share no mutable state and a single predict is internally sequential, so throughput scales with cores while every value stays bit-exact. The source must be Sync because it is read concurrently from every worker.