Skip to content

Commit

Permalink
[Docs] Replace markdownlint with mdformat for avoiding installing ruby (
Browse files Browse the repository at this point in the history
#298)

* use mdformat in pre-commit hook

* revise mmcv version in requirements
  • Loading branch information
LeoXing1996 authored May 19, 2022
1 parent 08762ff commit 6bce6ed
Show file tree
Hide file tree
Showing 45 changed files with 442 additions and 402 deletions.
5 changes: 2 additions & 3 deletions .github/ISSUE_TEMPLATE/error-report.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

Thanks for your error report and we appreciate it a lot.
Expand Down Expand Up @@ -33,8 +32,8 @@ A placeholder for the command.

1. Please run `python mmgen/utils/collect_env.py` to collect necessary environment information and paste it here.
2. You may add addition that may be helpful for locating the problem, such as
- How you installed PyTorch [e.g., pip, conda, source]
- Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.)
- How you installed PyTorch \[e.g., pip, conda, source\]
- Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.)

**Error traceback**
If applicable, paste the error trackback here.
Expand Down
5 changes: 2 additions & 3 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,14 @@ about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''

---

**Describe the feature**

**Motivation**
A clear and concise description of the motivation of the feature.
Ex1. It is inconvenient when [....].
Ex2. There is a recent paper [....], which is very helpful for [....].
Ex1. It is inconvenient when \[....\].
Ex2. There is a recent paper \[....\], which is very helpful for \[....\].

**Related resources**
If there is an official code release or third-party implementations, please also provide the information here, which would be very helpful.
Expand Down
1 change: 0 additions & 1 deletion .github/ISSUE_TEMPLATE/general_questions.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ about: Ask general questions to get help
title: ''
labels: ''
assignees: ''

---
5 changes: 2 additions & 3 deletions .github/ISSUE_TEMPLATE/reimplementation_questions.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
name: Reimplementation Questions
about: Ask about questions during model reimplementation
title: ''
labels: 'reimplementation'
labels: reimplementation
assignees: ''

---

**Notice**
Expand Down Expand Up @@ -52,7 +51,7 @@ A placeholder for the config.

1. Please run `python mmgen/utils/collect_env.py` to collect necessary environment information and paste it here.
2. You may add addition that may be helpful for locating the problem, such as
1. How you installed PyTorch [e.g., pip, conda, source]
1. How you installed PyTorch \[e.g., pip, conda, source\]
2. Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.)

**Results**
Expand Down
17 changes: 10 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,20 @@ repos:
hooks:
- id: docformatter
args: ["--in-place", "--wrap-descriptions", "79"]
- repo: https://github.com/markdownlint/markdownlint
rev: v0.11.0
hooks:
- id: markdownlint
args: ["-r", "~MD002,~MD013,~MD029,~MD033,~MD034",
"-t", "allow_different_nesting"]
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.14
hooks:
- id: mdformat
args: ["--number"]
additional_dependencies:
- mdformat-gfm
- mdformat_frontmatter
- linkify-it-py
- repo: https://github.com/codespell-project/codespell
rev: v2.1.0
hooks:
- id: codespell
args: ["--skip", "*.ipynb,tools/data/hvu/label_map.json", "-L", "formating,te,nd,thre,Gool,gool,lod"]
args: ["--skip", "*.ipynb,tools/data/hvu/label_map.json,docs/zh_cn/*", "-L", "formating,te,nd,thre,Gool,gool,lod"]
- repo: local
hooks:
- id: update-model-index
Expand Down
11 changes: 5 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,13 @@ MMGeneration is a powerful toolkit for generative models, especially for GANs no
<img src="https://user-images.githubusercontent.com/12726765/114534478-9a65a900-9c81-11eb-8087-de8b6816eed8.png" width="800"/>
</div>


## Major Features

- **High-quality Training Performance:** We currently support training on Unconditional GANs, Internal GANs, and Image Translation Models. Support for conditional models will come soon.
- **Powerful Application Toolkit:** A plentiful toolkit containing multiple applications in GANs is provided to users. GAN interpolation, GAN projection, and GAN manipulations are integrated into our framework. It's time to play with your GANs! ([Tutorial for applications](docs/en/tutorials/applications.md))
- **Efficient Distributed Training for Generative Models:** For the highly dynamic training in generative models, we adopt a new way to train dynamic models with `MMDDP`. ([Tutorial for DDP](docs/en/tutorials/ddp_train_gans.md))
- **New Modular Design for Flexible Combination:** A new design for complex loss modules is proposed for customizing the links between modules, which can achieve flexible combination among different modules. ([Tutorial for new modular design](docs/en/tutorials/customize_losses.md))


<table>
<thead>
<tr>
Expand Down Expand Up @@ -73,9 +71,10 @@ MMGeneration is a powerful toolkit for generative models, especially for GANs no

## Highlight

