Skip to main content

AsyncPlasticityExecutor

Struct AsyncPlasticityExecutor 

Source
pub struct AsyncPlasticityExecutor { /* private fields */ }
Expand description

Async plasticity executor for std environments

Runs plasticity computation in a background thread, allowing the burst loop to continue processing while patterns are detected and memory neurons created.

This is optimal for CPU/GPU backends where:

  • FireLedger is CPU-resident
  • Plasticity computation can overlap with GPU burst processing
  • Thread overhead is acceptable

Implementations§

Source§

impl AsyncPlasticityExecutor

Source

pub fn new( config: PlasticityConfig, memory_stats_cache: MemoryStatsCache, npu: Arc<TracingMutex<DynamicNPU>>, ) -> Self

Create a new async plasticity executor

Source

pub fn get_memory_stats_cache(&self) -> MemoryStatsCache

Get the memory stats cache

Source

pub fn enqueue_commands_for_test(&self, commands: Vec<PlasticityCommand>)

Trait Implementations§

Source§

impl PlasticityExecutor for AsyncPlasticityExecutor

Source§

fn notify_burst(&self, timestep: u64)

Notify the executor of a completed burst Read more
Source§

fn drain_commands(&self) -> Vec<PlasticityCommand>

Drain pending commands from the executor Read more
Source§

fn register_memory_area( &self, area_idx: u32, area_name: String, temporal_depth: u32, upstream_areas: Vec<u32>, lifecycle_config: Option<MemoryNeuronLifecycleConfig>, )

Register a memory area with the plasticity system Read more
Source§

fn start(&mut self)

Start the executor (for async implementations) Read more
Source§

fn stop(&mut self)

Stop the executor (for async implementations) Read more
Source§

fn is_running(&self) -> bool

Check if the executor is running

Auto Trait Implementations§

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<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

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

Source§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more