-
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.
- Loading branch information
Showing
12 changed files
with
3,753 additions
and
0 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,14 @@ | ||
--- | ||
Language: Cpp | ||
#AccessModifierOffset: 0 | ||
AlignTrailingComments: true | ||
AlwaysBreakTemplateDeclarations: true | ||
BreakBeforeBraces: Allman | ||
ColumnLimit: 0 | ||
FixNamespaceComments: false | ||
IndentWidth: 2 | ||
NamespaceIndentation: All | ||
PointerBindsToType: true | ||
SortIncludes: false | ||
SpaceAfterTemplateKeyword: false | ||
SpaceBeforeParens: false |
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 @@ | ||
build/* |
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,27 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "(gdb) Launch", | ||
"type": "cppdbg", | ||
"request": "launch", | ||
"program": "${workspaceFolder}/build/VPTree", | ||
"args": [], | ||
"stopAtEntry": false, | ||
"cwd": "${workspaceFolder}/build", | ||
"environment": [], | ||
"externalConsole": false, | ||
"MIMode": "gdb", | ||
"setupCommands": [ | ||
{ | ||
"description": "Enable pretty-printing for gdb", | ||
"text": "-enable-pretty-printing", | ||
"ignoreFailures": 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,6 @@ | ||
{ | ||
"files.associations": { | ||
"fstream": "cpp" | ||
}, | ||
"C_Cpp.default.configurationProvider": "vector-of-bool.cmake-tools" | ||
} |
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,23 @@ | ||
cmake_minimum_required(VERSION 3.10) | ||
project(VPTree) | ||
|
||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++17 -w") | ||
|
||
set(CMAKE_VERBOSE_MAKEFILE ON) | ||
|
||
#put all in one directory... | ||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}) | ||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}) | ||
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}) | ||
|
||
#==================================== | ||
macro(copy_file_to_target_dir arg0 arg1) | ||
add_custom_command(TARGET ${ARGV0} PRE_BUILD # Adds a post-build event to project name | ||
COMMAND ${CMAKE_COMMAND} -E copy_if_different # which executes "cmake - E copy_if_different..." | ||
${ARGV1} | ||
$<TARGET_FILE_DIR:${PROJECT_NAME}> # <--this is out-file path | ||
) | ||
endmacro(copy_file_to_target_dir) | ||
#========================= | ||
|
||
add_subdirectory(src) |
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,22 @@ | ||
== Generic VPTree | ||
|
||
.build status | ||
Ubuntu 18.10, GNU GCC 8.3: image:https://rgijsen.visualstudio.com/vptree/_apis/build/status/rgijsen.vptree?branchName=master["Build Status", | ||
link=https://rgijsen.visualstudio.com/vptree/_build/latest?definitionId=1&branchName=master] | ||
=== Description | ||
Generic Vantage Point Tree (VPTree) is a space partitioning algorithm. + | ||
This code is based on link:http://stevehanov.ca/blog/index.php?id=130[] and link:https://fribbels.github.io/vptree/writeup[] | ||
This implementation allows for generic point type (instead of only vector type points). Even aggregated point types are allowed. | ||
Requirements for the point type are: | ||
* Must have operator[] to access the elements | ||
* Must have size() function to return dimensional size | ||
The distance metric is a binary function of type: distance(point1, point2) + | ||
Supplied metrics are: | ||
* Euclidean full device metric | ||
* Euclidean periodic boundary condition, PBC, metric | ||
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 @@ | ||
# https://aka.ms/yaml | ||
|
||
resources: | ||
containers: | ||
- container: gcc | ||
image: magellan2/gcc8:1.1 | ||
|
||
variables: | ||
poolImage: 'ubuntu-latest' | ||
|
||
trigger: | ||
- master | ||
|
||
stages: | ||
- stage: build | ||
jobs: | ||
- job: Build | ||
container: gcc | ||
pool: | ||
vmImage: $(poolImage) | ||
steps: | ||
- script: | | ||
uname -a | ||
gcc --version | ||
cmake --version | ||
rm -rf build | ||
mkdir build | ||
cd build | ||
cmake .. | ||
make | ||
Oops, something went wrong.