|
# Home
|
|
# Home
|
|
|
|
|
|
[[_TOC_]]
|
|
|
|
|
|
|
|
This is the documentation for the Project Prolog MLpack Library.
|
|
This is the documentation for the Project Prolog MLpack Library.
|
|
|
|
|
|
Here you can find documentaion on the used Datatypes, a detailed documentation for the available Methods and for the helper files.
|
|
Here you can find documentaion on the used Datatypes, a detailed documentation for the available Methods and for the helper files.
|
|
|
|
|
|
# Quickstart
|
|
[[_TOC_]]
|
|
|
|
|
|
|
|
# **_Quickstart_**
|
|
|
|
|
|
## Todo
|
|
## Todo
|
|
|
|
|
|
# Data Types
|
|
# **_Data Types_**
|
|
|
|
|
|
To connect mlpack and SICStus prolog i used the c interface of SICStus which can convert prolog datatypes to c datatypes and vise versa.
|
|
To connect mlpack and SICStus prolog i used the c interface of SICStus which can convert prolog datatypes to c datatypes and vise versa.
|
|
|
|
|
|
[Here](https://sicstus.sics.se/sicstus/docs/latest4/html/sicstus.html/Conversions-between-Prolog-Arguments-and-C-Types.html) you can find a list of the available conversion types.
|
|
[Here](https://sicstus.sics.se/sicstus/docs/latest4/html/sicstus.html/Conversions-between-Prolog-Arguments-and-C-Types.html) you can find a list of the available conversion types.
|
|
|
|
|
|
## Extra Symbols
|
|
## Extra Symbols
|
|
|
|
|
|
* +
|
|
* is the symbol for inupting a concret value from prolog to c/c++
|
|
|
|
* is the symbol for inputing a variable from prolog to c/c++ that then gets assigned a value in one c side, that then can be used on the prolog side.
|
|
is the symbol for inupting a concret value from prolog to c/c++
|
|
|
|
* -
|
|
|
|
|
|
|
|
is the symbol for inputing a variable from prolog to c/c++ that then gets assigned a value in one c side, that then can be used on the prolog side.
|
|
|
|
* \[-\]
|
|
* \[-\]
|
|
|
|
|
|
is the symbol for an output value from c/c++ to prolog, in its function very similar to -.
|
|
is the symbol for an output value from c/c++ to prolog, in its function very similar to -.
|
... | @@ -32,12 +28,12 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
... | @@ -32,12 +28,12 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
|
|
|
|
|
* **_integer_**
|
|
* **_integer_**
|
|
|
|
|
|
are the normal numbers 1,2,3...
|
|
are the normal numbers 1,2,3...
|
|
|
|
|
|
c/c++ : _SP_integer_
|
|
c/c++ : _SP_integer_
|
|
* **_float_**
|
|
* **_float_**
|
|
|
|
|
|
are the numbers like 0.0, 1.2, 5.7...
|
|
are the numbers like 0.0, 1.2, 5.7...
|
|
|
|
|
|
full definition prolog : float_32 shortend to float32 since this has the correct Byte size for its counter part double
|
|
full definition prolog : float_32 shortend to float32 since this has the correct Byte size for its counter part double
|
|
|
|
|
... | @@ -46,7 +42,7 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
... | @@ -46,7 +42,7 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
|
|
|
|
|
are just atoms like: word, hello, nice7...
|
|
are just atoms like: word, hello, nice7...
|
|
|
|
|
|
c/c++ : _char const \*_
|
|
c/c++ : _char const \*_
|
|
* **_integer(bool)_**
|
|
* **_integer(bool)_**
|
|
|
|
|
|
there are no bool atoms in Prolog that could translate to bool in c, so i chose integer numbers as replacement with 1 = true and 0(or any other int number) = false
|
|
there are no bool atoms in Prolog that could translate to bool in c, so i chose integer numbers as replacement with 1 = true and 0(or any other int number) = false
|
... | @@ -58,13 +54,13 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
... | @@ -58,13 +54,13 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
|
|
|
|
|
currently on the prolog side you have to convert a normal list like \[1, 2, 3\] to a float_array with the help of some helper predicates in helper.pl.
|
|
currently on the prolog side you have to convert a normal list like \[1, 2, 3\] to a float_array with the help of some helper predicates in helper.pl.
|
|
|
|
|
|
input :
|
|
input :
|
|
* prolog : _+pointer(float_array) (converted list), +integer (list length), +integer (Rows)_
|
|
* prolog : _+pointer(float_array) (converted list), +integer (list length), +integer (Rows)_
|
|
* c/c++ : _float \* array, SP_integer size, SP_integer rows_
|
|
* c/c++ : _float \* array, SP_integer size, SP_integer rows_
|
|
|
|
|
|
output :
|
|
output :
|
|
* prolog : _-pointer(float_array) (converted list), -integer (Columns), -integer (Rows)_
|
|
* prolog : _-pointer(float_array) (converted list), -integer (Columns), -integer (Rows)_
|
|
* c/c++ : _float \*\*array, SP_integer \*colums, SP_integer \*rows_
|
|
* c/c++ : _float \*\*array, SP_integer \*colums, SP_integer \*rows_
|
|
* **_vector_**
|
|
* **_vector_**
|
|
|
|
|
|
currently on the prolog side you have to convert a normal list like \[1, 2, 3\] to a float_array with the help of some helper predicates in helper.pl.
|
|
currently on the prolog side you have to convert a normal list like \[1, 2, 3\] to a float_array with the help of some helper predicates in helper.pl.
|
... | @@ -73,7 +69,7 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
... | @@ -73,7 +69,7 @@ To connect mlpack and SICStus prolog i used the c interface of SICStus which can |
|
|
|
|
|
c/c++ : _float \*array, SP_integer size_
|
|
c/c++ : _float \*array, SP_integer size_
|
|
|
|
|
|
# Prolog Methods
|
|
# **_Prolog Methods_**
|
|
|
|
|
|
Here you can find all the documentation sites for the implemented mlpack methods of this libraray.
|
|
Here you can find all the documentation sites for the implemented mlpack methods of this libraray.
|
|
|
|
|
... | @@ -144,6 +140,6 @@ In the project they can be found under : |
... | @@ -144,6 +140,6 @@ In the project they can be found under : |
|
* [x] [Radical](https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Transformation/radical)
|
|
* [x] [Radical](https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Transformation/radical)
|
|
* [x] [Sparse_Coding](https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Transformation/sparse_coding)
|
|
* [x] [Sparse_Coding](https://gitlab.cs.uni-duesseldorf.de/stups/abschlussarbeiten/prolog-mlpack-libary/-/wikis/PrologMethods/Transformation/sparse_coding)
|
|
|
|
|
|
# Helper Functions
|
|
# **_Helper Functions_**
|
|
|
|
|
|
## Todo |
|
## Todo |
|
|
|
\ No newline at end of file |