Changes
Page history
Update dbscan
authored
Nov 20, 2022
by
Dean Samuel Schmitz
Show whitespace changes
Inline
Side-by-side
PrologMethods/Clustering/dbscan.md
View page @
b659d754
...
...
@@ -4,23 +4,32 @@ An implementation of DBSCAN clustering. Given a dataset, this can compute and re
# Available Predicates
*
[
dbscan/1
3
](
https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Clustering/dbscan#dbscan1
3
)
*
[
dbscan/1
0
](
https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Clustering/dbscan#dbscan1
0
)
---
[
links/resources
](
https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Clustering/dbscan#connected-linksresources
)
## **_dbscan/1
3
_**
## **_dbscan/1
0
_**
This is a one predicate model where you configure the model with the input parameters and get returned the results in the same predicate.
```
prolog
%% part of the predicate definition
dbscan
(
+
float32
,
+
integer
,
+
integer
,
%% predicate definition
dbscan
(
Epsilon
,
MinPoints
,
BatchMode
,
SelectionType
,
TreeType
,
DataList
,
DataRows
,
AssignList
,
CentroidsList
,
ZCols
)
:-
Epsilon
>
0
,
MinPoints
>
0
,
convert_list_to_float_array
(
DataList
,
DataRows
,
array
(
Xsize
,
Xrownum
,
X
)),
dbscanI
(
Epsilon
,
MinPoints
,
BatchMode
,
SelectionType
,
TreeType
,
X
,
Xsize
,
Xrownum
,
Y
,
Ysize
,
Z
,
ZCols
,
ZRows
),
convert_float_array_to_list
(
Y
,
Ysize
,
AssignList
),
convert_float_array_to_2d_list
(
Z
,
ZCols
,
ZRows
,
CentroidsList
).
%% foreign c++ predicate definition
foreign
(
dbscan
,
c
,
dbscanI
(
+
float32
,
+
integer
,
+
integer
,
+
string
,
+
string
,
+
pointer
(
float_array
),
+
integer
,
+
integer
,
-
pointer
(
float_array
),
-
integer
,
-
pointer
(
float_array
),
-
integer
,
-
integer
)
-
pointer
(
float_array
),
-
integer
,
-
integer
)
).
```
### Parameters
...
...
@@ -41,8 +50,8 @@ dbscan( +float32, +integer, +integer,
If you want a more detailed explanation, then go to the python documentation. There is most of the time a good explanation on how the methods work and what the parameters do.
*
[
**MLpack::dbscan_C++\_documentation**
](
https://www.mlpack.org/doc/
stable
/doxygen/classmlpack_1_1dbscan_1_1DBSCAN.html
)
*
[
**MLpack::dbscan_Python_documentation**
](
https://www.mlpack.org/doc/
stable
/python_documentation.html#dbscan
)
*
[
**MLpack::dbscan_C++\_documentation**
](
https://www.mlpack.org/doc/
mlpack-3.4.2
/doxygen/classmlpack_1_1dbscan_1_1DBSCAN.html
)
*
[
**MLpack::dbscan_Python_documentation**
](
https://www.mlpack.org/doc/
mlpack-3.4.2
/python_documentation.html#dbscan
)
added some of the links from the python documentation
...
...
...
...