Skip to main content

TabICL-Survival: A Tabular Foundation Model for Survival In-Context Learning

Project description

TabICL-Survival: A Tabular Foundation Model for Survival In-Context Learning

This repo is an adaptation of "TabICL: A Tabular Foundation Model for In-Context Learning on Large Data" for survival analysis. It is trained using Cox negative log likelihood.

Installation

Option 1: Installing tabicl-survival from PyPI

pip install tabicl-survival

Option 2: Installing tabicl-survival from the local clone

cd tabicl
pip install -e .

Option 3: Installing tabicl-survival directly from the git remote

pip install git+https://github.com/taltstidl/tabicl-survival.git

Basic Usage

from tabicl import TabICLSurver

surv = TabICLSurver()
surv.fit(X_train, y_train)  # this is cheap
surv.predict(X_test)  # in-context learning happens here

The code above will automatically download the pre-trained checkpoint (~325MB) from Hugging Face Hub on first use and choose a GPU if available. It supports datasets with up to 1,024 samples and 100 features at the moment.

Contributors

For the original TabICL implementation

For the adapted TabICL-Surival implementation

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tabicl_survival-0.1.0.tar.gz (93.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tabicl_survival-0.1.0-py3-none-any.whl (113.7 kB view details)

Uploaded Python 3

File details

Details for the file tabicl_survival-0.1.0.tar.gz.

File metadata

  • Download URL: tabicl_survival-0.1.0.tar.gz
  • Upload date:
  • Size: 93.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Hatch/1.16.3 cpython/3.12.10 HTTPX/0.28.1

File hashes

Hashes for tabicl_survival-0.1.0.tar.gz
Algorithm Hash digest
SHA256 3c21623445477b62673e9729e6e5b67b81b26f56fc963c7cdf7c0b18388ebcab
MD5 345ef156f5560f885f02104a011bb774
BLAKE2b-256 c7e31404eb6a4c14d90c4f312ab735cfac71d3328c00d8b9bc99fcebf3253422

See more details on using hashes here.

File details

Details for the file tabicl_survival-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: tabicl_survival-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 113.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Hatch/1.16.3 cpython/3.12.10 HTTPX/0.28.1

File hashes

Hashes for tabicl_survival-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2bf8f026ae4ceee5a5bb429010a7437d725f19d4e5a0151bd7f018cecee17e0a
MD5 e7ce4e0e652ff19fb3156ece754a6955
BLAKE2b-256 f9e5ce49e022ec3802aed9fe9508d89377e88eeae78d2bc3cfda011092fdc6ec

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page