-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Initialized repo with code * Added useful parts of ds-template * licensed as Apache 2.0 * Update LICENSE * full deepsense name as sp zoo * forward/backward small letters * Preparing support for semantic release * Modified url of pypi for testing purposes * pip install ds-splat not ds_splat * Modified name of package --------- Co-authored-by: kczerski <[email protected]> Co-authored-by: deepsense.ai <[email protected]>
- Loading branch information
1 parent
f1bc0a9
commit 2384416
Showing
38 changed files
with
3,600 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
--- | ||
BasedOnStyle: LLVM | ||
AlwaysBreakAfterDefinitionReturnType: None | ||
AlwaysBreakAfterReturnType: None | ||
NamespaceIndentation: None | ||
SpacesInSquareBrackets: 'false' | ||
Standard: Auto | ||
FixNamespaceComments: 'true' | ||
BreakBeforeBraces: Allman | ||
SortIncludes: 'true' | ||
SpaceBeforeParens: Never | ||
AllowShortFunctionsOnASingleLine: Inline | ||
BreakConstructorInitializers: BeforeColon | ||
IndentWidth: 4 | ||
PointerAlignment: Left | ||
SpaceInEmptyParentheses: 'false' | ||
SpacesBeforeTrailingComments: 1 | ||
SpacesInAngles: 'false' | ||
SpacesInParentheses: 'false' | ||
AlwaysBreakTemplateDeclarations: 'true' | ||
BreakBeforeInheritanceComma: 'false' | ||
ColumnLimit: 120 | ||
IndentCaseLabels: 'true' | ||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# This is a standard to preconfigure editors | ||
# check: https://editorconfig.org/ | ||
root = true | ||
|
||
# 4 space indentation | ||
[*.py] | ||
charset = utf-8 | ||
indent_style = space | ||
indent_size = 4 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = false | ||
end_of_line = lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
[flake8] | ||
ignore= | ||
# line too long - is to be checked by black | ||
E501, | ||
# E203 (spaces around :) | ||
E203, | ||
# and W503 (line break before binary operator) are output as a result of Black formatting | ||
W503 | ||
|
||
dictionaries=en_US,python,technical | ||
docstring-convention=google | ||
spellcheck-targets=comments |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: 🚀 Feature Request | ||
description: Submit a proposal/request for a new feature. | ||
title: "feat: " | ||
labels: ["feature"] | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for contributing! | ||
- type: textarea | ||
id: feature-description | ||
attributes: | ||
label: Feature description | ||
description: A clear and concise description of the feature proposal | ||
placeholder: Tell us what you want! | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: feature-motivation | ||
attributes: | ||
label: Motivation | ||
description: A clear and concise description of what the problem is, e.g., I'm always frustrated when [...] | ||
placeholder: Why do you need this feature? | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: feature-context | ||
attributes: | ||
label: Additional context | ||
description: Add any other context or screenshots about the feature request here. | ||
placeholder: Screenshots, code snippets, etc. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: 🐞 Bug Report | ||
description: File a bug report | ||
title: "bug: <short_name>" | ||
labels: ["bug"] | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for taking the time to fill out this bug report! | ||
- type: textarea | ||
id: what-happened | ||
attributes: | ||
label: What happened? | ||
description: Also tell us, what did you expect to happen? | ||
placeholder: Tell us what you see! | ||
value: "A bug happened!" | ||
validations: | ||
required: true | ||
- type: textarea | ||
id : how-to-reproduce | ||
attributes: | ||
label: How can we reproduce it? | ||
description: Please provide a code snippet to reproduce the bug. | ||
placeholder: import dbally | ||
render: python | ||
- type: textarea | ||
id: logs | ||
attributes: | ||
label: Relevant log output | ||
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks. | ||
render: shell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
name: Semantic Release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
releaseType: | ||
description: "version update type" | ||
required: true | ||
type: choice | ||
default: "automatic" | ||
options: | ||
- "automatic" | ||
- "major" | ||
- "minor" | ||
- "patch" | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
concurrency: release | ||
permissions: | ||
id-token: write | ||
contents: write | ||
|
||
environment: | ||
name: pypi | ||
url: https://test.pypi.org/project/ds-splat | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Python Semantic Release Manual | ||
id: release_manual | ||
if: ${{ github.event.inputs.releaseType != 'automatic' }} | ||
uses: python-semantic-release/python-semantic-release@master | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
force: ${{ github.event.inputs.releaseType }} | ||
changelog: false | ||
|
||
- name: Python Semantic Release Automatic | ||
id: release_automatic | ||
if: ${{ github.event.inputs.releaseType == 'automatic' }} | ||
uses: python-semantic-release/python-semantic-release@master | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
changelog: false | ||
|
||
|
||
- name: Publish package distributions to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
|
||
if: steps.release_manual.outputs.released == 'true' || steps.release_automatic.outputs.released == 'true' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
# Directories | ||
.vscode/ | ||
.idea/ | ||
.neptune/ | ||
.pytest_cache/ | ||
.mypy_cache/ | ||
venv/ | ||
__pycache__/ | ||
**.egg-info/ | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
env/ | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
public/ | ||
# autogenerated package license table | ||
docs/licenses_table.rst | ||
|
||
# license dump file | ||
licenses.txt | ||
|
||
# File formats | ||
*.onnx | ||
*.pyc | ||
*.pt | ||
*.pth | ||
*.pkl | ||
*.mar | ||
*.torchscript | ||
**/.ipynb_checkpoints | ||
**/dist/ | ||
**/checkpoints/ | ||
**/outputs/ | ||
|
||
# Other env files | ||
.python-version | ||
pyvenv.cfg | ||
pip-selfcheck.json | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*,cover | ||
.hypothesis/ | ||
|
||
# dotenv | ||
.env | ||
src/dbally_benchmark/.env | ||
|
||
# coverage and pytest reports | ||
coverage.xml | ||
report.xml | ||
|
||
# CMake | ||
cmake-build-*/ | ||
|
||
# Terraform | ||
**/.terraform.lock.hcl | ||
**/.terraform | ||
|
||
# experiments results | ||
experiments/ | ||
|
||
# mkdocs generated files | ||
site/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[submodule "cpp/gsplat/third_party/glm"] | ||
path = cpp/gsplat/third_party/glm | ||
url = https://github.com/g-truc/glm.git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
cmake_minimum_required(VERSION 3.18) | ||
project(cuda_rasterizer LANGUAGES CXX CUDA) | ||
|
||
set(CMAKE_CUDA_STANDARD 17) | ||
set(CMAKE_CXX_STANDARD 20) | ||
option(WITH_TORCH "Builds also rasterizer compatible with torch tensors" ON) | ||
|
||
find_package(Thrust REQUIRED) | ||
|
||
add_library(ds_cuda_rasterizer | ||
cpp/rasterizer_cuda.cu | ||
cpp/rasterizer_kernels.cu) | ||
|
||
target_include_directories(ds_cuda_rasterizer PRIVATE ${TORCH_INCLUDE_DIRS}) | ||
target_include_directories(ds_cuda_rasterizer PRIVATE ${CUDA_INCLUDE_DIRS}) | ||
target_include_directories(ds_cuda_rasterizer PUBLIC cpp) | ||
|
||
target_link_libraries(ds_cuda_rasterizer ${CUDA_LIBRARIES} thrust::thrust) | ||
|
||
set_target_properties(ds_cuda_rasterizer PROPERTIES | ||
CUDA_ARCHITECTURES "native") | ||
|
||
if(WITH_TORCH) | ||
find_package(Torch REQUIRED) | ||
find_package(Python3 COMPONENTS Interpreter Development REQUIRED) | ||
|
||
target_sources(ds_cuda_rasterizer PRIVATE | ||
cpp/rasterizer_torch.cu | ||
cpp/gsplat/backward.cu | ||
cpp/gsplat/bindings.cu) | ||
|
||
target_link_libraries(ds_cuda_rasterizer ${TORCH_LIBRARIES} Python3::Python) | ||
|
||
if(BUILD_TESTING AND WITH_TORCH) | ||
enable_testing() | ||
find_package(GTest REQUIRED) | ||
include(CTest) | ||
|
||
add_executable(rasterizer_test tests/rasterizer_test.cpp) | ||
target_link_libraries(rasterizer_test ds_cuda_rasterizer gtest::gtest ${TORCH_LIBRARIES} ${CUDA_LIBRARIES}) | ||
endif() | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,21 @@ | ||
MIT License | ||
This project adapts and modifies code for backward CUDA kernels from Nerfstudio's project gsplat (modified) | ||
|
||
Copyright (c) 2024 deepsense.ai | ||
https://github.com/nerfstudio-project/gsplat | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
Nerfstudio gsplat is available under the Apache 2.0 License, which you can find at http://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
The rest of the project, including forward CUDA calls, is the original work of the deepsense.ai team. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
Copyright (c) 2024 deepsense.ai sp. z o.o. | ||
|
||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
|
||
http://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
recursive-include cpp * | ||
include cpp/*.cpp | ||
include cpp/*.cu | ||
include cpp/gsplat/*.cu |
Oops, something went wrong.