pub struct CorticalArea {
pub cortical_id: CorticalID,
pub cortical_idx: u32,
pub name: String,
pub dimensions: CorticalAreaDimensions,
pub position: GenomeCoordinate3D,
pub cortical_type: CorticalAreaType,
pub properties: HashMap<String, Value>,
}Expand description
Cortical area metadata (genome representation)
Pure data structure containing static genome metadata. Runtime operations and transformations are implemented in feagi-bdu.
Fields§
§cortical_id: CorticalIDUnique typed cortical identifier
cortical_idx: u32Integer index assigned by ConnectomeManager
name: StringHuman-readable name
dimensions: CorticalAreaDimensions3D dimensions (width, height, depth in voxels)
position: GenomeCoordinate3D3D position in genome space
cortical_type: CorticalAreaTypeCortical area type (encoding method and functional classification)
properties: HashMap<String, Value>Additional user-defined properties Note: See PROPERTIES_STRUCT_MIGRATION_PROPOSAL.md for future struct-based design
Implementations§
Source§impl CorticalArea
impl CorticalArea
Sourcepub fn new(
cortical_id: CorticalID,
cortical_idx: u32,
name: String,
dimensions: CorticalAreaDimensions,
position: GenomeCoordinate3D,
cortical_type: CorticalAreaType,
) -> Result<CorticalArea, FeagiDataError>
pub fn new( cortical_id: CorticalID, cortical_idx: u32, name: String, dimensions: CorticalAreaDimensions, position: GenomeCoordinate3D, cortical_type: CorticalAreaType, ) -> Result<CorticalArea, FeagiDataError>
Create a new cortical area with validation
§Arguments
cortical_id- Unique typed cortical identifiercortical_idx- Integer index for fast lookupsname- Human-readable namedimensions- 3D dimensions (width, height, depth)position- 3D position in genome spacecortical_type- Cortical area type (encoding method)
§Errors
Returns error if name is empty
Sourcepub fn get_property(&self, key: &str) -> Option<&Value>
pub fn get_property(&self, key: &str) -> Option<&Value>
Get a property value by key
Sourcepub fn total_voxels(&self) -> u32
pub fn total_voxels(&self) -> u32
Get the total number of voxels in this area
Trait Implementations§
Source§impl Clone for CorticalArea
impl Clone for CorticalArea
Source§fn clone(&self) -> CorticalArea
fn clone(&self) -> CorticalArea
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl CorticalAreaExt for CorticalArea
impl CorticalAreaExt for CorticalArea
Source§fn with_properties(self, properties: HashMap<String, Value>) -> Self
fn with_properties(self, properties: HashMap<String, Value>) -> Self
Create a cortical area with custom properties
Source§fn add_property(self, key: String, value: Value) -> Self
fn add_property(self, key: String, value: Value) -> Self
Add a single property (builder pattern)
Source§fn add_property_mut(&mut self, key: String, value: Value)
fn add_property_mut(&mut self, key: String, value: Value)
Add a single property in-place
Source§fn contains_position(&self, pos: (i32, i32, i32)) -> bool
fn contains_position(&self, pos: (i32, i32, i32)) -> bool
Check if a 3D position is within this area’s bounds
Source§fn to_relative_position(&self, pos: (i32, i32, i32)) -> BduResult<Position>
fn to_relative_position(&self, pos: (i32, i32, i32)) -> BduResult<Position>
Convert absolute brain position to relative position within this area
Source§fn to_absolute_position(&self, rel_pos: Position) -> BduResult<(i32, i32, i32)>
fn to_absolute_position(&self, rel_pos: Position) -> BduResult<(i32, i32, i32)>
Convert relative position within area to absolute brain position
Source§fn neurons_per_voxel(&self) -> u32
fn neurons_per_voxel(&self) -> u32
Get neurons_per_voxel from properties (defaults to 1)
Source§fn refractory_period(&self) -> u16
fn refractory_period(&self) -> u16
Get refractory_period from properties (defaults to 0)
Source§fn snooze_period(&self) -> u16
fn snooze_period(&self) -> u16
Get snooze_period from properties (defaults to 0)
Source§fn leak_coefficient(&self) -> f32
fn leak_coefficient(&self) -> f32
Get leak_coefficient from properties (defaults to 0.0)
Source§fn firing_threshold(&self) -> f32
fn firing_threshold(&self) -> f32
Get firing_threshold from properties (defaults to 1.0)
Source§fn get_bool_property(&self, key: &str, default: bool) -> bool
fn get_bool_property(&self, key: &str, default: bool) -> bool
Get property as bool with default
Source§fn is_input_area(&self) -> bool
fn is_input_area(&self) -> bool
Check if this is an input area
Source§fn is_output_area(&self) -> bool
fn is_output_area(&self) -> bool
Check if this is an output area
Source§fn get_cortical_group(&self) -> Option<String>
fn get_cortical_group(&self) -> Option<String>
Get cortical group classification
Source§fn plasticity_constant(&self) -> f32
fn plasticity_constant(&self) -> f32
Get plasticity_constant from properties
Source§fn postsynaptic_current(&self) -> f32
fn postsynaptic_current(&self) -> f32
Get postsynaptic_current from properties
Source§fn psp_uniform_distribution(&self) -> bool
fn psp_uniform_distribution(&self) -> bool
Get psp_uniform_distribution from properties
Source§fn degeneration(&self) -> f32
fn degeneration(&self) -> f32
Get degeneration from properties
Source§fn burst_engine_active(&self) -> bool
fn burst_engine_active(&self) -> bool
Get burst_engine_active from properties
Source§fn firing_threshold_increment(&self) -> f32
fn firing_threshold_increment(&self) -> f32
Get firing_threshold_increment from properties
Source§fn firing_threshold_increment_x(&self) -> f32
fn firing_threshold_increment_x(&self) -> f32
Get firing_threshold_increment_x from properties
Source§fn firing_threshold_increment_y(&self) -> f32
fn firing_threshold_increment_y(&self) -> f32
Get firing_threshold_increment_y from properties
Source§fn firing_threshold_increment_z(&self) -> f32
fn firing_threshold_increment_z(&self) -> f32
Get firing_threshold_increment_z from properties
Source§fn firing_threshold_limit(&self) -> f32
fn firing_threshold_limit(&self) -> f32
Get firing_threshold_limit from properties (defaults to 0.0 = no limit)
Source§fn consecutive_fire_count(&self) -> u32
fn consecutive_fire_count(&self) -> u32
Get consecutive_fire_count from properties
Source§fn leak_variability(&self) -> f32
fn leak_variability(&self) -> f32
Get leak_variability from properties
Source§fn neuron_excitability(&self) -> f32
fn neuron_excitability(&self) -> f32
Get neuron_excitability from properties
Source§fn postsynaptic_current_max(&self) -> f32
fn postsynaptic_current_max(&self) -> f32
Get postsynaptic_current_max from properties
Source§fn mp_charge_accumulation(&self) -> bool
fn mp_charge_accumulation(&self) -> bool
Get mp_charge_accumulation from properties
Source§fn mp_driven_psp(&self) -> bool
fn mp_driven_psp(&self) -> bool
Get mp_driven_psp from properties
Source§fn init_lifespan(&self) -> u32
fn init_lifespan(&self) -> u32
Get init_lifespan from properties (memory parameter)
Source§fn lifespan_growth_rate(&self) -> f32
fn lifespan_growth_rate(&self) -> f32
Get lifespan_growth_rate from properties (memory parameter)
Source§fn longterm_mem_threshold(&self) -> u32
fn longterm_mem_threshold(&self) -> u32
Get longterm_mem_threshold from properties (memory parameter)
Source§impl Debug for CorticalArea
impl Debug for CorticalArea
Source§impl<'de> Deserialize<'de> for CorticalArea
impl<'de> Deserialize<'de> for CorticalArea
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<CorticalArea, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<CorticalArea, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for CorticalArea
impl Serialize for CorticalArea
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for CorticalArea
impl RefUnwindSafe for CorticalArea
impl Send for CorticalArea
impl Sync for CorticalArea
impl Unpin for CorticalArea
impl UnwindSafe for CorticalArea
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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