Commit c668ed4e authored by Min Xu's avatar Min Xu Committed by Facebook GitHub Bot
Browse files

add damit uri support in train_net local run

Summary:
Pull Request resolved: https://github.com/facebookresearch/d2go/pull/622

as title

Reviewed By: jiaxuzhu92, ywwwer

Differential Revision: D49672980

fbshipit-source-id: f34ffe944c25c948fe1abd492ea0b96e47dc5b06
parent 206a05c6
...@@ -219,3 +219,8 @@ def get_generalized_rcnn_runner_default_cfg(cfg: CN) -> CN: ...@@ -219,3 +219,8 @@ def get_generalized_rcnn_runner_default_cfg(cfg: CN) -> CN:
_add_rcnn_default_config(cfg) _add_rcnn_default_config(cfg)
return cfg return cfg
@fb_overwritable()
def preprocess_cfg(cfg: CN) -> CN:
return cfg
...@@ -13,6 +13,7 @@ import detectron2.utils.comm as comm ...@@ -13,6 +13,7 @@ import detectron2.utils.comm as comm
from d2go.config import CfgNode from d2go.config import CfgNode
from d2go.distributed import distributed_worker, launch from d2go.distributed import distributed_worker, launch
from d2go.runner import BaseRunner from d2go.runner import BaseRunner
from d2go.runner.config_defaults import preprocess_cfg
from d2go.setup import ( from d2go.setup import (
basic_argument_parser, basic_argument_parser,
build_basic_cli_args, build_basic_cli_args,
...@@ -112,6 +113,7 @@ def wrapped_main(*args, **kwargs) -> Callable[..., TrainOrTestNetOutput]: ...@@ -112,6 +113,7 @@ def wrapped_main(*args, **kwargs) -> Callable[..., TrainOrTestNetOutput]:
def run_with_cmdline_args(args): def run_with_cmdline_args(args):
cfg, output_dir, runner_name = prepare_for_launch(args) cfg, output_dir, runner_name = prepare_for_launch(args)
cfg = preprocess_cfg(cfg)
shared_context = setup_before_launch(cfg, output_dir, runner_name) shared_context = setup_before_launch(cfg, output_dir, runner_name)
main_func = ( main_func = (
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment