当前位置: 首页>>代码示例>>Python>>正文


Python train.get_training_roidb方法代码示例

本文整理汇总了Python中fast_rcnn.train.get_training_roidb方法的典型用法代码示例。如果您正苦于以下问题:Python train.get_training_roidb方法的具体用法?Python train.get_training_roidb怎么用?Python train.get_training_roidb使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在fast_rcnn.train的用法示例。


在下文中一共展示了train.get_training_roidb方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: combined_roidb

# 需要导入模块: from fast_rcnn import train [as 别名]
# 或者: from fast_rcnn.train import get_training_roidb [as 别名]
def combined_roidb(imdb_names):
    def get_roidb(imdb_name):
        imdb = get_imdb(imdb_name)
        print 'Loaded dataset `{:s}` for training'.format(imdb.name)
        imdb.set_proposal_method(cfg.TRAIN.PROPOSAL_METHOD)
        print 'Set proposal method: {:s}'.format(cfg.TRAIN.PROPOSAL_METHOD)
        roidb = get_training_roidb(imdb)
        return roidb

    roidbs = [get_roidb(s) for s in imdb_names.split('+')]
    roidb = roidbs[0]
    if len(roidbs) > 1:
        for r in roidbs[1:]:
            roidb.extend(r)
        imdb = datasets.imdb.imdb(imdb_names)
    else:
        imdb = get_imdb(imdb_names)
    return imdb, roidb 
开发者ID:playerkk,项目名称:face-py-faster-rcnn,代码行数:20,代码来源:train_net.py

示例2: get_roidb

# 需要导入模块: from fast_rcnn import train [as 别名]
# 或者: from fast_rcnn.train import get_training_roidb [as 别名]
def get_roidb(imdb_name, rpn_file=None):
    imdb = get_imdb(imdb_name)
    print 'Loaded dataset `{:s}` for training'.format(imdb.name)
    imdb.set_proposal_method(cfg.TRAIN.PROPOSAL_METHOD)
    print 'Set proposal method: {:s}'.format(cfg.TRAIN.PROPOSAL_METHOD)
    if rpn_file is not None:
        imdb.config['rpn_file'] = rpn_file
    roidb = get_training_roidb(imdb)
    return roidb, imdb 
开发者ID:playerkk,项目名称:face-py-faster-rcnn,代码行数:11,代码来源:train_faster_rcnn_alt_opt.py

示例3: get_roidb

# 需要导入模块: from fast_rcnn import train [as 别名]
# 或者: from fast_rcnn.train import get_training_roidb [as 别名]
def get_roidb(imdb_name, rpn_file=None):
    imdb = get_imdb(imdb_name)
    print 'Loaded dataset `{:s}` for training'.format(imdb.name)
    imdb.set_proposal_method(cfg.TRAIN.PROPOSAL_METHOD)
    print 'Set proposal method: {:s}'.format(cfg.TRAIN.PROPOSAL_METHOD)
    if rpn_file is not None:
        imdb.config['rpn_file'] = rpn_file
    roidb = get_training_roidb(imdb)
    return roidb, imdb

# ------------------------------------------------------------------------------
# Pycaffe doesn't reliably free GPU memory when instantiated nets are discarded
# (e.g. "del net" in Python code) . To work around this issue, each training
# stage is executed in a separate process using multiprocessing.Process.
# ------------------------------------------------------------------------------ 
开发者ID:djdam,项目名称:faster-rcnn-scenarios,代码行数:17,代码来源:train.py


注:本文中的fast_rcnn.train.get_training_roidb方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。