Skip to content

Commit 53131ed

Browse files
refactor: init value_and_grad (#737)
1 parent 5fd01e2 commit 53131ed

File tree

8 files changed

+345
-703
lines changed

8 files changed

+345
-703
lines changed

config.py

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -256,20 +256,6 @@ def create_parser():
256256
group.add_argument('--drop_overflow_update', type=bool, default=False,
257257
help='Whether to execute optimizer if there is an overflow (default=False)')
258258

259-
# modelarts
260-
group = parser.add_argument_group('modelarts')
261-
group.add_argument('--enable_modelarts', type=str2bool, nargs='?', const=True, default=False,
262-
help='Run on modelarts platform (default=False)')
263-
group.add_argument('--device_target', type=str, default='Ascend')
264-
group.add_argument('--multi_data_url', type=str, default='/cache/data/',
265-
help='path to multi dataset')
266-
group.add_argument('--data_url', type=str, default='/cache/data/',
267-
help='path to dataset')
268-
group.add_argument('--ckpt_url', type=str, default='/cache/output/',
269-
help='pre_train_model path in obs')
270-
group.add_argument('--train_url', type=str, default='/cache/output/',
271-
help='model folder to save/load')
272-
273259
return parser_config, parser
274260
# fmt: on
275261

examples/README.md

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,19 @@
1-
This folder contains examples for various tasks, which users can run easily.
2-
3-
### Single process with model training and evaluation
4-
```
5-
python examples/train_with_func_example.py
6-
```
7-
This example shows how to train and evaluate a model on your own dataset.
8-
9-
### Multiprocess with model training and evaluation
10-
```
11-
export CUDA_VISIBLE_DEVICES=0,1,2,3 # suppose there are 4 GPUs
12-
mpirun --allow-run-as-root -n 4 python examples/train_parallel_with_func_example.py
13-
```
14-
This example shows how to train and evaluate a mode with multiprocess on your own dataset on GPU.
1+
# Examples based on MindCV
2+
3+
This folder contains examples for various downstream tasks, which users can run easily.
4+
5+
## Finetune
6+
7+
- A detailed [sample](./finetune), aimed to easily adapt pretrained models to customized datasets.
8+
9+
## Detection
10+
11+
- [SSD](./det/ssd)
12+
13+
## Segmentation
14+
15+
- [DeepLabV3 & DeepLabV3+](./seg/deeplabv3)
16+
17+
## Vision Foundation Models
18+
19+
- coming soon.

examples/train_parallel_with_func_example.py

Lines changed: 0 additions & 161 deletions
This file was deleted.

examples/train_with_func_example.py

Lines changed: 0 additions & 136 deletions
This file was deleted.

0 commit comments

Comments
 (0)