IRC logs of #shogun for Monday, 2017-08-14

--- Log opened Mon Aug 14 00:00:38 2017
-!- mikeling [uid89706@gateway/web/irccloud.com/x-jpsadueqtgvxdwbi] has joined #shogun04:16
mikelingwiking: hi, do you have chance to read this https://github.com/shogun-toolbox/shogun/pull/3960#discussion_r132814850?06:13
@wikinglemme check it06:15
mikelingthank you06:15
@wikingabout the storage?06:15
@wikingwhat's the type of StorageIndex06:15
mikelingabout StorageIndex06:15
@wiking?06:15
@wikingor that's coming from eigen?06:17
mikelingwiking: the StorageIndex equal to _StorageIndex and I found the following comments06:19
mikeling _StorageIndex the type of the indices. It has to be a \b signed type (e.g., short, int, std::ptrdiff_t). Default is \c int.06:19
@wikingyeah06:20
@wikingthat's from eigen06:20
@wikingmmm in that case06:23
mikelingmmm, so we need to keep it as int32_t or? since it's about SparseMatrix06:23
@wikingwelll either that06:23
@wikingor when sparse matrix is being defined06:24
@wikingwe need to pass the type of StorageIndex06:24
@wikingi think here06:25
@wikingEigen::SparseMatrix<bool> matrix_power;06:25
@wikingSparseMatrixOperator.cpp:10306:25
@wikingas you can see https://eigen.tuxfamily.org/dox/classEigen_1_1SparseMatrix.html06:25
@wikingthese are the parameters06:25
@wikingtemplate<typename _Scalar, int _Options, typename _StorageIndex>06:25
@wikingso instead of simple06:26
@wikingEigen::SparseMatrix<bool> you would need to do Eigen::SparseMatrix<bool, 0, index_t>06:26
@wikingmikeling, can you try that for at least06:26
@wikingEigen::SparseMatrix<bool> matrix_power;06:27
@wikingso do Eigen::SparseMatrix<bool, 0, index_T> matrix_power;06:27
@wiking*index_t06:27
mikelingyeah, let me have a try :)06:27
mikelingwiking: I got this https://pastebin.mozilla.org/902965106:29
mikelingsorry06:30
mikelingmy bad06:30
@wiking?06:30
@wikingthat is rather weird06:30
@wikingwhat's your eigen version?06:31
@wikingEigen::SparseMatrix<bool, Eigen::ColMajor, index_t> should be the same06:31
mikelingit works now! Thank you. The error is because i type ,instead of ,06:31
@wikingoh ok utf806:32
@wiking:06:32
@wiking:P06:32
@sukey[https://github.com/shogun-toolbox/shogun] Issue https://github.com/shogun-toolbox/shogun/issues/3964 opened by vigsterkr08:21
-!- geektoni [~geektoni@93-34-128-38.ip49.fastwebnet.it] has joined #shogun10:06
@sukey[https://github.com/shogun-toolbox/shogun] Pull Request https://github.com/shogun-toolbox/shogun/pull/3953 synchronized by geektoni10:22
@wikinggeektoni, ready to merge right? https://github.com/shogun-toolbox/shogun/pull/395312:20
geektoniwiking: I still need to address a few comments of Heiko and then it's ready.12:23
@wikingk12:24
lisitsynwiking: booya13:06
@wikingboom boom13:06
lisitsynwhat's up?13:06
@wikingnot much13:07
@wikingstill watching btc :)13:07
lisitsynoh that's so13:07
lisitsynI am out of this shit13:07
@wiking4k usd :)13:07
lisitsyn:D13:07
@wikingheheh yeah13:07
lisitsynit must be so stressful to be in btc13:07
@wikinglisitsyn, :D13:07
@wikingit must be stressful to be a btc :D13:07
-!- geektoni [~geektoni@93-34-128-38.ip49.fastwebnet.it] has quit [Read error: Connection reset by peer]13:22
-!- geektoni [~geektoni@93-34-128-38.ip49.fastwebnet.it] has joined #shogun13:22
@sukey[https://github.com/shogun-toolbox/shogun] Pull Request https://github.com/shogun-toolbox/shogun/pull/3953 synchronized by geektoni14:41
@sukey[https://github.com/shogun-toolbox/shogun] Pull Request https://github.com/shogun-toolbox/shogun/pull/3953 synchronized by geektoni15:05
-!- olinguyen [81615ad9@gateway/web/freenode/ip.129.97.90.217] has joined #shogun16:41
@sukey[https://github.com/shogun-toolbox/shogun] Pull Request https://github.com/shogun-toolbox/shogun/pull/3953 synchronized by geektoni16:59
geektoniwiking: still there?17:19
@wikingpong17:26
@wikingyes17:26
geektoniwiking: I've added a comment on https://github.com/shogun-toolbox/shogun/pull/3953 to explain the today progress17:30
@wikingyep17:30
@wikingjust reading it17:30
geektoniso, yeah, once fixed those it is ready to go17:31
geektoniwiking: I'm more concerned about the SWING one. It should be rather easy to fix, but I don't see the problem :/17:33
@wikinggeektoni, https://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/interfaces/swig/Evaluation.i#L2018:07
@wikingnamespace shogun18:07
@wikingyou need to add the template within that18:07
@wikinggeektoni, see https://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/interfaces/swig/Distance.i#L5518:07
@wikingfor example18:07
@sukey[https://github.com/shogun-toolbox/shogun] Issue https://github.com/shogun-toolbox/shogun/issues/2699 closed by vigsterkr18:09
geektoniwiking: ohh thanks! Let's see if it works now18:10
@wikingmmm about the leak18:10
@wikingcan you run valgrind but with SHOGUN_NUM_THREADS=118:10
@wikingand get the output of that18:11
geektoniwiking: kk, give me a minute18:11
geektoniwiking: https://pastebin.com/v0XTZamp18:15
@wikingok cool18:19
@wikingso mkl + combined kernel18:19
@wikingi mean the only way to figure out18:20
@wikingis to actually see why that fucking MKL cloned18:20
@wikingis not being freed :D18:20
geektoniI'll try to give another look later then. It may be just a small detail I'm missing.18:23
geektoniwiking: btw, the interface thing still fails :P18:24
@wikingbut what does fail means exactly?18:28
@wiking?18:30
@wikinghttps://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/shogun/lib/parameter_observers/ParameterObserverCV.h#L6618:30
@wikingyou mean?18:30
@wikingbtw i'm not so sure if i understand the use of this interface18:30
@wikinghttps://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/shogun/lib/parameter_observers/ParameterObserverCV.h#L6818:30
@wikinggeektoni, btw i dont know how well does swig play with references as return values18:32
@wikingi mean they work just fine in function args, so one would presume that it should do the same with return vals18:32
geektoniwiking: so, by "fails" it means that I still see this error https://travis-ci.org/shogun-toolbox/shogun/jobs/264393708#L4311 after adding the namespace18:33
@wikinggeektoni, "Functions that return a reference are remapped to return a pointer instead. For example:18:33
@wiking"18:33
@wikingDon't return references to objects allocated as local variables on the stack. SWIG doesn't make a copy of the objects so this will probably cause your program to crash.18:34
@wikingso i think18:34
@wikingwhat you have there18:34
@wikingis actually an std::vector<...>*18:35
geektonimmh I see18:35
@wikingwhich is not iterable itself18:35
geektoniyes yes18:35
@wikingbtw %include <std_vector.i>18:36
@wikinginstead of relative ""18:36
-!- mikeling [uid89706@gateway/web/irccloud.com/x-jpsadueqtgvxdwbi] has quit [Quit: Connection closed for inactivity]18:36
@wikingbut18:36
@wikingcheck this18:36
@wikinghttps://stackoverflow.com/a/2724346118:36
@wiking<x.MyVector; proxy of <Swig Object of type 'std::vector< int > *' at 0x0000000002A7B030> >18:36
@wikingso that's actually an std::vector<...>*18:37
@wiking>>> for i in v: print(i)18:37
@wikingworks18:37
@wikingso18:37
@wikingmaybe you are missing something else18:37
geektonimmh18:37
geektoniwiking: ok, so I have this instead <Swig Object of type 'std::vector< shogun::CrossValidationStorage *,std::allocator< shogun::CrossValidationStorage * > > *' at 0x7f487d86cf48>18:45
@wikingmmm18:46
@wikingstill it's an std::vector18:46
@wikingonly that it has the allocator specified18:46
geektoniif I try to iterate over it I get this: TypeError: 'SwigPyObject' object is not iterable18:48
geektoniso I assume python still doesn't have any idea on how to treat it, despite it being a vector.18:48
@wikinggeektoni, you might need to actually include <vector> in the swig interface itself18:50
@wikingor not :S18:52
@wikingmmm18:52
@wikinghttps://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/shogun/lib/parameter_observers/ParameterObserverCV.h#L6818:52
geektoniah yeah18:52
geektoniso, basically it's a method I use to implement a "verbose" mode of the ParameterObserver18:53
geektoniwiking: https://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/shogun/lib/parameter_observers/ParameterObserverCV.cpp#L7018:53
@wikingnvm18:53
@wikingwrong copypaste18:53
@wikingi'm just wondering where thing go wrong here18:53
@wikinghttps://github.com/geektoni/shogun/blob/f0bd625b98f5a04ef67afcc934178497299a2c4b/src/interfaces/swig/Evaluation.i#L7318:56
@wikingin other cases the template renames18:56
@wikingare after18:56
@wikingthe %include18:56
@wikingcould you move the template specialization18:57
@wikingafter that include18:57
@wiking?18:57
geektoniI've just tried to place them at the end of the file but it still gives me problems18:57
geektoniwith problems ==  TypeError: 'SwigPyObject' object is not iterable18:58
geektoniwiking: no, okay, there was a cache problem! Now it recognize the object as an iterable.19:06
geektoniwiking: what if I have in python a Machine instance and I want to "cast" it to like a SVM one? Is that possible?19:20
-!- geektoni [~geektoni@93-34-128-38.ip49.fastwebnet.it] has quit [Remote host closed the connection]19:46
@sukey[https://github.com/shogun-toolbox/shogun] Pull Request https://github.com/shogun-toolbox/shogun/pull/3960 synchronized by MikeLing19:50
-!- sukey [~nodebot@ks312251.kimsufi.com] has quit [Remote host closed the connection]23:37
-!- sukey [~nodebot@ks312251.kimsufi.com] has joined #shogun23:38
-!- mode/#shogun [+o sukey] by ChanServ23:38
--- Log closed Tue Aug 15 00:00:39 2017

Generated by irclog2html.py 2.10.0 by Marius Gedminas - find it at mg.pov.lt!