Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Doc] Add Chinese translation of install.md and 4 super-resolution datasets README.md #424

Merged
merged 8 commits into from
Jul 21, 2021

Conversation

LiUzHiAn
Copy link
Contributor

@LiUzHiAn LiUzHiAn commented Jul 10, 2021

This PR adds a Chinese version of the installation instructions (install.md) and the 4 super-resolution datasets description files (in tools/data/super-resolution/*/README.md).

@LiUzHiAn LiUzHiAn changed the title [Doc] Add Chinese translation of install.md [Doc] Add Chinese translation of install.md and 4 super-resolution datasets README.md Jul 10, 2021
Copy link
Member

@ckkelvinchan ckkelvinchan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some comments. Thank you very much for your help.

@@ -1,11 +1,96 @@
## 依赖

- Linux (Windows is not officially supported)
- Linux (目前Windows不是官方支持)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When switching between Chinese and English, please insert a space before and after. For example:

目前 Windows 不是官方支持

There are some more similar examples below.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it, will fix them later.

conda create -n open-mmlab python=3.7 -y
conda activate open-mmlab
```
b. 安装[PyTorch官方文档](https://pytorch.org/)安装PyTorch和torchvision,如:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to above

安装[PyTorch 官方文档](https://pytorch.org/)安装 PyTorch 和 torchvision,如:

conda create -n open-mmlab python=3.7 -y
conda activate open-mmlab
```
b. 按照 [PyTorch官方文档](https://pytorch.org/) 安装 PyTorch 和 torchvision,如:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PyTorch官方文档 -> PyTorch 官方文档

```shell script
conda install pytorch torchvision -c pytorch
```
注意:确保你的 CUDA 编译版本和 CUDA 运行版本相匹配。 用户可以参照 [PyTorch官网](https://pytorch.org/) 对预编译包所支持的 CUDA 版本进行核对。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PyTorch官网 -> PyTorch 官网


3. 如果用户想使用 `opencv-python-headless` 而不是 `opencv-python`,可在安装 `MMCV` 前安装 `opencv-python-headless`。

4. 有些模型(例如图像修复任务中的 `EDVR`)依赖于`mmcv-full`中的一些 CUDA 算子,具体的依赖可在`requirements.txt`中找到。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

依赖于mmcv-full中 -> 依赖于 mmcv-full

requirements.txt中 -> 在 requirements.txt

3. 如果用户想使用 `opencv-python-headless` 而不是 `opencv-python`,可在安装 `MMCV` 前安装 `opencv-python-headless`。

4. 有些模型(例如图像修复任务中的 `EDVR`)依赖于`mmcv-full`中的一些 CUDA 算子,具体的依赖可在`requirements.txt`中找到。
如需要,请通过 `pip install -r requirements.txt`命令来安装`mmcv-full`,安装过程中会在本地编译 CUDA 算子,这个过程大概需要10分钟。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

请通过 pip install -r requirements.txt命令 -> 请通过 pip install -r requirements.txt 命令


4. 有些模型(例如图像修复任务中的 `EDVR`)依赖于`mmcv-full`中的一些 CUDA 算子,具体的依赖可在`requirements.txt`中找到。
如需要,请通过 `pip install -r requirements.txt`命令来安装`mmcv-full`,安装过程中会在本地编译 CUDA 算子,这个过程大概需要10分钟。
另一种方案是安装预编译版本的`mmcv-full`,请参考 [MMCV主页](https://github.com/open-mmlab/mmcv#install-with-pip) 获取具体的安装指令。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

版本的mmcv-full -> 版本的 mmcv-full

MMCV主页 -> MMCV 主页

4. 有些模型(例如图像修复任务中的 `EDVR`)依赖于`mmcv-full`中的一些 CUDA 算子,具体的依赖可在`requirements.txt`中找到。
如需要,请通过 `pip install -r requirements.txt`命令来安装`mmcv-full`,安装过程中会在本地编译 CUDA 算子,这个过程大概需要10分钟。
另一种方案是安装预编译版本的`mmcv-full`,请参考 [MMCV主页](https://github.com/open-mmlab/mmcv#install-with-pip) 获取具体的安装指令。
此外,如果你要使用的模型不依赖于 CUDA 算子,那么也可以使用`pip install mmcv`来安装轻量版本的 mmcv,其中 CUDA 算子被移除了。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

使用pip install mmcv来 -> 使用 pip install mmcv

@@ -1 +1,9 @@
# 数据集 - 复原
# 超分辨数据集
建议将数据集的根目录链接到`$MMEDITING/data`下,如果你的文件目录结构不一致,那么你可能需要在配置文件中修改对应的文件路径。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$MMEDITING/data下 -> 到 $MMEDITING/data

- 训练集: [REDS 数据集](https://seungjunnah.github.io/Datasets/reds.html).
- 验证集: [REDS 数据集](https://seungjunnah.github.io/Datasets/reds.html) 和 Vid4.

请注意,我们合并了 REDS 的训练集和验证集,以便在 REDS4 划分(在`EDVR`中会使用到)和官方验证集划分之间切换。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

EDVR中 -> 在 EDVR


请注意,我们合并了 REDS 的训练集和验证集,以便在 REDS4 划分(在`EDVR`中会使用到)和官方验证集划分之间切换。

原始验证集的名称被修改了(clip 000 到 029),以避免与训练集发生冲突(总共 240 个clip)。具体而言,验证集中的 clips 被改名为 240、241、... 269。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

总共 240 个clip -> 总共240个 clip

@@ -14,3 +14,36 @@
publisher={Springer}
}
```
训练集和测试集可以从 [此处](http://toflow.csail.mit.edu/) 下载。

Vimeo90K 数据集包含了如下所示的`clip/sequence/img`目录结构:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

所示的clip/sequence/img目录 -> 所示的 clip/sequence/img 目录

@codecov
Copy link

codecov bot commented Jul 11, 2021

Codecov Report

Merging #424 (a842211) into master (efcc174) will not change coverage.
The diff coverage is n/a.

❗ Current head a842211 differs from pull request most recent head 0c8b62b. Consider uploading reports for the commit 0c8b62b to get more accurate results
Impacted file tree graph

@@           Coverage Diff           @@
##           master     #424   +/-   ##
=======================================
  Coverage   80.66%   80.66%           
=======================================
  Files         188      188           
  Lines       10107    10107           
  Branches     1485     1485           
=======================================
  Hits         8153     8153           
  Misses       1740     1740           
  Partials      214      214           
Flag Coverage Δ
unittests 80.64% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update efcc174...0c8b62b. Read the comment docs.

@ckkelvinchan
Copy link
Member

@LiUzHiAn Please install pre-commit. This helps you check the format of the modified files.

After installing pre-commit, you can cd mmediting and enter pre-commit install.

@LiUzHiAn
Copy link
Contributor Author

LiUzHiAn commented Jul 11, 2021

@LiUzHiAn Please install pre-commit. This helps you check the format of the modified files.

After installing pre-commit, you can cd mmediting and enter pre-commit install.

After executing pre-commit run --all-files, the yapf related error was raised, just something as :

yapf.....................................................................Failed
- hook id: yapf
- exit code: 1
...
...
 File "/home/liuzhian/anaconda3/envs/mmlab/lib/python3.6/lib2to3/pgen2/parse.py", line 159, in addtoken
    raise ParseError("bad input", type, value, context)
lib2to3.pgen2.parse.ParseError: bad input: type=3, value="'\\btitle\\s*=\\s*{{\\s*{p}\\s*}}.*?\\n## (.*?)\\s*[,;]?\\s*\\n'", context=('', (44, 19))

Any idea to fix that? Thanks for your time

@ckkelvinchan
Copy link
Member

@LiUzHiAn Please install pre-commit. This helps you check the format of the modified files.
After installing pre-commit, you can cd mmediting and enter pre-commit install.

After executing pre-commit run --all-files, the yapf related error was raised, just something as :

yapf.....................................................................Failed
- hook id: yapf
- exit code: 1
...
...
 File "/home/liuzhian/anaconda3/envs/mmlab/lib/python3.6/lib2to3/pgen2/parse.py", line 159, in addtoken
    raise ParseError("bad input", type, value, context)
lib2to3.pgen2.parse.ParseError: bad input: type=3, value="'\\btitle\\s*=\\s*{{\\s*{p}\\s*}}.*?\\n## (.*?)\\s*[,;]?\\s*\\n'", context=('', (44, 19))

Any idea to fix that? Thanks for your time

Usually, I commit the changes as usual. If pre-commit is installed, it will parse your files and change some minor formatting errors for you. You can try that.

@LiUzHiAn
Copy link
Contributor Author

LiUzHiAn commented Jul 11, 2021

@LiUzHiAn Please install pre-commit. This helps you check the format of the modified files.
After installing pre-commit, you can cd mmediting and enter pre-commit install.

After executing pre-commit run --all-files, the yapf related error was raised, just something as :

yapf.....................................................................Failed
- hook id: yapf
- exit code: 1
...
...
 File "/home/liuzhian/anaconda3/envs/mmlab/lib/python3.6/lib2to3/pgen2/parse.py", line 159, in addtoken
    raise ParseError("bad input", type, value, context)
lib2to3.pgen2.parse.ParseError: bad input: type=3, value="'\\btitle\\s*=\\s*{{\\s*{p}\\s*}}.*?\\n## (.*?)\\s*[,;]?\\s*\\n'", context=('', (44, 19))

Any idea to fix that? Thanks for your time

Usually, I commit the changes as usual. If pre-commit is installed, it will parse your files and change some minor formatting errors for you. You can try that.

I seem to find the reason. It's because some lines of code in mmedit/models/backbones/encoder_decoders/decoders/fba_decoder.py don't meet the yapf format, but I never modify. Just running pre-commit run will force the pre-commit to skip this issue.

Indeed, commit the changes as usual will also lead to the pre-commit run command. Anyway, I've committed my final Doc changes.

@ckkelvinchan
Copy link
Member

@LiUzHiAn Please install pre-commit. This helps you check the format of the modified files.
After installing pre-commit, you can cd mmediting and enter pre-commit install.

After executing pre-commit run --all-files, the yapf related error was raised, just something as :

yapf.....................................................................Failed
- hook id: yapf
- exit code: 1
...
...
 File "/home/liuzhian/anaconda3/envs/mmlab/lib/python3.6/lib2to3/pgen2/parse.py", line 159, in addtoken
    raise ParseError("bad input", type, value, context)
lib2to3.pgen2.parse.ParseError: bad input: type=3, value="'\\btitle\\s*=\\s*{{\\s*{p}\\s*}}.*?\\n## (.*?)\\s*[,;]?\\s*\\n'", context=('', (44, 19))

Any idea to fix that? Thanks for your time

Usually, I commit the changes as usual. If pre-commit is installed, it will parse your files and change some minor formatting errors for you. You can try that.

I seem to find the reason. It's because some lines of code in mmedit/models/backbones/encoder_decoders/decoders/fba_decoder.py don't meet the yapf format, but I never modify. Just running pre-commit run will force the pre-commit to skip this issue.

Indeed, commit the changes as usual will also lead to the pre-commit run command. Anyway, I've committed my final Doc changes.

It worked now, thanks!

@ckkelvinchan ckkelvinchan mentioned this pull request Jul 11, 2021
22 tasks
docs_zh-CN/install.md Outdated Show resolved Hide resolved
LiUzHiAn and others added 3 commits July 15, 2021 10:46
Signed-off-by: lizz <lizz@sensetime.com>
Signed-off-by: lizz <lizz@sensetime.com>
@innerlee innerlee merged commit a811bc2 into open-mmlab:master Jul 21, 2021
Yshuo-Li pushed a commit to Yshuo-Li/mmediting that referenced this pull request Jul 15, 2022
…tasets README.md (open-mmlab#424)

* [Doc] Add Chinese translation of install.md

* [Doc] Add Chinese translation of super-resolution datasets description files

* [Doc] insert a space bwtween Chinese and English

* [Doc] Add missing space between Chinese and English

* [Doc] Add mising EOF line

* fix typo

* Format

Signed-off-by: lizz <lizz@sensetime.com>

* More formats

Signed-off-by: lizz <lizz@sensetime.com>

Co-authored-by: lizz <lizz@sensetime.com>
@OpenMMLab-Coodinator
Copy link

Hi @LiUzHiAn !First of all, we want to express our gratitude for your significant PR in this project. Your contribution is highly appreciated, and we are grateful for your efforts in helping improve this open-source project during your personal time. We believe that many developers will benefit from your PR.

We would also like to invite you to join our Special Interest Group (SIG) private channel on Discord, where you can share your experiences, ideas, and build connections with like-minded peers. To join the SIG channel, simply message moderator— OpenMMLab on Discord or briefly share your open-source contributions in the #introductions channel and we will assist you. Look forward to seeing you there! Join us :https://discord.gg/UjgXkPWNqA

If you have WeChat account,welcome to join our community on WeChat. You can add our assistant :openmmlabwx. Please add "mmsig + Github ID" as a remark when adding friends:)
Thank you again for your contribution❤

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants