Model card for xcit_medium_24_p16_224.histoencoder

An XCiT (Cross-Covariance Image Transformer) feature backbone for prostate histopathology (HistoEncoder).
DINO self-supervised pre-training on 48M prostate tissue tiles.

Model Details

Model Usage

Image Embeddings

from urllib.request import urlopen
from PIL import Image
import timm

# get example image
img = Image.open(
  urlopen("https://github.com/owkin/HistoSSLscaling/raw/main/assets/example.tif")
).convert('RGB')

# load model from the hub
model = timm.create_model(
  model_name="hf-hub:1aurent/xcit_medium_24_p16_224.histoencoder",
  pretrained=True,
).eval()

# get model specific transforms (normalization, resize)
data_config = timm.data.resolve_model_data_config(model)
transforms = timm.data.create_transform(**data_config, is_training=False)

data = transforms(img).unsqueeze(0) # input is a (batch_size, num_channels, img_size, img_size) shaped tensor
output = model(data)  # output is a (batch_size, num_features) shaped tensor

Citation

@article{jopo2026histoencoder,
  title  = {HistoEncoder: a digital pathology foundation model for prostate cancer},
  author = {Poupard, Jonathan and others},
  journal = {Journal of Pathology Informatics},
  volume = {2026},
  pages  = {100715},
  doi    = {10.1016/j.jpi.2026.100715},
  url    = {https://arxiv.org/abs/2411.11458}
}
Downloads last month
-
Safetensors
Model size
83.9M params
Tensor type
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Collection including 1aurent/xcit_medium_24_p16_224.histoencoder

Papers for 1aurent/xcit_medium_24_p16_224.histoencoder