Expand description
axonml-profile - Profiling Tools for Axonml ML Framework
Provides comprehensive profiling capabilities for neural network training and inference, including memory tracking, compute profiling, and bottleneck detection.
§Key Features
- Memory profiler: Track allocations, peak usage, and memory leaks
- Compute profiler: Measure operation times, FLOPS, and throughput
- Timeline profiler: Record events with timestamps for visualization
- Bottleneck detection: Identify performance bottlenecks automatically
§Example
ⓘ
use axonml_profile::{Profiler, MemoryProfiler, ComputeProfiler};
// Create a profiler
let profiler = Profiler::new();
// Profile a forward pass
profiler.start("forward_pass");
let output = model.forward(&input);
profiler.stop("forward_pass");
// Print summary
profiler.summary();@version 0.1.0 @author AutomataNexus Development Team
Re-exports§
pub use error::ProfileError;pub use error::ProfileResult;pub use memory::MemoryProfiler;pub use memory::MemoryStats;pub use memory::AllocationRecord;pub use compute::ComputeProfiler;pub use compute::OperationStats;pub use compute::ProfiledOp;pub use timeline::TimelineProfiler;pub use timeline::Event;pub use timeline::EventType;pub use bottleneck::BottleneckAnalyzer;pub use bottleneck::Bottleneck;pub use bottleneck::BottleneckType;pub use report::ProfileReport;pub use report::ReportFormat;
Modules§
- bottleneck
- Bottleneck Detection Module
- compute
- Compute Profiling Module
- error
- Error types for the profiling module.
- memory
- Memory Profiling Module
- report
- Report Generation Module
- timeline
- Timeline Profiling Module
Macros§
- profile_
scope - Creates a profile guard for automatic scope-based profiling.
Structs§
- Profile
Guard - RAII guard for automatic profiling scope.
- Profiler
- Unified profiler combining memory, compute, and timeline profiling.
Functions§
- global_
profiler - Gets the global profiler instance.
- record_
alloc - Records a memory allocation using the global profiler.
- record_
free - Records a memory deallocation using the global profiler.
- start
- Starts profiling an operation using the global profiler.
- stop
- Stops profiling an operation using the global profiler.