Browse Source

add hub config for warpctc and maskrcnn

tags/v1.1.0
gengdongjie 5 years ago
parent
commit
f86c8ca213
4 changed files with 45 additions and 0 deletions
  1. +1
    -0
      model_zoo/official/cv/maskrcnn/README.md
  2. +22
    -0
      model_zoo/official/cv/maskrcnn/mindspore_hub_conf.py
  3. +1
    -0
      model_zoo/official/cv/warpctc/README.md
  4. +21
    -0
      model_zoo/official/cv/warpctc/mindspore_hub_conf.py

+ 1
- 0
model_zoo/official/cv/maskrcnn/README.md View File

@@ -140,6 +140,7 @@ pip install mmcv=0.2.14
├─lr_schedule.py # leanring rate geneatore
├─network_define.py # network define for maskrcnn
└─util.py # routine operation
├─mindspore_hub_conf.py # mindspore hub interface
├─eval.py # evaluation scripts
└─train.py # training scripts
```


+ 22
- 0
model_zoo/official/cv/maskrcnn/mindspore_hub_conf.py View File

@@ -0,0 +1,22 @@
# Copyright 2020 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ============================================================================
"""hub config."""
from src.maskrcnn.mask_rcnn_r50 import Mask_Rcnn_Resnet50
from src.config import config

def create_network(name, *args, **kwargs):
if name == "maskrcnn":
return Mask_Rcnn_Resnet50(config=config)
raise NotImplementedError(f"{name} is not implemented in the repo")

+ 1
- 0
model_zoo/official/cv/warpctc/README.md View File

@@ -118,6 +118,7 @@ The dataset is self-generated using a third-party library called [captcha](https
├── metric.py # accuracy metric for warpctc network
├── warpctc.py # warpctc network definition
└── warpctc_for_train.py # warpctc network with grad, loss and gradient clip
├── mindspore_hub_conf.py # mindspore hub interface
├── eval.py # eval net
├── process_data.py # dataset generation script
└── train.py # train net


+ 21
- 0
model_zoo/official/cv/warpctc/mindspore_hub_conf.py View File

@@ -0,0 +1,21 @@
# Copyright 2020 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ============================================================================
"""hub config."""
from src.warpctc import StackedRNN

def create_network(name, *args, **kwargs):
if name == "warpctc":
return StackedRNN(*args, **kwargs)
raise NotImplementedError(f"{name} is not implemented in the repo")

Loading…
Cancel
Save