* **Positional Encoding as Spatial Inductive Bias in GANs (CVPR2021)** has been released in `MMGeneration`. [\[Config\]](configs/positional_encoding_in_gans/README.md), [\[Project Page\]](https://nbei.github.io/gan-pos-encoding.html)
* Conditional GANs have been supported in our toolkit. More methods and pre-trained weights will come soon.
* Mixed-precision training (FP16) for StyleGAN2 has been supported. Please check [the comparison](configs/styleganv2/README.md) between different implementations.
- **Positional Encoding as Spatial Inductive Bias in GANs (CVPR2021)** has been released in `MMGeneration`. [\[Config\]](configs/positional_encoding_in_gans/README.md), [\[Project Page\]](https://nbei.github.io/gan-pos-encoding.html)
- Conditional GANs have been supported in our toolkit. More methods and pre-trained weights will come soon.
- Mixed-precision training (FP16) for StyleGAN2 has been supported. Please check [the comparison](configs/styleganv2/README.md) between different implementations.

## Changelog

v0.7.1 was released on 30/04/2022. Please refer to [changelog.md](docs/en/changelog.md) for details and release history.
Expand All @@ -84,7 +83,6 @@ v0.7.1 was released on 30/04/2022. Please refer to [changelog.md](docs/en/change

These methods have been carefully studied and supported in our frameworks:


<details open>
<summary>Unconditional GANs (click to collapse)</summary>

Expand Down Expand Up @@ -133,6 +131,7 @@ These methods have been carefully studied and supported in our frameworks:
</details>

## Related-Applications

-[MMGEN-FaceStylor](https://github.com/open-mmlab/MMGEN-FaceStylor)

## License
Expand Down
12 changes: 5 additions & 7 deletions README_zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,13 @@ MMGeneration 是一个基于 PyTorch 和[MMCV](https://github.com/open-mmlab/mmc
<img src="https://user-images.githubusercontent.com/12726765/114534478-9a65a900-9c81-11eb-8087-de8b6816eed8.png" width="800"/>
</div>


## 主要特性

- **高质量高性能的训练:** 我们目前支持 Unconditional GANs, Internal GANs, 以及 Image Translation Models 的训练。很快将会支持 conditional models 的训练。
- **强有力的应用工具箱:** 为用户提供了丰富的工具箱,包含 GANs 中的多种应用。我们的框架集成了 GANs 的插值,投影和编辑。请用你的 GANs 尽情尝试!([应用教程](docs/tutorials/applications.md))
- **生成模型的高效分布式训练:** 对于生成模型中的高度动态训练,我们采用 `MMDDP` 的新方法来训练动态模型。([DDP教程](docs/tutorials/ddp_train_gans.md))
- **灵活组合的新型模块化设计:** 针对复杂的损失模块,我们提出了一种新的设计,可以自定义模块之间的链接,实现不同模块之间的灵活组合。 ([新模块化设计教程](docs/tutorials/customize_losses.md))


<table>
<thead>
<tr>
Expand Down Expand Up @@ -57,9 +55,10 @@ MMGeneration 是一个基于 PyTorch 和[MMCV](https://github.com/open-mmlab/mmc

## 亮点

* **Positional Encoding as Spatial Inductive Bias in GANs (CVPR2021)** 已在 `MMGeneration` 中发布. [\[配置文件\]](configs/positional_encoding_in_gans/README.md), [\[项目主页\]](https://nbei.github.io/gan-pos-encoding.html)
* 我们已经支持训练目前主流的 Conditional GANs 模型,更多的方法和预训练权重马上就会发布,敬请期待。
* 混合精度训练已经在 `StyleGAN2` 中进行了初步支持,请到[这里](configs/styleganv2/README.md)查看各种实现方式的详细比较。
- **Positional Encoding as Spatial Inductive Bias in GANs (CVPR2021)** 已在 `MMGeneration` 中发布. [\[配置文件\]](configs/positional_encoding_in_gans/README.md), [\[项目主页\]](https://nbei.github.io/gan-pos-encoding.html)
- 我们已经支持训练目前主流的 Conditional GANs 模型,更多的方法和预训练权重马上就会发布,敬请期待。
- 混合精度训练已经在 `StyleGAN2` 中进行了初步支持,请到[这里](configs/styleganv2/README.md)查看各种实现方式的详细比较。

## 更新日志

v0.7.1 在 30/04/2022 发布。 关于细节和发布历史,请参考 [changelog.md](docs/zh_cn/changelog.md)
Expand All @@ -68,7 +67,6 @@ v0.7.1 在 30/04/2022 发布。 关于细节和发布历史,请参考 [changel

这些算法在我们的框架中得到了认真研究和支持。


<details open>
<summary>Unconditional GANs (点击折叠)</summary>

Expand All @@ -92,7 +90,6 @@ v0.7.1 在 30/04/2022 发布。 关于细节和发布历史,请参考 [changel
-[SAGAN](configs/sagan/README.md) (ICML'2019)
-[BIGGAN/BIGGAN-DEEP](configs/biggan/README.md) (ICLR'2019)


</details>

<details open>
Expand Down Expand Up @@ -148,6 +145,7 @@ pip3 install -e .[all]
更详细的安装指南请参考 [get_started.md](docs/zh/get_started.md) .

## 相关应用

-[MMGEN-FaceStylor](https://github.com/open-mmlab/MMGEN-FaceStylor)

## 开源许可证
Expand Down
Loading

0 comments on commit 6bce6ed

Please sign in to comment.