00:11:57 | * | thomasross__ joined #nim |
00:14:43 | * | leorize joined #nim |
00:15:09 | * | thomasross_ quit (Ping timeout: 256 seconds) |
00:19:52 | * | BitPuffin quit (Remote host closed the connection) |
00:44:17 | * | gokr quit (Ping timeout: 248 seconds) |
00:47:08 | * | CodeVance joined #nim |
00:56:15 | * | endragor joined #nim |
01:00:36 | * | endragor quit (Ping timeout: 256 seconds) |
01:02:14 | * | skrylar joined #nim |
01:38:05 | * | leorize quit (Ping timeout: 240 seconds) |
01:38:42 | * | leorize joined #nim |
01:59:08 | FromDiscord | <2vg> small container size? |
02:04:21 | * | ftsf joined #nim |
02:32:52 | * | vivus quit (Quit: Leaving) |
02:35:58 | * | xkapastel quit (Quit: Connection closed for inactivity) |
02:55:50 | * | endragor joined #nim |
03:20:32 | skrylar | mratsim: boop |
03:32:10 | * | FuntDobra_ joined #nim |
03:37:36 | * | cspar quit (Read error: Connection reset by peer) |
03:38:00 | * | cspar joined #nim |
03:41:13 | * | CodeVance quit (Read error: Connection reset by peer) |
03:41:40 | * | CodeVance_ joined #nim |
03:59:10 | * | sz0 quit (Quit: Connection closed for inactivity) |
04:03:05 | * | yglukhov quit (Ping timeout: 240 seconds) |
04:42:53 | * | dddddd quit (Remote host closed the connection) |
04:44:57 | * | FuntDobra_ quit (Ping timeout: 240 seconds) |
04:59:13 | * | xkapastel joined #nim |
05:02:15 | skrylar | pushed the old neural net code from last year to github, also updates to skflatbuffer |
05:02:31 | skrylar | the gtk3 stuff isn't really interesting enough to post yet |
05:05:14 | * | leorize quit (Ping timeout: 260 seconds) |
05:25:07 | * | nsf joined #nim |
05:38:47 | * | gmpreussner quit (Ping timeout: 268 seconds) |
05:39:39 | * | gmpreussner joined #nim |
05:40:39 | * | CodeVance_ quit (Read error: Connection reset by peer) |
06:02:35 | * | CodeVance joined #nim |
06:13:53 | * | leorize joined #nim |
06:37:25 | * | gokr joined #nim |
06:45:54 | * | thor77 quit (Quit: ZNC 1.7.0 - https://znc.in) |
06:47:26 | * | thor77 joined #nim |
06:53:17 | * | yglukhov joined #nim |
06:55:26 | * | Ven`` joined #nim |
06:56:29 | FromGitter | <gogolxdong> How to assign biggest uint64 to a variable? |
07:01:00 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
07:11:24 | * | FuntDobra_ joined #nim |
07:14:48 | FromGitter | <survivorm> `let i = high(int64).uint64*2+1` |
07:15:05 | FromGitter | <survivorm> looks like it's the shortest way |
07:15:29 | FromGitter | <survivorm> Not sure it's the clearest |
07:17:54 | * | Ven`` joined #nim |
07:19:53 | FromGitter | <survivorm> `let i = high(int64).uint64 + low(int64).uint64` |
07:20:07 | FromGitter | <survivorm> I think it's a little better |
07:20:36 | FromGitter | <survivorm> In essence, count all + vals and all - vals, as the number is the same |
07:23:08 | FromGitter | <survivorm> one little thing is expected, but still a little off. `abs(low(int64))` results in `Error: unhandled exception: over- or underflow [OverflowError]` |
07:33:14 | FromGitter | <mratsim> @skrylar, yes? |
07:33:44 | skrylar | mratsim i wasn't around to see your answer about arraymancer and TTS stuff |
07:33:45 | FromGitter | <mratsim> @gogolxdong let hi_uint64 = not 0’u64 |
07:34:27 | * | Vladar joined #nim |
07:34:42 | skrylar | toying around with the idea of either a macro that converts math in to tensor code or porting my HMMs to nim (which i could probably use arraymancer for, because matrix multiplication) |
07:35:34 | FromGitter | <mratsim> would love to be able to write equations like that: http://fluxml.ai/ but we need unicode support |
07:36:10 | FromGitter | <survivorm> please... please... no unicode |
07:36:18 | FromGitter | <survivorm> in code, at least |
07:36:41 | FromGitter | <mratsim> unicode in exported code is a pain yes |
07:37:22 | FromGitter | <survivorm> not all editors work well with it, so i don't want issues with 'i've corrected a single line and now code's somehow broken everythere' |
07:38:07 | FromGitter | <survivorm> If you want unicode in comments - You're welcome, but not in the code, please |
07:38:38 | FromGitter | <survivorm> There are enough rakes in the world to step on beside this one |
07:39:13 | FromGitter | <survivorm> And can you explain the magic with ` not 0’u64`? |
07:39:32 | FromGitter | <survivorm> what does this op mean |
07:39:51 | FromGitter | <mratsim> high(uint8) is 11111111, low(uint8) is 00000000 |
07:39:58 | FromGitter | <mratsim> not flips the bits |
07:39:59 | FromGitter | <survivorm> ah |
07:40:05 | FromGitter | <survivorm> i see |
07:40:11 | FromGitter | <survivorm> clever one, yes |
07:41:14 | FromGitter | <mratsim> ^^ |
07:44:17 | FromGitter | <mratsim> similarly high(int) can be done like this for arbitrary precision: https://github.com/status-im/nim-stint/blob/master/stint/private/int_highlow.nim#L12-L25 |
07:44:38 | skrylar | it just looks like this (concept): # Tanh-Elman layers |
07:44:38 | skrylar | tanh(reduce(inputs * weights) + (hidden * weights.hidden) + bias) |
07:44:41 | FromGitter | <mratsim> 1) not shr 1 |
07:46:43 | FromGitter | <mratsim> @skrylar, I added GRU Cell primitive yesterday, still have to implement a Fused GRU layer: https://github.com/mratsim/Arraymancer/pull/231 |
07:46:53 | skrylar | i saw something about that |
07:47:03 | skrylar | i'm not sure if merging those in to one codebase is the best of ideas, but everyone is doing it |
07:47:18 | * | skrylar has written GRUs by hand .. more times than desired |
07:47:32 | FromGitter | <mratsim> what do you mean? |
07:47:43 | skrylar | well shouldn't tensors and layers be separate modules |
07:48:09 | skrylar | i know torch et all merge them in to one pile, but maybe i just want the tensors to do Markovian models efficiently |
07:48:14 | FromGitter | <mratsim> they are, the library is monolithic but internally, it’s cleanly separated |
07:48:37 | skrylar | as an aside, i've been lamenting how little crossover there is. someone is either all markov, all evolution, or all neural net :-| |
07:49:03 | FromGitter | <mratsim> I even got Intel deep learning guys in my issues (I don’t know how :?): https://github.com/mratsim/Arraymancer/issues/228#issuecomment-388833934 |
07:49:15 | skrylar | but yes the math macro .. dunno. wrote some concept code for it. trying to write the concept code for GRUs, but the macro itself == total pain, have to tackle register allocation |
07:49:53 | * | floppydh joined #nim |
07:49:57 | FromGitter | <mratsim> I’m not all neural nets ;), I’ve added some stats tool as well (covariance matrices, eigenvecs, PCA …) |
07:50:16 | FromGitter | <mratsim> I want to add sparse tensors as well |
07:50:27 | skrylar | i just want a voice synthesizer that isn't trash :( |
07:50:58 | skrylar | i don't know how torch does it. i think keras one time i peeked creates new tensors all the time |
07:51:04 | FromGitter | <mratsim> seems like @cabhishek friend that was developing Vectorflow completely stopped: https://github.com/Netflix/vectorflow so it might be an opportunity to replace D usage at Netflix with Nim :D |
07:51:12 | skrylar | Aphelion created a pool of "scratch" tensors and reused the memory |
07:51:37 | FromGitter | <survivorm> Hearing all this talks i think myself stupid. |
07:51:40 | FromGitter | <mratsim> Fused kernels reuse the same tensors |
07:51:51 | skrylar | i guess thats what i did then |
07:51:56 | skrylar | i reused the same tensors for all layers |
07:52:09 | skrylar | except ones set aside for private use (ex. hidden layers, weights) |
07:52:33 | FromGitter | <mratsim> @survivorm different fields, talk about networking and async, or B-Trees and I’m lost as well :D |
07:52:44 | skrylar | If you don't care about that, then the macro is easy. just replace a DSL with tensor calls and maybe do some common subexpression caching |
07:53:06 | skrylar | hey i understand all of those things :f never done a b-tree by hand though |
07:53:48 | FromGitter | <mratsim> Basically my plan is this: https://github.com/mratsim/Arraymancer/issues/175#issuecomment-388215144 ⏎ ⏎ very low-level API Fortran like that never allocates and you have to pass “workspace array” as var parameter |
07:53:50 | FromGitter | <survivorm> @mratsim I guess. We're not living Aristoteles, we can't be proficient in everything |
07:54:17 | FromGitter | <mratsim> medium level API like torch and PyTorch |
07:54:27 | skrylar | that low level model works; it's what i did |
07:54:31 | skrylar | but the code is ugly |
07:54:34 | FromGitter | <mratsim> and high level neural net domain specific language so that NN can be done in like 5~10 lines |
07:55:00 | skrylar | vectorflow may have also been killed by tensorflow |
07:55:18 | FromGitter | <mratsim> No, Vectorflow addresses a unique need, Sparse neural networks |
07:55:29 | skrylar | didn't cafe or keras (one of the research ones) basically seppuku'd because one is just too big of a marketing target, can get randos off the street to hack bad tensorflow models together |
07:55:33 | skrylar | ah |
07:55:39 | FromGitter | <mratsim> Netfliw apparently must processes millions of columns per client |
07:55:43 | FromGitter | <mratsim> Netflix* |
07:55:49 | skrylar | well, i just need a few good small ones :) |
07:56:05 | FromGitter | <mratsim> so they have 1M x 50M tensors =) |
07:56:32 | skrylar | yea. hidden markovs have some sparsity issues at times |
07:56:59 | skrylar | i still feel that if you have millions of parameters you are doing it wrong; technique > power, every time |
07:57:30 | skrylar | there is that paper where someone is passing captchas ~99% because they changed from convnets to some message passing micro thing |
07:57:54 | skrylar | i could get the paper next time i'm browsing archives if its still there |
07:58:21 | FromGitter | <mratsim> I didn’t check if they used unsupervised diensionality reduction, as far as I know they used logistic regression and softmax multiclass classification mostly. |
07:59:10 | skrylar | hm |
07:59:20 | skrylar | dunno. i've been out of the AI game for eight months |
07:59:38 | skrylar | I am curious why nobody is using the gradient descent by gradient descent |
07:59:41 | FromGitter | <mratsim> the library is just 5k lines of code or so I think |
07:59:46 | skrylar | the google paper claims an order of magnitude reduction in training time |
08:00:10 | FromGitter | <mratsim> PyTorch implemented Hessians just 6 months ago I think? |
08:00:27 | FromGitter | <mratsim> but they had L-BFGS since the beginning |
08:01:03 | * | noonien joined #nim |
08:01:08 | skrylar | anyway guessing can rely on sorting the commutative ops by hash or some deterministic value, caching those in a list and then somehow backwardsing single assignment from that |
08:01:30 | skrylar | so you give it the GRU formula in text, and it somehow converts that in to a neat set of scratch calls |
08:01:51 | FromGitter | <mratsim> sounds like fun :P |
08:02:02 | FromGitter | <mratsim> you could train a NN to do that ;) |
08:02:36 | FromGitter | <mratsim> with a numerical_gradient as the loss function to optimize :P |
08:02:56 | skrylar | i would have to already have the NN code to do that |
08:03:02 | skrylar | and it would probably make the compile time depressing |
08:03:36 | skrylar | i also wonder what happens if you run an FFI before wavenet |
08:03:55 | skrylar | suspect it's so slow because its trying to invent the fourier transform using neurons :hrm: |
08:04:07 | FromGitter | <mratsim> I still have to look into WaveNets, never tried one. So little time ... |
08:04:18 | skrylar | well, deep voice and tacotron are quite good |
08:04:27 | * | gmpreussner quit (Ping timeout: 240 seconds) |
08:04:36 | skrylar | you produce mel-cepstral data and let wavenet "fill in the gaps" between the cepstral frequencies and original sound |
08:05:07 | skrylar | the fault here is that they're all end-to-end, so you can't do smart things like train the wavenet on 50 voices. it turns out, baidu did (kind of) and it works perfectly |
08:05:23 | FromGitter | <mratsim> I tried to use multi-attention GRU for a 24h iron-man competition to predict traffic in a city: https://github.com/mratsim/McKinsey-SmartCities-Traffic-Prediction#results the results were bad >___> |
08:05:28 | * | gmpreussner joined #nim |
08:05:35 | skrylar | i think taco/deepvoice cut out about half of wavenet, and baidu published a guide on running a full wavenet in real time |
08:05:49 | skrylar | allegedly deep voice 3 can clone a voice from 30 minute samples |
08:06:03 | skrylar | well, it can borrow from test corpuses and adapt what it knows to be that voice anyway |
08:06:18 | skrylar | i want this on my desktop =p |
08:06:25 | FromGitter | <mratsim> lol |
08:06:31 | FromGitter | <mratsim> robot voice is enough |
08:08:51 | skrylar | not that you need it, but skflatbuffers (soon to be renamed) now exports in protobuf and supports arrays/seqs with very little boilerplate |
08:08:57 | skrylar | re-import is still. eh |
08:09:19 | skrylar | flatbuffers are going to be a pain to import |
08:10:18 | * | jaco60 joined #nim |
08:12:37 | skrylar | well thats all i had to say really. have to try and figure out arraymancer at some point |
08:15:23 | FromGitter | <gogolxdong> what the wrapper of a span over string? |
08:16:36 | * | ftsf quit (Read error: Connection reset by peer) |
08:16:43 | FromGitter | <gogolxdong> never mind ,it's """ |
08:17:21 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
08:20:13 | * | Ven`` joined #nim |
08:24:16 | FromGitter | <gogolxdong> How to get the type of variable? |
08:26:48 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
08:27:35 | * | FuntDobra_ quit (Ping timeout: 240 seconds) |
08:27:41 | Yardanico | type(variable) |
08:29:31 | * | FuntDobra_ joined #nim |
08:31:13 | * | Ven`` joined #nim |
08:31:14 | FromGitter | <gogolxdong> and how to get the string literals? |
08:31:39 | Yardanico | you mean type of a variable as string? |
08:31:49 | Yardanico | !eval import typetraits; let a = 1; echo type(a) |
08:31:51 | NimBot | int |
08:32:13 | Yardanico | you need to "import typetraits" since this module provides $ procedure for a typedesc |
08:33:26 | FromGitter | <gogolxdong> alright |
08:35:27 | * | Ven`` quit (Ping timeout: 240 seconds) |
08:55:48 | FromGitter | <mratsim> The completely unscientific bench is getting out of hands: frol/completely-unscientific-benchmarks@9e13da0 |
08:59:02 | Yardanico | wait , Nim "manual" (static) is faster than any other one |
08:59:10 | Yardanico | on "Tunned Implementations Scoreboard" |
08:59:30 | FromGitter | <mratsim> yes Nim is the current speed king |
08:59:56 | Yardanico | and it will be much faster in ""Naive" Implementations Scoreboard" after new nim stable ;) |
09:14:47 | * | xet7 joined #nim |
09:20:32 | * | sendell joined #nim |
09:21:03 | * | FuntDobra_ quit (Ping timeout: 255 seconds) |
09:29:50 | FromGitter | <mratsim> I still want to fix the need to {.noInit.} ref object. |
09:29:52 | * | FuntDobra_ joined #nim |
09:30:07 | * | ofelas joined #nim |
09:33:45 | * | FuntDobra joined #nim |
09:34:58 | * | FuntDobra_ quit (Ping timeout: 268 seconds) |
09:36:51 | * | FuntDobra_ joined #nim |
09:39:13 | * | FuntDobra quit (Ping timeout: 248 seconds) |
09:51:14 | * | thor77 quit (Quit: ZNC 1.7.0 - https://znc.in) |
09:52:12 | * | thor77 joined #nim |
10:11:26 | * | leorize quit (Ping timeout: 265 seconds) |
10:21:44 | * | FuntDobra_ quit (Ping timeout: 256 seconds) |
10:29:29 | * | FuntDobra_ joined #nim |
10:34:52 | * | cspar_ joined #nim |
10:37:27 | * | cspar quit (Ping timeout: 240 seconds) |
10:39:29 | * | xet7 quit (Ping timeout: 248 seconds) |
10:51:31 | * | xet7 joined #nim |
11:03:36 | * | Ven`` joined #nim |
11:04:08 | * | Snircle joined #nim |
11:24:53 | * | ofelas quit (Remote host closed the connection) |
11:29:55 | * | ofelas joined #nim |
11:30:08 | * | dddddd joined #nim |
11:34:09 | FromGitter | <tim-st> @mratsim When I create a fixed size array (not seq) as var type (so I can change entries at index) at the top of the proc is this done at compile time and if I call it like 100_000 times will this be slower than using a link to a buffer? |
11:34:50 | FromGitter | <tim-st> yesterday I thought I need a seq with cap now I know there is always an upper limit |
11:34:53 | FromGitter | <mratsim> faster |
11:35:09 | FromGitter | <tim-st> but will this still be created at each call? |
11:35:15 | FromGitter | <mratsim> a heap allocated buffer would have to wait for the OS to give it memory. |
11:35:42 | * | thomasross__ quit (Quit: Leaving) |
11:35:45 | FromGitter | <mratsim> the space is reserved at compile-time in the binary produced |
11:36:14 | FromGitter | <mratsim> be default it will have to be zero-ed out with memset |
11:36:39 | FromGitter | <mratsim> but you can use var buffer{.noInit.} = array[10, int] if initiailization is not needed |
11:36:58 | * | FuntDobra__ joined #nim |
11:37:03 | FromGitter | <tim-st> thanks, what will be in there instead? :D |
11:37:05 | FromGitter | <mratsim> be aware that you can only have about 2K~4k stack size depending on your OS |
11:37:20 | FromGitter | <tim-st> I need 10byte only |
11:37:25 | FromGitter | <mratsim> instead, random junk, probably past discard variables/results |
11:37:50 | FromGitter | <mratsim> discarded* |
11:38:01 | FromGitter | <mratsim> what the program used this memory for before |
11:38:29 | FromGitter | <tim-st> ah ok, makes sense, thank you! |
11:39:03 | FromGitter | <tim-st> then I will possibly make the quickest implmentation of all languages :D |
11:39:23 | FromGitter | <mratsim> 10 byte is super small by the way, an uint64 is already 8 bytes |
11:39:57 | * | FuntDobra_ quit (Ping timeout: 264 seconds) |
11:40:12 | FromGitter | <tim-st> yes |
11:42:40 | FromGitter | <tim-st> *36bytes needed |
11:43:17 | FromGitter | <tim-st> but still should be good :) |
11:46:28 | FromGitter | <tim-st> btw does the type Seq uses `noInit` too? at least it could |
11:47:17 | FromGitter | <tim-st> ok, there is `newSeqUninitialized` |
11:50:38 | * | sendell quit (Ping timeout: 268 seconds) |
11:50:55 | * | jjido joined #nim |
11:59:37 | * | FuntDobra__ quit (Remote host closed the connection) |
12:00:24 | * | FuntDobra joined #nim |
12:02:13 | * | leorize joined #nim |
12:12:37 | * | sendell joined #nim |
12:27:07 | * | DarkArctic_ joined #nim |
12:28:46 | * | DarkArctic_ quit (Client Quit) |
12:29:07 | * | DarkArctic joined #nim |
13:02:50 | * | athenot joined #nim |
13:26:50 | * | nsf quit (Quit: WeeChat 2.1) |
13:27:57 | * | FuntDobra quit (Ping timeout: 260 seconds) |
13:28:39 | * | FuntDobra joined #nim |
13:31:30 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
13:40:34 | * | Ven`` joined #nim |
13:41:09 | * | Ven`` quit (Client Quit) |
13:47:14 | * | BitPuffin joined #nim |
13:52:51 | dom96 | https://travis-ci.org/dom96/geckodriver-travis/builds/380221171 |
13:52:52 | dom96 | :D |
13:52:59 | dom96 | Headless firefox tests on travis with web driver :) |
14:02:22 | * | leorize quit (Ping timeout: 260 seconds) |
14:04:25 | * | Ven`` joined #nim |
14:04:49 | * | FuntDobra quit (Ping timeout: 248 seconds) |
14:07:41 | * | endragor quit (Remote host closed the connection) |
14:13:45 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
14:14:35 | * | leorize joined #nim |
14:15:34 | * | Ven`` joined #nim |
14:19:33 | FromGitter | <ephja> does anyone else only see links to "https://github.com/zah/grip-lang/..." and so on, and not the official repo when googling nim topics? :p |
14:20:54 | FromGitter | <Vindaar> the official repo is the 3rd result googling "nim lang" for me (after the website and wikipedia) |
14:25:54 | * | endragor joined #nim |
14:26:23 | * | leorize quit (Ping timeout: 255 seconds) |
14:27:19 | FromGitter | <ephja> it might mostly be when including terms that appear in code |
14:28:05 | FromGitter | <Vindaar> if you provide an example..? :) from my experience in general I find what I search for |
14:28:38 | * | leorize joined #nim |
14:29:20 | FromGitter | <ephja> try `nim mAstToStr` |
14:29:31 | FromGitter | <ephja> I should just use github's search feature |
14:29:52 | FromGitter | <Vindaar> in that case I get the same as you, yes |
14:30:13 | FromGitter | <Vindaar> the only times I used github's search I was thoroughly disappointed |
14:30:25 | * | endragor quit (Ping timeout: 248 seconds) |
14:31:09 | FromGitter | <ephja> @zah I guess you need to remove the aforementioned repo :p |
14:31:23 | FromGitter | <ephja> that university with its old version too. lol |
14:31:24 | FromGitter | <Vindaar> in general though a combination of https://nim-lang.org/docs/theindex.html, the manual and grepping through the source code in the command line is all it takes |
14:36:20 | FromGitter | <ephja> yeah that's good enough |
14:39:20 | * | BitPuffin quit (Remote host closed the connection) |
14:39:55 | * | BitPuffin joined #nim |
14:52:46 | * | miran joined #nim |
15:08:30 | * | xkapastel quit (Quit: Connection closed for inactivity) |
15:16:25 | * | Trustable joined #nim |
15:16:53 | * | floppydh quit (Quit: WeeChat 2.1) |
15:20:18 | * | leorize quit (Quit: WeeChat 2.1) |
15:22:11 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
15:41:31 | * | FuntDobra joined #nim |
15:58:08 | * | sz0 joined #nim |
15:59:20 | * | FuntDobra quit (Ping timeout: 256 seconds) |
16:05:06 | * | nsf joined #nim |
16:20:32 | FromGitter | <brentp> is there a standard dockerhub repo for nim? would be nice to rely on that for travis, etc. |
16:20:52 | FromGitter | <mratsim> @yglukhov ^ |
16:21:45 | FromGitter | <mratsim> @brentp both: https://github.com/moigagoo/nimage and https://github.com/yglukhov/nim-docker but I would like an official docker build as well |
16:23:51 | FromGitter | <mratsim> and for devel: https://github.com/status-im/nim-docker sometimes it includes unmerged PR but 99% of the time it’s equal to Nim-devel |
16:24:07 | FromGitter | <brentp> great! thanks. |
16:24:47 | FromGitter | <brentp> is there an estimated date for 0.18.1? |
16:25:14 | FromGitter | <mratsim> none, 0.18.1 is for devel ;) |
16:25:30 | FromGitter | <mratsim> next version is either 0.18.2 or 0.19.0 |
16:25:51 | FromGitter | <mratsim> I would guess 0.19.0 due to the potential breaking nil changes |
16:30:15 | * | sendell quit (Remote host closed the connection) |
16:30:15 | * | jjido quit (Read error: Connection reset by peer) |
16:31:42 | Yardanico | even fac procedure may be broken in old code (which uses math module) |
16:32:00 | Yardanico | because before it could compute bigger factorial numbers, but now it only has a precomputed table |
16:32:13 | Yardanico | up to fac(21) |
16:33:25 | FromGitter | <mratsim> but fac22 is bigger than high(uint64) or something no? |
16:36:13 | Yardanico | well, it works for JS target at least :) and it broke my math library a bit (well, nil changes broke it too) |
16:36:37 | Yardanico | doesn't really matter anyway, just saying :) |
16:37:57 | FromGitter | <mratsim> I suddenly want to do a bit of project Euler :P |
16:47:03 | FromGitter | <Varriount> @mratsim "Nim 0.19.0: Bull in a China Shop" |
16:52:17 | FromDiscord | <treeform> what is the potential breaking nil change? |
16:53:57 | * | CodeVance quit (Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org) |
16:55:14 | * | NimBot joined #nim |
16:55:30 | FromGitter | <brentp> I have been hitting a few bugs that are fixed in 0.18.1 |
16:58:11 | Yardanico | @treeform you can't access null terminator in strings |
16:58:33 | Yardanico | also strings/seqs are not nil anymore, you don't have to initialize them |
16:58:37 | Yardanico | read changelog for more info :) |
17:08:14 | miran | Yardanico: is that by default or only behind .experimental.? |
17:08:21 | Yardanico | AFAIK by default |
17:08:36 | Yardanico | and about strings - you can get old behaviour with a switch |
17:08:47 | Yardanico | (i don't remember the exact name, it's in changelog) |
17:09:26 | FromGitter | <data-man> --laxStrings:on |
17:24:14 | Araq | treeform: cstring(nimstring) still works and cstrings have access to the zero terminator |
17:33:19 | FromDiscord | <treeform> never needed the null terminator on strings |
17:33:55 | Yardanico | well, they're quite useful when you do some parsing |
17:36:08 | * | CodeVance joined #nim |
17:39:15 | enthus1ast | can i "monkeypatch" nim functions somehow? For example to let httpclient use my implementation of new(Async)Socket to, for example, connect to an SOCKS server? |
17:44:04 | enthus1ast | i guess this is what the "dependency injection" meme is for |
17:45:52 | subsetpark | enthus1ast: yes, you can use the `patchFile()` function in a .nims with the same name as your test file |
17:46:21 | subsetpark | the nims will get evaluated when the test file is run, and that can replace some library module with a module that you write |
17:49:41 | enthus1ast | then i import the original and export all but my changed procedures i guess |
17:52:27 | subsetpark | i couldn't get that to work. the patch makes it so that it ends up as a circular import. |
17:52:59 | subsetpark | but you can always set up your code so you have an intermediary service layer that can be more easily patched |
17:57:20 | FromGitter | <data-man> Just added filecompress to nimsnappyc/tests. Happy compressing! 😄 |
18:01:53 | FromGitter | <data-man> And dared make my first commit to Nim's repo. 😄 |
18:02:58 | enthus1ast | :) |
18:09:44 | enthus1ast | if we have it about SOCKS, it seems the tcp bind is somehow misdesigned, since it allows just one incomeing connection |
18:19:35 | * | FuntDobra joined #nim |
18:22:14 | * | koranza joined #nim |
18:27:10 | koranza | hey guys, has anyone had "nimble install [anything]" crash the windows command line before? |
18:27:22 | koranza | I'm on Windows 10 and used choosenim to install nim and switched to the devel branch. It appears that to also happen for 0.17.0 and choosenim's stable branch (0.18.0) |
18:28:53 | miran | i have installed just a few packages on windows, but i haven't had any crashes |
18:28:59 | Yardanico | hmm, never experienced crashes in windows cmd |
18:29:15 | Yardanico | really never |
18:29:18 | koranza | I've worked around it by changing the file "C:\Users\[username]\.choosenim\toolchains\nim-#devel\dist\nimble\src\nimblepkg\download.nim" in the command "doClone" |
18:30:33 | koranza | if I change the line about "doCmd(git clone.....)" to provide a second argument to doCmd of "showOuput = true" it gets past that crash |
18:32:11 | koranza | There was a 2nd issue then about index out of bounds which required changes to "C:\Users\[username]\.choosenim\toolchains\nim-#devel\lib\pure\os.nim" |
18:32:30 | miran | strange |
18:32:55 | miran | is this fresh/recent install of nim? |
18:33:08 | * | nsf quit (Quit: WeeChat 2.1) |
18:33:48 | koranza | in the findExe proc around line 154, need to change "var x = (if candidate[0] == '"'...." to be "var x = (if candidate.len > 2 and candidate[0] == '"' ...." |
18:35:43 | koranza | I would guess so, it's whatever happens after running "choosenim update devel" |
18:39:25 | dom96 | "crash the windows command line"? |
18:39:36 | dom96 | Do you mean that the command window itself crashes? |
18:40:42 | * | sz0 quit (Quit: Connection closed for inactivity) |
18:40:44 | koranza | Yeah, it disappears completely. Most times I can't see it as a process using Process Explorer, but one time I saw it still running but not visible |
18:41:29 | Yardanico | wait, how do you launch your windows cmd? |
18:43:42 | koranza | The last time I launched it, it was from the Windows File Explorer. File > Open new command prompt > Open command prompt |
18:44:40 | * | Sembei joined #nim |
18:50:19 | * | Sentreen quit (Remote host closed the connection) |
18:53:52 | dom96 | Perhaps this is a bug report for Microsoft :) |
19:06:41 | * | smt quit (Ping timeout: 248 seconds) |
19:08:26 | koranza | They're anti-Nim now? xD |
19:08:46 | koranza | "This operation is forbidden. All software must be .Net" |
19:08:50 | * | endragor joined #nim |
19:10:48 | * | Sentreen joined #nim |
19:13:33 | * | endragor quit (Ping timeout: 264 seconds) |
19:16:38 | * | koranza quit (Quit: leaving) |
19:20:26 | FromGitter | <ephja> it was fun to experiment with Racket, but who knows if you ever get used to the syntax |
19:21:38 | * | jaco60 quit (Remote host closed the connection) |
19:22:41 | * | vegax87 quit (Changing host) |
19:22:41 | * | vegax87 joined #nim |
19:22:41 | * | vegax87 quit (Changing host) |
19:22:41 | * | vegax87 joined #nim |
19:27:07 | * | jaco60 joined #nim |
19:32:15 | * | BitPuffin quit (Remote host closed the connection) |
19:49:43 | * | xkapastel joined #nim |
19:54:28 | Yardanico | github changed how main page looks? https://i.imgur.com/sjltzUu.png |
19:56:08 | dom96 | indeed |
19:56:09 | dom96 | wat |
19:56:40 | dom96 | why change the sides? |
19:56:45 | Yardanico | yeah, I was confused too |
19:56:53 | dom96 | feels like they're making changes for the sake of it |
19:56:59 | Yardanico | btw, what is this one? https://www.youtube.com/watch?v=TP-YBOGQmLM |
20:00:10 | dom96 | ooh, wonder who gave this talk |
20:00:20 | dom96 | Don't recognise him :) |
20:06:17 | Yardanico | also found this website http://helloworldcollection.de/ :) |
20:06:51 | FromGitter | <xmonader> how can i define product types in object variant? |
20:07:06 | Araq | a product type is a tuple |
20:07:08 | FromGitter | <xmonader> or i use a tuple in the variant instead? |
20:07:20 | FromGitter | <xmonader> yup thanks @Araq |
20:08:04 | Yardanico | wait, what, there's a GNU Hello world program? eh... https://www.gnu.org/software/hello/ |
20:11:35 | skrylar | is the license longer than the program |
20:22:47 | thor77 | Yardanico: huh, it's in german oO looks interesting, though |
20:34:54 | FromGitter | <xmonader> what's named expression? ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5afde76ef04ce53632e701c5] |
20:35:10 | FromGitter | <xmonader> i get named expression isn't allowed here in the third statement |
20:37:44 | * | nsf joined #nim |
20:38:36 | FromGitter | <xmonader> wow movign the sequence to the above line fixed it, but so unclear error message it was giving me the error at `remaining:rem` |
20:40:33 | * | FuntDobra quit (Ping timeout: 255 seconds) |
20:54:03 | FromGitter | <stisa> @xmonader maybe you need a space between `:` and `@`? I think I remember an error like that |
20:54:31 | * | Vladar quit (Quit: Leaving) |
21:01:48 | FromGitter | <mratsim> haha Ithink you found it |
21:21:35 | * | miran quit (Ping timeout: 276 seconds) |
21:25:31 | * | Trustable quit (Remote host closed the connection) |
21:25:46 | * | nsf quit (Quit: WeeChat 2.1) |
21:51:18 | * | qwertfisch is now known as qwertschaf |
22:01:06 | * | jaco60 quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
22:11:24 | * | aleandros joined #nim |
22:25:56 | * | CodeVance_ joined #nim |
22:28:41 | * | CodeVance quit (Read error: Connection reset by peer) |
22:37:48 | FromGitter | <brentp> @mratsim I am trying to do with Arraymancer: `arr[i, _, _] = something` where arr.shape == `[2000, 300, 4]` and something.shape == `[300, 4]` |
22:38:04 | FromGitter | <brentp> but I get error: `unhandled exception: Your tensors or openarrays do not have the same shape: [1, 300, 4] and [300, 4] [IndexError]` |
22:38:38 | FromGitter | <brentp> how can I get around this? |
22:48:31 | Araq | I don't have Ruby installed, who can run this for me... |
22:48:32 | Araq | https://github.com/kostya/benchmarks/blob/master/json/generate_json.rb |
22:48:41 | Araq | and gist the JSON please |
22:51:40 | Araq | or translate the script to Nim for me :-) |
22:51:46 | Araq | that would be even better |
22:52:52 | Araq | oh well, I can almost figure it out on my own :P |
22:56:46 | FromGitter | <xmonader> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5afe08ae2df44c2d0637f6e0] |
22:56:47 | FromGitter | <xmonader> i get attempted to call undeclared routine `p` |
22:56:54 | FromGitter | <xmonader> any idea how to solve this? |
22:57:33 | FromGitter | <xmonader> oops sorry forget it i figured it out, another question then can i override *call* for object? |
22:57:53 | Araq | proc `()`(o: MyObject) |
22:57:58 | Araq | but it's .experimental |
22:58:17 | FromGitter | <xmonader> thanks ^_^ |
22:58:59 | FromGitter | <Vindaar> @brentp for the tensor with shape `[1, 300, 4]` you can use the `squeeze` proc to remove that dimension of length 1 |
23:00:45 | * | xet7 quit (Read error: Connection reset by peer) |
23:10:22 | * | CodeVance__ joined #nim |
23:10:27 | * | skrylar quit (Ping timeout: 240 seconds) |
23:12:28 | * | CodeVance__ quit (Client Quit) |
23:14:02 | * | CodeVance_ quit (Ping timeout: 276 seconds) |
23:19:03 | * | arecaceae quit (Remote host closed the connection) |
23:19:26 | * | arecaceae joined #nim |
23:20:16 | Araq | muhahaha |
23:20:27 | Araq | stdlib: used Mem: 1.277GiB |
23:20:44 | Araq | packedjson: 140.063MiB |
23:25:59 | Araq | time: 3.1s vs 3.7s |
23:26:17 | Araq | smaller by a factor of 10. and faster too |
23:28:26 | FromDiscord | <treeform> Hey Araq, i also did experiments with "packedjson" like structures. |
23:28:35 | FromDiscord | <treeform> I messages you but you never replied. |
23:28:51 | Araq | huh, gitter? |
23:28:57 | Araq | never saw your messages, sorry |
23:29:07 | FromDiscord | <treeform> I think I just @ you here and you did not notice and I forgot too. |
23:29:33 | FromDiscord | <treeform> I did a simpler one, which was just a string:string packed dictionary. |
23:30:06 | FromDiscord | <treeform> I saw slow downs on small scale but when I scaled it up it was a significant speed up. |
23:31:01 | FromDiscord | <treeform> My guess is that it used less memory and memory next to each other, it kept the memory caches hotter. |
23:31:27 | Araq | https://github.com/Araq/packedjson |
23:32:47 | Araq | and I haven't optimized it much (yet) |
23:33:27 | FromDiscord | <treeform> This is what i did: https://gist.github.com/treeform/eab4d05013d0953cbec580466e1018d7 |
23:34:56 | FromDiscord | <treeform> mine is much simpler |
23:37:51 | * | noonien quit (Quit: Connection closed for inactivity) |
23:38:13 | Araq | mine is a json.nim replacement |
23:39:14 | FromDiscord | <treeform> Araq, I am looking at your parser, it looks like you create a new buffer, but could you make it faster if you just clobber the existing json buffer with control bytes and NOP bytes, some thing like parseJsonClobber maybe? |
23:39:26 | * | gokr quit (Ping timeout: 255 seconds) |
23:40:53 | FromDiscord | <treeform> You also seem to do a liner scan for [] and contains. How does the current implementation work? |
23:41:19 | Araq | the current or mine? |
23:42:12 | Araq | it's really simple. |
23:42:22 | Araq | I use a binary Lisp tree |
23:42:38 | Araq | (a (b c) d) |
23:42:57 | Araq | ( is mapped to \0, ) is \1 and the space is \2 |
23:43:19 | Araq | I keep strings unescaped so they can't contain these bytes |
23:43:38 | Araq | that's it. 3 control bytes to navigate the structure. |
23:43:46 | * | leorize joined #nim |
23:44:15 | Araq | oh and the space is not a separator, but a terminator |
23:44:27 | Araq | makes the algorithms simpler |
23:44:41 | FromDiscord | <treeform> neat |
23:45:03 | FromDiscord | <treeform> so like "(a (b c ) d )"? |
23:45:25 | FromDiscord | <treeform> or "(a (b c )d )" |
23:45:33 | Araq | "(a (b c ) d )" |
23:46:09 | FromDiscord | <treeform> "(a (b c ) d ) "? |
23:46:27 | FromDiscord | <treeform> do you need the last space? |
23:46:32 | Araq | "(a (b c ) d )" |
23:46:37 | Araq | no, as I wrote it. |
23:46:41 | FromDiscord | <treeform> In JsonNode what do a or b point to? |
23:46:57 | FromDiscord | <treeform> Why do you need a space after ")" node? |
23:47:01 | Araq | slices into the t[] string |
23:47:14 | Araq | I don't need the space, but it keeps things simple |
23:47:23 | FromDiscord | <treeform> start and end? |
23:47:25 | Araq | every list element is terminated by a space |
23:47:28 | FromDiscord | <treeform> or start and len? |
23:47:40 | Araq | start..end (inclusive) |
23:48:32 | FromDiscord | <treeform> you store ints as strings? so that you need to parseInt? |
23:48:51 | Araq | yeah, think about the control bytes |
23:49:04 | Araq | but it also helps to keep the representation small in memory. |
23:49:11 | Araq | usually numbers are small |
23:49:19 | Araq | and take up less than 8 bytes |
23:49:46 | FromDiscord | <treeform> yeah that is true but you talked about the SQLite number encoding. |
23:49:52 | FromDiscord | <treeform> which is even better? |
23:50:19 | FromDiscord | <treeform> Also you store bool as full true or false, but you only check for 't'? |
23:50:36 | Araq | no, I store it as 't' and 'f' |
23:50:55 | Araq | also, yeah, you can use SQLite's number represenation (I have the code ready) |
23:51:14 | Araq | but then you need to convert the number into ascii for pretty/$ |
23:51:39 | Araq | and for json "back to string" is important (send to websocket...) |
23:51:57 | FromDiscord | <treeform> https://github.com/Araq/packedjson/blob/master/packedjson.nim#L432 |
23:52:13 | FromDiscord | <treeform> looks like you store full "true" or "false" and "null" or I am not reading it right. |
23:52:25 | Araq | that is proc toPretty |
23:52:36 | Araq | (stringification) |
23:52:48 | Araq | so you're looking at the wrong thing |
23:53:12 | FromDiscord | <treeform> ok got it! |
23:53:28 | FromDiscord | <treeform> ok found it: https://github.com/Araq/packedjson/blob/master/packedjson.nim#L604 |
23:55:04 | FromDiscord | <treeform> I don't see you adding space after the } https://github.com/Araq/packedjson/blob/master/packedjson.nim#L630 |
23:55:32 | FromDiscord | <treeform> You said it should have a space after it: "(a (b c ) d )" |
23:55:36 | Araq | not every ) gets the space |
23:55:42 | Araq | it's really simple. |
23:55:49 | Araq | the space comes after the element in the list. |
23:56:04 | Araq | if the element is itself a () tree, it still gets the space. |
23:56:25 | FromDiscord | <treeform> Got it. Yeah is see it now. Thanks. |
23:56:38 | FromDiscord | <treeform> only inside a [] or {} there is a space between elements. |
23:56:54 | Araq | only these have elements. |
23:56:58 | Araq | the others are atoms. |
23:58:19 | FromDiscord | <treeform> Do you think this can be used for other data structures, like in native nim? |
23:58:39 | Araq | what do you think? that JSON is some toy data structure? :P |
23:58:46 | FromDiscord | <treeform> foo = object {.bufferpacked.} |
23:58:52 | FromDiscord | <treeform> and it handles string packing for you? |
23:59:19 | FromDiscord | <treeform> and you can use them as normal objects/ |
23:59:22 | FromDiscord | <treeform> and you can use them as normal objects? |
23:59:31 | FromDiscord | <treeform> you probably don't need to store keys though |
23:59:40 | FromDiscord | <treeform> you know the element # at compile time. |
23:59:52 | Araq | doesn't help, it's all variable sized |