Aggregation Performance

Analysis of post-quantum signature aggregation and verification in Lean Consensus clients.

This notebook examines:

  • Signature aggregation time
  • Total signatures aggregated
  • Aggregation verification time
  • Aggregation and verification throughput (per second and per slot)
  • Performance comparison across clients
Show code
import json
from pathlib import Path

import pandas as pd
import plotly.graph_objects as go
from plotly.subplots import make_subplots

# Set default renderer for static HTML output
import plotly.io as pio
pio.renderers.default = "notebook"
Show code
# Resolve devnet_id
DATA_DIR = Path("../data")

if devnet_id is None:
    # Use latest devnet from manifest
    devnets_path = DATA_DIR / "devnets.json"
    if devnets_path.exists():
        with open(devnets_path) as f:
            devnets = json.load(f).get("devnets", [])
        if devnets:
            devnet_id = devnets[-1]["id"]  # Latest
            print(f"Using latest devnet: {devnet_id}")
    else:
        raise ValueError("No devnets.json found. Run 'just detect-devnets' first.")

DEVNET_DIR = DATA_DIR / devnet_id
print(f"Loading data from: {DEVNET_DIR}")
Loading data from: ../data/pqdevnet-20260516T2124Z
Show code
# Load devnet metadata
with open(DATA_DIR / "devnets.json") as f:
    devnets_data = json.load(f)
    devnet_info = next((d for d in devnets_data["devnets"] if d["id"] == devnet_id), None)

if devnet_info:
    print(f"Devnet: {devnet_info['id']}")
    print(f"Duration: {devnet_info['duration_hours']:.1f} hours")
    print(f"Time: {devnet_info['start_time']} to {devnet_info['end_time']}")
    print(f"Slots: {devnet_info['start_slot']} β†’ {devnet_info['end_slot']}")
    print(f"Clients: {', '.join(devnet_info['clients'])}")
Devnet: pqdevnet-20260516T2124Z
Duration: 0.5 hours
Time: 2026-05-16T21:24:15+00:00 to 2026-05-16T21:51:42+00:00
Slots: 0 β†’ 364
Clients: ethlambda_0, ethlambda_1, ethlambda_10, ethlambda_11, ethlambda_12, ethlambda_13, ethlambda_14, ethlambda_15, ethlambda_2, ethlambda_3, ethlambda_4, ethlambda_5, ethlambda_6, ethlambda_7, ethlambda_8, ethlambda_9, gean_0, gean_1, gean_10, gean_11, gean_12, gean_13, gean_14, gean_15, gean_2, gean_3, gean_4, gean_5, gean_6, gean_7, gean_8, gean_9, nlean_0, nlean_1, nlean_10, nlean_11, nlean_12, nlean_13, nlean_14, nlean_15, nlean_2, nlean_3, nlean_4, nlean_5, nlean_6, nlean_7, nlean_8, nlean_9, zeam_0, zeam_1, zeam_10, zeam_11, zeam_12, zeam_13, zeam_14, zeam_15, zeam_2, zeam_3, zeam_4, zeam_5, zeam_6, zeam_7, zeam_8, zeam_9

Load DataΒΆ

