Skip to content

Releases: qubvel-org/segmentation_models.pytorch

Segmentation Models - v0.4.0

08 Jan 15:28
12f8394
Compare
Choose a tag to compare

New models

Segformer

contributed by @brianhou0208

Originally, SegFormer is a transformer-based semantic segmentation model known for its simplicity and efficiency. It uses a lightweight hierarchical encoder to capture multi-scale features and a minimal decoder for fast inference.

With segmentation-models-pytorch you can utilize the model with a native Mix Vision Transformer encoder as long as with 800+ other encoders supported by the library. Original weights are also supported and can be loaded as follows:

import segmentation_models_pytorch as smp

model = smp.from_pretrained("smp-hub/segformer-b5-640x640-ade-160k")

or with any other encoder:

import segmentation_models_pytorch as smp

model = smp.Segformer("resnet34")

See more checkpoints on the HF Hub.

UperNet

contributed by @brianhou0208

UPerNet (Unified Perceptual Parsing Network) is a versatile semantic segmentation model designed to handle diverse scene parsing tasks. It combines a Feature Pyramid Network (FPN) with a Pyramid Pooling Module (PPM) to effectively capture multi-scale context.

import segmentation_models_pytorch as smp

model = smp.UPerNet("resnet34")

New Encoders

Thanks to @brianhou0208 contribution 800+ timm encoders are now supported in segmentation_models.pytorch. New modern encoders like convnext, efficientvit, efficientformerv2, hiera, mambaout and more can be used as easy as:

import segmentation_models_pytorch as smp

model = smp.create_model("upernet", encoder_name="tu-mambaout_small")
# or
model = smp.UPerNet("tu-mambaout_small")

New examples

Other changes

  • Project migrated to pyproject.toml by @adamjstewart
  • Better dependency managing and testing (minimal and latest dependencies, linux/windows/mac platforms) by @adamjstewart
  • Better type annotations
  • Tests are refactored for faster CI and local testing by @qubvel

All changes

New Contributors

Full Changelog: v0.3.4...v0.4.0

Segmentation Models - v0.3.4

23 Aug 13:15
Compare
Choose a tag to compare

Updates

  • 🤗 Hugging Face integration: you can save, load, and share models with HF Hub, see example notebook.

Full log

New Contributors

Full Changelog: v0.3.3...v0.3.4

Segmentation Models - v0.3.3

28 May 15:49
e5d3db2
Compare
Choose a tag to compare

Updates

  • Pytorch image models (timm) version upgrade to 0.9.2

Segmentation Models - v0.3.2

07 Jan 10:37
c39de0c
Compare
Choose a tag to compare

Updates

  • Added Apple's Mobile One encoder from repo (use encoder_name="mobileone_s{0..4}").
  • Pytorch image models (timm) version upgrade to 0.6.12 (500+ encoders available)
  • Minor typo fixes and docs updates

Breaking changes

  • Minimum Python version 3.6 -> 3.7

Thanks @VadimLevin, @kevinpl07, @Abd-elr4hman

Segmentation Models - v0.3.1

30 Nov 12:31
Compare
Choose a tag to compare

Updates

  • Added Mix Vision Transformer encoder from SegFormer [official code] [paper]. Use argument encoder_name="mit_b0" (or mit_b1..b5) to create a model.
  • Minor typo fixes and docs updates

Segmentation Models - v0.3.0

29 Jul 10:32
Compare
Choose a tag to compare

Updates

  • Added smp.metrics module with different metrics based on confusion matrix, see docs
  • Added new notebook with training example using pytorch-lightning Open In Colab
  • Improved handling of incorrect input image size error (checking image size is 2^n)
  • Codebase refactoring and style checks (black, flake8)
  • Minor typo fixes and bug fixes

Breaking changes

  • utils module is going to be deprecated, if you still need it import it manually from segmentation_models_pytorch import utils

Thanks a lot for all contributors!

Segmentation Models - v0.2.1

18 Nov 10:48
a288d33
Compare
Choose a tag to compare

Updates

  • Universal timm encoder. 400+ pretrained encoders from timm available with tu- prefix. List of available encoders here.
  • Minor fixes and improvements.

Segmentation Models - v0.2.0

05 Jul 09:05
914f2bf
Compare
Choose a tag to compare

Updates

  • New architecture: MANet (#310)
  • New encoders from timm: mobilenetv3 (#355) and gernet (#344)
  • New loss functions in smp.losses module (smp.utils.losses would be deprecated in future versions)
  • New pretrained weight initialization for first convolution if in_channels > 3
  • Updated timm version (0.4.12)
  • Bug fixes and docs improvement

Thanks to @azkalot1 @JulienMaille @originlake @Kupchanski @loopdigga96 @zurk @nmerty @ludics @Vozf @markson14 and others!

Segmentation Models - v0.1.3

13 Dec 10:22
Compare
Choose a tag to compare

Updates

  • New architecture Unet++ (#279)
  • New encoders RegNet, ResNest, SK-Net, Res2Net (#286)
  • Updated timm version (0.3.2)
  • Improved docstrings and typehints for models
  • Project documentation on https://smp.readthedocs.io

Thanks to @azkalot1 for the new encoders and architecture!

Segmentation Models - v0.1.2

28 Sep 21:15
176f277
Compare
Choose a tag to compare

Fixes

  • Fix pytorch-efficientnet package version in requirements.txt to strict 0.6.3 (#260)