def test_eval_mstest(self): cfg = load_config(self.mstest_cfg_file) trainer = Trainer(cfg, mode='eval') cfg.weights = 'https://paddledet.bj.bcebos.com/models/faster_rcnn_r34_fpn_1x_coco.pdparams' trainer.load_weights(cfg.weights) trainer.evaluate()
def run(FLAGS, cfg): # build trainer trainer = Trainer(cfg, mode='eval') # load weights trainer.load_weights(cfg.weights, 'resume') # training trainer.evaluate()
def run(FLAGS, cfg): # init parallel environment if nranks > 1 init_parallel_env() # build trainer trainer = Trainer(cfg, mode='eval') # load weights trainer.load_weights(cfg.weights, 'resume') # training trainer.evaluate()
def run(FLAGS, cfg): if FLAGS.json_eval: logger.info( "In json_eval mode, PaddleDetection will evaluate json files in " "output_eval directly. And proposal.json, bbox.json and mask.json " "will be detected by default.") json_eval_results(cfg.metric, json_directory=FLAGS.output_eval, dataset=cfg['EvalDataset']) return # init parallel environment if nranks > 1 init_parallel_env() # build trainer trainer = Trainer(cfg, mode='eval') # load weights trainer.load_weights(cfg.weights) # training trainer.evaluate()