# Beckschen/TransUNet

This repository includes the official project of TransUNet, presented in our paper: TransUNet: Transformers Make Strong Encoders for Medical Image Segmentation.

Repository: https://github.com/Beckschen/TransUNet
Canonical: https://ross.abutalabs.com/products/transunet
Language: Python
License: Apache-2.0
License Family: permissive
Last push: 2026-02-25T04:44:14+00:00

## Health v2 (maintenance only)
Score: 63/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 69, release rhythm 35, longevity 100
- inputs: {"age_days": 2032, "days_push": 189, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3234, forks 583 (observed 2026-08-28T04:07:50.232388+00:00)

## What it is
Official PyTorch implementation of TransUNet, a U-Net-style architecture that uses a Vision Transformer encoder for medical image segmentation, supporting both 2D and 3D data. It includes training and testing scripts, pretrained ViT checkpoints, and datasets like Synapse and ACDC.

## Use cases
- segment medical images with a transformer-based U-Net
- train a segmentation model on the Synapse multi-organ dataset
- run 3D medical image segmentation on CT volumes
- benchmark against nn-UNet on BTCV or ACDC
- fine-tune pretrained ViT weights for segmentation
- reproduce results from the TransUNet paper

## When to choose
- you need state-of-the-art transformer-based medical image segmentation in PyTorch
- you want a published, well-cited reference implementation with pretrained weights
- you work with 2D medical images or 3D volumes and want one codebase for both

## When to avoid
- you need a production-ready, pip-installable segmentation library rather than research code
- you lack a GPU or want lightweight CPU inference
- you need general-purpose (non-medical) image segmentation out of the box

## Facets
- artifact type: library
- maturity: stable
- function: machine-learning, deep-learning, image-processing, computer-vision
- domain: deep-learning, computer-vision, healthcare
- platform: python
- tags: segmentation, unet, vision-transformer, medical-image-segmentation, research-code, pytorch, medical-imaging, gpu, linux

## Member repositories
- Beckschen/TransUNet (main) score 63

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:50.232388+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:24:36.871027+00:00, confidence not recorded.
  - readme: https://github.com/Beckschen/TransUNet (fetched 2026-08-28T04:07:50.232388+00:00, sha 1798c6fdb4a5)
- Data as of 2026-08-30T08:39:29.467469+00:00.