Show code
# Load PQ signature timing data
timing_df = pd.read_parquet(DEVNET_DIR / "pq_signature_timing.parquet")
print(f"Loaded {len(timing_df)} timing records")
print(f"Metrics: {timing_df['metric'].unique().tolist()}")
print(f"Clients: {timing_df['client'].unique().tolist()}")
Loaded 2907 timing records
Metrics: ['signing', 'verification', 'agg_verification']
Clients: ['ethlambda_11', 'ethlambda_15', 'ethlambda_3', 'ethlambda_7', 'ethlambda_1', 'ethlambda_13', 'ethlambda_5', 'ethlambda_9', 'ethlambda_10', 'ethlambda_14', 'ethlambda_2', 'ethlambda_6', 'ethlambda_0', 'ethlambda_12', 'ethlambda_4', 'ethlambda_8', 'gean_10', 'gean_14', 'gean_2', 'gean_6', 'gean_0', 'gean_12', 'gean_4', 'gean_8', 'gean_1', 'gean_13', 'gean_5', 'gean_9', 'gean_11', 'gean_15', 'gean_3', 'gean_7', 'nlean_1', 'nlean_13', 'nlean_5', 'nlean_9', 'nlean_10', 'nlean_14', 'nlean_2', 'nlean_6', 'nlean_11', 'nlean_15', 'nlean_3', 'nlean_7', 'nlean_0', 'nlean_12', 'nlean_4', 'nlean_8', 'zeam_10', 'zeam_14', 'zeam_2', 'zeam_6', 'zeam_1', 'zeam_13', 'zeam_5', 'zeam_9', 'zeam_0', 'zeam_12', 'zeam_4', 'zeam_8', 'zeam_11', 'zeam_15', 'zeam_3', 'zeam_7']
Show code
# Load PQ signature counts
counts_df = pd.read_parquet(DEVNET_DIR / "pq_signature_metrics.parquet")
print(f"Loaded {len(counts_df)} count records")
print(f"Metrics: {counts_df['metric'].unique().tolist()}")

