Skip to main content

PartitionedTextExecution

Struct PartitionedTextExecution 

Source
pub struct PartitionedTextExecution<E, G, R, I, T, U, V>(/* private fields */);
Expand description

Stateless strategy marker selecting PartitionedTextRuntime in the shared session.

Implementations§

Source§

impl<E, G, R, I, T, U, V> PartitionedTextExecution<E, G, R, I, T, U, V>

Source

pub const fn new() -> Self

Creates the statically dispatched partition strategy.

Trait Implementations§

Source§

impl<E, G, R, I, T, U, V> Default for PartitionedTextExecution<E, G, R, I, T, U, V>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<A, B, S, Resident, Bounded, E, G, R, I, T, U, V> ReplicatedTextExecutionStrategy<A, B, S, Resident, Bounded> for PartitionedTextExecution<E, G, R, I, T, U, V>
where B: CommunicationBackend, S: RuntimeState<B>, A: LayeredArchitecture<B, S>, Resident: LayerwisePolicy<B, A::Unit>, Bounded: LayerwisePolicy<B, A::Unit, Error = Resident::Error>, E: PartitionedGroupExecutor<A, B, S, G, R, I>, G: Borrow<B::CommunicationGroup>, R: Borrow<B::CommunicationRoute>, I: CommunicationTensorMetadata<B>, T: PartitionBoundaryTransport<B, G, R, I>, U: PartitionOutputPublisher<B, G, R, I>, V: PartitionCommitAgreement<B, G, R, I>, A::Error: Display, Resident::Error: Display,

Source§

const PARTITIONED_SESSION: bool = true

Whether this strategy executes one rank of a partitioned session.
Source§

const DISTRIBUTED_PHASE_AGREEMENT: bool = V::PHASE_FAILURE_AGREEMENT

Whether control phases use a selected bounded all-rank agreement.
Source§

type Runtime = PartitionedTextRuntime<A, B, S, Bounded, E, G, R, I, T, U, V>

Concrete execution runtime paired before the shared session lifecycle begins.
Source§

fn bounded_policy(runtime: &Self::Runtime) -> Option<&Bounded>

Returns bounded residency state for the shared session report.
Source§

fn execution_residency( runtime: &Self::Runtime, _selected: &SelectedReplicatedTextRealization, ) -> ExecutionResidency

Returns the execution residency actually installed on this rank.
Source§

fn forward_with_observer<'a, O>( &mut self, runtime: &mut Self::Runtime, input: A::Input<'a>, state: &mut S, pass_kind: ExpertPass, context: &<B::Tensor as Tensor>::Context, observer: &mut O, ) -> Result<(B::Tensor, A::ForwardContext), ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>
where O: ActivationObserver<B::Tensor, A::Error> + ?Sized,

Executes one complete layered pass through the selected unit strategy.
Source§

fn observe_output<O>( runtime: &mut Self::Runtime, output: &B::Tensor, observer: &mut O, _context: &<B::Tensor as Tensor>::Context, ) -> Result<B::Tensor, ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>
where O: ActivationObserver<B::Tensor, A::Error> + ?Sized,

Applies the architecture’s final-logits observation on the rank that owns the authoritative output. Ordinary replicated strategies observe locally; partitioned strategies may suppress the seam on destinations.
Source§

fn publish_observed_output( runtime: &mut Self::Runtime, output: B::Tensor, _context: &<B::Tensor as Tensor>::Context, ) -> Result<B::Tensor, ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>

Publishes an already-observed authoritative output after every rank has agreed that final observation succeeded.
Source§

fn prediction_target_capture( runtime: &mut Self::Runtime, forward: &A::ForwardContext, context: &<B::Tensor as Tensor>::Context, ) -> Result<Option<B::Tensor>, ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>

Resolves the rank-local tensor used by an additive prediction extension. Read more
Source§

fn publish_prediction_target_capture( runtime: &mut Self::Runtime, capture: B::Tensor, _context: &<B::Tensor as Tensor>::Context, ) -> Result<B::Tensor, ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>

Publishes the output-owner capture to every prediction participant.
Source§

fn apply_prediction_target_operation<O>( runtime: &mut Self::Runtime, state: &mut S, operation: O, context: &<B::Tensor as Tensor>::Context, ) -> Result<Option<O::Output>, ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>
where O: PredictionTargetOperation<A, B, S>,

Runs one typed prediction-only operation against session-owned target modules and state.
Source§

fn commit_after_completion( runtime: &mut Self::Runtime, epoch: DistributedCommitEpoch, _context: &<B::Tensor as Tensor>::Context, ) -> DistributedCommitOutcome

Performs strategy-specific distributed commit only after output intervention and exact mechanism completion have succeeded.
Source§

fn agree_distributed_phase( runtime: &mut Self::Runtime, phase: DistributedExecutionPhase, local_success: bool, _context: &<B::Tensor as Tensor>::Context, ) -> Result<bool, ReplicatedTextSessionError<A::Error, Resident::Error, Infallible>>

Propagates one local shared-session phase result before the lifecycle can advance. Direct and unsupported strategies retain the local result.

Auto Trait Implementations§

§

impl<E, G, R, I, T, U, V> Freeze for PartitionedTextExecution<E, G, R, I, T, U, V>

§

impl<E, G, R, I, T, U, V> RefUnwindSafe for PartitionedTextExecution<E, G, R, I, T, U, V>

§

impl<E, G, R, I, T, U, V> Send for PartitionedTextExecution<E, G, R, I, T, U, V>

§

impl<E, G, R, I, T, U, V> Sync for PartitionedTextExecution<E, G, R, I, T, U, V>

§

impl<E, G, R, I, T, U, V> Unpin for PartitionedTextExecution<E, G, R, I, T, U, V>

§

impl<E, G, R, I, T, U, V> UnsafeUnpin for PartitionedTextExecution<E, G, R, I, T, U, V>

§

impl<E, G, R, I, T, U, V> UnwindSafe for PartitionedTextExecution<E, G, R, I, T, U, V>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.