benchmarks-mv
Measurement harnesses and evidence bundles for AIEN on the NVIDIA DGX Spark GB10. Speed is reported against the machine's physical limit and my own previous run. Attachment of AienOS.
Brought by drakestapleton
benchmarks-mv / src / models.rs
| 1 | // SPDX-License-Identifier: Apache-2.0 |
| 2 | // Copyright 2026 Drake Stapleton (AIEN / aien-dev) |
| 3 | // |
| 4 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | // you may not use this file except in compliance with the License. |
| 6 | // You may obtain a copy of the License at |
| 7 | // |
| 8 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | // |
| 10 | // Unless required by applicable law or agreed to in writing, software |
| 11 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | // See the License for the specific language governing permissions and |
| 14 | // limitations under the License. |
| 15 | |
| 16 | use serde::{Deserialize, Serialize}; |
| 17 | |
| 18 | #[derive(Debug, Clone, Serialize, Deserialize)] |
| 19 | pub struct BenchmarkData { |
| 20 | pub benchmark_suite: String, |
| 21 | pub version: String, |
| 22 | #[serde(default)] |
| 23 | pub schema_version: Option<String>, |
| 24 | #[serde(default)] |
| 25 | pub benchmark_commit: Option<String>, |
| 26 | #[serde(default)] |
| 27 | pub core_commit: Option<String>, |
| 28 | pub timestamp: String, |
| 29 | pub hardware: HardwareInfo, |
| 30 | #[serde(default)] |
| 31 | pub environment: EnvironmentInfo, |
| 32 | pub memory_rss: Vec<MemoryMetric>, |
| 33 | pub latency_concurrency: Vec<LatencyMetric>, |
| 34 | pub neural_inference: Vec<NeuralMetric>, |
| 35 | #[serde(default)] |
| 36 | pub concurrency_pressure: Vec<ConcurrencyPressureMetric>, |
| 37 | #[serde(default)] |
| 38 | pub context_scaling: Vec<ContextScalingMetric>, |
| 39 | #[serde(default)] |
| 40 | pub multi_model_breadth: Vec<MultiModelMetric>, |
| 41 | #[serde(default)] |
| 42 | pub cross_surface: Vec<CrossSurfaceMetric>, |
| 43 | } |
| 44 | |
| 45 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 46 | pub struct HardwareInfo { |
| 47 | pub system: String, |
| 48 | pub processor: String, |
| 49 | pub architecture: String, |
| 50 | pub memory_unified_gb: u32, |
| 51 | pub os: String, |
| 52 | } |
| 53 | |
| 54 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 55 | pub struct EnvironmentInfo { |
| 56 | pub rustc_version: String, |
| 57 | pub kernel_version: String, |
| 58 | pub page_size_kb: u32, |
| 59 | pub concurrency_tested: u32, |
| 60 | pub requests_per_endpoint: u32, |
| 61 | pub warmup_requests: u32, |
| 62 | } |
| 63 | |
| 64 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 65 | pub struct MemoryMetric { |
| 66 | #[serde(default)] |
| 67 | pub measurement_id: Option<String>, |
| 68 | pub service: String, |
| 69 | pub role: String, |
| 70 | pub architecture: String, |
| 71 | pub rss_mb: f64, |
| 72 | } |
| 73 | |
| 74 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 75 | pub struct LatencyMetric { |
| 76 | #[serde(default)] |
| 77 | pub measurement_id: Option<String>, |
| 78 | pub service: String, |
| 79 | pub endpoint: String, |
| 80 | pub description: String, |
| 81 | pub engine: String, |
| 82 | pub requests_per_sec: f64, |
| 83 | pub p50_ms: f64, |
| 84 | pub p95_ms: f64, |
| 85 | pub p99_ms: f64, |
| 86 | pub concurrency: u32, |
| 87 | pub sample_size: u32, |
| 88 | } |
| 89 | |
| 90 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 91 | pub struct NeuralMetric { |
| 92 | #[serde(default)] |
| 93 | pub measurement_id: Option<String>, |
| 94 | pub workload: String, |
| 95 | pub model: String, |
| 96 | pub engine: String, |
| 97 | pub p50_ms: f64, |
| 98 | /// Absent when too few observations exist for a real p95 (see llm_stream::P95_MIN_SAMPLES). |
| 99 | #[serde(default, skip_serializing_if = "Option::is_none")] |
| 100 | pub p95_ms: Option<f64>, |
| 101 | } |
| 102 | |
| 103 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 104 | pub struct ConcurrencyPressureMetric { |
| 105 | #[serde(default)] |
| 106 | pub measurement_id: Option<String>, |
| 107 | pub concurrency: u32, |
| 108 | pub aien_ttft_p50_ms: f64, |
| 109 | pub aien_ttft_p95_ms: f64, |
| 110 | pub aien_itl_p50_ms: f64, |
| 111 | pub aien_itl_p95_ms: f64, |
| 112 | pub tokens_per_sec: f64, |
| 113 | pub ttft_speedup: f64, |
| 114 | pub itl_speedup: f64, |
| 115 | pub power_watts: f64, |
| 116 | pub joules_per_token: f64, |
| 117 | } |
| 118 | |
| 119 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 120 | pub struct ContextScalingMetric { |
| 121 | #[serde(default)] |
| 122 | pub measurement_id: Option<String>, |
| 123 | pub context_length: u32, |
| 124 | pub ttft_p50_ms: f64, |
| 125 | pub prefix_cache_hit_pct: f64, |
| 126 | pub kv_memory_mb: f64, |
| 127 | pub scheduler_latency_us: f64, |
| 128 | } |
| 129 | |
| 130 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 131 | pub struct MultiModelMetric { |
| 132 | pub model_name: String, |
| 133 | pub architectural_topology: String, |
| 134 | pub quantization: String, |
| 135 | pub ttft_p50_ms: f64, |
| 136 | pub itl_p50_ms: f64, |
| 137 | pub kv_footprint_gb: f64, |
| 138 | pub status: String, |
| 139 | } |
| 140 | |
| 141 | #[derive(Debug, Clone, Serialize, Deserialize, Default)] |
| 142 | pub struct CrossSurfaceMetric { |
| 143 | pub surface: String, |
| 144 | pub processor: String, |
| 145 | pub execution_pipeline: String, |
| 146 | pub status: String, |
| 147 | } |