Skip to content

TabPFN memory calibration grid for the admission estimator #8

Description

@amrit110

Why

The factory-preloaded admission grid (memory/calibration_tabicl_a100.py) is TabICLv2 data measured on an A100-40GB. TabPFNBackend deployments therefore start from the conservative power-law formula plus whatever runtime observations accumulate (AdaptiveMemoryEstimator), so early TabPFN admissions are much tighter than the hardware allows and /v1/tabctx/limits under-reports what TabPFN can take. backends/tabpfn.py says as much in context_bytes_hint.

Since v0.10.0 the serving budget is the detected device capacity, so the grid only needs to describe the model's peak memory per shape; the card size is handled separately.

Tasks

  • Run benchmarks/calibrate_memory.py-style sweeps through TabPFNBackend on an A100 for the three cache modes (kv -> fit_with_cache, repr -> fit_preprocessors, off -> low_memory), recording peak fit bytes, resident bytes, predict-time peak at N_TEST_ROWS, and the first OOM per feature count. TabPFN's pretraining limits (~10k rows / ~500 features on the v2-series checkpoints, larger on TabPFN-3) bound the grid; record where the model rejects (422) vs where the device OOMs.
  • Extend benchmarks/gen_calibration_data.py to emit A100_40GB_TABPFN_* grids and teach serve/factory.py::_preloaded_observations to select the grid by backend kind (today it returns empty for anything but tabicl).
  • Unit test: build_estimator(ServeSettings(backends=("tabpfn",))) reports preloaded measurements in confidence() and estimates a grid shape from measurement, not formula (mirror TestCalibrationPreload).
  • Re-run benchmarks/probe_deployment.py on a TabPFN deployment and confirm max_admissible_train_rows_by_feature_count loosened accordingly.

Pointers

memory/adaptive.py (preloaded observations, margins), memory/calibration_tabicl_a100.py (generated file format), ROADMAP.md item 3.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestroadmapTracked in ROADMAP.md

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions