Skip to content

Commit b833f7a

Browse files
committed
Initial commit for cuOpt OSS
0 parents  commit b833f7a

File tree

733 files changed

+162264
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

733 files changed

+162264
-0
lines changed

.clang-format

Lines changed: 164 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,164 @@
1+
---
2+
# Refer to the following link for the explanation of each params:
3+
# http://releases.llvm.org/8.0.0/tools/clang/docs/ClangFormatStyleOptions.html
4+
Language: Cpp
5+
# BasedOnStyle: Google
6+
AccessModifierOffset: -1
7+
AlignAfterOpenBracket: Align
8+
AlignConsecutiveAssignments: true
9+
AlignConsecutiveBitFields: true
10+
AlignConsecutiveDeclarations: false
11+
AlignConsecutiveMacros: true
12+
AlignEscapedNewlines: Left
13+
AlignOperands: true
14+
AlignTrailingComments: true
15+
AllowAllArgumentsOnNextLine: true
16+
AllowAllConstructorInitializersOnNextLine: true
17+
AllowAllParametersOfDeclarationOnNextLine: true
18+
AllowShortBlocksOnASingleLine: true
19+
AllowShortCaseLabelsOnASingleLine: true
20+
AllowShortEnumsOnASingleLine: true
21+
AllowShortFunctionsOnASingleLine: All
22+
AllowShortIfStatementsOnASingleLine: true
23+
AllowShortLambdasOnASingleLine: true
24+
AllowShortLoopsOnASingleLine: false
25+
# This is deprecated
26+
AlwaysBreakAfterDefinitionReturnType: None
27+
AlwaysBreakAfterReturnType: None
28+
AlwaysBreakBeforeMultilineStrings: true
29+
AlwaysBreakTemplateDeclarations: Yes
30+
BinPackArguments: false
31+
BinPackParameters: false
32+
BraceWrapping:
33+
AfterClass: false
34+
AfterControlStatement: false
35+
AfterEnum: false
36+
AfterFunction: false
37+
AfterNamespace: false
38+
AfterObjCDeclaration: false
39+
AfterStruct: false
40+
AfterUnion: false
41+
AfterExternBlock: false
42+
BeforeCatch: false
43+
BeforeElse: false
44+
IndentBraces: false
45+
# disabling the below splits, else, they'll just add to the vertical length of source files!
46+
SplitEmptyFunction: false
47+
SplitEmptyRecord: false
48+
SplitEmptyNamespace: false
49+
BreakAfterJavaFieldAnnotations: false
50+
BreakBeforeBinaryOperators: None
51+
BreakBeforeBraces: WebKit
52+
BreakBeforeInheritanceComma: false
53+
BreakBeforeTernaryOperators: true
54+
BreakConstructorInitializersBeforeComma: false
55+
BreakConstructorInitializers: BeforeColon
56+
BreakInheritanceList: BeforeColon
57+
BreakStringLiterals: true
58+
ColumnLimit: 100
59+
CommentPragmas: '^ IWYU pragma:'
60+
CompactNamespaces: false
61+
ConstructorInitializerAllOnOneLineOrOnePerLine: true
62+
# Kept the below 2 to be the same as `IndentWidth` to keep everything uniform
63+
ConstructorInitializerIndentWidth: 2
64+
ContinuationIndentWidth: 2
65+
Cpp11BracedListStyle: true
66+
DerivePointerAlignment: false
67+
DisableFormat: false
68+
ExperimentalAutoDetectBinPacking: false
69+
FixNamespaceComments: true
70+
ForEachMacros:
71+
- foreach
72+
- Q_FOREACH
73+
- BOOST_FOREACH
74+
IncludeBlocks: Preserve
75+
IncludeCategories:
76+
- Regex: '^<ext/.*\.h>'
77+
Priority: 2
78+
- Regex: '^<.*\.h>'
79+
Priority: 1
80+
- Regex: '^<.*'
81+
Priority: 2
82+
- Regex: '.*'
83+
Priority: 3
84+
IncludeIsMainRegex: '([-_](test|unittest))?$'
85+
IndentCaseLabels: true
86+
IndentPPDirectives: None
87+
IndentWidth: 2
88+
IndentWrappedFunctionNames: false
89+
JavaScriptQuotes: Leave
90+
JavaScriptWrapImports: true
91+
KeepEmptyLinesAtTheStartOfBlocks: false
92+
MacroBlockBegin: ''
93+
MacroBlockEnd: ''
94+
MaxEmptyLinesToKeep: 1
95+
NamespaceIndentation: None
96+
ObjCBinPackProtocolList: Never
97+
ObjCBlockIndentWidth: 2
98+
ObjCSpaceAfterProperty: false
99+
ObjCSpaceBeforeProtocolList: true
100+
PenaltyBreakAssignment: 2
101+
PenaltyBreakBeforeFirstCallParameter: 1
102+
PenaltyBreakComment: 300
103+
PenaltyBreakFirstLessLess: 120
104+
PenaltyBreakString: 1000
105+
PenaltyBreakTemplateDeclaration: 10
106+
PenaltyExcessCharacter: 1000000
107+
PenaltyReturnTypeOnItsOwnLine: 200
108+
PointerAlignment: Left
109+
RawStringFormats:
110+
- Language: Cpp
111+
Delimiters:
112+
- cc
113+
- CC
114+
- cpp
115+
- Cpp
116+
- CPP
117+
- 'c++'
118+
- 'C++'
119+
CanonicalDelimiter: ''
120+
- Language: TextProto
121+
Delimiters:
122+
- pb
123+
- PB
124+
- proto
125+
- PROTO
126+
EnclosingFunctions:
127+
- EqualsProto
128+
- EquivToProto
129+
- PARSE_PARTIAL_TEXT_PROTO
130+
- PARSE_TEST_PROTO
131+
- PARSE_TEXT_PROTO
132+
- ParseTextOrDie
133+
- ParseTextProtoOrDie
134+
CanonicalDelimiter: ''
135+
BasedOnStyle: google
136+
# Enabling comment reflow causes doxygen comments to be messed up in their formats!
137+
ReflowComments: true
138+
SortIncludes: true
139+
SortUsingDeclarations: true
140+
SpaceAfterCStyleCast: false
141+
SpaceAfterTemplateKeyword: true
142+
SpaceBeforeAssignmentOperators: true
143+
SpaceBeforeCpp11BracedList: false
144+
SpaceBeforeCtorInitializerColon: true
145+
SpaceBeforeInheritanceColon: true
146+
SpaceBeforeParens: ControlStatements
147+
SpaceBeforeRangeBasedForLoopColon: true
148+
SpaceBeforeSquareBrackets: false
149+
SpaceInEmptyBlock: false
150+
SpaceInEmptyParentheses: false
151+
SpacesBeforeTrailingComments: 2
152+
SpacesInAngles: false
153+
SpacesInConditionalStatement: false
154+
SpacesInContainerLiterals: true
155+
SpacesInCStyleCastParentheses: false
156+
SpacesInParentheses: false
157+
SpacesInSquareBrackets: false
158+
Standard: c++17
159+
StatementMacros:
160+
- Q_UNUSED
161+
- QT_REQUIRE_VERSION
162+
# Be consistent with indent-width, even for people who use tab for indentation!
163+
TabWidth: 2
164+
UseTab: Never

