BiliSakura / RSBuilding-Swin-T

huggingface.co
Total runs: 6
24-hour runs: 0
7-day runs: 0
30-day runs: -7
Model's Last Updated: February 05 2026
feature-extraction

Introduction of RSBuilding-Swin-T

Model Details of RSBuilding-Swin-T

RSBuilding-Swin-T

HuggingFace Transformers version of RSBuilding Swin-Tiny model, converted from MMDetection/MMSegmentation format.

Source
Model Information
  • Architecture : Swin Transformer Tiny
  • Embedding Dimension : 96
  • Depths : [2, 2, 6, 2]
  • Number of Heads : [3, 6, 12, 24]
  • Window Size : 7
  • Image Size : 224×224
  • Patch Size : 4×4
Important Notes
Missing Buffer Keys (Expected)

When loading this model, you may see messages about missing buffer keys (typically ~12 keys). This is expected and normal.

These missing keys are buffers that are computed dynamically during model initialization:

  • relative_position_index : Precomputed index mapping for window-based attention
  • relative_coords_table : Precomputed coordinate table for relative positions
  • relative_position_bias_table : Precomputed bias table

Why they're missing:

  • These buffers are recalculated each time the model is instantiated based on window_size and other configuration parameters
  • They don't need to be saved in checkpoints because they're deterministic and computed from config
  • This is standard behavior in HuggingFace Swin transformers

Action required: None. The model will work correctly with these buffers computed automatically.

Quick Start
Installation
pip install transformers torch pillow
Inference Example
from transformers import SwinModel, AutoImageProcessor
from PIL import Image
import torch

# Load model and processor
model = SwinModel.from_pretrained("BiliSakura/RSBuilding-Swin-T")
processor = AutoImageProcessor.from_pretrained("BiliSakura/RSBuilding-Swin-T")

# Load and process image
image = Image.open("your_image.jpg")
inputs = processor(image, return_tensors="pt")

# Forward pass
with torch.no_grad():
    outputs = model(**inputs)

# Get features
# outputs.last_hidden_state: (batch_size, num_patches, hidden_size)
# outputs.pooler_output: (batch_size, hidden_size) - pooled representation
features = outputs.last_hidden_state
pooled_features = outputs.pooler_output

print(f"Feature shape: {features.shape}")
print(f"Pooled feature shape: {pooled_features.shape}")
Feature Extraction for Downstream Tasks
from transformers import SwinModel, AutoImageProcessor
import torch

model = SwinModel.from_pretrained("BiliSakura/RSBuilding-Swin-T")
processor = AutoImageProcessor.from_pretrained("BiliSakura/RSBuilding-Swin-T")

# Process image
image = Image.open("your_image.jpg")
inputs = processor(image, return_tensors="pt")

# Extract features
with torch.no_grad():
    outputs = model(**inputs)
    
# Use pooled features for classification/regression
features = outputs.pooler_output  # Shape: (1, 768)

# Or use last hidden state for dense prediction tasks
spatial_features = outputs.last_hidden_state  # Shape: (1, num_patches, 768)
Model Configuration

The model uses the following configuration:

  • image_size : 224
  • patch_size : 4
  • num_channels : 3
  • embed_dim : 96
  • depths : [2, 2, 6, 2]
  • num_heads : [3, 6, 12, 24]
  • window_size : 7
  • mlp_ratio : 4.0
  • hidden_act : "gelu"
Citation

If you use this model, please cite the original RSBuilding paper:

@article{wangRSBuildingGeneralRemote2024a,
  title = {{{RSBuilding}}: {{Toward General Remote Sensing Image Building Extraction}} and {{Change Detection With Foundation Model}}},
  shorttitle = {{{RSBuilding}}},
  author = {Wang, Mingze and Su, Lili and Yan, Cilin and Xu, Sheng and Yuan, Pengcheng and Jiang, Xiaolong and Zhang, Baochang},
  year = {2024},
  journal = {IEEE Transactions on Geoscience and Remote Sensing},
  volume = {62},
  pages = {1--17},
  issn = {1558-0644},
  doi = {10.1109/TGRS.2024.3439395},
  keywords = {Building extraction,Buildings,change detection (CD),Data mining,Feature extraction,federated training,foundation model,Image segmentation,Remote sensing,remote sensing images,Task analysis,Training}
}

Runs of BiliSakura RSBuilding-Swin-T on huggingface.co

6
Total runs
0
24-hour runs
0
3-day runs
0
7-day runs
-7
30-day runs

More Information About RSBuilding-Swin-T huggingface.co Model

More RSBuilding-Swin-T license Visit here:

https://choosealicense.com/licenses/apache-2.0

RSBuilding-Swin-T huggingface.co

RSBuilding-Swin-T huggingface.co is an AI model on huggingface.co that provides RSBuilding-Swin-T's model effect (), which can be used instantly with this BiliSakura RSBuilding-Swin-T model. huggingface.co supports a free trial of the RSBuilding-Swin-T model, and also provides paid use of the RSBuilding-Swin-T. Support call RSBuilding-Swin-T model through api, including Node.js, Python, http.

RSBuilding-Swin-T huggingface.co Url

https://huggingface.co/BiliSakura/RSBuilding-Swin-T

BiliSakura RSBuilding-Swin-T online free

RSBuilding-Swin-T huggingface.co is an online trial and call api platform, which integrates RSBuilding-Swin-T's modeling effects, including api services, and provides a free online trial of RSBuilding-Swin-T, you can try RSBuilding-Swin-T online for free by clicking the link below.

BiliSakura RSBuilding-Swin-T online free url in huggingface.co:

https://huggingface.co/BiliSakura/RSBuilding-Swin-T

RSBuilding-Swin-T install

RSBuilding-Swin-T is an open source model from GitHub that offers a free installation service, and any user can find RSBuilding-Swin-T on GitHub to install. At the same time, huggingface.co provides the effect of RSBuilding-Swin-T install, users can directly use RSBuilding-Swin-T installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

RSBuilding-Swin-T install url in huggingface.co:

https://huggingface.co/BiliSakura/RSBuilding-Swin-T

Url of RSBuilding-Swin-T

RSBuilding-Swin-T huggingface.co Url

Provider of RSBuilding-Swin-T huggingface.co

BiliSakura
ORGANIZATIONS

Other API from BiliSakura

huggingface.co

Total runs: 130
Run Growth: 99
Growth Rate: 75.57%
Updated:February 16 2026
huggingface.co

Total runs: 26
Run Growth: -16
Growth Rate: -61.54%
Updated:February 16 2026
huggingface.co

Total runs: 15
Run Growth: 8
Growth Rate: 50.00%
Updated:March 09 2026
huggingface.co

Total runs: 7
Run Growth: -17
Growth Rate: -242.86%
Updated:March 09 2026
huggingface.co

Total runs: 6
Run Growth: -1
Growth Rate: -16.67%
Updated:March 09 2026
huggingface.co

Total runs: 2
Run Growth: -6
Growth Rate: -300.00%
Updated:March 09 2026