Skip to content

Commit f6ef24d

Browse files
committed
Adding pose estimation models, adding new models to previous tasks
1 parent 10311ad commit f6ef24d

File tree

107 files changed

+2575
-121
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

107 files changed

+2575
-121
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
In this repository, we provide popular models for each task in the [BDD100K dataset](https://www.bdd100k.com/). For each task in the dataset, we make publicly available the model weights, evaluation results, predictions, visualizations, as well as scripts to performance evaluation and visualization. The goal is to provide a set of competitive baselines to facilitate research and provide a common benchmark for comparison.
88

9-
The number of pre-trained models in this zoo is :one::one::five:. **You can include your models in this repo as well!** See [contribution](./doc/CONTRIBUTING.md) instructions.
9+
The number of pre-trained models in this zoo is :one::seven::nine:. **You can include your models in this repo as well!** See [contribution](./doc/CONTRIBUTING.md) instructions.
1010

1111
This repository currently supports the tasks listed below. For more information about each task, click on the task name. We plan to support all tasks in the BDD100K dataset eventually; see the [roadmap](#roadmap) for our plan and progress.
1212

@@ -17,14 +17,15 @@ This repository currently supports the tasks listed below. For more information
1717
- [**Drivable Area**](./drivable)
1818
- [**Multiple Object Tracking (MOT)**](./mot)
1919
- [**Multiple Object Tracking and Segmentation (MOTS)**](./mots)
20+
- [**Pose Estimation**](./pose)
2021

2122
If you have any questions, please go to the BDD100K [discussions](https://github.com/bdd100k/bdd100k/discussions).
2223

2324
## Roadmap
2425

26+
- [x] Pose estimation
2527
- [ ] Lane marking
2628
- [ ] Panoptic segmentation
27-
- [ ] Pose estimation
2829

2930
## Dataset
3031

det/README.md

Lines changed: 77 additions & 30 deletions
Large diffs are not rendered by default.
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
"""HRNet18, 1x schedule."""
2+
3+
_base_ = "./faster_rcnn_hrnetv2p_w32_1x_det_bdd100k.py"
4+
model = dict(
5+
pretrained="open-mmlab://msra/hrnetv2_w18",
6+
backbone=dict(
7+
extra=dict(
8+
stage2=dict(num_channels=(18, 36)),
9+
stage3=dict(num_channels=(18, 36, 72)),
10+
stage4=dict(num_channels=(18, 36, 72, 144)),
11+
),
12+
),
13+
neck=dict(type="HRFPN", in_channels=[18, 36, 72, 144], out_channels=256),
14+
)
15+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/faster_rcnn_hrnetv2p_w18_1x_det_bdd100k.pth"
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
"""HRNet18, 3x schedule, MS training."""
2+
3+
_base_ = "./faster_rcnn_hrnetv2p_w32_3x_det_bdd100k.py"
4+
model = dict(
5+
pretrained="open-mmlab://msra/hrnetv2_w18",
6+
backbone=dict(
7+
extra=dict(
8+
stage2=dict(num_channels=(18, 36)),
9+
stage3=dict(num_channels=(18, 36, 72)),
10+
stage4=dict(num_channels=(18, 36, 72, 144)),
11+
),
12+
),
13+
neck=dict(type="HRFPN", in_channels=[18, 36, 72, 144], out_channels=256),
14+
)
15+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/faster_rcnn_hrnetv2p_w18_3x_det_bdd100k.pth"
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
"""HRNet32, 1x schedule."""
2+
3+
_base_ = "./faster_rcnn_r50_fpn_1x_det_bdd100k.py"
4+
model = dict(
5+
pretrained="open-mmlab://msra/hrnetv2_w32",
6+
backbone=dict(
7+
_delete_=True,
8+
type="HRNet",
9+
extra=dict(
10+
stage1=dict(
11+
num_modules=1,
12+
num_branches=1,
13+
block="BOTTLENECK",
14+
num_blocks=(4,),
15+
num_channels=(64,),
16+
),
17+
stage2=dict(
18+
num_modules=1,
19+
num_branches=2,
20+
block="BASIC",
21+
num_blocks=(4, 4),
22+
num_channels=(32, 64),
23+
),
24+
stage3=dict(
25+
num_modules=4,
26+
num_branches=3,
27+
block="BASIC",
28+
num_blocks=(4, 4, 4),
29+
num_channels=(32, 64, 128),
30+
),
31+
stage4=dict(
32+
num_modules=3,
33+
num_branches=4,
34+
block="BASIC",
35+
num_blocks=(4, 4, 4, 4),
36+
num_channels=(32, 64, 128, 256),
37+
),
38+
),
39+
),
40+
neck=dict(
41+
_delete_=True,
42+
type="HRFPN",
43+
in_channels=[32, 64, 128, 256],
44+
out_channels=256,
45+
),
46+
)
47+
data = dict(samples_per_gpu=2, workers_per_gpu=2)
48+
optimizer = dict(type="SGD", lr=0.02, momentum=0.9, weight_decay=0.0001)
49+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/faster_rcnn_hrnetv2p_w32_1x_det_bdd100k.pth"
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
"""HRNet32, 3x schedule, MS training."""
2+
3+
_base_ = "./faster_rcnn_r50_fpn_3x_det_bdd100k.py"
4+
model = dict(
5+
pretrained="open-mmlab://msra/hrnetv2_w32",
6+
backbone=dict(
7+
_delete_=True,
8+
type="HRNet",
9+
extra=dict(
10+
stage1=dict(
11+
num_modules=1,
12+
num_branches=1,
13+
block="BOTTLENECK",
14+
num_blocks=(4,),
15+
num_channels=(64,),
16+
),
17+
stage2=dict(
18+
num_modules=1,
19+
num_branches=2,
20+
block="BASIC",
21+
num_blocks=(4, 4),
22+
num_channels=(32, 64),
23+
),
24+
stage3=dict(
25+
num_modules=4,
26+
num_branches=3,
27+
block="BASIC",
28+
num_blocks=(4, 4, 4),
29+
num_channels=(32, 64, 128),
30+
),
31+
stage4=dict(
32+
num_modules=3,
33+
num_branches=4,
34+
block="BASIC",
35+
num_blocks=(4, 4, 4, 4),
36+
num_channels=(32, 64, 128, 256),
37+
),
38+
),
39+
),
40+
neck=dict(
41+
_delete_=True,
42+
type="HRFPN",
43+
in_channels=[32, 64, 128, 256],
44+
out_channels=256,
45+
),
46+
)
47+
data = dict(samples_per_gpu=2, workers_per_gpu=2)
48+
optimizer = dict(type="SGD", lr=0.02, momentum=0.9, weight_decay=0.0001)
49+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/faster_rcnn_hrnetv2p_w32_3x_det_bdd100k.pth"
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
"""Libra R-CNN with ResNet101-FPN, 3x schedule, MS training."""
2+
3+
_base_ = "./libra_faster_rcnn_r50_fpn_3x_det_bdd100k.py"
4+
model = dict(
5+
backbone=dict(
6+
depth=101,
7+
init_cfg=dict(type="Pretrained", checkpoint="torchvision://resnet101"),
8+
)
9+
)
10+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/libra_faster_rcnn_r101_fpn_3x_det_bdd100k.pth"
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
"""Libra R-CNN with ResNet50-FPN, 1x schedule."""
2+
3+
_base_ = "./faster_rcnn_r50_fpn_1x_det_bdd100k.py"
4+
model = dict(
5+
neck=[
6+
dict(
7+
type="FPN",
8+
in_channels=[256, 512, 1024, 2048],
9+
out_channels=256,
10+
num_outs=5,
11+
),
12+
dict(
13+
type="BFP",
14+
in_channels=256,
15+
num_levels=5,
16+
refine_level=2,
17+
refine_type="non_local",
18+
),
19+
],
20+
roi_head=dict(
21+
bbox_head=dict(
22+
loss_bbox=dict(
23+
_delete_=True,
24+
type="BalancedL1Loss",
25+
alpha=0.5,
26+
gamma=1.5,
27+
beta=1.0,
28+
loss_weight=1.0,
29+
)
30+
)
31+
),
32+
# model training and testing settings
33+
train_cfg=dict(
34+
rpn=dict(sampler=dict(neg_pos_ub=5), allowed_border=-1),
35+
rcnn=dict(
36+
sampler=dict(
37+
_delete_=True,
38+
type="CombinedSampler",
39+
num=512,
40+
pos_fraction=0.25,
41+
add_gt_as_proposals=True,
42+
pos_sampler=dict(type="InstanceBalancedPosSampler"),
43+
neg_sampler=dict(
44+
type="IoUBalancedNegSampler",
45+
floor_thr=-1,
46+
floor_fraction=0,
47+
num_bins=3,
48+
),
49+
)
50+
),
51+
),
52+
)
53+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/libra_faster_rcnn_r50_fpn_1x_det_bdd100k.pth"
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
"""Libra R-CNN with ResNet50-FPN, 3x schedule, MS training."""
2+
3+
_base_ = "./faster_rcnn_r50_fpn_3x_det_bdd100k.py"
4+
model = dict(
5+
neck=[
6+
dict(
7+
type="FPN",
8+
in_channels=[256, 512, 1024, 2048],
9+
out_channels=256,
10+
num_outs=5,
11+
),
12+
dict(
13+
type="BFP",
14+
in_channels=256,
15+
num_levels=5,
16+
refine_level=2,
17+
refine_type="non_local",
18+
),
19+
],
20+
roi_head=dict(
21+
bbox_head=dict(
22+
loss_bbox=dict(
23+
_delete_=True,
24+
type="BalancedL1Loss",
25+
alpha=0.5,
26+
gamma=1.5,
27+
beta=1.0,
28+
loss_weight=1.0,
29+
)
30+
)
31+
),
32+
# model training and testing settings
33+
train_cfg=dict(
34+
rpn=dict(sampler=dict(neg_pos_ub=5), allowed_border=-1),
35+
rcnn=dict(
36+
sampler=dict(
37+
_delete_=True,
38+
type="CombinedSampler",
39+
num=512,
40+
pos_fraction=0.25,
41+
add_gt_as_proposals=True,
42+
pos_sampler=dict(type="InstanceBalancedPosSampler"),
43+
neg_sampler=dict(
44+
type="IoUBalancedNegSampler",
45+
floor_thr=-1,
46+
floor_fraction=0,
47+
num_bins=3,
48+
),
49+
)
50+
),
51+
),
52+
)
53+
load_from = "https://dl.cv.ethz.ch/bdd100k/det/models/libra_faster_rcnn_r50_fpn_3x_det_bdd100k.pth"

det/test.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,7 @@ def main() -> None:
107107

108108
cfg = Config.fromfile(args.config)
109109
if cfg.load_from is None:
110-
cfg_name = os.path.split(args.config)[-1].replace(
111-
"_bdd100k.py", ".pth"
112-
)
110+
cfg_name = os.path.split(args.config)[-1].replace(".py", ".pth")
113111
cfg.load_from = MODEL_SERVER + cfg_name
114112
if args.cfg_options is not None:
115113
cfg.merge_from_dict(args.cfg_options)

0 commit comments

Comments
 (0)