← all repositories
bubbliiiing/unet-pytorch

U-Net with training wheels and a medical bias

A ready-to-train PyTorch U-Net that openly admits it prefers medical images over street scenes.

1.7k stars Python Computer VisionML Frameworks
unet-pytorch
Not currently ranked — collecting fresh signals.
star history

What it does This is a straightforward PyTorch training and inference kit for the classic U-Net segmentation architecture. It wraps the model with VGG or ResNet50 backbones, adds data loading and mIOU evaluation, and targets users who want to train on custom datasets—especially medical imagery—without writing boilerplate from scratch.

The interesting bit The author breaks from README tradition by warning that U-Net is a poor fit for rich-feature datasets like VOC, steering users toward biomedical tasks where shallow features win. That honesty is paired with a dedicated medical training script and Baidu Netdisk-hosted weights, making the repo feel like a Chinese-language cooking show for segmentation novices.

Key highlights

  • Dual backbones: choose between VGG and ResNet50 encoders.
  • Unusually candid performance table: mIOU of 58.78 (VGG) and 67.53 (ResNet50) on VOC, with an explicit note that the model is better suited to medical data.
  • Separate train_medical.py pipeline and pre-trained weights for biomedical tasks.
  • 2022 update added step/cosine learning-rate decay, Adam/SGD switching, and batch-size-aware LR scaling.

Caveats

  • The README title mislabels the project as an “object detection model,” which is a sloppy mismatch for a segmentation repo.
  • Dependencies are pinned to PyTorch 1.2.0 and torchvision 0.4.0, so expect friction on modern environments.
  • Pre-trained weights and datasets live on Baidu Netdisk, which is cumbersome if you are outside mainland China.

Verdict Grab this if you are a student or hobbyist needing a no-surprises U-Net baseline for medical-image segmentation. Skip it if you need state-of-the-art general segmentation or a codebase that tracks the latest PyTorch release.

Frequently asked

What is bubbliiiing/unet-pytorch?
A ready-to-train PyTorch U-Net that openly admits it prefers medical images over street scenes.
Is unet-pytorch open source?
Yes — bubbliiiing/unet-pytorch is open source, released under the MIT license.
What language is unet-pytorch written in?
bubbliiiing/unet-pytorch is primarily written in Python.
How popular is unet-pytorch?
bubbliiiing/unet-pytorch has 1.7k stars on GitHub.
Where can I find unet-pytorch?
bubbliiiing/unet-pytorch is on GitHub at https://github.com/bubbliiiing/unet-pytorch.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.