--- Log opened Thu Apr 28 00:00:14 2016 |
00:18 | | Reiver_ [NSwebIRC@Nightstar-g7fs0k.xtra.co.nz] has joined #code |
00:27 | | Derakon[AFK] is now known as Derakon |
00:48 | | Azash [Azash@wizard.engineering] has quit [Operation timed out] |
00:48 | | Azash [Azash@wizard.engineering] has joined #code |
00:53 | | himi [fow035@Nightstar-dm0.2ni.203.150.IP] has joined #code |
00:53 | | mode/#code [+o himi] by ChanServ |
01:07 | | himi [fow035@Nightstar-dm0.2ni.203.150.IP] has quit [Ping timeout: 121 seconds] |
01:08 | | himi [fow035@Nightstar-dm0.2ni.203.150.IP] has joined #code |
01:08 | | mode/#code [+o himi] by ChanServ |
01:28 | | catadroid` [catalyst@Nightstar-kjhkif.dab.02.net] has joined #code |
01:31 | | catadroid [catalyst@Nightstar-pf9ba3.dab.02.net] has quit [Ping timeout: 121 seconds] |
03:15 | | ion [Owner@Nightstar-6grqph.vs.shawcable.net] has quit [Ping timeout: 121 seconds] |
03:17 | | ion [Owner@Nightstar-6grqph.vs.shawcable.net] has joined #code |
03:27 | | abudhabi [abudhabi@Nightstar-7nkq9k.de] has quit [Ping timeout: 121 seconds] |
03:27 | | abudhabi [abudhabi@Nightstar-7nkq9k.de] has joined #code |
03:32 | | Crossfire [Z@Nightstar-r9lk5l.cust.comxnet.dk] has quit [Ping timeout: 121 seconds] |
04:02 | | Harlow [harlow@Nightstar-6eslf9.ece.uic.edu] has joined #code |
04:04 | < Harlow> | does anyone know what kind of regex you'd do for say translating something like rrrrtttoo to rrttoo r'(.)\1{2}', r'\1' |
04:04 | < Harlow> | is what im using, but it doesn't really work |
04:10 | <~Vornicus> | --like, you want each multiletter to appear twice exactly |
04:10 | <~Vornicus> | so aaaaaaaaaaaaaaaaaabbbbbbeeeeeeeeeeeeghhhhhhhhhhhhhhhhh would be aabbeeghh? |
04:10 | < Azash> | Vornicus: Based on the r'' strings he wants to replace each triple occurrence with a single |
04:10 | <~Vornicus> | azash - that's not what the example shows though |
04:11 | < Azash> | But that wouldn't change - yeah |
04:11 | < Azash> | Harlow: In natural language, what do you want to do? |
04:11 | | Turaiel is now known as Turaiel[Offline] |
04:12 | < Harlow> | Replace two or more occurrences of the same character with two occurrences. i.e. âexcitedddddâ to âexciteddâ |
04:12 | < Azash> | Ah |
04:13 | < Harlow> | if it has multiplicity it returns at most multiplicity 2 |
04:13 | < Azash> | s/(.)\1{2,}/\1\1/ should probably do it |
04:13 | < Azash> | Note the 2, instead of 2 |
04:14 | < Azash> | The comma turns it from "exactly 2" to "from 2 to (no upper bound)" |
04:15 | < Harlow> | Ah |
04:19 | < Harlow> | so Azash I'm doing words = map ( lambda word : re.sub ( r's/(.)\1{2,}', r'\1\1', word ), words ) # this is python words is a list of words, the regex does not actually effect the output |
04:34 | | * Azash doesn't know python very well |
04:35 | < [R]> | What's the \1 do in the search part of the search/replace? |
04:36 | <~Vornicus> | it's a backreference. "the first captured group" |
04:36 | <~Vornicus> | or should. |
04:36 | <~Vornicus> | Harlow: what's that s/ for? |
04:37 | < Azash> | [R]: \1 is a specific reference to the (.), as eg. .{3,} is just.. any set of 3 or more characters |
04:38 | < Harlow> | I think you sent me a sed command instead of regex, i tried r'(.)\1{2,}', r'\1\1' and it worked uh but without that sed command i don't think i would have got it |
04:38 | < Harlow> | thanks Azash |
04:38 | < Harlow> | :D |
04:39 | < [R]> | perl uses that notation as well IIRC |
04:39 | < Azash> | No worries |
05:11 | | Derakon is now known as Derakon[AFK] |
06:09 | | Harlow [harlow@Nightstar-6eslf9.ece.uic.edu] has quit [Connection closed] |
06:10 | | mac [harlow@Nightstar-6eslf9.ece.uic.edu] has joined #code |
06:11 | | * simon_ opted in on a deal at his gym: 1 protein product/day for $15/month, but I have to show up every day and grab it. |
06:11 | < simon_> | but they also have energy drinks. |
06:12 | < simon_> | a co-worker lives next to a branch of this gym and basically just gets one energy drink every morning and either drinks it on that day or stashes it. |
06:12 | | mac [harlow@Nightstar-6eslf9.ece.uic.edu] has quit [[NS] Quit: BED] |
06:12 | < simon_> | I thought I'd do the same. but since I don't visit the gym more often than every other day, it's a bit annoying and I end up skipping the deal every other day. |
06:13 | < simon_> | then I realized, as long as I exercise close to midnight, I can grab two days worth of energy drinks, one before and one after midnight. :P |
06:13 | < simon_> | also, I have an abusive relationship to energy drinks. |
06:15 | < simon_> | this way I get them at a third of the price I normally would. |
06:16 | < simon_> | this co-worker who introduced me to the abuse used to grind caffeine pills and mix them with homemade club soda. |
06:16 | < simon_> | I don't think it gets cheaper than that. |
06:16 | < simon_> | (we work in finance, so I'm not really sure why we're so cheap about it.) |
06:24 | | ion_ [Owner@Nightstar-6grqph.vs.shawcable.net] has joined #code |
06:27 | | ion [Owner@Nightstar-6grqph.vs.shawcable.net] has quit [Ping timeout: 121 seconds] |
06:48 | | crystalclaw is now known as crystalclaw|AFK |
07:07 | | Alek [Alek@Nightstar-9qtiqv.il.comcast.net] has quit [Ping timeout: 121 seconds] |
07:10 | | Kindamoody[zZz] is now known as Kindamoody |
07:10 | | Alek [Alek@Nightstar-9qtiqv.il.comcast.net] has joined #code |
07:10 | | mode/#code [+o Alek] by ChanServ |
07:40 | | himi [fow035@Nightstar-dm0.2ni.203.150.IP] has quit [Ping timeout: 121 seconds] |
07:59 | | catadroid [catalyst@Nightstar-u3fv4k.dab.02.net] has joined #code |
08:01 | | catadroid` [catalyst@Nightstar-kjhkif.dab.02.net] has quit [Ping timeout: 121 seconds] |
08:27 | | catadroid [catalyst@Nightstar-u3fv4k.dab.02.net] has quit [[NS] Quit: Bye] |
08:32 | | VirusJTG_ [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has joined #code |
08:34 | | VirusJTG [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has quit [Ping timeout: 121 seconds] |
08:36 | | VirusJTG [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has joined #code |
08:37 | | VirusJTG_ [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has quit [Ping timeout: 121 seconds] |
09:17 | | Kindamoody is now known as Kindamoody|out |
09:38 | | himi [fow035@Nightstar-v37cpe.internode.on.net] has joined #code |
09:38 | | mode/#code [+o himi] by ChanServ |
10:01 | | Emmy [NSkiwiirc@Nightstar-esfu0j.dynamic.ziggo.nl] has joined #code |
10:11 | | Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Connection closed] |
11:20 | | Emmy [NSkiwiirc@Nightstar-esfu0j.dynamic.ziggo.nl] has quit [[NS] Quit: http://www.kiwiirc.com/ - A hand crafted IRC client] |
11:42 | | Crossfire [Z@Nightstar-r9lk5l.cust.comxnet.dk] has joined #code |
11:42 | | mode/#code [+o Crossfire] by ChanServ |
15:18 | | Natanial [NSwebIRC@Nightstar-f3k.t3q.245.162.IP] has joined #code |
15:19 | < Natanial> | Hey |
15:24 | | Crossfire [Z@Nightstar-r9lk5l.cust.comxnet.dk] has quit [Ping timeout: 121 seconds] |
16:05 | | Natanial [NSwebIRC@Nightstar-f3k.t3q.245.162.IP] has quit [[NS] Quit: Page closed] |
16:39 | | emmy [M@Nightstar-9p7hb1.direct-adsl.nl] has joined #code |
16:55 | | catadroid [catalyst@Nightstar-1a6vfr.dab.02.net] has joined #code |
17:46 | | catalyst [catalyst@Nightstar-bt5k4h.81.in-addr.arpa] has joined #code |
18:43 | | crystalclaw|AFK is now known as crystalclaw |
19:11 | | Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code |
19:11 | | mode/#code [+qo Vornicus Vornicus] by ChanServ |
20:59 | | catadroid` [catalyst@Nightstar-nobhb9.dab.02.net] has joined #code |
21:01 | | catadroid [catalyst@Nightstar-1a6vfr.dab.02.net] has quit [Ping timeout: 121 seconds] |
21:54 | | Crossfire [Z@Nightstar-r9lk5l.cust.comxnet.dk] has joined #code |
21:54 | | mode/#code [+o Crossfire] by ChanServ |
22:21 | | Kindamoody|out is now known as Kindamoody |
22:41 | | Derakon [chriswei@Nightstar-5mvs4e.ca.comcast.net] has joined #code |
22:41 | | mode/#code [+ao Derakon Derakon] by ChanServ |
22:41 | <&Derakon> | Quick C++ check. What does this do? |
22:41 | <&Derakon> | class Universal : public CCameraBase<Universal> |
22:41 | <&Derakon> | It looks to me like it's saying "create a class named Universal, which descends from the templated CCameraBase class, with a template type of Universal". |
22:42 | <&McMartin> | Correct. |
22:42 | <&McMartin> | And yes, it's using itself as a template argument, and yes, that is legal. |
22:42 | <&Derakon> | Okay, thanks. |
22:43 | <&McMartin> | Template arguments in their first phase end up working like a slightly more lexical-analysis-aware preprocessor, and then the results are type-checked and built as usual. |
22:43 | | * McMartin is gesturing wildly in parts of this explanation; this is the kind of thing he consults catadroid about if the details matter >.> |
22:44 | <&Derakon> | Okay, so it turns out that CCameraBase is defined via |
22:44 | <&Derakon> | template <class U> class CCameraBase : public CDeviceBase<MM::Camera, U> |
22:44 | <&McMartin> | So it's forwarding that typename as the second template argument to CDeviceBase. |
22:44 | <&Derakon> | Hmm...I guess that's okay. |
22:45 | <&McMartin> | Are you getting error messages with lengths measured in actual kilobytes and trying to work out why here by any chance~ |
22:45 | <&Derakon> | Ultimately we're getting an error in the definition of the "Universal" class, where it defines a function |
22:45 | <&Derakon> | error: cannot initialize object parameter of type 'CDeviceBase<MM::Camera, Universal>' with an expression of type 'Universal' |
22:45 | <&McMartin> | Oh, hmmmm. |
22:46 | <&Derakon> | And no, the errors are not gigantic, so it's probably not a template problem, yes. :) |
22:46 | <&McMartin> | Does CDeviceBase have a U field in it by any chance. |
22:46 | <&McMartin> | Alternately: What is the line that is actually failing |
22:46 | <&Derakon> | template <class T, class U> class CDeviceBase : public T |
22:46 | <&Derakon> | And the failing line: |
22:46 | <&Derakon> | MM::MMTime GetCurrentTime() { return GetCurrentMMTime();} |
22:47 | <&McMartin> | That's interesting because it doesn't appear to refer to type U in there at any point. |
22:47 | <&Derakon> | No, it doesn't. |
22:48 | <&Derakon> | GetCurrentMMTime is defined in DeviceBase, incidentally, and returns an MMTime. |
22:48 | <&Derakon> | I suppose it might be significant that that function is the last declared function in the header? Everything else is member variables. |
22:48 | <&McMartin> | Are you compiling this with g++, clang, or MSVC |
22:48 | <&Derakon> | Wait, no, I lied. |
22:49 | <&Derakon> | This is, uh, clang, looks like. Our automated build tool. |
22:49 | <&Derakon> | Specifically, this is an email warning me that the OSX build is broken. |
22:49 | <&Derakon> | Windows build appears to be fine. |
22:49 | <&Derakon> | (Or at least I've gotten no email about it) |
22:50 | <&McMartin> | clang is stricter on some stuff but it also often has very lengthy explanatory messages |
22:50 | <&Derakon> | I'm tempted to just email the guy and say "hey you broke the build, fix it", but I'd like to understand how it's broken. |
22:50 | <&Derakon> | (Besides that he failed to #define ulong64 on Mac platforms, but that one was easy to figure out) |
22:50 | <&McMartin> | ... step 1 is to attempt a clean rebuild |
22:51 | <&Derakon> | Heh, fair enough. |
22:51 | <&McMartin> | Bug report: You should be #include-ing <cstdint> and using uint64_t |
22:51 | <&Derakon> | Well, wait, the automated build system should start from clean every time. |
22:51 | <&Derakon> | It certainly has the output of ./configure in the logs there. |
22:51 | <&McMartin> | Hm. |
22:51 | <&McMartin> | OK |
22:52 | <&McMartin> | This error is usually longer than what you quoted |
22:53 | <&Derakon> | Here: http://pastebin.com/d8XApqFc |
22:54 | <&Derakon> | If Universal descends from CDeviceBase then it ought to be a valid MMDevice... |
22:54 | <&McMartin> | Hum |
22:54 | <&Derakon> | ...I think. |
22:55 | <&McMartin> | OK we are in deep magic area here |
22:55 | <&McMartin> | My first theory here is that MM::Device has no direct relationship to CDeviceBase. |
22:56 | <&McMartin> | The other possibility is that there's some implicit coercion/constructor-calls going on that clang does not accept, but I thought those rules were fixed. |
22:56 | | * Derakon tries to build locally, gets an error that master.h was not found. |
22:57 | <&Derakon> | Oh, that's because I don't have the PVCAM libraries installed properly. |
22:57 | <&Derakon> | You know what, don't worry about it. |
22:57 | <&Derakon> | I'll just tell him "hey, it doesn't work, fix it". |
22:57 | <&Derakon> | Thanks for your assistance. |
22:58 | <&McMartin> | I would also double-check windows-build results and look for warnings. |
22:58 | <&McMartin> | The failures in PVCAMAdapter are very surprising to me |
22:58 | <&McMartin> | If they are brand-new and Mac-only. |
22:59 | <&Derakon> | Alas, I no longer have access to the build server, so I'm basically read-only here. And there's no notifications for successful builds. |
23:00 | <&Derakon> | ("no longer" because we're still using the UCSF build server and I don't work there any more) |
23:02 | <&McMartin> | The ultimate resolution will be relevant to my interests, so I hope you can share that once it's sorted |
23:02 | | crystalclaw is now known as crystalclaw|AFK |
23:03 | <&Derakon> | Sure, this is all public code. |
23:04 | <&Derakon> | Meanwhile, I just wrote up a little test of some functions to compare speeds. |
23:05 | <&Derakon> | First three tests show an order-of-magnitude difference between the two functions. |
23:05 | <&Derakon> | Fourth test shows them both taking 0s, presumably because the JIT compiler optimized them. |
23:05 | <&Derakon> | Hooray for Java~ |
23:06 | <&McMartin> | For all the shit Java takes, Java's JIT was the first widely available Really Good JIT. |
23:06 | <&McMartin> | I won't gainsay Sun's engineers. |
23:06 | <&McMartin> | Their businesspeople, well... |
23:19 | <&Derakon> | Okay, $coworker suggests that the ulong64 error invalidated the type of Universal, such that it was not a valid MMDevice, thereby causing cascading errors when later parts of the code tried to treat it as such. |
23:19 | <&Derakon> | Sounds plausible to me, anyway. |
23:20 | <&McMartin> | If fixing the ulong64 error makes all the errors go away, that'd check out, to be sure |
23:27 | | * Derakon vanishes aetherwards. |
23:27 | | Derakon [chriswei@Nightstar-5mvs4e.ca.comcast.net] has quit [[NS] Quit: leaving] |
23:37 | | crystalclaw|AFK is now known as crystalclaw |
--- Log closed Fri Apr 29 00:00:29 2016 |