.flake8

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2023-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+
# SPDX-License-Identifier: Apache-2.0
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
[flake8]
17+
filename = *.py, *.pyx, *.pxd, *.pxi
18+
exclude = __init__.py, *.egg, build, docs, .git
19+
force-check = True
20+
ignore =
21+
# line break before binary operator
22+
W503,
23+
# whitespace before :
24+
E203
25+
per-file-ignores =
26+
# Rules ignored only in Cython:
27+
# E211: whitespace before '(' (used in multi-line imports)
28+
# E225: Missing whitespace around operators (breaks cython casting syntax like <int>)
29+
# E226: Missing whitespace around arithmetic operators (breaks cython pointer syntax like int*)
30+
# E227: Missing whitespace around bitwise or shift operator (Can also break casting syntax)
31+
# E275: Missing whitespace after keyword (Doesn't work with Cython except?)
32+
# E402: invalid syntax (works for Python, not Cython)
33+
# E999: invalid syntax (works for Python, not Cython)
34+
# W504: line break after binary operator (breaks lines that end with a pointer)
35+
*.pyx: E211, E225, E226, E227, E275, E402, E999, W504
36+
*.pxd: E211, E225, E226, E227, E275, E402, E999, W504
37+
*.pxi: E211, E225, E226, E227, E275, E402, E999, W504

