--- Log opened Tue Jul 26 00:00:21 2011 | ||
@sonney2k | heiko1, still awake? | 00:32 |
---|---|---|
heiko1 | yes | 00:32 |
heiko1 | but, i really want to go home now :) | 00:32 |
heiko1 | whats up? | 00:32 |
heiko1 | just sent a pull request | 00:33 |
heiko1 | sonney2k, so lets speack tomorrow :) | 00:35 |
@sonney2k | heiko1, it is quasi schon morgen :) | 00:35 |
@sonney2k | heiko1, ok cu! | 00:35 |
heiko1 | sonney2k, you should also go to bed :) | 00:35 |
@bettyboo | hoho heiko1 | 00:36 |
heiko1 | sonney2k, byebye | 00:36 |
-!- heiko1 [~heiko@134.91.52.56] has quit [Ping timeout: 258 seconds] | 00:40 | |
-!- f-x [~user@117.192.204.152] has joined #shogun | 02:31 | |
-!- f-x [~user@117.192.204.152] has quit [Ping timeout: 260 seconds] | 04:25 | |
-!- f-x [~user@117.192.204.152] has joined #shogun | 04:37 | |
-!- gsomix [~gsomix@109.169.131.11] has joined #shogun | 05:46 | |
-!- gsomix [~gsomix@109.169.131.11] has quit [Client Quit] | 05:46 | |
serialhex | for some reason when i compile just the ruby_modular interface, it locks here: https://gist.github.com/1105955 | 06:12 |
serialhex | sorry i've been MIA, lots of work & not enough sleep | 06:13 |
-!- f-x [~user@117.192.204.152] has quit [Ping timeout: 260 seconds] | 06:43 | |
-!- f-x [~user@117.192.215.140] has joined #shogun | 08:37 | |
-!- in3xes [~in3xes@180.149.49.227] has joined #shogun | 09:26 | |
-!- blackburn [~blackburn@109.226.76.87] has joined #shogun | 09:49 | |
-!- sploving1 [~sploving@124.16.139.194] has joined #shogun | 10:04 | |
sploving1 | sonney2k, in python, swig_typemaps.i, it has "#include <numpy/arrayobject.h>". when i write ruby swig_typemaps.i, #include <narray.h>, why it said: cannot find ../../shogun/narray.h | 10:05 |
sploving1 | i have make installed narray. and narray.h and narray.so is in /usr/local/lib/site_ruby/1.8/i486-linux:. | 10:06 |
@sonney2k | serialhex, it will just takes a few minutes to compile that's all - be patient | 10:06 |
blackburn | sonney2k: I wrote small test generator for distances, preprocessors and kernels :D | 10:06 |
sploving1 | I set $PATH="$PATH:/usr/local/lib/site_ruby/1.8/i486-linux:." | 10:06 |
sploving1 | but it still cannot find narray.h, why?? | 10:06 |
@sonney2k | sploving1, please open an editor and edit shogun/.config | 10:07 |
sploving1 | serialhex, are you here? | 10:07 |
@sonney2k | sploving1, sorry src/.config | 10:07 |
@sonney2k | sploving1, btw did you test lua string support yet? | 10:08 |
sploving1 | not yet. | 10:08 |
@sonney2k | sploving1, please do this first - I can then in the meantime do some configure magic to detect narray | 10:08 |
@sonney2k | for ruby | 10:08 |
sploving1 | my machine cannot show all the columns of the results | 10:09 |
sploving1 | like yesterday, it just show the first 8 columns | 10:09 |
sploving1 | so I cannot decide whether it is right or not | 10:09 |
@sonney2k | sploving1, I meant just creating StringCharFeatures etc | 10:10 |
@sonney2k | sploving1, python_modular/features_string_char_modular.py | 10:10 |
@sonney2k | just translate this to lua and test | 10:11 |
sploving1 | I will take a look at that | 10:12 |
sploving1 | sonney2k, can you support narray ? | 10:12 |
sploving1 | I have change the typemap, and would like to see narrya works well or not | 10:13 |
@sonney2k | sure | 10:13 |
sploving1 | I compiled several times, and cannot find narray.h or "/home/sploving/shogun/src/interfaces/ruby_modular/modshogun_wrap.cxx:425348: undefined reference to `na_to_array' | 10:14 |
sploving1 | " | 10:14 |
sploving1 | /home/sploving/shogun/src/interfaces/ruby_modular/modshogun_wrap.cxx:425612: undefined reference to `cNArray' | 10:14 |
@sonney2k | sploving1, please do the lua string test first - when that is done we discuss about narray OK? | 10:14 |
sploving1 | okay | 10:14 |
sploving1 | I will add it and you can hele me take a test. as you know, the kernel results in you machines show the same results. but in my machines it does not show the right | 10:16 |
@sonney2k | sploving1, why don't you pipe it to a file and then open these files in an editor? | 10:16 |
sploving1 | I will have a try | 10:17 |
@sonney2k | blackburn, you are awake? | 10:29 |
@sonney2k | already? | 10:29 |
blackburn | yes | 10:29 |
blackburn | is it strange? | 10:29 |
@sonney2k | totally missed you message | 10:29 |
@sonney2k | yes you usually work until 5 am or so and thus sleep a bit longer | 10:29 |
blackburn | which message? | 10:29 |
blackburn | I was messing with some java examples last night and wrote a simple template generator | 10:30 |
@sonney2k | template generator? | 10:30 |
blackburn | wrong word order | 10:30 |
blackburn | by template | 10:30 |
blackburn | e.g. most of dim.reduction preprocessors works similar | 10:31 |
@sonney2k | similar is within eps 1e-15 or so? | 10:31 |
blackburn | no, I mean they are used in similar way | 10:32 |
blackburn | %CLASS% preprocessor = %CLASS%(); | 10:32 |
blackburn | and so on | 10:32 |
blackburn | so, just replacing %CLASS% - no need to write tests manually | 10:32 |
blackburn | I would like to automate all the tests if possible | 10:33 |
@sonney2k | blackburn, yes that would be great... but it needs some thought how to do that properly | 10:34 |
@sonney2k | I mean ideally one would be able to use that same system on all languages | 10:35 |
@sonney2k | s/on/for/ | 10:35 |
blackburn | for now I'm going to get it work for java, may be later we could write some automagic | 10:36 |
blackburn | btw, distances are working | 10:37 |
blackburn | string distances to go though | 10:37 |
sploving1 | sonney2k, [ERROR] assertion a failed in file features/Alphabet.cpp line 98 | 10:37 |
sploving1 | init();ASSERT(a);set_alphabet(a->get_alphabet());copy_histogram(a); | 10:37 |
sploving1 | what does ASSERT(a) mean? | 10:38 |
@sonney2k | it is non-zero | 10:38 |
blackburn | okay sorry gtg | 10:40 |
-!- blackburn [~blackburn@109.226.76.87] has quit [Quit: Leaving.] | 10:40 | |
CIA-87 | shogun: Baozeng Ding master * rf5b05f4 / examples/undocumented/lua_modular/features_string_char_modular.lua : add string features lua example - https://github.com/shogun-toolbox/shogun/commit/f5b05f473c275c9cc78d2d102ee8101c80fac3cb | 11:27 |
CIA-87 | shogun: Soeren Sonnenburg master * r16fc2a1 / examples/undocumented/lua_modular/features_string_char_modular.lua : | 11:27 |
CIA-87 | shogun: Merge pull request #234 from sploving/master | 11:27 |
CIA-87 | shogun: add lua string features modular - https://github.com/shogun-toolbox/shogun/commit/16fc2a1b93f5e2121524a6d468a6f972b2f2d8c2 | 11:27 |
CIA-87 | shogun: Soeren Sonnenburg master * r93a63c7 / src/configure : add ruby narray detection in configure - https://github.com/shogun-toolbox/shogun/commit/93a63c749ac5994478b04611d696a6cc73eb8076 | 11:28 |
@sonney2k | sploving1, and does the script return the same result? | 11:28 |
sploving1 | no, Wrong arguments for overloaded function 'StringCharFeatures_set_feature_vector' | 11:56 |
sploving1 | Possible C/C++ prototypes are: | 11:56 |
sploving1 | set_feature_vector(shogun::CStringFeatures< char > *,shogun::SGVector< char >,int32_t) | 11:57 |
sploving1 | set_feature_vector(shogun::CStringFeatures< char > *,int32_t,char *,int32_t) | 11:57 |
sploving1 | I am looking why | 11:57 |
-!- sploving1 [~sploving@124.16.139.194] has left #shogun [] | 12:01 | |
-!- in3xes [~in3xes@180.149.49.227] has quit [Read error: Connection reset by peer] | 12:08 | |
CIA-87 | shogun: Baozeng Ding master * r0654cea / (3 files in 2 dirs): support SGVector<char> - https://github.com/shogun-toolbox/shogun/commit/0654cead46731267087bad0b73baf5f51e5d7ac5 | 12:18 |
CIA-87 | shogun: Soeren Sonnenburg master * rcb17d3a / (3 files in 2 dirs): | 12:18 |
CIA-87 | shogun: Merge pull request #235 from sploving/master | 12:18 |
CIA-87 | shogun: support lua sgvector<char> - https://github.com/shogun-toolbox/shogun/commit/cb17d3ad839c39d942986d5955d165151e77482d | 12:18 |
CIA-87 | shogun: Baozeng Ding master * rc4fc6c5 / src/interfaces/ruby_modular/swig_typemaps.i : support ruby narray library - https://github.com/shogun-toolbox/shogun/commit/c4fc6c56b4039b949f0a939559a46ebad65c0662 | 12:23 |
CIA-87 | shogun: Soeren Sonnenburg master * rc9e1279 / src/interfaces/ruby_modular/swig_typemaps.i : | 12:23 |
CIA-87 | shogun: Merge pull request #236 from sploving/master | 12:23 |
CIA-87 | shogun: support ruby narray library - https://github.com/shogun-toolbox/shogun/commit/c9e1279f9fb46924a77d276ca155a1a20acbf912 | 12:23 |
-!- sploving1 [~sploving@124.16.139.194] has joined #shogun | 12:31 | |
sploving1 | sonney2k,preprocessor/LocallyLinearEmbedding.cpp:210: error: ‘arpack_dsaupd’ was not declared in this scope | 12:31 |
sploving1 | when I compile the upstream, it shows the above error. | 12:31 |
@sonney2k | sploving1, hopefully fixed | 12:33 |
CIA-87 | shogun: Soeren Sonnenburg master * r2387fee / src/shogun/preprocessor/LocallyLinearEmbedding.cpp : fix compile failure w/o arpack - https://github.com/shogun-toolbox/shogun/commit/2387fee9f7071e46aaf9c70e4171dfb870473c4f | 12:33 |
sploving1 | I will try again. | 12:34 |
-!- sploving1 [~sploving@124.16.139.194] has left #shogun [] | 12:34 | |
-!- in3xes [~in3xes@180.149.49.227] has joined #shogun | 13:33 | |
CIA-87 | shogun: Soeren Sonnenburg master * r19b3616 / src/interfaces/python_modular/swig_typemaps.i : take care of dealloc of python objects in python typemaps and remove unused functions - https://github.com/shogun-toolbox/shogun/commit/19b3616126b6507227003aff3753a7c075d632e9 | 13:43 |
CIA-87 | shogun: Soeren Sonnenburg master * r5ee1b7e / src/configure : fix ruby linkflags - https://github.com/shogun-toolbox/shogun/commit/5ee1b7e12b32b6da3ddfc81c24197fb95ea77f75 | 13:43 |
CIA-87 | shogun: Soeren Sonnenburg master * r595aee7 / src/shogun/lib/DataType.h : | 13:44 |
CIA-87 | shogun: Introduce destroy_vector/matrix. This function should be called only be | 13:44 |
CIA-87 | shogun: the 'owner' of the vector/matrix object. - https://github.com/shogun-toolbox/shogun/commit/595aee74bcf5dd8bfec404d6a36b87b4269cbc03 | 13:44 |
-!- sploving1 [~sploving@210.77.14.219] has joined #shogun | 14:06 | |
sploving1 | how to print f.get_features in python. | 14:07 |
sploving1 | here is :strings <modshogun.CharStringList; proxy of <Swig Object of type 'shogun::SGStringList< char > *' at 0xb6524b18> > if we use print method | 14:07 |
sploving1 | sonney2k, any other print method in features_string_char_modular.py | 14:08 |
@sonney2k | sploving1, ohh | 14:12 |
@sonney2k | I didn't notice that get_features for strings is nto workign in python | 14:13 |
@sonney2k | you could do ''.join(f.get_feature_vector(num)) | 14:13 |
@sonney2k | for now | 14:13 |
sploving1 | num? | 14:14 |
sploving1 | so strange | 14:14 |
@sonney2k | num = 0, ..., number_of_strings | 14:15 |
sploving1 | what is the result expected? | 14:15 |
@sonney2k | a string | 14:16 |
sploving1 | i mean f:get_features() should get which string? | 14:16 |
sploving1 | strings = {'hey','guys','i','am','a','string'}? | 14:16 |
@sonney2k | no | 14:16 |
@sonney2k | a number | 14:16 |
@sonney2k | e.g. 0 | 14:17 |
@sonney2k | then the output should be 'hey' | 14:17 |
sploving1 | f.set_feature_vector(array(['t','e','s','t']), 0) does not effect the result? | 14:17 |
@sonney2k | when you have that in then the output should be 'test' | 14:18 |
sploving1 | vector means columns? then I know | 14:19 |
@sonney2k | vector == one string | 14:19 |
sploving1 | so after that it should be strings = {'test','guys','i','am','a','string'} | 14:19 |
@sonney2k | ahh stupid bug in python typemaps | 14:20 |
@sonney2k | yes | 14:20 |
@sonney2k | sploving1, btw | 14:24 |
@sonney2k | the delete[] is wrong in the string typemap | 14:25 |
@sonney2k | also in python | 14:25 |
@sonney2k | sploving1, so just remove the delete[] str[i].string and delete[] str; | 14:25 |
sploving1 | sonney2k, okay | 14:25 |
@sonney2k | sploving1, what does SWIG_arg++ do? | 14:26 |
sploving1 | that is why when I test, it crashes | 14:26 |
@sonney2k | sploving1, yes | 14:26 |
@sonney2k | (I just got the python typemap to work again) | 14:26 |
sploving1 | SWIG_arg++, maybe related to the number of lua stack | 14:27 |
sploving1 | I am not quite sure about it | 14:27 |
@sonney2k | sploving1, but in typemaps will be translated for every argument right? | 14:27 |
sploving1 | yeap. then? | 14:28 |
@sonney2k | I mean all 3 arguments of foo(SGVector, SGVector, SGMatrix) would be translated or? | 14:28 |
sploving1 | yeap. they can use one typemap | 14:28 |
sploving1 | SGVector use vector typemap and SGMatrix use matrix typemap | 14:29 |
sploving1 | is similar to foo(int, int, int), just write an int typemap | 14:30 |
CIA-87 | shogun: Soeren Sonnenburg master * r6ffbbae / src/interfaces/python_modular/swig_typemaps.i : fix python out typemap for strings - https://github.com/shogun-toolbox/shogun/commit/6ffbbae774955b7de9e581b1718b8479823b9eb2 | 14:36 |
@sonney2k | sploving1, ok | 14:36 |
sploving1 | sonney2k, c++: Internal error: killed (program cc1plus) | 14:39 |
sploving1 | Please submit a full bug report. | 14:39 |
@sonney2k | seems to require too much memory... | 14:39 |
sploving1 | oh | 14:40 |
sploving1 | I will shut down other app(include irc) to re compile it | 14:40 |
-!- sploving1 [~sploving@210.77.14.219] has left #shogun [] | 14:40 | |
-!- sploving1 [~sploving@210.77.14.219] has joined #shogun | 15:23 | |
sploving1 | hmm, compiled,but still not work well | 15:23 |
CIA-87 | shogun: Baozeng Ding master * re79b597 / src/interfaces/lua_modular/swig_typemaps.i : splite SGVector<char> from other types, since there is no char type in lua, we need use one-len string in lua to map a char in C - https://github.com/shogun-toolbox/shogun/commit/e79b5978ee002a6c210cb9312ad913503b47deee | 15:24 |
CIA-87 | shogun: Soeren Sonnenburg master * r6536a37 / src/interfaces/lua_modular/swig_typemaps.i : | 15:24 |
CIA-87 | shogun: Merge pull request #237 from sploving/master | 15:24 |
CIA-87 | shogun: splite SGVector<char> from other types, since there is no char type in lua, we need use one-len string in lua to map a char in C - https://github.com/shogun-toolbox/shogun/commit/6536a37bdeed738599eb1a3d1206878886f470aa | 15:24 |
sploving1 | hey�� | 15:25 |
sploving1 | guys��� | 15:25 |
-!- blackburn [~blackburn@109.226.76.87] has joined #shogun | 15:25 | |
sploving1 | after set, t���� | 15:25 |
sploving1 | guys��� | 15:25 |
sploving1 | every time, I changed typemap and recompile, there usually take a long time and some times the machine crashes! | 15:31 |
blackburn | sonney2k: why it was failing? | 15:32 |
blackburn | LLE+arpack | 15:32 |
sploving1 | is anyway to reduce compile time, other than ./configure --interfaces=lua_modular --enable-debug --disable-doxygen --disable-optimization | 15:32 |
blackburn | ah I see | 15:33 |
blackburn | sploving1: I can't mind any other way | 15:33 |
sploving1 | Checking for Ruby NArray Developer Files ... no why? | 15:35 |
sploving1 | blackburn, oh | 15:35 |
sploving1 | I have installed NArray. | 15:35 |
@sonney2k | sploving1, we will try to reduce the wrapper code size | 15:48 |
@sonney2k | sploving1, we just have too many templates | 15:48 |
@sonney2k | and of course swig typemaps should be as small as possible for all the types | 15:48 |
@sonney2k | like 1-2 lines per type if possible and calling other fucntions | 15:49 |
@sonney2k | this way the generated *.cxx file becomes much smaller... | 15:49 |
@sonney2k | sploving1, bad examples are stringfeatures currently | 15:49 |
sploving1 | sonney2k, okay. | 15:49 |
@sonney2k | string in / out typemap I mean | 15:49 |
sploving1 | Checking for Ruby NArray Developer Files ... no | 15:49 |
@sonney2k | sploving1, yes | 15:50 |
@sonney2k | please install narray to /usr | 15:50 |
@sonney2k | not /usr/local | 15:50 |
@sonney2k | then it should work | 15:50 |
sploving1 | --prefix = /usr/local? | 15:50 |
sploving1 | --prefix = /usr/ | 15:50 |
sploving1 | ? | 15:50 |
@sonney2k | yes | 15:50 |
@sonney2k | not for shogun but for narray | 15:51 |
sploving1 | I will have a try | 15:51 |
@sonney2k | blackburn, I #ifdef'd your arpack code | 15:52 |
@sonney2k | blackburn, so it should now work... | 15:52 |
sploving1 | sonney2k, how do you compiled narray. there is no configure file | 15:52 |
sploving1 | so there cannot use prefix | 15:52 |
@sonney2k | blackburn, btw - trying to fix all memory leaks/borderline issues I realized that it is actually pretty annoying that we use delete[] and new[] ... | 15:52 |
sploving1 | just a Makefile | 15:52 |
sploving1 | ruby extconf.rb make make site-install | 15:53 |
sploving1 | do you mean ruby extconf.rb --prefix=/usr | 15:54 |
@sonney2k | sploving1, where are your ruby extensions normally? | 15:54 |
@sonney2k | for example mine are in /usr/lib/ruby/1.8/x86_64-linux | 15:55 |
sploving1 | /usr/local/lib/site_ruby/1.8/i486-linux | 15:55 |
sploving1 | sonney2k, this is mine | 15:55 |
sploving1 | you mean I should compile ruby?? | 15:56 |
@sonney2k | blackburn, it might be even better to use just SG_MALLOC / SG_CALLOC / SG_FREE - this way we can always SG_RESIZE etc | 15:56 |
@sonney2k | sploving1, no | 15:56 |
@sonney2k | sploving1, but that should then work too | 15:56 |
sploving1 | another simple way is?? | 15:56 |
@sonney2k | sploving1, what does shogun in .config say | 15:56 |
@sonney2k | grep -i INCLUDES_RUBY_MOD .config | 15:57 |
sploving1 | INCLUDES_RUBY= -I/usr/lib/ruby/1.8/i486-linux | 15:57 |
sploving1 | INCLUDES_RUBY_MODULAR= -I/usr/lib/ruby/1.8/i486-linux | 15:57 |
@sonney2k | hmmhh that is weird then - why doesn't it detect it to be in /usr/local ...? | 15:58 |
@sonney2k | does the directory /usr/lib/ruby/1.8/i486-linux exist? | 15:58 |
blackburn | sonney2k: what do you mean? | 15:58 |
blackburn | where do you suggest to use it? | 15:58 |
sploving1 | sonney2k, yeap | 15:59 |
@sonney2k | blackburn, I think we should replace all new[] / delete[] with SG_MALLOC / SG_FREE | 15:59 |
sploving1 | it exist | 15:59 |
@sonney2k | sploving1, ok then that is the path where the extensions should go | 15:59 |
blackburn | sonney2k: what is the +s of this way? | 15:59 |
@sonney2k | blackburn, no more delete[] / free() mismatches between interfaces, we could then use realloc to resize arrays, calloc to allocate a zeroed array (no need to do all this memset(xxx,xxx,0)) | 16:00 |
@sonney2k | blackburn, and even better we can trace memory allocations since we are using our own macros :D | 16:01 |
blackburn | hmm okay | 16:01 |
blackburn | I'll make a tranistion for my preprocessors | 16:01 |
@sonney2k | blackburn, stop | 16:01 |
blackburn | aren't you suggesting me to do that? :D | 16:01 |
@sonney2k | blackburn, that is a big change so we should be pretty sure that this is the right way | 16:02 |
@sonney2k | we should e.g. ask f-x too or heiko... | 16:02 |
blackburn | I could do that for preprocessors | 16:02 |
blackburn | and if something goes wrong - we will know it earlier | 16:02 |
blackburn | some practice ground for SG_* | 16:03 |
@sonney2k | blackburn, things will definitely go wrong because we will then have delete[] / SG_FREE / new[] / SG_MALLOC mismatches | 16:03 |
@sonney2k | blackburn, it has to be done at once | 16:03 |
@sonney2k | replacing delete[] | 16:04 |
blackburn | hmm not only delete/new | 16:04 |
@sonney2k | is trivial sed operation | 16:04 |
blackburn | e.g. if REALLOC was allowed - I would not create new feature matrix | 16:04 |
blackburn | just realloc old one | 16:04 |
blackburn | and so on | 16:04 |
@sonney2k | replacing new[] needs some thought. we might want to change SG_MALLOC to contain the type of the thing to be alloc'd as first argument | 16:04 |
@sonney2k | blackburn, yes correct - that would be possible then | 16:05 |
f-x | sonney2k: i'm for this kind of transition.. but as you say replacing new[] may not be so direct | 16:05 |
@sonney2k | f-x, if we replace new int[17] -> SG_MALLOC(int, 17) it can be done with some regular expression too | 16:06 |
@sonney2k | but yes there might be tough exceptions... | 16:06 |
@sonney2k | better do this manually | 16:06 |
@sonney2k | then we should overload new[] / delete[] to throw an error that this is not allowed ... | 16:07 |
f-x | gradually - i could do it in my part of the code.. would be easier if you just give us some kind of example to follow first | 16:07 |
f-x | right | 16:07 |
@sonney2k | sploving1, hmmhh would it help if we just include /usr/local in include paths too? | 16:10 |
sploving1 | I do not know. I removed the local dir, and I am recompiling narray,using make install instead of make site-install | 16:12 |
@sonney2k | blackburn, f-x ok then so it is decided. I will probably enter berserk mode and just do this change | 16:14 |
blackburn | sonney2k: again berserk mode? :D | 16:14 |
@bettyboo | lol | 16:14 |
@sonney2k | blackburn, berserk mode is the way to go :D | 16:15 |
@sonney2k | so I will first change SG_MALLOC to take as first argument the data type | 16:16 |
@sonney2k | same for SG_REALLOC and SG_CALLOC | 16:17 |
sploving1 | sonney2k, it works! I use : cp /usr/local/lib/site_ruby/1.8/i486-linux/* /usr/lib/ruby/1.8/i486-linux/ | 16:18 |
@sonney2k | sploving1, OK - great | 16:18 |
sploving1 | simple but effective way | 16:19 |
@sonney2k | sploving1, I think at some point we will need to support /usr/local too but for now I dont' know how except hardcoding it | 16:19 |
sploving1 | oh. maybe serialhex can help | 16:19 |
@sonney2k | sploving1, that is true - he might know how to detect the install path(s) | 16:20 |
-!- gsomix [~gsomix@109.169.145.83] has joined #shogun | 16:21 | |
sploving1 | gtg, bye sonney2k | 16:21 |
@sonney2k | sploving1, ok cu | 16:21 |
-!- sploving1 [~sploving@210.77.14.219] has left #shogun [] | 16:22 | |
@sonney2k | blackburn, do you know what gsomix's opinion on SG_MALLOC vs new[] would be? | 16:22 |
blackburn | I don't know - he is here | 16:23 |
-!- gsomix [~gsomix@109.169.145.83] has quit [Ping timeout: 258 seconds] | 16:28 | |
-!- gsomix [~gsomix@109.169.145.83] has joined #shogun | 16:29 | |
gsomix | sonney2k, i vote for 'new'. | 16:31 |
@sonney2k | gsomix, new[] you mean? | 16:31 |
gsomix | yep | 16:31 |
@sonney2k | gsomix, did you read our discussion in the logs? | 16:31 |
gsomix | sonney2k, wait a minute | 16:32 |
@sonney2k | <sonney2k> blackburn, no more delete[] / free() mismatches between interfaces, we could then use realloc to resize arrays, calloc to allocate a zeroed array (no need to do all this memset(xxx,xxx,0)) | 16:33 |
@sonney2k | <sonney2k> blackburn, and even better we can trace memory allocations since we are using our own macros :D | 16:33 |
blackburn | can't mind any reason why new is better ;) | 16:37 |
gsomix | sonney2k, i have no arguments other than aesthetics. :) In this case, the macros better. | 16:38 |
gsomix | afk | 16:39 |
@sonney2k | gsomix, well we can use int* x=SG_MALLOC(int, 123) vs int* x=new int[123] | 16:39 |
blackburn | SG_CALLOC I guess? | 16:41 |
@sonney2k | blackburn, does new[] zero the memory? | 16:42 |
@sonney2k | I thought not? | 16:42 |
blackburn | no | 16:42 |
blackburn | do you mind to use malloc as calloc? | 16:42 |
@sonney2k | yes | 16:42 |
blackburn | why? | 16:42 |
@sonney2k | then better use SG_CALLOC explicitly | 16:42 |
@sonney2k | non-standard behaviour | 16:43 |
blackburn | SG_MALLOC(int, 123) is kinda non-standart | 16:43 |
gsomix | sonney2k, ok. I will fix own code. | 16:43 |
blackburn | gsomix: you shouldn't | 16:43 |
blackburn | we have specially trained berserk for that kind of ops | 16:44 |
gsomix | wow | 16:44 |
@sonney2k | black mode ops | 16:44 |
blackburn | I heard he have six 24' displays and 12 eyes | 16:45 |
blackburn | and 5 hands of course | 16:45 |
@sonney2k | blackburn, and is being sponsored by CIA, FBI, KGB... and google! | 16:45 |
blackburn | yes, especially by non-existent KGB :D | 16:46 |
* gsomix remembered the joke about Vim and a third arm. | 16:46 | |
@sonney2k | gsomix, you name it + vim powered | 16:48 |
@sonney2k | blackburn, you would think! | 16:48 |
blackburn | hmm I use wrong kernel now | 16:50 |
blackburn | :D | 16:50 |
-!- blackburn [~blackburn@109.226.76.87] has quit [Quit: Leaving.] | 16:50 | |
gsomix | I was without electricity today. =___= | 16:57 |
gsomix | And yesterday. | 16:57 |
-!- blackburn [~blackburn@109.226.76.87] has joined #shogun | 16:59 | |
-!- sploving1 [~sploving@210.77.14.219] has joined #shogun | 17:04 | |
sploving1 | sonne2y, I tested minimal_test.rb | 17:05 |
sploving1 | sonney2k, but it does not work | 17:05 |
sploving1 | require 'modshogun' | 17:05 |
sploving1 | gk=modshogun::GaussianKernel.new(), is this right?? | 17:05 |
sploving1 | serialhex, any suggestion?? | 17:11 |
-!- in3xes [~in3xes@180.149.49.227] has quit [Quit: Leaving] | 17:21 | |
-!- [1]warpy [~warpy@bzq-79-181-43-167.red.bezeqint.net] has joined #shogun | 17:22 | |
[1]warpy | hey sonney2k | 17:23 |
-!- sploving1 [~sploving@210.77.14.219] has left #shogun [] | 17:23 | |
[1]warpy | i have the updated typemap and all the java converted examples. can i issue a pull request even though they are a little broken. i just want to get them on the master branch so that sploving can use them when he starts with the c# thing | 17:24 |
-!- in3xes [~in3xes@180.149.49.227] has joined #shogun | 18:07 | |
CIA-87 | shogun: Sergey Lisitsyn master * re0df385 / (2 files): Merge branch 'master' of git://github.com/gsomix/shogun - https://github.com/shogun-toolbox/shogun/commit/e0df3851f64846855e56dde8e2092f22e0ef6977 | 18:12 |
CIA-87 | shogun: Evgeniy Andreev master * r72b9f6c / (2 files): Added get_key function for Fibonacci heap - https://github.com/shogun-toolbox/shogun/commit/72b9f6c797f73f1f83007de84c5f4b5a0e6cb118 | 18:12 |
-!- f-x [~user@117.192.215.140] has quit [Ping timeout: 260 seconds] | 18:26 | |
-!- gsomix [~gsomix@109.169.145.83] has quit [Read error: Connection reset by peer] | 18:43 | |
-!- gsomix [~gsomix@109.169.154.188] has joined #shogun | 18:50 | |
CIA-87 | shogun: Evgeniy Andreev master * rf8fba71 / src/shogun/lib/FibonacciHeap.cpp : Fix fatal bug - https://github.com/shogun-toolbox/shogun/commit/f8fba71e0d82189adb15a49df3003013a6d54396 | 18:56 |
CIA-87 | shogun: Sergey Lisitsyn master * r0370104 / src/shogun/lib/FibonacciHeap.cpp : Merge branch 'master' of git://github.com/gsomix/shogun - https://github.com/shogun-toolbox/shogun/commit/0370104d67d2da5f5fd734d984459700354ac190 | 18:56 |
CIA-87 | shogun: Sergey Lisitsyn master * r08e35cf / (2 files): Moved isomap_distance to .cpp - https://github.com/shogun-toolbox/shogun/commit/08e35cf3e7d080c3469a412458013fae92d86274 | 19:36 |
[1]warpy | sonney2k alive ? | 19:47 |
CIA-87 | shogun: Soeren Sonnenburg master * rcc045e9 / (30 files in 11 dirs): | 19:53 |
CIA-87 | shogun: Introduce new SG_MALLOC/REALLOC/CALLOC macros calling sg_malloc etc but | 19:53 |
CIA-87 | shogun: have the type information as first argument. Change all of shogun to use | 19:53 |
CIA-87 | shogun: these new macros. - https://github.com/shogun-toolbox/shogun/commit/cc045e9cfb9e08c439f5fad300c81a6623661c92 | 19:53 |
@sonney2k | blackburn, please have a look at the new SG_MALLOC macros | 19:55 |
@sonney2k | they are in shogun/lib/memory.h | 19:55 |
@sonney2k | f-x_, you too please ^ | 19:55 |
@sonney2k | if these are ok with you f-x_ blackburn I continue the berserk and do the delete[] new[] stuff | 19:56 |
blackburn | looks much better to me | 19:57 |
@sonney2k | blackburn, it even saved quite a bit of code already | 19:57 |
@sonney2k | utilizing the SG_CALLOC that is | 19:58 |
@sonney2k | $ grep 'new [^[]*\[' shogun/ -r | wc -l | 19:58 |
@sonney2k | 1382 | 19:58 |
@sonney2k | hmmhhhh | 19:58 |
blackburn | shhhhhh | 19:58 |
@sonney2k | and I thought there were many ALLOC's | 20:00 |
@sonney2k | $ grep 'SG_.*ALLOC' shogun/ -r | wc -l | 20:00 |
@sonney2k | 220 | 20:00 |
@sonney2k | but no... | 20:00 |
@sonney2k | $ grep 'delete\[\]' shogun/ -r | wc -l | 20:01 |
@sonney2k | 1540 | 20:01 |
@sonney2k | huh ?! we delete[] more often than we new[] ... | 20:01 |
blackburn | :D | 20:01 |
blackburn | ??? | 20:02 |
@sonney2k | I guess cleanups in error handling... | 20:02 |
@sonney2k | anyways | 20:02 |
blackburn | фр | 20:02 |
* sonney2k goes berserk again | 20:02 | |
blackburn | ah | 20:02 |
blackburn | destructors and so on | 20:02 |
-!- gsomix [~gsomix@109.169.154.188] has quit [Quit: Ухожу я от вас (xchat 2.4.5 или старше)] | 20:06 | |
* sonney2k issues find shogun -type f -exec sed -ie 's/delete\[\][ \t]*\([^ ;]*\)[ \t]*;/SG_FREE(\1);/g' {} \; | 20:07 | |
@sonney2k | delete[]'s are gone... | 20:20 |
@sonney2k | blackburn, gotcha - what is this in LLE? | 20:29 |
@sonney2k | SGMatrix<float64_t>(new float64_t[N*N],N,N,true); ? | 20:29 |
@sonney2k | just write SGMatrix<flaot64_t>(N,N,true) | 20:29 |
@sonney2k | and it will be alloc'd | 20:29 |
blackburn | seriously? | 20:29 |
blackburn | didn't know | 20:29 |
blackburn | :) | 20:29 |
@sonney2k | look at lib/DataType.h | 20:29 |
blackburn | feel free to fix ;) | 20:30 |
@sonney2k | blackburn, I have to because my sed script wont' work with new xxx[], bla, foo); | 20:30 |
blackburn | okay | 20:30 |
[1]warpy | sonney2k, did you see my pull request | 20:38 |
@sonney2k | blackburn, so instead of writing | 20:38 |
@sonney2k | SGMatrix<float64_t> M_matrix = SGMatrix<float64_t>(new float64_t[N*N],N,N,true); | 20:38 |
@sonney2k | you can write | 20:38 |
@sonney2k | SGMatrix<float64_t> M_matrix(N,N,true); | 20:38 |
blackburn | hmm | 20:38 |
blackburn | okay | 20:39 |
@sonney2k | blackburn, looks much better doesn't it? | 20:39 |
blackburn | exactly it is | 20:39 |
-!- gsomix [~gsomix@109.169.154.188] has joined #shogun | 20:39 | |
blackburn | just habits of using this way with other objects | 20:40 |
@sonney2k | [1]warpy, yes but no time right now - this transition has prio | 20:41 |
@sonney2k | blackburn, heiko is doing the same thing :( | 20:42 |
[1]warpy | ok | 20:57 |
-!- [1]warpy [~warpy@bzq-79-181-43-167.red.bezeqint.net] has quit [Quit: HydraIRC -> http://www.hydrairc.com <- s0 d4Mn l33t |t'z 5c4rY!] | 20:57 | |
blackburn | hooray, managed ltsa to work | 21:00 |
blackburn | http://dl.dropbox.com/u/10139213/shogun/ltsa-k8.png | 21:02 |
blackburn | sonney2k: how it is going? | 21:50 |
@sonney2k | blackburn, I had an important phone call so I couldn't do anythin in the last hour :( | 21:56 |
* sonney2k back to berserk | 21:56 | |
blackburn | I see | 21:56 |
@sonney2k | blackburn, I have high hopes that I can solve everything with sed :) | 21:59 |
@sonney2k | it is just not looking too beautiful I must admit... | 21:59 |
blackburn | I hope so | 21:59 |
* sonney2k runs find shogun -type f -exec sed -i -e 's/new[ \t]*\([^[(]*\)\[\(.*\)\];/SG_MALLOCX(\1, \2);/g' {} \; | 22:17 | |
* sonney2k reverts the change | 22:21 | |
blackburn | fail? | 22:22 |
@sonney2k | blackburn, berserk not fail :D | 22:26 |
@sonney2k | it will be so super cool to ./configure --trace-mallocs | 22:26 |
@sonney2k | and then to list all malloc'd size's | 22:26 |
blackburn | any way to automagically detect memory leak? | 22:28 |
-!- in3xes [~in3xes@180.149.49.227] has quit [Quit: Leaving] | 22:30 | |
@sonney2k | blackburn, at least we could store a table with sizes of the allocated memory | 22:34 |
@sonney2k | blackburn, otherwise valgrind... | 22:34 |
@sonney2k | of course if we modify SG_MALLOC to take as last parameter __LINE__ then we can really trace it... | 22:35 |
@sonney2k | actually that is easy - we just do this when TRACE_MALLOCS is on | 22:36 |
@sonney2k | so we see the lines where SG_MALLOC got called including the memory size :D | 22:37 |
@bettyboo | interesting sonney2k | 22:37 |
@sonney2k | bettyboo, you are damn right | 22:37 |
@bettyboo | sonney2k: but on the other hand these are damn cool features. | 22:37 |
@sonney2k | blackburn, it did compile with my changes in... | 22:38 |
@sonney2k | so the above grep doesn't return anything now :) | 22:39 |
@bettyboo | interesting | 22:39 |
blackburn | sonney2k: I have an idea | 22:39 |
@sonney2k | ? | 22:39 |
blackburn | if we store all the allocated things in some 'table' or so | 22:40 |
blackburn | we could force free it with warning | 22:40 |
blackburn | on exit | 22:40 |
@sonney2k | blackburn, we do already | 22:40 |
blackburn | so no crashes | 22:40 |
@sonney2k | well ohh no | 22:40 |
@sonney2k | not a good idea... | 22:40 |
blackburn | why? | 22:40 |
@sonney2k | because we don't know when we exit | 22:40 |
@sonney2k | hmmhh 2 examples segfault now | 22:41 |
@sonney2k | all the others seem to work just fine :) | 22:41 |
blackburn | too bad we can't do auto-cleaning :( | 22:43 |
@sonney2k | ahh examples crashed because I forgot to convert them :D | 22:49 |
blackburn | did you restrict new somehow? | 22:50 |
@sonney2k | blackburn, the problem really is that if you want to do efficient memory handling you have to do it manually | 22:50 |
@sonney2k | blackburn, restrict? | 22:50 |
blackburn | prohibit/disallow/.. | 22:50 |
blackburn | you said we should do it or so | 22:51 |
@sonney2k | I know the word but I don't understand what you are asking | 22:51 |
blackburn | me too | 22:53 |
blackburn | :D | 22:53 |
blackburn | nevermind | 22:53 |
@sonney2k | blackburn, do you have an idea what | 22:53 |
@sonney2k | *(CSGObject***) m_parameter | 22:53 |
@sonney2k | = new CSGObject*[new_length](); | 22:53 |
@sonney2k | this means? | 22:53 |
blackburn | oh shit | 22:53 |
@sonney2k | what do the extra () do ? | 22:53 |
@sonney2k | if I put a SG_MALLOC(CSGObject, new_length) there | 22:53 |
@sonney2k | it will crash | 22:53 |
@sonney2k | hmmhh CALLOC works | 22:54 |
@sonney2k | so that was just a CALLOC ... | 22:55 |
blackburn | yes looks like | 22:56 |
blackburn | will new double[](10.0); work? | 22:56 |
blackburn | triple pointer rocks | 22:57 |
CIA-87 | shogun: Soeren Sonnenburg master * r8431a6d / (194 files in 32 dirs): examples all run trough nicely, so rename SG_MALLOCX -> SG_MALLOC (+6 more commits...) - https://github.com/shogun-toolbox/shogun/commit/8431a6db403e11a7b0b678bb348ba5a35b70e0b6 | 22:58 |
blackburn | sonney2k: soon you'll have ~1M lines changed :D | 22:59 |
@sonney2k | blackburn, nope won't work error: ISO C++ forbids initialization in array new | 23:00 |
blackburn | hmm | 23:00 |
blackburn | with classes it works I guess | 23:01 |
@sonney2k | but that works | 23:01 |
@sonney2k | double* l=new double[5](); | 23:01 |
@sonney2k | looks like it is inited with 0 | 23:01 |
@sonney2k | just like CALLOC | 23:01 |
blackburn | yes | 23:01 |
@sonney2k | blackburn, crazy sh... | 23:01 |
blackburn | yes we use kinda strange language :) | 23:02 |
blackburn | that's why I suggest you to write shogun in perl | 23:02 |
@sonney2k | blackburn, I had one more such problem with the SG_MALLOC thingy | 23:07 |
@sonney2k | there was a double templated type | 23:07 |
@sonney2k | sth like new foo<int, int>[17] | 23:08 |
@sonney2k | SG_MALLOC(foo<int,int>, 17) didn't work because the macro parser thought that due to the additional ',' the macro gets 3 arguments | 23:08 |
@sonney2k | ^ blackburn hefty corner cases right? | 23:09 |
blackburn | uh | 23:09 |
@sonney2k | so I worked around this by using typedef's... | 23:09 |
blackburn | hmmm there are a robust version of LTSA | 23:11 |
blackburn | if it is good and I implement it - shogun will have it 'exclusively' | 23:11 |
@sonney2k | blackburn, I am modifying lib/memory now such that we can use TRACE_MALLOCS :) | 23:11 |
blackburn | nice | 23:11 |
blackburn | sonney2k: could you write a command to replace new/delete? | 23:16 |
@sonney2k | you mean overload the operator? | 23:16 |
blackburn | not, that you used | 23:16 |
@sonney2k | ?! | 23:16 |
blackburn | you did sed ... blabla to replace it, right? | 23:17 |
@sonney2k | yes | 23:17 |
blackburn | can you paste it here? | 23:17 |
@sonney2k | blackburn, I closed the shell already .. don't have it in history ... | 23:18 |
blackburn | ah oka | 23:18 |
@sonney2k | blackburn, ahh here | 23:18 |
@sonney2k | find shogun -type f -exec sed -i -e 's/new \([a-zA-Z][^[(]*\)\[\(.*\)\];/SG_MALLOCX(\1, \2);/g' {} \; | 23:18 |
@sonney2k | but it will replace to MALLOCX | 23:18 |
@sonney2k | (I did this for debugging to be able to see that this is not a standard MALLOC) | 23:19 |
blackburn | uh | 23:19 |
blackburn | how to use it for one file? | 23:19 |
@sonney2k | sed -i -e 's/new \([a-zA-Z][^[(]*\)\[\(.*\)\];/SG_MALLOCX(\1, \2);/g' file.cpp | 23:24 |
blackburn | thanks | 23:24 |
@sonney2k | easy to read isn't it :D | 23:29 |
@sonney2k | I wonder when bettyboo will paste that line :D | 23:29 |
blackburn | I can't understand a little | 23:29 |
@bettyboo | sonney2k: I had been sick for a while just like Chris, such a wonder - cold is going around Samara and Tuebingen both :D | 23:29 |
blackburn | shh | 23:30 |
blackburn | can* | 23:30 |
blackburn | not can't | 23:30 |
@sonney2k | bettyboo, now I am sick though and the others are ok | 23:30 |
@bettyboo | sonney2k: ok, you're not getting the spiffy cleaned-up version today, but you are getting the version that works today... it's sleep time yo! nite all, and morning everyone else!!! | 23:30 |
blackburn | I can say whose phrase does she say | 23:30 |
blackburn | every time | 23:31 |
blackburn | LTSA for shogun is almost done | 23:32 |
@sonney2k | :) | 23:36 |
@sonney2k | and :) | 23:36 |
-!- gsomix [~gsomix@109.169.154.188] has quit [Ping timeout: 263 seconds] | 23:45 | |
blackburn | hoooooooooooooooray | 23:58 |
--- Log closed Wed Jul 27 00:00:31 2011 |
Generated by irclog2html.py 2.10.0 by Marius Gedminas - find it at mg.pov.lt!