--- Log opened Sat Nov 17 00:00:17 2012 | ||
-!- zxtx [~zv@216.3.101.62] has joined #shogun | 00:02 | |
-!- zxtx [~zv@216.3.101.62] has quit [Ping timeout: 245 seconds] | 00:17 | |
-!- blackburn [~blackburn@109.226.125.245] has quit [Quit: Leaving.] | 00:34 | |
shogun-buildbot | build #145 of nightly_all is complete: Failure [failed compile] Build details are at http://www.shogun-toolbox.org/buildbot/builders/nightly_all/builds/145 | 03:00 |
---|---|---|
shogun-buildbot | build #151 of nightly_none is complete: Failure [failed compile] Build details are at http://www.shogun-toolbox.org/buildbot/builders/nightly_none/builds/151 | 03:00 |
shogun-buildbot | build #174 of nightly_default is complete: Failure [failed compile] Build details are at http://www.shogun-toolbox.org/buildbot/builders/nightly_default/builds/174 | 03:01 |
-!- ptizoom [~christian@85.210.94.175] has joined #shogun | 08:53 | |
-!- zxtx [~zv@ool-45750cfe.dyn.optonline.net] has joined #shogun | 09:34 | |
-!- blackburn [~blackburn@109.226.125.245] has joined #shogun | 10:01 | |
blackburn | *okayface* | 10:01 |
-!- blackburn [~blackburn@109.226.125.245] has quit [Quit: Leaving.] | 12:37 | |
-!- blackburn [~blackburn@109.226.125.245] has joined #shogun | 13:14 | |
blackburn | sonney2k: I see you are a fan of russian driving? | 13:14 |
-!- blackburn [~blackburn@109.226.125.245] has quit [Client Quit] | 13:14 | |
-!- blackburn [~blackburn@109.226.125.245] has joined #shogun | 13:17 | |
-!- blackburn [~blackburn@109.226.125.245] has quit [Client Quit] | 13:18 | |
-!- blackburn [~blackburn@109.226.125.245] has joined #shogun | 13:24 | |
-!- blackburn [~blackburn@109.226.125.245] has quit [Client Quit] | 13:25 | |
-!- blackburn [~blackburn@109.226.125.245] has joined #shogun | 13:26 | |
-!- blackburn [~blackburn@109.226.125.245] has quit [Remote host closed the connection] | 14:12 | |
wiking | \\\oooooooooooooooooo////////////// | 14:18 |
wiking | NCBM is wooooooooooooooooorking | 14:18 |
wiking | at least the convex part of it! | 14:19 |
-!- blackburn [~blackburn@109.226.125.245] has joined #shogun | 14:32 | |
wiking | blackburn: maaan | 14:43 |
wiking | good news | 14:43 |
wiking | ncbm started to work! | 14:43 |
blackburn | yes? | 14:43 |
blackburn | cool | 14:43 |
wiking | mmm | 14:45 |
wiking | mmm | 14:46 |
wiking | maybe even lbfgs | 14:46 |
wiking | can compute only the linesearch? :) | 14:46 |
wiking | it seems not | 14:46 |
blackburn | you mean pass a function to let it do linesearch only? | 14:47 |
wiking | yes | 14:47 |
blackburn | no idea | 14:47 |
wiking | as it has the line search algo implemented i need | 14:47 |
blackburn | copy paste | 14:47 |
blackburn | :D | 14:47 |
wiking | hahahah | 14:47 |
wiking | yeah maybe | 14:47 |
wiking | or as shogun has it | 14:47 |
wiking | i should be able to call it as extern | 14:47 |
wiking | lbfgs can solve min f(x)? | 14:48 |
blackburn | that's what it purposed to, no? | 14:48 |
wiking | dunno | 14:49 |
wiking | i'm wondering what it can solve | 14:49 |
blackburn | any nonlinear problem I think | 14:49 |
blackburn | with continuous gradient at least | 14:50 |
wiking | mmm | 14:51 |
wiking | i could give it go i guess ;) | 14:51 |
wiking | lol it's one big c file | 14:54 |
wiking | mmm i think i should be able to call it | 14:54 |
wiking | mmm this'll be an interesting one | 14:57 |
wiking | eheeem | 16:00 |
wiking | i do better with less iterations | 16:00 |
wiking | :> | 16:00 |
wiking | 115 vs 44 iterations | 16:01 |
wiking | but there's 2 times more cutting planes | 16:01 |
wiking | well something for someting | 16:01 |
blackburn | heh | 16:03 |
blackburn | sonney2k: I think you should take a look at the Processing language | 18:52 |
wiking | someone should fix the inline malloc ;) | 19:13 |
blackburn | haha | 19:13 |
blackburn | who cares | 19:13 |
@sonney2k | wiking, I think we should (inside of) SG_INPLACE_MALLOC use new[]() and SG_INPLACE_FREE then to free it | 20:44 |
blackburn | free new[] is a good idea ;) | 20:45 |
@sonney2k | blackburn, what do you want to say? | 20:45 |
blackburn | just joking | 20:45 |
blackburn | I mean we have to be careful to delete[] it | 20:45 |
blackburn | not to delete or free | 20:45 |
@sonney2k | blackburn, sure | 20:47 |
@sonney2k | it sucks big times that the only reason for the existence of new[] is that new[]() stuff | 20:47 |
@sonney2k | which is so cumbersome in syntax that it really feels broken by design :/ | 20:48 |
@sonney2k | anyways SG_MALLOC has helped us a lot to avoid copying matrices | 20:48 |
blackburn | why? I don't feel new[] is inconsistent | 20:48 |
@sonney2k | new() | 20:48 |
@sonney2k | new[] | 20:48 |
@sonney2k | new[]() ? | 20:48 |
@sonney2k | malloc | 20:48 |
@sonney2k | delete | 20:48 |
@sonney2k | delete[] | 20:48 |
@sonney2k | free? | 20:48 |
blackburn | what is new[]()? | 20:49 |
@sonney2k | realloc? | 20:49 |
@sonney2k | blackburn, that is what we need to call the default constructor | 20:49 |
blackburn | ahh | 20:49 |
@sonney2k | your placement constructor / inplace new | 20:49 |
blackburn | new FuckerClass[30](); | 20:49 |
blackburn | like that? | 20:49 |
blackburn | well still - isn't really inconsistent | 20:49 |
@sonney2k | new SGVector<int>[40](); | 20:49 |
blackburn | I mean it is quite minimal | 20:49 |
@sonney2k | what? | 20:49 |
@sonney2k | you cannot mix any of the stuff above | 20:50 |
@sonney2k | so you break all api's to C | 20:50 |
blackburn | well | 20:50 |
@sonney2k | and we interface to lots of C libraries | 20:50 |
blackburn | interfacing is not a problem | 20:50 |
blackburn | pointers are valid still | 20:50 |
blackburn | and libraries do not free our resources | 20:51 |
@sonney2k | so we basically need to stay at malloc & friends | 20:51 |
@sonney2k | yeah but it is not just calling it is owning a ptr allocated by e.g. numpy | 20:51 |
@sonney2k | and vise versa | 20:51 |
blackburn | we let libs own our memory only in sgvector case I think | 20:52 |
blackburn | sgmatrix/sgvector | 20:52 |
@sonney2k | exactly | 20:52 |
blackburn | so for collections of vectors or anything like that | 20:52 |
blackburn | we can use new[] | 20:52 |
@sonney2k | but new[] is not enough | 20:52 |
@sonney2k | new[]() | 20:52 |
blackburn | what's the problem with new[]() and new[]? | 20:53 |
@sonney2k | it is a big difference | 20:53 |
@sonney2k | one will be as bad as malloc() | 20:53 |
@sonney2k | (requiring the placement constructor call) | 20:53 |
@sonney2k | and the issue I have with this is that I would have liked to just use one macro for all SG_MALLOC | 20:54 |
@sonney2k | so now we again have to be cautious which malloc macro we use | 20:54 |
blackburn | it is possible with templates :D | 20:54 |
@sonney2k | how so? | 20:55 |
blackburn | we specialize template for stypes like float64-t | 20:55 |
blackburn | to not call in-place | 20:55 |
@sonney2k | but we cannot do it for everything | 20:56 |
@sonney2k | I mean think of people using some structure | 20:56 |
blackburn | it is actually compiles to inplace say float | 20:56 |
blackburn | (I think so) | 20:56 |
blackburn | I mean new float[64]() works | 20:56 |
@sonney2k | maybe the other way around would work | 20:57 |
@sonney2k | we specialize templates only for SGVector & friends | 20:57 |
blackburn | yeah it would work too | 20:57 |
@sonney2k | to call new[]() | 20:57 |
@sonney2k | and delete[] | 20:57 |
@sonney2k | so to do this we would need to make the sg_malloc function templated | 20:58 |
@sonney2k | and then overload the implementation for SGVector | 20:58 |
blackburn | yes, if we specialize it it would work smoothly | 20:59 |
@sonney2k | but will this compile - I mean when we define a templated function that uses malloc by default? | 20:59 |
blackburn | why not? | 20:59 |
@sonney2k | well conflict in function definition? no? | 21:00 |
blackburn | no, it is not overloading | 21:00 |
@sonney2k | I mean if we specialize one type - don't we have to specialize all types? | 21:00 |
blackburn | it is specialization | 21:00 |
blackburn | no | 21:00 |
blackburn | just put it to header | 21:00 |
@sonney2k | sure about that? | 21:00 |
blackburn | absolutely, that's how generic C++ works | 21:00 |
@sonney2k | we ignore lib/memory* in interfaces anyways | 21:00 |
@sonney2k | so then that will solve all our problems | 21:00 |
@sonney2k | and we can get rid of this sh* extra macro | 21:01 |
blackburn | template<typename T> sg_malloc(...) { default impl } | 21:02 |
blackburn | template<> sg_malloc<SGVector> sg_malloc(...) { inplace } | 21:02 |
@sonney2k | and we can acturally even return a T* | 21:02 |
blackburn | ah return type | 21:02 |
blackburn | so | 21:02 |
blackburn | template<> sg_malloc<SGVector> SGVector* sg_malloc(...) { inplace } | 21:03 |
blackburn | template<typename T> T* sg_malloc(...) { default impl } | 21:03 |
blackburn | then we use | 21:03 |
@sonney2k | blackburn, but what about SGVector? | 21:03 |
blackburn | sg_malloc<SGVector>() | 21:03 |
@sonney2k | I mean it is templated again | 21:03 |
blackburn | ahh | 21:03 |
blackburn | hehe | 21:03 |
@sonney2k | so we would need to do this for all types right? | 21:03 |
blackburn | no | 21:03 |
@sonney2k | sg_malloc<SGVector<int> > etc | 21:03 |
blackburn | we can use | 21:04 |
blackburn | template<template .. | 21:04 |
@sonney2k | ohh I need the exact syntax | 21:04 |
blackburn | hah I just don't know how would it work with basic types | 21:05 |
@sonney2k | template<class T, class U> T* sg_malloc(...) { default impl } | 21:05 |
blackburn | uh oh | 21:05 |
blackburn | sounds like a problem :D | 21:06 |
@sonney2k | why? | 21:06 |
blackburn | we can't specialize templated templates | 21:06 |
blackburn | we'd need to specialize it for all possible types | 21:07 |
blackburn | if that's ok - it still would work | 21:07 |
@sonney2k | luckily sgvector etc use only a couple of fixed numeric types | 21:08 |
@sonney2k | so yes it would work | 21:08 |
blackburn | sonney2k: I use partial specialization in tapkee instead of virtual methods | 21:10 |
blackburn | I have enum parameter 'method' which I specialize with concrete implementation | 21:11 |
@sonney2k | yeah there is always >1 way and there are pros/cons | 21:12 |
@sonney2k | so we need to do this for malloc, calloc, realloc | 21:13 |
blackburn | do we use realloc? | 21:13 |
@sonney2k | at least we should throw an exception if someone does | 21:14 |
@sonney2k | for a user it seems it is all malloc handles so he might be tempted to use realloc | 21:14 |
@sonney2k | another reason I hate new[] | 21:15 |
@sonney2k | now realloc available | 21:15 |
@sonney2k | no | 21:15 |
blackburn | I don't know real use-cases of realloc | 21:15 |
@sonney2k | a dynamically growing array? | 21:15 |
blackburn | it should be hidden | 21:16 |
@sonney2k | something like std:;vector but fast | 21:16 |
blackburn | haha std vector is fast | 21:16 |
@sonney2k | resize it then | 21:16 |
@sonney2k | it cannot use realloc | 21:16 |
@sonney2k | it needs to *copy* | 21:16 |
blackburn | why are you so sure about that? | 21:17 |
@sonney2k | because there is no realloc op in C++ | 21:18 |
blackburn | what makes it so impossible to use it in implementation of vector? | 21:18 |
@sonney2k | and what is worse: if you have a 1G matrix and want to resize it to a 2G matrix | 21:18 |
@sonney2k | you not only have to copy 1G | 21:18 |
@sonney2k | but you also need 3G of mem | 21:18 |
@sonney2k | temporarily but still | 21:18 |
@sonney2k | new[] delete[] lala | 21:19 |
blackburn | you make me have to find it in sources | 21:19 |
blackburn | right | 21:22 |
blackburn | sonney2k: okay actually 1G -> 2G resize is something wrong | 21:24 |
blackburn | I mean you just shouldn't use such data structure | 21:24 |
blackburn | you can't *guarantee* realloc will manage to free 1G next to your 1G available | 21:24 |
blackburn | I'd say it is very unlikely realloc will keep it at its place | 21:25 |
@sonney2k | blackburn, why? | 21:29 |
@sonney2k | memory is for a long time not contiguous (in real world) | 21:29 |
blackburn | sonney2k: yes it is very non-contiguous | 21:29 |
@sonney2k | some weird mapping the kerlneld will do | 21:30 |
@sonney2k | anyway lets first template sg_malloc and friends and then specialize | 21:30 |
wiking | lalalalalaaaaaaaaaaaaaaaaaaaa | 21:31 |
@sonney2k | wiking, singing in the rain? | 21:31 |
@sonney2k | too bad that we didn't get in doc camp btw but looks like you were right | 21:32 |
wiking | and by the way this is lol: http://www.flickr.com/photos/whitehouse/8191317327/in/photostream | 21:32 |
wiking | sonney2k: hehehe that's alright | 21:32 |
wiking | in a parallel universe we got in and we wrote a book | 21:32 |
wiking | ;) | 21:32 |
@sonney2k | I hope these templates won't create dependency hell again | 21:34 |
blackburn | http://www.roflcat.com/images/cats/I_Should_Buy_A_Boat.jpg | 21:35 |
-!- sonney2k [~shogun@7nn.de] has left #shogun ["Ex-Chat"] | 21:35 | |
blackburn | C++ programmers go right to dependency hell after passing away | 21:35 |
-!- sonney2k [~shogun@7nn.de] has joined #shogun | 21:38 | |
-!- mode/#shogun [+o sonney2k] by ChanServ | 21:38 | |
@sonney2k | blackburn, hum I cannot have the real sg_malloc in the .cpp file any longer right? | 21:40 |
blackburn | no if you want it to be generic you can't | 21:40 |
@sonney2k | only if I wanted to allow a certain fixed amount of types | 21:40 |
blackburn | that's not generic just some code generation | 21:41 |
@sonney2k | maybe I should keep the original sg_malloc in there and then just define a templated one that calls the sg_malloc by default | 21:41 |
blackburn | yeah why not | 21:41 |
blackburn | but template goes to .h | 21:41 |
wiking | mmm | 21:41 |
wiking | one question | 21:41 |
@sonney2k | only one? | 21:42 |
blackburn | the answer is yes | 21:42 |
@sonney2k | no 43 | 21:42 |
blackburn | always say yes | 21:42 |
blackburn | 42& | 21:42 |
blackburn | ? | 21:42 |
wiking | shouldn't we have like line searching methods under optimizers? | 21:42 |
wiking | i mean now that i'm putting one in for my method as a static function | 21:42 |
@sonney2k | makes sense | 21:42 |
wiking | maybe in a future | 21:42 |
blackburn | I consider line search as a part of optimizers | 21:42 |
wiking | somebody else will need it as well | 21:42 |
wiking | blackburn: well yeah i'm writing this optimizer | 21:43 |
wiking | but now i need line searching | 21:43 |
blackburn | well they are pretty tied to each other | 21:43 |
wiking | but i wonder if maybe somebody else will need it | 21:43 |
wiking | if ever of course.. | 21:43 |
wiking | btw i have some more code cleanups for the bmrm methods | 21:43 |
blackburn | problem is that line-search schemes are usually use a few parameters from the outside | 21:43 |
wiking | yes indeed | 21:44 |
blackburn | and it is hard to provide interface so flexible it fits everywhere | 21:44 |
wiking | yeah that's true | 21:44 |
wiking | but yeah you need somekind of a function evaluator to be able to pass | 21:44 |
wiking | and initial vector with the gradient | 21:44 |
wiking | that's kind of like what you need to be able to pass in general | 21:44 |
@sonney2k | blackburn, ok doing it like this: | 21:45 |
@sonney2k | #define SG_MALLOC(type, len) sg_generic_malloc<type>(size_t(len), __FILE__, __LINE__) | 21:45 |
wiking | ok then i take it as a yes | 21:45 |
wiking | and we'll see how it goes... | 21:45 |
@sonney2k | void* sg_malloc(size_t size, const char* file, int line); | 21:45 |
@sonney2k | template <class T> | 21:45 |
@sonney2k | T* sg_generic_malloc(size_t len, const char* file, int line) | 21:45 |
@sonney2k | { | 21:45 |
@sonney2k | return (T*) sg_malloc(sizeof(T)*len, file, line); | 21:45 |
@sonney2k | } | 21:45 |
@sonney2k | etc | 21:45 |
blackburn | yeah | 21:45 |
@sonney2k | CALLOC, REALLOC, FREE | 21:46 |
@sonney2k | all the same way | 21:46 |
blackburn | yeah we can do that generic too if you want | 21:46 |
blackburn | :D | 21:46 |
@sonney2k | blackburn, we do | 21:46 |
blackburn | I mean CALLOC/REALLOC/FREE | 21:46 |
@sonney2k | btw we could simplify the SG_MALLOC * macro | 21:46 |
@sonney2k | ahh now | 21:47 |
@sonney2k | no | 21:47 |
blackburn | ?? | 21:47 |
@sonney2k | forget it | 21:47 |
blackburn | oops | 21:47 |
blackburn | :D | 21:47 |
blackburn | I love templates | 21:47 |
blackburn | but actually lets rather copypaste | 21:47 |
@sonney2k | I don't. They increase compile time and issues | 21:47 |
@sonney2k | copy paste where? | 21:47 |
blackburn | calloc/realloc/free | 21:47 |
blackburn | they are powerful | 21:48 |
blackburn | sonney2k: have you seen thing I wrote to wiking yesterday? | 21:48 |
blackburn | 58 ????diffusion_matrix.array().cwiseQuotient((p*p.transpose()).array().pow(timesteps)); | 21:48 |
blackburn | sonney2k: ^ diffusion_matrix is a matrix, p is a vector, timesteps is an integer | 21:48 |
blackburn | *NO* temporaries | 21:48 |
wiking | mmm | 21:49 |
@sonney2k | that certainly is cool | 21:49 |
blackburn | it is not only shorter but faster | 21:50 |
wiking | i start to be very annoyed by fucking c/c++ | 21:51 |
wiking | takes too much time to get something tested | 21:51 |
blackburn | write in processing! | 21:52 |
blackburn | :0 | 21:52 |
blackburn | :) | 21:52 |
wiking | hahaha | 21:52 |
wiking | that shit i hate | 21:52 |
@sonney2k | wiking, or python :) | 21:52 |
wiking | :> | 21:52 |
wiking | yeah python | 21:52 |
wiking | but some things i can have as lib function in c | 21:52 |
wiking | there's no python eqv | 21:52 |
wiking | and no bindings either | 21:52 |
blackburn | write in java | 21:52 |
wiking | java my ass | 21:53 |
wiking | :>>> | 21:53 |
blackburn | AbstractCollectionItemGeneratorParser | 21:53 |
wiking | :D | 21:53 |
wiking | indeed | 21:53 |
wiking | AbstractCollectionItemGeneratorParserFactory | 21:53 |
wiking | ;) | 21:53 |
wiking | never forget the factory | 21:53 |
wiking | :D | 21:53 |
blackburn | ConcurrentBlockingMulticollectionGenericQueue | 21:53 |
wiking | java certainly feels like factory toolkit | 21:53 |
wiking | you stand in the factory assembly line | 21:53 |
blackburn | AbstractSingletonDispatchingMultipleFactoryBlockingCollectionGenericToolkitDependencyInjectionScheme | 21:53 |
wiking | and code | 21:54 |
wiking | like a monkey | 21:54 |
@sonney2k | java has its benefits | 21:54 |
@sonney2k | if only it were fast | 21:55 |
blackburn | sonney2k: it is fast | 21:55 |
@sonney2k | sure | 21:55 |
@sonney2k | and no latencies | 21:55 |
@sonney2k | and no memory overhead | 21:55 |
blackburn | function calls in java are as fast as in C++ | 21:55 |
blackburn | virtual I mean | 21:55 |
blackburn | sonney2k: what is slow in java? :) | 21:56 |
wiking | sonney2k: it's fucking fast | 21:57 |
wiking | sonney2k: have u seen the comparison of languages/performance by google? | 21:58 |
wiking | it's nicely shows that java is fast | 21:58 |
wiking | but i hate the fucking GC | 21:58 |
wiking | :D | 21:58 |
wiking | i mean the one thing about java | 21:58 |
@sonney2k | wiking, you mean like 3x slower? | 21:58 |
wiking | nono | 21:58 |
blackburn | 3x?? | 21:58 |
wiking | check it out | 21:58 |
blackburn | come on | 21:58 |
blackburn | it is not 1999 outside | 21:58 |
@sonney2k | then it would be 1000 times slower | 21:59 |
blackburn | aha | 21:59 |
blackburn | and std::vector is non-contiguous | 21:59 |
blackburn | :D | 21:59 |
wiking | :>>>>>>> | 22:00 |
wiking | that's why you can always use | 22:00 |
blackburn | sonney2k: if you have latencies you really should check you use caching properly | 22:00 |
wiking | &std::vector<..>[0] | 22:00 |
wiking | as a continous memory array | 22:00 |
wiking | ;) | 22:00 |
@sonney2k | haha in that paper | 22:01 |
@sonney2k | java has a 3.7 times higher memory footprint | 22:01 |
blackburn | that's ok if you don't multiply matrices | 22:01 |
blackburn | I'd 90% of software doesn't | 22:01 |
@sonney2k | and it is 5.8 times slower | 22:01 |
wiking | gc | 22:02 |
wiking | of course | 22:02 |
wiking | and jvm | 22:02 |
blackburn | 5.8 slower on what? | 22:02 |
@sonney2k | https://days2011.scala-lang.org/sites/days2011/files/ws3-1-Hundt.pdf | 22:02 |
@sonney2k | c++ | 22:02 |
@sonney2k | wiking, and that even minimal arrays[] are like std::vector | 22:02 |
@sonney2k | anyways I didn't say it has its benefits | 22:03 |
blackburn | well no frameworks, no EE | 22:04 |
blackburn | for C++ | 22:04 |
@sonney2k | but for high speed stuff were even factor 2 counts it is unbearable | 22:04 |
@sonney2k | blackburn, yeah sure | 22:04 |
blackburn | sonney2k: scala is even slower but ask mikio why he uses it :) | 22:09 |
@sonney2k | well it is convenient | 22:10 |
@sonney2k | like java | 22:10 |
@sonney2k | lots of third party libs | 22:10 |
@sonney2k | nice ides | 22:10 |
blackburn | life is too short to write in C++ | 22:10 |
blackburn | :D | 22:10 |
@sonney2k | yeah that is why I use python :) | 22:10 |
blackburn | I spent two years doing inplace malloc | 22:11 |
blackburn | :D | 22:11 |
@sonney2k | blackburn, only because you didn't impl. proper templated sg_mallocs :( | 22:11 |
@sonney2k | we should be more lazy | 22:11 |
@sonney2k | but lazy at the right places | 22:12 |
blackburn | we have such atmosphere I didn't ever thing about it | 22:12 |
blackburn | think* | 22:12 |
@sonney2k | huh? | 22:12 |
blackburn | well we are old-school C and I had no chance to really understand templates | 22:12 |
@sonney2k | all the templated stuff in shogun is there for a reason | 22:12 |
@sonney2k | to avoid code duplication | 22:13 |
blackburn | after tapkee I do understand much more | 22:13 |
wiking | doh motherfuckers | 22:14 |
wiking | i can haz libqp | 22:14 |
wiking | ;) | 22:14 |
@sonney2k | blackburn, you talk about pluskid's templated labels or what? | 22:15 |
@sonney2k | we didn't really have anyone attempting to use templates for anything | 22:15 |
blackburn | sonney2k: yeah so I had no chance :) | 22:16 |
@sonney2k | pluskids label draft didn't work - we needed to expose labels to the outside | 22:17 |
blackburn | I am not talking about this concrete example | 22:17 |
@sonney2k | so %template and %rename would have been needed big times | 22:17 |
@sonney2k | and for everything else we can use it but only if we just use it *internally* | 22:18 |
blackburn | oops I was wrong about no alloc | 22:20 |
blackburn | :D | 22:21 |
@sonney2k | no temporaries you mean? | 22:23 |
blackburn | yeahh | 22:26 |
blackburn | but in other not-such-complex cases it works | 22:26 |
-shogungit:#shogun- [shogun] sonney2k pushed 2 new commits to master: https://github.com/shogun-toolbox/shogun/compare/c9a8772920c0...dad0687edf4c | 22:27 | |
-shogungit:#shogun- shogun/master 7d54bf9 Soeren Sonnenburg: next realease will be shogun 2.1.0 | 22:27 | |
-shogungit:#shogun- shogun/master dad0687 Soeren Sonnenburg: add templated sg_malloc functions | 22:27 | |
@sonney2k | blackburn, could you please have a look at my sg_malloc stuff? | 22:27 |
blackburn | righto | 22:27 |
blackburn | looks good | 22:28 |
blackburn | time to specialize! | 22:28 |
blackburn | :D | 22:28 |
@sonney2k | blackburn, do you remember for what parts of the code you called the placement news? | 22:28 |
@sonney2k | I mean this will cause crashes | 22:28 |
shogun-buildbot | build #647 of deb1 - libshogun is complete: Failure [failed compile] Build details are at http://www.shogun-toolbox.org/buildbot/builders/deb1%20-%20libshogun/builds/647 blamelist: Soeren Sonnenburg <sonne@debian.org> | 22:28 |
blackburn | sonney2k: all things that use sgvector arrays | 22:29 |
blackburn | I reverted sgstring things though | 22:29 |
@sonney2k | so we do one test for sgvector for now | 22:29 |
@sonney2k | blackburn, why that? | 22:29 |
@sonney2k | was sth still not working? | 22:29 |
blackburn | I spend 2-3 days trying to fix serialization | 22:29 |
@sonney2k | oh yes - that simply is not implemented | 22:30 |
blackburn | no success so get back to working | 22:30 |
@sonney2k | while this automagic refcounting stuff in sgvector is nice | 22:30 |
@sonney2k | it really causes pain in serialzation | 22:30 |
shogun-buildbot | build #648 of deb1 - libshogun is complete: Success [build successful] Build details are at http://www.shogun-toolbox.org/buildbot/builders/deb1%20-%20libshogun/builds/648 | 22:31 |
@sonney2k | code there assumed to be able to write to some ptr | 22:31 |
blackburn | yeah | 22:31 |
@sonney2k | but now that would really need a rewrite to work for any sg* datatype explicitly | 22:31 |
@sonney2k | anyways | 22:31 |
blackburn | maybe when I get drunk celebrating new year | 22:32 |
blackburn | I will attempt to fix everything | 22:32 |
blackburn | :D | 22:32 |
@sonney2k | or when heiko gets his new job | 22:32 |
blackburn | what's up with his job now? | 22:32 |
@sonney2k | (the better choice ;) | 22:32 |
blackburn | I see him pretty rare here | 22:33 |
@sonney2k | template<> SGVector<uint8_t>* sg_generic_malloc(size_t len) | 22:34 |
@sonney2k | { | 22:34 |
@sonney2k | return new SGVector<uint8_t>[len](); | 22:34 |
@sonney2k | } | 22:34 |
@sonney2k | like this right? | 22:34 |
blackburn | template<> SGVector<uint8_t>* sg_generic_malloc<SGVector<uint8_t>>(size_t len) | 22:35 |
blackburn | template<> SGVector<uint8_t>* sg_generic_malloc<SGVector<uint8_t> >(size_t len) | 22:35 |
@sonney2k | but with > > | 22:36 |
@sonney2k | (note the space) | 22:36 |
@sonney2k | k | 22:36 |
@sonney2k | blackburn, do we need that for SGMatrix too? | 22:37 |
blackburn | no idea | 22:37 |
blackburn | arrays of matrices.. humm | 22:37 |
@sonney2k | btw - I think we could even drop SGString and use SGVector there | 22:38 |
@sonney2k | but hey not a big thing | 22:38 |
blackburn | what do you mean? | 22:38 |
@sonney2k | string == vector | 22:38 |
blackburn | oh | 22:39 |
blackburn | well | 22:39 |
blackburn | it would require quite huge amount of time | 22:40 |
@sonney2k | blackburn, I am back to dependency hell | 22:49 |
@sonney2k | lib/memory.h now needs to include SGVector | 22:49 |
@sonney2k | .h | 22:49 |
blackburn | hehe | 22:49 |
@sonney2k | which itself uses memory | 22:50 |
blackburn | extern templates are not possible hah | 22:50 |
blackburn | only in C++11 | 22:50 |
-!- travis-ci [~travis-ci@ec2-23-20-88-236.compute-1.amazonaws.com] has joined #shogun | 22:54 | |
travis-ci | [travis-ci] it's Soeren Sonnenburg's turn to pay the next round of drinks for the massacre he caused in shogun-toolbox/shogun: http://travis-ci.org/shogun-toolbox/shogun/builds/3244580 | 22:54 |
-!- travis-ci [~travis-ci@ec2-23-20-88-236.compute-1.amazonaws.com] has left #shogun [] | 22:54 | |
@sonney2k | blackburn, can I do the template specialization only in the .cpp file? | 22:55 |
@sonney2k | but then I still need SGVector in header right? | 22:56 |
blackburn | I don't think you can | 22:56 |
@sonney2k | ahh no | 22:56 |
@sonney2k | should work | 22:56 |
@sonney2k | seems like it compiles | 23:01 |
blackburn | with in .cpp specialization? | 23:01 |
@sonney2k | yeah | 23:03 |
@sonney2k | Q of course is if it works | 23:03 |
-!- ptizoom [~christian@85.210.94.175] has quit [Quit: Ex-Chat] | 23:05 | |
-!- ptizoom [~christian@85.210.94.175] has joined #shogun | 23:05 | |
@sonney2k | blackburn, please check again | 23:07 |
-shogungit:#shogun- [shogun] sonney2k pushed 1 new commit to master: https://github.com/shogun-toolbox/shogun/commit/3d23faabc887b3bc2082b8f17144a70ef3a3346b | 23:07 | |
-shogungit:#shogun- shogun/master 3d23faa Soeren Sonnenburg: add specialization for SGVector and malloc/calloc/realloc/free | 23:07 | |
@sonney2k | in principle the inplace allocations could go now | 23:07 |
@sonney2k | aswell as the ~ stuff | 23:07 |
@sonney2k | that should *significantly* simplify our code | 23:07 |
blackburn | yeah | 23:08 |
@sonney2k | blackburn, so please test and be brave to remove the placement (de)constructors if it works | 23:09 |
blackburn | will test | 23:09 |
blackburn | not promise to remove it next days though :) | 23:09 |
@sonney2k | well test it at least | 23:10 |
@sonney2k | and tell us :) | 23:10 |
-!- ptizoom [~christian@85.210.94.175] has quit [Ping timeout: 252 seconds] | 23:25 | |
-!- ptizoom [~christian@79-71-89-182.dynamic.dsl.as9105.com] has joined #shogun | 23:39 | |
--- Log closed Sun Nov 18 00:00:17 2012 |
Generated by irclog2html.py 2.10.0 by Marius Gedminas - find it at mg.pov.lt!