# Unified client list from devnet metadata (includes all containers via cAdvisor)
all_clients = sorted(devnet_info["clients"])
n_cols = min(len(all_clients), 2)
n_rows = -(-len(all_clients) // n_cols)
print(f"\nAll clients ({len(all_clients)}): {all_clients}")
Loaded 6840 count records
Metrics: ['lean_pq_sig_aggregated_signatures_valid_total', 'lean_pq_sig_aggregated_signatures_invalid_total', 'lean_pq_sig_aggregated_signatures_total', 'lean_pq_sig_attestations_in_aggregated_signatures_total']

All clients (64): ['ethlambda_0', 'ethlambda_1', 'ethlambda_10', 'ethlambda_11', 'ethlambda_12', 'ethlambda_13', 'ethlambda_14', 'ethlambda_15', 'ethlambda_2', 'ethlambda_3', 'ethlambda_4', 'ethlambda_5', 'ethlambda_6', 'ethlambda_7', 'ethlambda_8', 'ethlambda_9', 'gean_0', 'gean_1', 'gean_10', 'gean_11', 'gean_12', 'gean_13', 'gean_14', 'gean_15', 'gean_2', 'gean_3', 'gean_4', 'gean_5', 'gean_6', 'gean_7', 'gean_8', 'gean_9', 'nlean_0', 'nlean_1', 'nlean_10', 'nlean_11', 'nlean_12', 'nlean_13', 'nlean_14', 'nlean_15', 'nlean_2', 'nlean_3', 'nlean_4', 'nlean_5', 'nlean_6', 'nlean_7', 'nlean_8', 'nlean_9', 'zeam_0', 'zeam_1', 'zeam_10', 'zeam_11', 'zeam_12', 'zeam_13', 'zeam_14', 'zeam_15', 'zeam_2', 'zeam_3', 'zeam_4', 'zeam_5', 'zeam_6', 'zeam_7', 'zeam_8', 'zeam_9']

Total Signatures AggregatedΒΆ

Cumulative number of individual signatures included in aggregated signature proofs over time.

Show code
att_in_agg_df = counts_df[counts_df["metric"] == "lean_pq_sig_attestations_in_aggregated_signatures_total"]

if att_in_agg_df.empty:
    print("No signatures in aggregated signature proof available")
else:
    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        cdf = att_in_agg_df[att_in_agg_df["client"] == client].sort_values("timestamp")
        if not cdf.empty and cdf["value"].max() > 0:
            fig.add_trace(
                go.Scatter(
                    x=cdf["timestamp"], y=cdf["value"],
                    showlegend=False,
                    line=dict(color="#636EFA"),
                ),
                row=row, col=col,
            )
            fig.update_yaxes(title_text="count", row=row, col=col)
        else:
            fig.add_trace(
                go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
                row=row, col=col,
            )
            _n = (row - 1) * n_cols + col
            _s = "" if _n == 1 else str(_n)
            fig.add_annotation(
                text="No data available",
                xref=f"x{_s} domain", yref=f"y{_s} domain",
                x=0.5, y=0.5,
                showarrow=False,
                font=dict(size=12, color="#999"),
            )

    fig.update_layout(
        title="Total Signatures Aggregated by Client",
        height=270 * n_rows,
    )
    fig.show()

Signature Aggregation TimeΒΆ

Time to build an aggregated signatures proof from individual post-quantum signatures.

Show code
# Filter to aggregate building metric
agg_build_df = timing_df[timing_df["metric"] == "agg_building"].copy()

if agg_build_df.empty:
    print("No signature aggregation timing data available")
else:
    agg_build_df["value_ms"] = agg_build_df["value"] * 1000

    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    colors = {"0.5": "#636EFA", "0.95": "#EF553B", "0.99": "#00CC96"}
    legend_added = set()

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        cdf = agg_build_df[agg_build_df["client"] == client]
        if not cdf.empty:
            for q in sorted(cdf["quantile"].unique()):
                qdf = cdf[cdf["quantile"] == q].sort_values("timestamp")
                q_str = str(q)
                label = f"p{int(q * 100)}"
                show_legend = q_str not in legend_added
                legend_added.add(q_str)
                fig.add_trace(
                    go.Scatter(
                        x=qdf["timestamp"], y=qdf["value_ms"],
                        name=label, legendgroup=q_str,
                        showlegend=show_legend,
                        line=dict(color=colors.get(q_str, "#AB63FA")),
                    ),
                    row=row, col=col,
                )
        else:
            fig.add_trace(
                go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
                row=row, col=col,
            )
            _n = (row - 1) * n_cols + col
            _s = "" if _n == 1 else str(_n)
            fig.add_annotation(
                text="No data available",
                xref=f"x{_s} domain", yref=f"y{_s} domain",
                x=0.5, y=0.5,
                showarrow=False,
                font=dict(size=12, color="#999"),
            )
        fig.update_yaxes(title_text="ms", row=row, col=col)

    fig.update_layout(
        title="Signature Aggregation Time by Client",
        height=270 * n_rows,
    )
    fig.show()
No signature aggregation timing data available
Show code
# Summary statistics by client
if not agg_build_df.empty:
    summary = agg_build_df.groupby(["client", "quantile"])["value_ms"].agg(["mean", "min", "max"]).round(3)
    summary.columns = ["Mean (ms)", "Min (ms)", "Max (ms)"]
    display(summary)

Aggregation Verification TimeΒΆ

Time to verify an aggregated post-quantum signatures proof.

Show code
# Filter to aggregate verification metric
agg_ver_df = timing_df[timing_df["metric"] == "agg_verification"].copy()

if agg_ver_df.empty:
    print("No aggregated signature verification timing data available")
else:
    agg_ver_df["value_ms"] = agg_ver_df["value"] * 1000

    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    colors = {"0.5": "#636EFA", "0.95": "#EF553B", "0.99": "#00CC96"}
    legend_added = set()

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        cdf = agg_ver_df[agg_ver_df["client"] == client]
        if not cdf.empty:
            for q in sorted(cdf["quantile"].unique()):
                qdf = cdf[cdf["quantile"] == q].sort_values("timestamp")
                q_str = str(q)
                label = f"p{int(q * 100)}"
                show_legend = q_str not in legend_added
                legend_added.add(q_str)
                fig.add_trace(
                    go.Scatter(
                        x=qdf["timestamp"], y=qdf["value_ms"],
                        name=label, legendgroup=q_str,
                        showlegend=show_legend,
                        line=dict(color=colors.get(q_str, "#AB63FA")),
                    ),
                    row=row, col=col,
                )
        else:
            fig.add_trace(
                go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
                row=row, col=col,
            )
            _n = (row - 1) * n_cols + col
            _s = "" if _n == 1 else str(_n)
            fig.add_annotation(
                text="No data available",
                xref=f"x{_s} domain", yref=f"y{_s} domain",
                x=0.5, y=0.5,
                showarrow=False,
                font=dict(size=12, color="#999"),
            )
        fig.update_yaxes(title_text="ms", row=row, col=col)

    fig.update_layout(
        title="Aggregation Verification Time by Client",
        height=270 * n_rows,
    )
    fig.show()
Show code
# Summary statistics by client
if not agg_ver_df.empty:
    summary = agg_ver_df.groupby(["client", "quantile"])["value_ms"].agg(["mean", "min", "max"]).round(3)
    summary.columns = ["Mean (ms)", "Min (ms)", "Max (ms)"]
    display(summary)
Mean (ms) Min (ms) Max (ms)
client quantile
ethlambda_0 0.50 53.778 50.032 59.914
0.95 137.340 95.061 220.311
0.99 261.241 99.064 442.600
ethlambda_1 0.50 55.472 50.216 69.565
0.95 148.506 95.409 231.623
... ... ... ... ...
zeam_8 0.95 95.000 95.000 95.000
0.99 99.000 99.000 99.000
zeam_9 0.50 50.000 50.000 50.000
0.95 95.000 95.000 95.000
0.99 99.000 99.000 99.000

192 rows Γ— 3 columns

Signatures Aggregated per SlotΒΆ

Rate of signature aggregations per slot (4-second slot time). Useful for researchers and implementers with a focus on signature aggregation in conjunction with consensus.

Show code
SLOT_TIME = 4  # seconds

agg_total_df = counts_df[counts_df["metric"] == "lean_pq_sig_aggregated_signatures_total"]

if agg_total_df.empty:
    print("No signature aggregation count data available")
else:
    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        cdf = agg_total_df[agg_total_df["client"] == client].sort_values("timestamp")
        if not cdf.empty and cdf["value"].max() > 0:
            dt = cdf["timestamp"].diff().dt.total_seconds()
            dv = cdf["value"].diff()
            rate = (dv / dt * SLOT_TIME).iloc[1:]
            ts = cdf["timestamp"].iloc[1:]
            mask = rate >= 0
            rate = rate[mask]
            ts = ts[mask]
            if not rate.empty:
                fig.add_trace(
                    go.Scatter(
                        x=ts, y=rate,
                        showlegend=False,
                        line=dict(color="#636EFA"),
                    ),
                    row=row, col=col,
                )
                fig.update_yaxes(title_text="/slot", row=row, col=col)
                continue
        fig.add_trace(
            go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
            row=row, col=col,
        )
        _n = (row - 1) * n_cols + col
        _s = "" if _n == 1 else str(_n)
        fig.add_annotation(
            text="No data available",
            xref=f"x{_s} domain", yref=f"y{_s} domain",
            x=0.5, y=0.5,
            showarrow=False,
            font=dict(size=12, color="#999"),
        )

    fig.update_layout(
        title="Signatures Aggregated per Slot by Client",
        height=270 * n_rows,
    )
    fig.show()
Show code
# Summary statistics by client
if not agg_total_df.empty:
    rows = []
    for client in all_clients:
        cdf = agg_total_df[agg_total_df["client"] == client].sort_values("timestamp")
        if cdf.empty or cdf["value"].max() == 0:
            continue
        dt = cdf["timestamp"].diff().dt.total_seconds()
        dv = cdf["value"].diff()
        rate = (dv / dt * SLOT_TIME).iloc[1:]
        rate = rate[rate >= 0]
        if not rate.empty:
            rows.append({"client": client, "Mean (/slot)": rate.mean(), "Min (/slot)": rate.min(), "Max (/slot)": rate.max()})
    if rows:
        display(pd.DataFrame(rows).set_index("client").round(3))
Mean (/slot) Min (/slot) Max (/slot)
client
ethlambda_0 0.844 0.000 1.867
ethlambda_1 0.023 0.000 0.600
ethlambda_10 0.064 0.000 1.600
ethlambda_12 0.044 0.000 1.133
ethlambda_13 0.097 0.000 1.467
ethlambda_2 0.043 0.000 1.067
ethlambda_3 0.099 0.000 1.267
ethlambda_4 0.064 0.000 1.333
ethlambda_5 0.028 0.000 0.733
ethlambda_7 0.049 0.000 1.267
ethlambda_8 0.141 0.000 1.267
ethlambda_9 0.108 0.000 1.400
gean_0 1.556 0.933 2.733
nlean_0 1.092 0.667 1.533
zeam_0 0.233 0.000 1.067
zeam_1 0.072 0.000 1.067
zeam_10 0.082 0.000 1.067
zeam_11 0.041 0.000 1.067
zeam_12 0.041 0.000 1.067
zeam_13 0.246 0.000 1.067
zeam_14 0.041 0.000 1.067
zeam_15 0.036 0.000 0.933
zeam_2 0.069 0.000 1.067
zeam_3 0.079 0.000 1.067
zeam_4 0.049 0.000 1.067
zeam_5 0.059 0.000 1.067
zeam_6 0.041 0.000 1.067
zeam_7 0.082 0.000 1.067
zeam_8 0.082 0.000 1.067
zeam_9 0.241 0.000 1.067

Signatures Verified per SlotΒΆ

Rate of valid/invalid aggregated signature verifications per slot (4-second slot time). Useful for researchers and implementers with a focus on signature aggregation in conjunction with consensus.

Show code
SLOT_TIME = 4  # seconds

# Calculate valid/invalid signature counts
valid_df = counts_df[counts_df["metric"] == "lean_pq_sig_aggregated_signatures_valid_total"]
invalid_df = counts_df[counts_df["metric"] == "lean_pq_sig_aggregated_signatures_invalid_total"]

if valid_df.empty and invalid_df.empty:
    print("No signature count data available")
else:
    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    colors = {"valid": "#2ecc71", "invalid": "#e74c3c"}
    legend_added = set()

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        has_data = False

        for status, sdf in [("valid", valid_df), ("invalid", invalid_df)]:
            cdf = sdf[sdf["client"] == client].sort_values("timestamp")
            if cdf.empty or cdf["value"].max() == 0:
                continue
            # Compute rate per slot: diff(value) / diff(seconds) * slot_time
            dt = cdf["timestamp"].diff().dt.total_seconds()
            dv = cdf["value"].diff()
            rate = (dv / dt * SLOT_TIME).iloc[1:]
            ts = cdf["timestamp"].iloc[1:]
            # Drop negative rates (counter resets)
            mask = rate >= 0
            rate = rate[mask]
            ts = ts[mask]
            if rate.empty:
                continue
            has_data = True
            show_legend = status not in legend_added
            legend_added.add(status)
            fig.add_trace(
                go.Scatter(
                    x=ts, y=rate,
                    name=status, legendgroup=status,
                    showlegend=show_legend,
                    line=dict(color=colors[status]),
                ),
                row=row, col=col,
            )

        if has_data:
            fig.update_yaxes(title_text="/slot", row=row, col=col)

        else:
            fig.add_trace(
                go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
                row=row, col=col,
            )
            _n = (row - 1) * n_cols + col
            _s = "" if _n == 1 else str(_n)
            fig.add_annotation(
                text="No data available",
                xref=f"x{_s} domain", yref=f"y{_s} domain",
                x=0.5, y=0.5,
                showarrow=False,
                font=dict(size=12, color="#999"),
            )
    fig.update_layout(
        title="Signatures Verified per Slot by Client",
        height=270 * n_rows,
    )
    fig.show()
Show code
# Summary statistics by client
if not valid_df.empty or not invalid_df.empty:
    rows = []
    for client in all_clients:
        for status, sdf in [("valid", valid_df), ("invalid", invalid_df)]:
            cdf = sdf[sdf["client"] == client].sort_values("timestamp")
            if cdf.empty or cdf["value"].max() == 0:
                continue
            dt = cdf["timestamp"].diff().dt.total_seconds()
            dv = cdf["value"].diff()
            rate = (dv / dt * SLOT_TIME).iloc[1:]
            rate = rate[rate >= 0]
            if not rate.empty:
                rows.append({"client": client, "status": status, "Mean (/slot)": rate.mean(), "Min (/slot)": rate.min(), "Max (/slot)": rate.max()})
    if rows:
        display(pd.DataFrame(rows).set_index(["client", "status"]).round(3))
Mean (/slot) Min (/slot) Max (/slot)
client status
ethlambda_0 valid 1.977 0.0 9.533
ethlambda_1 valid 1.977 0.0 9.533
ethlambda_10 valid 1.701 0.0 9.533
ethlambda_11 valid 1.649 0.0 8.800
ethlambda_12 valid 1.977 0.0 8.800
ethlambda_13 valid 1.977 0.0 9.533
ethlambda_14 valid 1.701 0.0 9.533
ethlambda_15 valid 1.636 0.0 9.533
ethlambda_2 valid 1.701 0.0 8.667
ethlambda_3 valid 2.000 0.0 9.533
ethlambda_4 valid 1.977 0.0 8.067
ethlambda_5 valid 1.977 0.0 8.733
ethlambda_6 valid 1.701 0.0 9.533
ethlambda_7 valid 1.636 0.0 8.733
ethlambda_8 valid 1.977 0.0 8.800
ethlambda_9 valid 1.977 0.0 9.533
zeam_0 valid 1.133 0.0 7.067
zeam_1 valid 1.738 0.0 9.533
zeam_10 valid 1.677 0.0 9.533
zeam_11 valid 1.636 0.0 11.333
zeam_12 valid 1.636 0.0 9.533
zeam_13 valid 1.323 0.0 9.533
zeam_14 valid 1.636 0.0 9.533
zeam_15 valid 1.595 0.0 8.800
zeam_2 valid 1.636 0.0 8.800
zeam_3 valid 1.615 0.0 10.600
zeam_4 valid 1.595 0.0 9.533
zeam_5 valid 1.636 0.0 9.533
zeam_6 valid 1.636 0.0 8.067
zeam_7 valid 1.636 0.0 8.800
zeam_8 valid 1.636 0.0 9.533
zeam_9 valid 1.703 0.0 9.533

Signatures Aggregated per SecondΒΆ

Rate of signature aggregations per second. Useful for researchers and implementers with a focus on signature aggregation performance.

Show code
if agg_total_df.empty:
    print("No signature aggregation count data available")
else:
    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        cdf = agg_total_df[agg_total_df["client"] == client].sort_values("timestamp")
        if not cdf.empty and cdf["value"].max() > 0:
            dt = cdf["timestamp"].diff().dt.total_seconds()
            dv = cdf["value"].diff()
            rate = (dv / dt).iloc[1:]
            ts = cdf["timestamp"].iloc[1:]
            mask = rate >= 0
            rate = rate[mask]
            ts = ts[mask]
            if not rate.empty:
                fig.add_trace(
                    go.Scatter(
                        x=ts, y=rate,
                        showlegend=False,
                        line=dict(color="#636EFA"),
                    ),
                    row=row, col=col,
                )
                fig.update_yaxes(title_text="/s", row=row, col=col)
                continue
        fig.add_trace(
            go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
            row=row, col=col,
        )
        _n = (row - 1) * n_cols + col
        _s = "" if _n == 1 else str(_n)
        fig.add_annotation(
            text="No data available",
            xref=f"x{_s} domain", yref=f"y{_s} domain",
            x=0.5, y=0.5,
            showarrow=False,
            font=dict(size=12, color="#999"),
        )

    fig.update_layout(
        title="Signatures Aggregated per Second by Client",
        height=270 * n_rows,
    )
    fig.show()
Show code
# Summary statistics by client
if not agg_total_df.empty:
    rows = []
    for client in all_clients:
        cdf = agg_total_df[agg_total_df["client"] == client].sort_values("timestamp")
        if cdf.empty or cdf["value"].max() == 0:
            continue
        dt = cdf["timestamp"].diff().dt.total_seconds()
        dv = cdf["value"].diff()
        rate = (dv / dt).iloc[1:]
        rate = rate[rate >= 0]
        if not rate.empty:
            rows.append({"client": client, "Mean (/s)": rate.mean(), "Min (/s)": rate.min(), "Max (/s)": rate.max()})
    if rows:
        display(pd.DataFrame(rows).set_index("client").round(3))
Mean (/s) Min (/s) Max (/s)
client
ethlambda_0 0.211 0.000 0.467
ethlambda_1 0.006 0.000 0.150
ethlambda_10 0.016 0.000 0.400
ethlambda_12 0.011 0.000 0.283
ethlambda_13 0.024 0.000 0.367
ethlambda_2 0.011 0.000 0.267
ethlambda_3 0.025 0.000 0.317
ethlambda_4 0.016 0.000 0.333
ethlambda_5 0.007 0.000 0.183
ethlambda_7 0.012 0.000 0.317
ethlambda_8 0.035 0.000 0.317
ethlambda_9 0.027 0.000 0.350
gean_0 0.389 0.233 0.683
nlean_0 0.273 0.167 0.383
zeam_0 0.058 0.000 0.267
zeam_1 0.018 0.000 0.267
zeam_10 0.021 0.000 0.267
zeam_11 0.010 0.000 0.267
zeam_12 0.010 0.000 0.267
zeam_13 0.062 0.000 0.267
zeam_14 0.010 0.000 0.267
zeam_15 0.009 0.000 0.233
zeam_2 0.017 0.000 0.267
zeam_3 0.020 0.000 0.267
zeam_4 0.012 0.000 0.267
zeam_5 0.015 0.000 0.267
zeam_6 0.010 0.000 0.267
zeam_7 0.021 0.000 0.267
zeam_8 0.021 0.000 0.267
zeam_9 0.060 0.000 0.267

Signatures Verified per SecondΒΆ

Rate of valid/invalid aggregated signature verifications per second. Useful for researchers and implementers with a focus on signature aggregation performance.

Show code
if valid_df.empty and invalid_df.empty:
    print("No signature count data available")
else:
    fig = make_subplots(
        rows=n_rows, cols=n_cols,
        subplot_titles=all_clients,
        vertical_spacing=0.12 / max(n_rows - 1, 1) * 2,
        horizontal_spacing=0.08,
    )

    colors = {"valid": "#2ecc71", "invalid": "#e74c3c"}
    legend_added = set()

    for i, client in enumerate(all_clients):
        row = i // n_cols + 1
        col = i % n_cols + 1
        has_data = False

        for status, sdf in [("valid", valid_df), ("invalid", invalid_df)]:
            cdf = sdf[sdf["client"] == client].sort_values("timestamp")
            if cdf.empty or cdf["value"].max() == 0:
                continue
            # Compute rate: diff(value) / diff(timestamp) in per-second
            dt = cdf["timestamp"].diff().dt.total_seconds()
            dv = cdf["value"].diff()
            rate = (dv / dt).iloc[1:]  # per second, skip first NaN
            ts = cdf["timestamp"].iloc[1:]
            # Drop negative rates (counter resets)
            mask = rate >= 0
            rate = rate[mask]
            ts = ts[mask]
            if rate.empty:
                continue
            has_data = True
            show_legend = status not in legend_added
            legend_added.add(status)
            fig.add_trace(
                go.Scatter(
                    x=ts, y=rate,
                    name=status, legendgroup=status,
                    showlegend=show_legend,
                    line=dict(color=colors[status]),
                ),
                row=row, col=col,
            )

        if has_data:
            fig.update_yaxes(title_text="/s", row=row, col=col)

        else:
            fig.add_trace(
                go.Scatter(x=[None], y=[None], showlegend=False, hoverinfo='skip'),
                row=row, col=col,
            )
            _n = (row - 1) * n_cols + col
            _s = "" if _n == 1 else str(_n)
            fig.add_annotation(
                text="No data available",
                xref=f"x{_s} domain", yref=f"y{_s} domain",
                x=0.5, y=0.5,
                showarrow=False,
                font=dict(size=12, color="#999"),
            )
    fig.update_layout(
        title="Signatures Verified per Second by Client",
        height=270 * n_rows,
    )
    fig.show()
Show code
# Summary statistics by client
if not valid_df.empty or not invalid_df.empty:
    rows = []
    for client in all_clients:
        for status, sdf in [("valid", valid_df), ("invalid", invalid_df)]:
            cdf = sdf[sdf["client"] == client].sort_values("timestamp")
            if cdf.empty or cdf["value"].max() == 0:
                continue
            dt = cdf["timestamp"].diff().dt.total_seconds()
            dv = cdf["value"].diff()
            rate = (dv / dt).iloc[1:]
            rate = rate[rate >= 0]
            if not rate.empty:
                rows.append({"client": client, "status": status, "Mean (/s)": rate.mean(), "Min (/s)": rate.min(), "Max (/s)": rate.max()})
    if rows:
        display(pd.DataFrame(rows).set_index(["client", "status"]).round(3))
Mean (/s) Min (/s) Max (/s)
client status
ethlambda_0 valid 0.494 0.0 2.383
ethlambda_1 valid 0.494 0.0 2.383
ethlambda_10 valid 0.425 0.0 2.383
ethlambda_11 valid 0.412 0.0 2.200
ethlambda_12 valid 0.494 0.0 2.200
ethlambda_13 valid 0.494 0.0 2.383
ethlambda_14 valid 0.425 0.0 2.383
ethlambda_15 valid 0.409 0.0 2.383
ethlambda_2 valid 0.425 0.0 2.167
ethlambda_3 valid 0.500 0.0 2.383
ethlambda_4 valid 0.494 0.0 2.017
ethlambda_5 valid 0.494 0.0 2.183
ethlambda_6 valid 0.425 0.0 2.383
ethlambda_7 valid 0.409 0.0 2.183
ethlambda_8 valid 0.494 0.0 2.200
ethlambda_9 valid 0.494 0.0 2.383
zeam_0 valid 0.283 0.0 1.767
zeam_1 valid 0.435 0.0 2.383
zeam_10 valid 0.419 0.0 2.383
zeam_11 valid 0.409 0.0 2.833
zeam_12 valid 0.409 0.0 2.383
zeam_13 valid 0.331 0.0 2.383
zeam_14 valid 0.409 0.0 2.383
zeam_15 valid 0.399 0.0 2.200
zeam_2 valid 0.409 0.0 2.200
zeam_3 valid 0.404 0.0 2.650
zeam_4 valid 0.399 0.0 2.383
zeam_5 valid 0.409 0.0 2.383
zeam_6 valid 0.409 0.0 2.017
zeam_7 valid 0.409 0.0 2.200
zeam_8 valid 0.409 0.0 2.383
zeam_9 valid 0.426 0.0 2.383

SummaryΒΆ

Key findings from this devnet iteration:

Show code
# Generate summary statistics
print(f"Devnet: {devnet_id}")
print(f"Duration: {devnet_info['duration_hours']:.1f} hours")
print(f"Clients analyzed: {len(timing_df['client'].unique())}")
print()

if not agg_build_df.empty:
    p95_agg = agg_build_df[agg_build_df["quantile"] == 0.95]["value_ms"].mean()
    print(f"Average P95 aggregation time: {p95_agg:.2f} ms")

if not agg_ver_df.empty:
    p95_ver = agg_ver_df[agg_ver_df["quantile"] == 0.95]["value_ms"].mean()
    print(f"Average P95 proof verification time: {p95_ver:.2f} ms")
Devnet: pqdevnet-20260516T2124Z
Duration: 0.5 hours
Clients analyzed: 64

Average P95 proof verification time: 166.53 ms