pub struct StarTopologyScore {
pub min_degree: usize,
/* private fields */
}Expand description
Star topology score kernel.
Detects and scores star/hub-and-spoke topology patterns. Critical for AML (smurfing detection) and fraud (money mule identification).
Fields§
§min_degree: usizeMinimum degree to be considered a potential hub.
Implementations§
Source§impl StarTopologyScore
impl StarTopologyScore
Sourcepub fn with_min_degree(min_degree: usize) -> Self
pub fn with_min_degree(min_degree: usize) -> Self
Create with custom minimum degree threshold.
Sourcepub fn compute_single(
graph: &CsrGraph,
in_degrees: Option<&[u32]>,
node: usize,
min_degree: usize,
) -> StarTopologyResult
pub fn compute_single( graph: &CsrGraph, in_degrees: Option<&[u32]>, node: usize, min_degree: usize, ) -> StarTopologyResult
Compute star topology score for a single node.
Sourcepub fn compute_batch(&self, graph: &CsrGraph) -> Vec<StarTopologyResult>
pub fn compute_batch(&self, graph: &CsrGraph) -> Vec<StarTopologyResult>
Compute star topology scores for all nodes.
Sourcepub fn top_k_hubs(&self, graph: &CsrGraph, k: usize) -> Vec<StarTopologyResult>
pub fn top_k_hubs(&self, graph: &CsrGraph, k: usize) -> Vec<StarTopologyResult>
Find top-K star hubs.
Sourcepub fn find_in_stars(
&self,
graph: &CsrGraph,
min_score: f64,
) -> Vec<StarTopologyResult>
pub fn find_in_stars( &self, graph: &CsrGraph, min_score: f64, ) -> Vec<StarTopologyResult>
Find in-star hubs (collection accounts).
Sourcepub fn find_out_stars(
&self,
graph: &CsrGraph,
min_score: f64,
) -> Vec<StarTopologyResult>
pub fn find_out_stars( &self, graph: &CsrGraph, min_score: f64, ) -> Vec<StarTopologyResult>
Find out-star hubs (distribution accounts - potential smurfing).
Trait Implementations§
Source§impl Clone for StarTopologyScore
impl Clone for StarTopologyScore
Source§fn clone(&self) -> StarTopologyScore
fn clone(&self) -> StarTopologyScore
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 Debug for StarTopologyScore
impl Debug for StarTopologyScore
Source§impl Default for StarTopologyScore
impl Default for StarTopologyScore
Source§impl GpuKernel for StarTopologyScore
impl GpuKernel for StarTopologyScore
Source§fn metadata(&self) -> &KernelMetadata
fn metadata(&self) -> &KernelMetadata
Returns the kernel metadata.
Source§fn requires_gpu_native(&self) -> bool
fn requires_gpu_native(&self) -> bool
Returns true if this kernel requires GPU-native execution.
Auto Trait Implementations§
impl Freeze for StarTopologyScore
impl RefUnwindSafe for StarTopologyScore
impl Send for StarTopologyScore
impl Sync for StarTopologyScore
impl Unpin for StarTopologyScore
impl UnwindSafe for StarTopologyScore
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
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> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.