MCPcopy Index your code
hub / github.com/RolandGao/RegSeg

github.com/RolandGao/RegSeg @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
359 symbols 885 edges 25 files 24 documented · 7%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

RegSeg

The official implementation of "Rethink Dilated Convolution for Real-time Semantic Segmentation"

Paper: arxiv

D block

Decoder

Setup

Install the dependencies in requirements.txt by using pip and virtualenv.

Download Cityscapes

go to https://www.cityscapes-dataset.com, create an account, and download gtFine_trainvaltest.zip and leftImg8bit_trainvaltest.zip. Unzip both of them and put them in a directory called cityscapes_dataset. The cityscapes_dataset directory should be inside the RegSeg directory. If you put the dataset somewhere else, you can set the config field

config["dataset_dir"]="the location of your dataset"

You can delete the test images to save some space if you don't want to submit to the competition. Make sure that you have downloaded the required python packages and run

CITYSCAPES_DATASET=cityscapes_dataset csCreateTrainIdLabelImgs

There are 19 classes.

Results from paper

To see the ablation studies results from the paper, go here.

Usage

To visualize your model, go to show.py.

To see the model definitions and do some speed tests, go to model.py.

To train, validate, benchmark, and save the results of your model, go to train.py.

Cityscapes test results

RegSeg (exp48_decoder26, 30FPS)

test mIOU: 78.3

model weights

Larger RegSeg (exp53_decoder29, 20 FPS)

test mIOU: 79.5

model weights

Comparison against DDRNet-23

Run RegSeg model weights DDRNet-23 model weights
run1 77.76 77.84
run2 78.85 78.07
run3 78.07 77.53

Citation

If you find our work helpful, please consider citing our paper.

@article{gao2021rethink,
  title={Rethink Dilated Convolution for Real-time Semantic Segmentation},
  author={Gao, Roland},
  journal={arXiv preprint arXiv:2111.09957},
  year={2021}
}

Core symbols most depended-on inside this repo

get_dataset_loaders
called by 10
train_utils.py
channels
called by 9
blocks.py
_make_layer
called by 8
competitors_models/DDRNet_Reimplementation.py
activation
called by 7
blocks.py
norm2d
called by 7
blocks.py
build_val_transform
called by 7
data.py
average
called by 6
benchmark.py
get_dataloader_val
called by 6
data_utils.py

Shape

Function 148
Method 148
Class 63

Languages

Python100%

Modules by API surface

blocks.py58 symbols
transforms.py47 symbols
competitor_blocks.py31 symbols
train.py25 symbols
competitors_models/DDRNet_Reimplementation.py25 symbols
competitors_models/hardnet.py24 symbols
show.py23 symbols
precise_iou.py20 symbols
benchmark.py15 symbols
model.py10 symbols
augment.py10 symbols
datasets/coco.py9 symbols

For agents

$ claude mcp add RegSeg \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact