Views
No views yet
1from sklearn.datasets import load_breast_cancer
2from sklearn.metrics import accuracy_score, roc_auc_score
3from sklearn.model_selection import train_test_split
4from huggingface_hub import hf_hub_download
5import numpy as np
6import os, sys
7
8# Setup environment for inference
9os.environ["RANK"] = "0"
10os.environ["WORLD_SIZE"] = "1"
11os.environ["MASTER_ADDR"] = "127.0.0.1"
12os.environ["MASTER_PORT"] = "29500"
13
14# Assuming the LimiX repository is cloned and in the python path
15# from inference.predictor import LimiXPredictor
16
17X, y = load_breast_cancer(return_X_y=True)
18X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.5, random_state=42)
19
20# Download model weights
21model_file = hf_hub_download(repo_id="stableai-org/LimiX-2M", filename="LimiX-2M.ckpt", local_dir="./cache")
22
23# Initialize predictor (Requires local inference code from GitHub)
24# clf = LimiXPredictor(device='cuda', model_path=model_file, inference_config='config/cls_default_retrieval.json')
25# prediction = clf.predict(X_train, y_train, X_test)
26
27# print("roc_auc_score:", roc_auc_score(y_test, prediction[:, 1]))
28# print("accuracy_score:", accuracy_score(y_test, np.argmax(prediction, axis=1)))1pip install python==3.12.7 torch==2.7.1 torchvision==0.22.1 torchaudio==2.7.1
2pip install scikit-learn einops huggingface-hub matplotlib networkx numpy pandas scipy tqdm typing_extensions xgboost kditransform hyperopt1@article{zhang2025limix,
2 title={Limix: Unleashing structured-data modeling capability for generalist intelligence},
3 author={Zhang, Xingxuan and Ren, Gang and Yu, Han and Yuan, Hao and Wang, Hui and Li, Jiansheng and Wu, Jiayun and Mo, Lang and Mao, Li and Hao, Mingchao and others},
4 journal={arXiv preprint arXiv:2509.03505},
5 year={2025}
6}
7
8@article{limix2m2026,
9 title={LimiX-2M: Mitigating Low-Rank Collapse and Attention Bottlenecks in Tabular Foundation Models},
10 author={Zhang, Xingxuan and others},
11 journal={arXiv preprint arXiv:2606.04485},
12 year={2026}
13}