good first issuehelp wanted
Metriche repository
- Star
- (64 stelle)
- Metriche merge PR
- (Nessuna PR mergiata in 30 g)
Descrizione
Description
Create a benchmarking suite to measure and track performance metrics over time.
Current Status - Partially Implemented
The benchmarking infrastructure exists but needs enhancement for comprehensive performance tracking.
Already Implemented
- ✅ Criterion crate integration in Cargo.toml
- ✅ benches/ directory structure
- ✅ Basic benchmark in benches/inference_benchmark.rs
- ✅ CI job running benchmarks (benchmarks job in ci.yml)
Remaining Work
- Enhance existing benchmarks for ResNet18 built-in model
- Add memory usage benchmarking
- Add throughput benchmarks for different batch sizes
- Add concurrent request benchmarking
- Store benchmark results for comparison
- Add performance regression detection
- Add HTTP endpoint benchmarking (end-to-end)
Updated Implementation Focus
Since the app now uses built-in ResNet18 model:
- Benchmark with 150,528 input elements (3×224×224)
- Test with realistic ImageNet-style input data
- Measure inference time for built-in model vs dummy fallback
- Benchmark batch processing (1, 2, 4, 8 images)
Implementation Guidance
- Enhance existing benches/inference_benchmark.rs
- Use criterion for Rust benchmarking (already configured)
- Add benchmarks for the core inference functions with ResNet18
- Consider using hyperfine for end-to-end HTTP benchmarks
- Benchmark both successful inference and error cases
Estimated Difficulty
Medium - 1 day (reduced due to existing infrastructure)