Commit 80a37498 authored by yongshk's avatar yongshk
Browse files

Initial commit

parents
Pipeline #3463 failed with stages
in 0 seconds
# Ignore all Dockerfiles
**/*dockerfile
# Ignore configuration files
.gitignore
.gitmodules
.editorconfig
.vscode/
# Ignore git
**/.git
# General
.DS_Store
__MACOSX/
.AppleDouble
.LSOverride
Icon[]
# Thumbnails
._*
# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent
# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
# Windows thumbnail cache files
Thumbs.db
Thumbs.db:encryptable
ehthumbs.db
ehthumbs_vista.db
# Dump file
*.stackdump
# Folder config file
[Dd]esktop.ini
# Recycle Bin used on file shares
$RECYCLE.BIN/
# Windows Installer files
*.cab
*.msi
*.msix
*.msm
*.msp
# Windows shortcuts
*.lnk
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
# This file defines what runs automatically before `git commit`
repos:
# ============================================================
# 1. Official pre-commit hooks (safety & hygiene)
#
# These hooks are:
# - extremely fast
# - non-controversial
# - designed to prevent costly mistakes
# ============================================================
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
# Prevent committing unresolved merge conflicts
- id: check-merge-conflict
# Remove trailing whitespace
- id: trailing-whitespace
# Ensure files end with a newline (POSIX requirement)
- id: end-of-file-fixer
# Prevent accidentally committing large files
# (model checkpoints, logs, datasets, etc.)
- id: check-added-large-files
args:
- "--maxkb=10240"
# Attempts to load all yaml files to verify syntax.
- id: check-yaml
# 排除 detectron2 使用了 pyyaml 语法的 yaml 文件
exclude: |
(?x)(
^common/base/autodrive/3rdparty/detectron2/configs/Base-RetinaNet\.yaml$ |
^common/base/autodrive/3rdparty/detectron2/projects/Panoptic-DeepLab/configs/COCO-PanopticSegmentation/panoptic_deeplab_R_52_os16_mg124_poly_200k_bs64_crop_640_640_coco_dsconv\.yaml$
)
# Attempts to load all json files to verify syntax.
- id: check-json
# Attempts to load all TOML files to verify syntax.
- id: check-toml
# Checks for symlinks which do not point to anything.
- id: check-symlinks
# 贡献指南
欢迎参与本项目的开发!为确保代码风格统一并提升协作效率,本项目使用 [pre-commit](https://pre-commit.com/) 框架在每次提交前自动执行代码格式化与检查。
## 环境准备
### 1. 安装 pre-commit
确保系统已安装 Python 3.9+ 和 pip3,然后安装 `pre-commit`
```bash
pip3 install pre-commit==4.5.1
```
或者使用 `uv` 安装:
```bash
uv tool install pre-commit==4.5.1 --python python3.11
```
### 2. 激活 Git Hooks
在项目根目录执行以下命令,将 pre-commit 钩子安装到本地 `.git/hooks` 中:
```bash
pre-commit install
```
## 工作流程
完成上述步骤后,每次执行 `git commit` 时,pre-commit 会自动运行以下检查:
| Hook | 说明 |
|------|------|
| `check-merge-conflict` | 检测未解决的合并冲突 |
| `trailing-whitespace` | 移除行尾空格 |
| `end-of-file-fixer` | 确保文件以换行符结尾 |
| `check-added-large-files` | 阻止提交大于 10MB 的文件 |
| `check-yaml` / `check-json` / `check-toml` | 校验配置文件语法 |
| `check-symlinks` | 检查无效符号链接 |
### 提交代码
```bash
git add .
git commit -m "feat: your message"
```
如果检查失败:
- **自动修复的问题**:重新 `git add` 修改后的文件,再次提交
- **需手动修复的问题**:根据终端提示修复后再提交
### (可选)手动运行检查
```bash
# 检查所有文件
pre-commit run --all-files
# 检查指定文件
pre-commit run --files path/to/file.py
```
## 常见问题
**Q: 如何跳过 pre-commit 检查?**
紧急情况下可使用 `--no-verify`,但不推荐:
```bash
git commit --no-verify -m "your message"
```
# Hygon-hub
海光测试镜像仓库。
## 贡献指南
为了提升协作效率,本项目使用 [pre-commit](https://pre-commit.com/) 框架在每次提交前自动执行代码格式化与检查。具体使用方式请参考 [CONTRIBUTING.md](./CONTRIBUTING.md)
## 镜像层级依赖关系
本项目的 Docker 镜像采用分层构建策略,各镜像之间存在依赖关系。下图展示了镜像的构建层级和目录位置:
```mermaid
flowchart TD
A["<b>🏭 Hygon PyTorch Base</b><br/><code>harbor.sourcefind.cn:5443/dcu/admin/base/pytorch</code><br/><br/>"]
B["<b>📦 PyTorch Common Base</b><br/><code>common/base/pytorch/</code><br/><br/>"]
C["<b>🚗 Autodrive</b><br/><code>common/base/autodrive/</code><br/><br/>"]
D["<b>💬 Megatron-LM</b><br/><code>common/base/megatron/</code><br/><br/>"]
E["<b>🎨 DiffSynth-Studio</b><br/><code>common/base/diffsynth-studio/</code><br/><br/>"]
F["<b>Qwen3</b><br/><code>models/Qwen2-3/</code><br/><br/>"]
G["<b>Wan2.2, FLUX.2, ...</b><br/><code>models/xxx/</code><br/><br/>"]
H["<b>BEVFormer, ...</b><br/><code>models/BEVFormer/</code><br/><br/>"]
A --> B
B --> C & D & E
C --> H
D --> F
E --> G
style A fill:#e1f5fe,stroke:#01579b,stroke-width:2px
style B fill:#fff3e0,stroke:#e65100,stroke-width:2px
style C fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px
style D fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px
style E fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px
style F fill:#e8f5e9,stroke:#2e7d32,stroke-width:2px
style G fill:#e8f5e9,stroke:#2e7d32,stroke-width:2px
style H fill:#e8f5e9,stroke:#2e7d32,stroke-width:2px
```
### 镜像层级说明
| 层级 | 名称 | 说明 | 构建目录 |
|------|------|------|----------|
| L0 | 海光官方镜像 | 由海光提供的 PyTorch DCU 基础镜像 | - |
| L1 | PyTorch 公共镜像 | 包含 SSH、网络、环境变量等通用配置 | `common/base/pytorch/` |
| L2 | 框架公共镜像 | 面向特定领域的框架镜像(自动驾驶/LLM/生成模型) | `common/base/<framework>/` |
| L3 | 模型镜像 | 特定模型的训练镜像 | `models/<model>/` |
### 构建顺序
构建镜像时需要按照依赖顺序进行:
1. **L1**: 先构建 `common/base/pytorch/dockerfile`
2. **L2**: 再构建框架镜像(如 `common/base/autodrive/dockerfile`
3. **L3**: 最后构建具体模型镜像(如 `models/BEVFormer/dockerfile`
> ⚠️ **注意**: 构建下层镜像前,请确保其依赖的上层镜像已经构建完成并正确推送到镜像仓库。
## 项目目录结构
```
TrainingPerfBench/
├── common/ # 公共文件
│ ├── base/ # 基础框架镜像目录
│ │ ├── diffsynth-studio/ # DiffSynthStudio 目录
│ │ │ ├── DiffSynth-Studio/ # DiffSynthStudio 项目源码
│ │ │ ├── dockerfile # DiffSynthStudio 基础镜像 dockerfile
│ │ │ └── README.md # 镜像构建命令
│ │ │
│ │ ├── megatron/ # Megatron-LM 目录
│ │ │ ├── Megatron-LM/ # Megatron-LM 项目源码
│ │ │ ├── dockerfile # Megatron-LM 基础镜像 dockerfile
│ │ │ └── README.md # 镜像构建命令
│ │ └── ...
│ │
│ └── utils/ # 通用工具脚本
│ ├── download_utils.sh
│ └── run_cmd.sh
├── models/ # 模型特定训练镜像
│ ├── Qwen2-3/ # Qwen 2/3 训练
│ │ ├── dockerfile
│ │ ├── train_qwen.sh
│ │ ├── download_datasets.sh
│ │ └── README.md # 镜像构建命令
│ │
│ ├── Qwen2.5VL/ # Qwen 2.5 多模态视觉语言模型
│ ├── Wan2/ # Wan2 模型
│ └── ...
├── .dockerignore
├── .gitignore
├── .gitmodules
└── README.md
```
AccessModifierOffset: -1
AlignAfterOpenBracket: AlwaysBreak
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlinesLeft: true
AlignOperands: false
AlignTrailingComments: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: Empty
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: true
BinPackArguments: false
BinPackParameters: false
BraceWrapping:
AfterClass: false
AfterControlStatement: false
AfterEnum: false
AfterFunction: false
AfterNamespace: false
AfterObjCDeclaration: false
AfterStruct: false
AfterUnion: false
BeforeCatch: false
BeforeElse: false
IndentBraces: false
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Attach
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: false
ColumnLimit: 80
CommentPragmas: '^ IWYU pragma:'
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat: false
ForEachMacros: [ FOR_EACH, FOR_EACH_R, FOR_EACH_RANGE, ]
IncludeCategories:
- Regex: '^<.*\.h(pp)?>'
Priority: 1
- Regex: '^<.*'
Priority: 2
- Regex: '.*'
Priority: 3
IndentCaseLabels: true
IndentWidth: 2
IndentWrappedFunctionNames: false
KeepEmptyLinesAtTheStartOfBlocks: false
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: false
PenaltyBreakBeforeFirstCallParameter: 1
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Left
ReflowComments: true
SortIncludes: true
SpaceAfterCStyleCast: false
SpaceBeforeAssignmentOperators: true
SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Cpp11
TabWidth: 8
UseTab: Never
# This is an example .flake8 config, used when developing *Black* itself.
# Keep in sync with setup.cfg which is used for source packages.
[flake8]
ignore = W503, E203, E221, C901, C408, E741, C407, B017, F811, C101, EXE001, EXE002
max-line-length = 100
max-complexity = 18
select = B,C,E,F,W,T4,B9
exclude = build
per-file-ignores =
**/__init__.py:F401,F403,E402
**/configs/**.py:F401,E402
configs/**.py:F401,E402
**/tests/config/**.py:F401,E402
tests/config/**.py:F401,E402
# Code of Conduct
Facebook has adopted a Code of Conduct that we expect project participants to adhere to.
Please read the [full text](https://code.fb.com/codeofconduct/)
so that you can understand what actions will and will not be tolerated.
# Contributing to detectron2
## Issues
We use GitHub issues to track public bugs and questions.
Please make sure to follow one of the
[issue templates](https://github.com/facebookresearch/detectron2/issues/new/choose)
when reporting any issues.
Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe
disclosure of security bugs. In those cases, please go through the process
outlined on that page and do not file a public issue.
## Pull Requests
We actively welcome pull requests.
However, if you're adding any significant features (e.g. > 50 lines), please
make sure to discuss with maintainers about your motivation and proposals in an issue
before sending a PR. This is to save your time so you don't spend time on a PR that we'll not accept.
We do not always accept new features, and we take the following
factors into consideration:
1. Whether the same feature can be achieved without modifying detectron2.
Detectron2 is designed so that you can implement many extensions from the outside, e.g.
those in [projects](https://github.com/facebookresearch/detectron2/tree/master/projects).
* If some part of detectron2 is not extensible enough, you can also bring up a more general issue to
improve it. Such feature request may be useful to more users.
2. Whether the feature is potentially useful to a large audience (e.g. an impactful detection paper, a popular dataset,
a significant speedup, a widely useful utility),
or only to a small portion of users (e.g., a less-known paper, an improvement not in the object
detection field, a trick that's not very popular in the community, code to handle a non-standard type of data)
* Adoption of additional models, datasets, new task are by default not added to detectron2 before they
receive significant popularity in the community.
We sometimes accept such features in `projects/`, or as a link in `projects/README.md`.
3. Whether the proposed solution has a good design / interface. This can be discussed in the issue prior to PRs, or
in the form of a draft PR.
4. Whether the proposed solution adds extra mental/practical overhead to users who don't
need such feature.
5. Whether the proposed solution breaks existing APIs.
To add a feature to an existing function/class `Func`, there are always two approaches:
(1) add new arguments to `Func`; (2) write a new `Func_with_new_feature`.
To meet the above criteria, we often prefer approach (2), because:
1. It does not involve modifying or potentially breaking existing code.
2. It does not add overhead to users who do not need the new feature.
3. Adding new arguments to a function/class is not scalable w.r.t. all the possible new research ideas in the future.
When sending a PR, please do:
1. If a PR contains multiple orthogonal changes, split it to several PRs.
2. If you've added code that should be tested, add tests.
3. For PRs that need experiments (e.g. adding a new model or new methods),
you don't need to update model zoo, but do provide experiment results in the description of the PR.
4. If APIs are changed, update the documentation.
5. We use the [Google style docstrings](https://www.sphinx-doc.org/en/master/usage/extensions/napoleon.html) in python.
6. Make sure your code lints with `./dev/linter.sh`.
## Contributor License Agreement ("CLA")
In order to accept your pull request, we need you to submit a CLA. You only need
to do this once to work on any of Facebook's open source projects.
Complete your CLA here: <https://code.facebook.com/cla>
## License
By contributing to detectron2, you agree that your contributions will be licensed
under the LICENSE file in the root directory of this source tree.
<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1930.09 354.96"><defs><style>.cls-1{fill:#aab4bc;}.cls-2{fill:#d2d6d7;}.cls-3{fill:#9da2ab;}.cls-4{fill:#e7eef1;}.cls-5{fill:#5173f1;}.cls-6{opacity:0.7;}.cls-7{fill:#797f89;}.cls-8{fill:#e3e7e9;}.cls-9{fill:#161622;}.cls-10{fill:#3f4652;}.cls-11{fill:#fff;}</style></defs><title>Detectron2-Logo-Horz</title><path class="cls-1" d="M191.24,31h71.34a4.87,4.87,0,0,1,4.87,4.87v5a0,0,0,0,1,0,0H186.38a0,0,0,0,1,0,0v-5A4.87,4.87,0,0,1,191.24,31Z"/><path class="cls-2" d="M412.92,100.67V263.61c0,.69,0,1.33,0,2a59.73,59.73,0,0,1-59.73,57.74H100.73A59.8,59.8,0,0,1,40.9,263.61V100.67c0-.69,0-1.33,0-2a59.33,59.33,0,0,1,8.79-29.21c.76-1.24,1.57-2.46,2.42-3.64A59.76,59.76,0,0,1,100.73,40.9H353.15a59.78,59.78,0,0,1,59.77,59.77Z"/><rect class="cls-3" x="198.81" y="262.89" width="55.95" height="41.28" rx="10.15"/><path class="cls-4" d="M244.61,260.72H209A12.33,12.33,0,0,0,196.64,273v21A12.33,12.33,0,0,0,209,306.33h35.65A12.32,12.32,0,0,0,256.92,294V273A12.32,12.32,0,0,0,244.61,260.72ZM209,265.05h35.65a8,8,0,0,1,8,8v1.45H201V273A8,8,0,0,1,209,265.05Zm43.63,13.76v9.43H201v-9.43Zm-8,23.19H209a8,8,0,0,1-8-8v-1.44h51.61V294A8,8,0,0,1,244.61,302Z"/><path class="cls-1" d="M382.21,177.18h71.34a4.87,4.87,0,0,1,4.87,4.87v5a0,0,0,0,1,0,0H377.35a0,0,0,0,1,0,0v-5A4.87,4.87,0,0,1,382.21,177.18Z" transform="translate(600.02 -235.74) rotate(90)"/><path class="cls-1" d="M.28,177.18H71.62a4.87,4.87,0,0,1,4.87,4.87v5a0,0,0,0,1,0,0H-4.59a0,0,0,0,1,0,0v-5A4.87,4.87,0,0,1,.28,177.18Z" transform="translate(-146.19 218.09) rotate(-90)"/><circle class="cls-1" cx="83.04" cy="283.53" r="6.28"/><circle class="cls-1" cx="370.79" cy="283.53" r="6.28"/><circle class="cls-1" cx="226.91" cy="66.06" r="6.28"/><circle class="cls-5" cx="368.44" cy="82.89" r="20.49"/><polygon class="cls-1" points="412.92 179.98 316.61 179.98 312.27 179.98 141.55 179.98 137.21 179.98 40.9 179.98 40.9 184.3 137.21 184.3 137.21 323.38 141.55 323.38 141.55 184.3 312.27 184.3 312.27 323.38 316.61 323.38 316.61 184.3 412.92 184.3 412.92 179.98"/><g class="cls-6"><path class="cls-7" d="M403.72,193a81.13,81.13,0,1,1-81.15-81.1A81.12,81.12,0,0,1,403.72,193Z"/></g><path class="cls-8" d="M313.71,104.06a76.74,76.74,0,1,0,76.74,76.74A76.75,76.75,0,0,0,313.71,104.06Zm0,132.48a55.74,55.74,0,1,1,55.73-55.74A55.8,55.8,0,0,1,313.71,236.54Z"/><path class="cls-9" d="M376.27,180.79a62.57,62.57,0,1,1-125.13,0,61,61,0,0,1,1.93-15.33,62.55,62.55,0,0,1,123.2,15.33Z"/><path class="cls-3" d="M313.71,121.19a59.6,59.6,0,1,1-59.6,59.6A57.93,57.93,0,0,1,256,166.18a59.72,59.72,0,0,1,57.76-45m0-3.65a63.36,63.36,0,0,0-61.3,47.75,61.81,61.81,0,0,0-1.95,15.5,63.25,63.25,0,1,0,63.25-63.25Z"/><g class="cls-6"><path class="cls-7" d="M228.66,193a81.12,81.12,0,1,1-81.14-81.1A81.11,81.11,0,0,1,228.66,193Z"/></g><path class="cls-8" d="M138.65,104.06A76.74,76.74,0,1,0,215.4,180.8,76.74,76.74,0,0,0,138.65,104.06Zm0,132.48a55.74,55.74,0,1,1,55.74-55.74A55.8,55.8,0,0,1,138.65,236.54Z"/><path class="cls-9" d="M201.22,180.79a62.57,62.57,0,1,1-125.13,0A61,61,0,0,1,78,165.46a62.55,62.55,0,0,1,123.2,15.33Z"/><path class="cls-3" d="M138.65,121.19a59.6,59.6,0,1,1-59.6,59.6,58.38,58.38,0,0,1,1.84-14.61,59.72,59.72,0,0,1,57.76-45m0-3.65a63.39,63.39,0,0,0-61.3,47.75,62.28,62.28,0,0,0-1.94,15.5,63.25,63.25,0,1,0,63.24-63.25Z"/><circle class="cls-10" cx="313.71" cy="180.79" r="29"/><circle class="cls-10" cx="138.65" cy="180.79" r="29"/><circle class="cls-11" cx="154.83" cy="156.49" r="12.7"/><circle class="cls-11" cx="329.89" cy="156.49" r="12.7"/><path class="cls-1" d="M312.27,40.91V81.77a100.32,100.32,0,0,0-72.71,33.61H214.3A100.51,100.51,0,0,0,142,81.82V40.9h-4.33V81.77A99.56,99.56,0,0,0,86.17,97.06l-34-31.27c-.85,1.18-1.66,2.4-2.42,3.64l36,33.1,0,0a95.88,95.88,0,0,1,126,16.46l.65.74h29.18l.65-.74a96,96,0,0,1,72.27-32.89h2.17V40.91Z"/><path class="cls-5" d="M1899.11,280.92H1758.56V251.65l81.53-77.75q19.44-18.35,19.44-39.32,0-14.55-9-23.29t-24.15-8.74q-16.59,0-25,9.6t-8.44,25.32l.87,9.6h-35.21a77.72,77.72,0,0,1-.58-10.19q0-30,18.77-48.45T1826.36,70q32,0,50.48,17.75t18.48,46q0,20.08-8,35.49t-27.22,32.29l-52.95,46.87h92Z"/><path class="cls-10" d="M557.9,280.92H487.77V74.32H557.9q52.38,0,81.62,28.37t29.24,74.93q0,46.56-29.24,74.93T557.9,280.92Zm54.85-51.36q18.76-18.76,18.77-51.94t-18.77-51.94q-18.76-18.77-56-18.77H523V248.33h33.76Q594,248.33,612.75,229.56Z"/><path class="cls-10" d="M826.87,215.45H711.93q2,18,13.1,28.66t29.1,10.62a40.72,40.72,0,0,0,21.53-5.82,32.61,32.61,0,0,0,13.68-15.71h34.91a70.46,70.46,0,0,1-26,37.1q-19.07,14.11-45,14.11-33.75,0-54.56-22.41t-20.8-56.74q0-33.45,21-56.15T753,126.41q33.18,0,53.69,22.26t20.51,56ZM753,154.63q-16.29,0-27.06,9.61t-13.38,25.6h80.31q-2.34-16-12.81-25.6T753,154.63Z"/><path class="cls-10" d="M915.19,250.08v30q-6.41,1.74-18,1.74-44.24,0-44.23-44.52V157.54h-23V129.9h23V90.62h34.63V129.9h28.22v27.64H887.55v76.24q0,17.76,16.88,17.75Z"/><path class="cls-10" d="M1075.48,215.45H960.54q2,18,13.09,28.66t29.1,10.62a40.72,40.72,0,0,0,21.53-5.82,32.55,32.55,0,0,0,13.68-15.71h34.92a70.48,70.48,0,0,1-26,37.1q-19.05,14.11-44.95,14.11-33.76,0-54.56-22.41t-20.8-56.74q0-33.45,20.94-56.15t54.13-22.7q33.16,0,53.68,22.26t20.52,56Zm-73.91-60.82q-16.3,0-27.06,9.61t-13.39,25.6h80.31q-2.33-16-12.8-25.6T1001.57,154.63Z"/><path class="cls-10" d="M1086.1,205.56q0-33.47,21.24-56.31t54.13-22.84q31.13,0,49.61,17.6t22,40.59h-35.5a36,36,0,0,0-13-20.08q-9.75-7.56-23.42-7.56-18.33,0-29.39,13.53t-11.06,35.07q0,21.52,11.06,34.91t29.39,13.39q13.66,0,23.42-7.57a35.88,35.88,0,0,0,13-20.08h35.5q-3.49,23-22,40.6t-49.61,17.6q-32.9,0-54.13-22.84T1086.1,205.56Z"/><path class="cls-10" d="M1322.58,250.08v30q-6.4,1.74-18,1.74-44.22,0-44.23-44.52V157.54h-23V129.9h23V90.62h34.63V129.9h28.23v27.64h-28.23v76.24q0,17.76,16.88,17.75Z"/><path class="cls-10" d="M1428.44,128.74V161a55.4,55.4,0,0,0-7.85-.59q-39,0-39,41.91v78.56H1347v-151h32v20.95q12.8-22.41,44.51-22.41Z"/><path class="cls-10" d="M1507.79,284.41q-34.92,0-56.6-23t-21.67-55.86q0-32.9,21.67-56t56.6-23.13q35.2,0,56.89,23.13t21.68,56q0,32.88-21.68,55.86T1507.79,284.41Zm-43.65-78.85q0,21.52,12.37,34.91t31.28,13.39q19.2,0,31.57-13.39t12.37-34.91q0-21.84-12.37-35.21T1507.79,157q-18.91,0-31.28,13.39T1464.14,205.56Z"/><path class="cls-10" d="M1631.22,129.9V150q5.25-9.9,17.32-16.74t29.24-6.83q26.78,0,41.47,16.29t14.69,43.36v94.86h-34.63v-90.5q0-16-7.42-25.17t-22.55-9.16q-16.58,0-26,9.89t-9.46,27.35v87.59h-34.62v-151Z"/></svg>
Please select an issue template from
https://github.com/facebookresearch/detectron2/issues/new/choose .
Otherwise your issue will be closed.
---
name: "🐛 Bugs"
about: Report bugs in detectron2
title: Please read & provide the following
---
## Instructions To Reproduce the 🐛 Bug:
1. Full runnable code or full changes you made:
```
If making changes to the project itself, please use output of the following command:
git rev-parse HEAD; git diff
<put code or diff here>
```
2. What exact command you run:
3. __Full logs__ or other relevant observations:
```
<put logs here>
```
4. please simplify the steps as much as possible so they do not require additional resources to
run, such as a private dataset.
## Expected behavior:
If there are no obvious error in "full logs" provided above,
please tell us the expected behavior.
## Environment:
Provide your environment information using the following command:
```
wget -nc -q https://github.com/facebookresearch/detectron2/raw/main/detectron2/utils/collect_env.py && python collect_env.py
```
If your issue looks like an installation issue / environment issue,
please first try to solve it yourself with the instructions in
https://detectron2.readthedocs.io/tutorials/install.html#common-installation-issues
# require an issue template to be chosen
blank_issues_enabled: false
contact_links:
- name: How-To / All Other Questions
url: https://github.com/facebookresearch/detectron2/discussions
about: Use "github discussions" for community support on general questions that don't belong to the above issue categories
- name: Detectron2 Documentation
url: https://detectron2.readthedocs.io/index.html
about: Check if your question is answered in tutorials or API docs
# Unexpected behaviors & bugs are split to two templates.
# When they are one template, users think "it's not a bug" and don't choose the template.
#
# But the file name is still "unexpected-problems-bugs.md" so that old references
# to this issue template still works.
# It's ok since this template should be a superset of "bugs.md" (unexpected behaviors is a superset of bugs)
---
name: "\U0001F4DA Documentation Issue"
about: Report a problem about existing documentation, comments, website or tutorials.
labels: documentation
---
## 📚 Documentation Issue
This issue category is for problems about existing documentation, not for asking how-to questions.
* Provide a link to an existing documentation/comment/tutorial:
* How should the above documentation/comment/tutorial improve:
---
name: "\U0001F680Feature Request"
about: Suggest an improvement or new feature
labels: enhancement
---
## 🚀 Feature
A clear and concise description of the feature proposal.
## Motivation & Examples
Tell us why the feature is useful.
Describe what the feature would look like, if it is implemented.
Best demonstrated using **code examples** in addition to words.
## Note
We only consider adding new features if they are relevant to many users.
If you request implementation of research papers -- we only consider papers that have enough significance and prevalance in the object detection field.
We do not take requests for most projects in the `projects/` directory, because they are research code release that is mainly for other researchers to reproduce results.
"Make X faster/accurate" is not a valid feature request. "Implement a concrete feature that can make X faster/accurate" can be a valid feature request.
Instead of adding features inside detectron2,
you can implement many features by [extending detectron2](https://detectron2.readthedocs.io/tutorials/extend.html).
The [projects/](https://github.com/facebookresearch/detectron2/tree/main/projects/) directory contains many of such examples.
---
name: "😩 Unexpected behaviors"
about: Report unexpected behaviors when using detectron2
title: Please read & provide the following
---
If you do not know the root cause of the problem, please post according to this template:
## Instructions To Reproduce the Issue:
Check https://stackoverflow.com/help/minimal-reproducible-example for how to ask good questions.
Simplify the steps to reproduce the issue using suggestions from the above link, and provide them below:
1. Full runnable code or full changes you made:
```
If making changes to the project itself, please use output of the following command:
git rev-parse HEAD; git diff
<put code or diff here>
```
2. What exact command you run:
3. __Full logs__ or other relevant observations:
```
<put logs here>
```
## Expected behavior:
If there are no obvious crash in "full logs" provided above,
please tell us the expected behavior.
If you expect a model to converge / work better, we do not help with such issues, unless
a model fails to reproduce the results in detectron2 model zoo, or proves existence of bugs.
## Environment:
Paste the output of the following command:
```
wget -nc -nv https://github.com/facebookresearch/detectron2/raw/main/detectron2/utils/collect_env.py && python collect_env.py
```
If your issue looks like an installation issue / environment issue,
please first check common issues in https://detectron2.readthedocs.io/tutorials/install.html#common-installation-issues
name: "Install Detectron2"
runs:
using: composite
steps:
- name: Install Detectron2
shell: bash
run: |
# Remove first, in case it's in the CI cache
pip uninstall -y detectron2
pip install --progress-bar off -e .[all]
python -m detectron2.utils.collect_env
./datasets/prepare_for_tests.sh
name: "Install Detectron2"
runs:
using: composite
steps:
- name: Install Detectron2
shell: bash
run: |
# Remove first, in case it's in the CI cache
pip uninstall -y detectron2
pip install --progress-bar off -e .[all]
python -m detectron2.utils.collect_env
# TODO: this command fails because windows does not have wget
# ./datasets/prepare_for_tests.sh
name: "Install Dependencies"
inputs:
torch-version:
description: torch version to install
torchvision-version:
description: torch vision version to install, version number or "master"
pytorch-index:
description: where to install torch from
required: false
default: "https://download.pytorch.org/whl/torch_stable.html"
# use test wheels index to have access to RC wheels
# https://download.pytorch.org/whl/test/torch_test.html
runs:
using: composite
steps:
- name: Install Dependencies
shell: bash
run: |
# disable crash coredump, so unittests fail fast
sudo systemctl stop apport.service || true
pip install -U pip
# install from github to get latest; install iopath first since fvcore depends on it
pip install --progress-bar off -U 'git+https://github.com/facebookresearch/iopath'
pip install --progress-bar off -U 'git+https://github.com/facebookresearch/fvcore'
# Don't use pytest-xdist: cuda tests are unstable under multi-process workers.
# Don't use opencv 4.7.0.68: https://github.com/opencv/opencv-python/issues/765
pip install --progress-bar off ninja opencv-python-headless!=4.7.0.68 pytest tensorboard pycocotools onnx
pip install --progress-bar off torch==${{inputs.torch-version}} -f ${{inputs.pytorch-index}}
if [[ "${{inputs.torchvision-version}}" == "master" ]]; then
pip install git+https://github.com/pytorch/vision.git
else
pip install --progress-bar off torchvision==${{inputs.torchvision-version}} -f ${{inputs.pytorch-index}}
fi
echo python install path: $pythonLocation
python -c 'import torch; print("CUDA:", torch.cuda.is_available())'
gcc --version
name: "Install GPU Dependencies"
inputs:
cuda-version:
description: version of cuda to install, ie "12-5" for 12.5
runs:
using: composite
steps:
- name: Install GPU Dependencies
shell: bash
run: |
uname -r
# https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html#network-repo-installation-for-ubuntu
# Installing the keyring seems to be unnecessary
sudo apt-get update
apt-cache search cuda-toolkit
sudo apt-get --yes install cuda-toolkit-${{inputs.cuda-version}}
sudo apt-get --yes install nvidia-gds-${{inputs.cuda-version}}
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