Function
render_status
(
elapsed: float, total: int, sensor_count: int, vec3_count: int, kind: str, size: int
)
Source from the content-addressed store, hash-verified
| 146 | |
| 147 | |
| 148 | def render_status( |
| 149 | elapsed: float, total: int, sensor_count: int, vec3_count: int, kind: str, size: int |
| 150 | ) -> str: |
| 151 | rate = total / elapsed if elapsed > 0 else 0.0 |
| 152 | return ( |
| 153 | f" {kind:<6} {size:3d}B " |
| 154 | f"| sent {total:>6} ({sensor_count} sensor + {vec3_count} vec3) " |
| 155 | f"| {rate:5.1f} Hz | {elapsed:6.1f}s" |
| 156 | f"{ANSI_CLEAR_EOL}\r" |
| 157 | ) |
| 158 | |
| 159 | |
| 160 | # --------------------------------------------------------------------------- |
Tested by
no test coverage detected