Skip to content

Commit 6ef94b3

Browse files
committed
fix(schema): expose gpu fp32_tflops in API responses
fp32_tflops lived on the GPU model and ingest path but was never added to the GPURead response schema or gpu_read serializer, so the API silently dropped it. Wire it through so the computed peak-FP32 values surface in /v1/gpus.
1 parent 2e3983d commit 6ef94b3

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

app/schemas/gpu.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ class GPURead(BaseModel):
3535
boost_clock_mhz: int
3636
tdp_w: int
3737
pcie_version: str
38+
fp32_tflops: float | None = None
3839
blender_score: float | None = None
3940
verified: bool
4041
source_urls: list[str]

app/schemas/serializers.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ def gpu_read(gpu: DiscreteGPU, manufacturer: Brand) -> GPURead:
126126
boost_clock_mhz=gpu.boost_clock_mhz,
127127
tdp_w=gpu.tdp_w,
128128
pcie_version=gpu.pcie_version,
129+
fp32_tflops=gpu.fp32_tflops,
129130
blender_score=gpu.blender_score,
130131
verified=gpu.verified,
131132
source_urls=gpu.source_urls,

0 commit comments

Comments
 (0)