.github/CODEOWNERS

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#cpp code owners
2+
cpp/ @rapidsai/cuopt-cpp-codeowners
3+
4+
#python code owners
5+
python/ @rapidsai/cuopt-python-codeowners
6+
notebooks/ @rapidsai/cuopt-python-codeowners
7+
docs/ @rapidsai/cuopt-python-codeowners
8+
9+
#infra code owners
10+
**/CMakeLists.txt @rapidsai/cuopt-infra-codeowners
11+
**/cmake/ @rapidsai/cuopt-infra-codeowners
12+
container-builder/ @rapidsai/cuopt-infra-codeowners
13+
14+
#CI code owners
15+
/.github/ @rapidsai/ci-codeowners
16+
/ci/ @rapidsai/ci-codeowners
17+
/.pre-commit-config.yaml @rapidsai/ci-codeowners
18+
19+
#packaging code owners
20+
/.devcontainer/ @rapidsai/packaging-codeowners
21+
/conda/ @rapidsai/packaging-codeowners
22+
/dependencies.yaml @rapidsai/packaging-codeowners
23+
/build.sh @rapidsai/packaging-codeowners
24+
pyproject.toml @rapidsai/packaging-codeowners
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
name: Bug report
3+
about: Create a bug report to help us improve cuOpt
4+
title: "[BUG]"
5+
labels: "? - Needs Triage, bug"
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**Steps/Code to reproduce bug**
14+
Follow this guide http://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports to craft a minimal bug report. This helps us reproduce the issue you're having and resolve the issue more quickly.
15+
16+
**Expected behavior**
17+
A clear and concise description of what you expected to happen.
18+
19+
**Environment details (please complete the following information):**
20+
- Environment location: [Bare-metal, Docker, Cloud(specify cloud provider)]
21+
- Method of cuOpt install: [conda, Docker, or from source]
22+
- If method of install is [Docker], provide `docker pull` & `docker run` commands used
23+
24+
25+
**Additional context**
26+
Add any other context about the problem here.
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
---
2+
name: Documentation request
3+
about: Report incorrect or needed documentation
4+
title: "[DOC]"
5+
labels: "? - Needs Triage, doc"
6+
assignees: ''
7+
8+
---
9+
10+
## Report incorrect documentation
11+
12+
**Location of incorrect documentation**
13+
Provide links and line numbers if applicable.
14+
15+
**Describe the problems or issues found in the documentation**
16+
A clear and concise description of what you found to be incorrect.
17+
18+
**Steps taken to verify documentation is incorrect**
19+
List any steps you have taken:
20+
21+
**Suggested fix for documentation**
22+
Detail proposed changes to fix the documentation if you have any.
23+
24+
---
25+
26+
## Report needed documentation
27+
28+
**Report needed documentation**
29+
A clear and concise description of what documentation you believe it is needed and why.
30+
31+
**Describe the documentation you'd like**
32+
A clear and concise description of what you want to happen.
33+
34+
**Steps taken to search for needed documentation**
35+
List any steps you have taken:
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for cuOpt
4+
title: "[FEA]"
5+
labels: "? - Needs Triage, feature request"
6+
assignees: ''
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe.**
11+
A clear and concise description of what the problem is. Ex. I wish I could use cuOpt to do [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered.
18+
19+
**Additional context**
20+
Add any other context, code examples, or references to existing implementations about the feature request here.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
name: Submit question
3+
about: Ask a general question about cuOpt
4+
title: "[QST]"
5+
labels: "? - Needs Triage, question"
6+
assignees: ''
7+
8+
---
9+
10+
**What is your question?**

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
<!--
2+
3+
Thank you for contributing to cuOpt :)
4+
5+
Here are some guidelines to help the review process go smoothly.
6+
7+
1. Please write a description in this text box of the changes that are being
8+
made.
9+
10+
2. Please ensure that you have written units tests for the changes made/features
11+
added.
12+
13+
3. If you are closing an issue please use one of the automatic closing words as
14+
noted here: https://help.github.com/articles/closing-issues-using-keywords/
15+
16+
4. If your pull request is not ready for review but you want to make use of the
17+
continuous integration testing facilities please label it with `[WIP]`.
18+
19+
5. If your pull request is ready to be reviewed without requiring additional
20+
work on top of it, then remove the `[WIP]` label (if present) and replace
21+
it with `[REVIEW]`. If assistance is required to complete the functionality,
22+
for example when the C/C++ code of a feature is complete but Python bindings
23+
are still required, then add the label `[HELP-REQ]` so that others can triage
24+
and assist. The additional changes then can be implemented on top of the
25+
same PR. If the assistance is done by members of the rapidsAI team, then no
26+
additional actions are required by the creator of the original PR for this,
27+
otherwise the original author of the PR needs to give permission to the
28+
person(s) assisting to commit to their personal fork of the project. If that
29+
doesn't happen then a new PR based on the code of the original PR can be
30+
opened by the person assisting, which then will be the PR that will be
31+
merged.
32+
33+
6. Once all work has been done and review has taken place please do not add
34+
features or make changes out of the scope of those requested by the reviewer
35+
(doing this just add delays as already reviewed code ends up having to be
36+
re-reviewed/it is hard to tell what is new etc!). Further, please do not
37+
rebase your branch on main/force push/rewrite history, doing any of these
38+
causes the context of any comments made by reviewers to be lost. If
39+
conflicts occur against main they should be resolved by merging main
40+
into the branch used for making the pull request.
41+
42+
Many thanks in advance for your cooperation!
43+
44+
-->

.github/copy-pr-bot.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Configuration file for `copy-pr-bot` GitHub App
2+
# https://docs.gha-runners.nvidia.com/apps/copy-pr-bot/
3+
4+
enabled: true
5+
auto_sync_draft: false

.github/ops-bot.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# This file controls which features from the `ops-bot` repository below are enabled.
2+
# - https://github.com/rapidsai/ops-bot
3+
4+
auto_merger: true
5+
branch_checker: true
6+
label_checker: true
7+
release_drafter: true
8+
forward_merger: true

0 commit comments

Comments
 (0)