infer.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:ifp 作者: morris-frank 项目源码 文件源码
def main(argv):
    sport = 'long_jump'
    model = 'snap_iter_50000.caffemodel'
    #---
    weights = model_root + 'fcn/' + sport + '/' + model
    netf = './fcn/' + sport + '/deploy.prototxt'

    gpu = 0
    caffe.set_device(gpu)
    caffe.set_mode_gpu()

    net = caffe.Net(netf, weights, caffe.TEST)
    im_head = '/export/home/mfrank/data/OlympicSports/clips/'
    im_head = '/export/home/mfrank/data/OlympicSports/patches/'
    test_path_file = 'fcn/' + sport + '/test.txt'
    train_path_file = 'fcn/' + sport + '/train.txt'

    inferfile(net, train_path_file, im_head)
    ifp_morris.apply_overlayfcn(train_path_file, factor=4)

    inferfile(net, test_path_file, im_head)
    ifp_morris.apply_overlayfcn(test_path_file, factor=4)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号