From ec989c320980192f5a039b46586990d39ca16ec7 Mon Sep 17 00:00:00 2001 From: txh18 Date: Fri, 29 May 2015 15:00:56 +0800 Subject: added nerv.typename, which is luaT_lua_typename --- nerv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/nerv.c b/nerv.c index 5693d68..fa47c62 100644 --- a/nerv.c +++ b/nerv.c @@ -8,6 +8,7 @@ static const luaL_Reg nerv_utils_methods[] = { {"setmetatable", luaT_lua_setmetatable}, {"getmetatable", luaT_lua_getmetatable}, {"newmetatable", luaT_lua_newmetatable}, + {"typename", luaT_lua_typename}, {NULL, NULL} }; -- cgit v1.2.3 From d0bf4368e7c4c60966cabc8bc07a3ec7d3aa0d80 Mon Sep 17 00:00:00 2001 From: cloudygoose Date: Fri, 29 May 2015 16:15:43 +0800 Subject: README added --- README.md | 13 +++++++++++++ doc/nerv.md | 3 +++ 2 files changed, 16 insertions(+) create mode 100644 README.md create mode 100644 doc/nerv.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..465fa29 --- /dev/null +++ b/README.md @@ -0,0 +1,13 @@ +#The Nerv Toolkit User Manual# +This user manual will provide information about Nerv's interface. + +##Nerv Packages## +* __luaT__ +Nerv uses [luaT]\(a [Torch] library\) to define lua class in C. +* __[Nerv](doc/nerv.md)__ +Inlcudes some utility functions from luaT to implement __Nerv.Class__. +* __Nerv.Matrix__ +__Nerv.Matrix__ is a basic class in __Nerv__ that is used to store and manipulate matrices. + +[luaT]:https://github.com/torch/torch7/tree/master/lib/luaT +[Torch]:https://github.com/torch \ No newline at end of file diff --git a/doc/nerv.md b/doc/nerv.md new file mode 100644 index 0000000..3f544b1 --- /dev/null +++ b/doc/nerv.md @@ -0,0 +1,3 @@ +#The Nerv Package# +Part of the [Nerv](../README.md) toolkit. +##Methods## \ No newline at end of file -- cgit v1.2.3 From 240cc240f0c5d7f0691febfb0aedc61d00291dad Mon Sep 17 00:00:00 2001 From: cloudygoose Date: Fri, 29 May 2015 16:20:57 +0800 Subject: ... --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 465fa29..60bd21f 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,13 @@ #The Nerv Toolkit User Manual# -This user manual will provide information about Nerv's interface. +This user manual will information about how to use __Nerv__ and __Nerv__'s interface. ##Nerv Packages## -* __luaT__ +* __luaT__ Nerv uses [luaT]\(a [Torch] library\) to define lua class in C. -* __[Nerv](doc/nerv.md)__ +* __[The Nerv utility functions](doc/nerv.md)__ Inlcudes some utility functions from luaT to implement __Nerv.Class__. -* __Nerv.Matrix__ -__Nerv.Matrix__ is a basic class in __Nerv__ that is used to store and manipulate matrices. +* __The Nerv Matrix Package__ +The Matrix package is a basic package in __Nerv__ that is used to store and manipulate matrices. [luaT]:https://github.com/torch/torch7/tree/master/lib/luaT [Torch]:https://github.com/torch \ No newline at end of file -- cgit v1.2.3 From e991ad1e5153d23a8ae38110e3093b88e058140a Mon Sep 17 00:00:00 2001 From: cloudygoose Date: Fri, 29 May 2015 17:16:24 +0800 Subject: modified documentation for nerv utility --- README.md | 23 ++++++++++++++++++++++- doc/nerv.md | 6 ++++-- 2 files changed, 26 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 60bd21f..54d0218 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,26 @@ #The Nerv Toolkit User Manual# This user manual will information about how to use __Nerv__ and __Nerv__'s interface. +##How to use## +First make sure you have __lua__ and __CUDA__ installed on your computer. +__Nerv__ is currently developed via github.You can download and make __Nerv__ by doing the following: +``` +cd ~ +git clone https://github.com/Determinant/nerv.git +cd nerv +git submodule init && git submodule update +make +``` +The `git submodule` command is for the __luajit__ repository inside __Nerv__. +Now, you can try to run some example scripts. +``` +./nerv examples/cumatrix_example.lua +``` + +##How to contribute## +Fork the original repository, then use the __pull&merge__ function in github to contribute. +The pull&merge request can be found on your dashboard in github. See this [sync-help] to sync with the original repository. + ##Nerv Packages## * __luaT__ Nerv uses [luaT]\(a [Torch] library\) to define lua class in C. @@ -10,4 +30,5 @@ Inlcudes some utility functions from luaT to implement __Nerv.Class__. The Matrix package is a basic package in __Nerv__ that is used to store and manipulate matrices. [luaT]:https://github.com/torch/torch7/tree/master/lib/luaT -[Torch]:https://github.com/torch \ No newline at end of file +[Torch]:https://github.com/torch +[sync-help]:https://help.github.com/articles/syncing-a-fork/ \ No newline at end of file diff --git a/doc/nerv.md b/doc/nerv.md index 3f544b1..b6631a6 100644 --- a/doc/nerv.md +++ b/doc/nerv.md @@ -1,3 +1,5 @@ -#The Nerv Package# +#The Nerv utility functions# Part of the [Nerv](../README.md) toolkit. -##Methods## \ No newline at end of file +##Methods## +* __string = nerv.setmetatable(table self, string tname)__ +A registered function, the original function is `luaT_lua_setmetatable`. It assigns the metatable registered in __luaT__ by the name *tname* to the table *self*. And return *tname* to user. -- cgit v1.2.3 From b88d2ab16af682194d2f94f5ef17d658ec101234 Mon Sep 17 00:00:00 2001 From: cloudygoose Date: Fri, 29 May 2015 17:17:57 +0800 Subject: ... --- doc/nerv.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/nerv.md b/doc/nerv.md index b6631a6..85a86ca 100644 --- a/doc/nerv.md +++ b/doc/nerv.md @@ -1,5 +1,5 @@ #The Nerv utility functions# Part of the [Nerv](../README.md) toolkit. ##Methods## -* __string = nerv.setmetatable(table self, string tname)__ +* __string = nerv.setmetatable(table self, string tname)__ A registered function, the original function is `luaT_lua_setmetatable`. It assigns the metatable registered in __luaT__ by the name *tname* to the table *self*. And return *tname* to user. -- cgit v1.2.3