Shortcuts

comp1k 源代码

# Copyright (c) OpenMMLab. All rights reserved.
from mmengine.dataset import DefaultSampler, InfiniteSampler

from mmagic.evaluation import SAD, ConnectivityError, GradientError, MattingMSE

# Base config for Composition-1K dataset

# dataset settings
[文档]dataset_type = 'AdobeComp1kDataset'
[文档]data_root = 'data/adobe_composition-1k'
[文档]train_dataloader = dict( num_workers=4, persistent_workers=False, sampler=dict(type=InfiniteSampler, shuffle=True), dataset=dict( type=dataset_type, data_root=data_root, ann_file='training_list.json', test_mode=False,
))
[文档]val_dataloader = dict( num_workers=4, persistent_workers=False, drop_last=False, sampler=dict(type=DefaultSampler, shuffle=False), dataset=dict( type=dataset_type, data_root=data_root, ann_file='test_list.json', test_mode=True,
))
[文档]test_dataloader = val_dataloader
# TODO: matting
[文档]val_evaluator = [ dict(type=SAD), dict(type=MattingMSE), dict(type=GradientError), dict(type=ConnectivityError),
]
[文档]test_evaluator = val_evaluator
Read the Docs v: latest
Versions
latest
stable
0.x
Downloads
pdf
epub
On Read the Docs
Project Home
Builds

Free document hosting provided by Read the Docs.