code logs -> 2016 -> Sat, 03 Dec 2016< code.20161202.log - code.20161204.log >
--- Log opened Sat Dec 03 00:00:34 2016
00:24 catalyst [catalyst@Nightstar-bt5k4h.81.in-addr.arpa] has quit [[NS] Quit: Leaving]
01:11
<@TheWatcher>
abudhabi: uh
01:14
<@TheWatcher>
Try now
01:14
<@TheWatcher>
2.2 -> 2.4 apache issue
01:18 Kindamoody is now known as Kindamoody[zZz]
01:22 Irssi: #code: Total of 37 nicks [36 ops, 0 halfops, 0 voices, 1 normal]
01:22 Vash [Vash@Nightstar-uhn82m.ct.comcast.net] has joined #code
03:32
< Vash>
Vorn something around the lines, "We need to start you on some simple exercises for coding" (after I said something about getting into learning it again, since I abandoned it last time I tried learning it). me "Maybe someone in code would be good at that, like *blank* and *blank*" vorn, "... I'm the one who has teached people to code including *college attended*"
03:32
< Vash>
me "... Oh. =X"
03:32
< Vash>
On the one hand, Vorn says I should start on Python, and that was the same thing we were trying last time.
03:33
< Vash>
On the other hand, we had started a bit back on Love2D and were working on something (which means I'd probably get more into it and stuff... since python is so open to making anything that it makes me feel like i don't know how it's going to help me get started?)
03:34
<&[R]>
I've read that a few times, and I'm having trouble parsing it.
03:35
<~Vornicus>
I think Vash is trying to say that Lua - via Love2D - was more domain specific
03:35
<~Vornicus>
Which isn't actually *true*, really, but
03:40
< Vash>
I think after asking (what I think was the right question), Vorn explained some stuff about the languages that I think makes me understand it now. About my confusing talk
03:41
<~Vornicus>
But by providing a framework that's already about video games it tends to feel restrictive in ways that themselves allow for better exploration of the sapce
04:04
<@celticminstrel>
<_< I have officially joined the dark side. "const T*const operator&() const"
04:06
<~Vornicus>
you madman
04:11
<@celticminstrel>
Hmmm, cost_to_here is NaN. That can't be good. (Back to the JS A* stuff.)
04:12
<@celticminstrel>
If I could make JS return infinity instead of undefined for nonexistent keys, that would be so much better for this.
04:13
<~Vornicus>
Something is funny here
04:13
<~Vornicus>
nonexistent keys?
04:14
<@celticminstrel>
A map storing the best known cost for reaching each tile.
04:14
<@celticminstrel>
The key is a string identifying the tile.
04:15
<~Vornicus>
right but... why are you looking in there for nonexistent keys?
04:15
<@celticminstrel>
Tiles that haven't yet been visited.
04:17
<~Vornicus>
I'm *really* confused as to what you're up to where this is happening.
04:17
<@celticminstrel>
Well, this is the pseudocode I originally used as a reference: https://en.wikipedia.org/wiki/A*_search_algorithm#Pseudocode
04:18
<@celticminstrel>
It calls it gScore.
04:18 * celticminstrel just realized I forgot to set the best cost to the starting point as 0.
04:19
<@celticminstrel>
That might very well be the problem here.
04:20
<@celticminstrel>
I'm also a bit uncertain since it seems like I'm storing the same thing in too different places though...
04:20
<@celticminstrel>
I mean I'm also storing this cost alongside each tile in the heap, since the comparison function uses it... but I figured that might not always be the best cost. Maybe I'm overthinking it.
04:27
<&[R]>
> o = {a: 'foo', b: 'bar'}; f = function(k) { return o.hasOwnProperty(k) ? o[k] : Infinity }; 'abcd'.split('').map(f)
04:27
<&[R]>
[ 'foo', 'bar', Infinity, Infinity ]
04:29
<@celticminstrel>
Well, I have "best_to = {}" and want best_to["blah"] to return infinity. Which I'm pretty sure is not possible. I could probably compromise though and use best_to.get("blah") instead...
04:31
<&[R]>
Well, if best_to returns non-zero values: best_to[k] || Infinity
04:31
<@celticminstrel>
Right.
04:31
<@celticminstrel>
But best_to[start] = 0.
04:31
<@celticminstrel>
I actually worked around that by fetching and comparing to undefined...
04:31
<@celticminstrel>
...but...
04:32
<@celticminstrel>
...that was when getting the cost of the neighbour, not the tile currently being visited.
04:32
<&[R]>
As in: `undefined == x`?
04:32
<@celticminstrel>
Which, come to think of it, probably is redundant.
04:32
<@celticminstrel>
Well, reversed from that, but basically yes.
04:33
<&[R]>
You should be doing `'undefined' == typeof x` instead.
04:33
<&[R]>
Because `undefined` is actually a variable...
04:33
<@celticminstrel>
Firefox doesn't allow me to assign to undefined.
04:35
<@celticminstrel>
Also, why does everyone not use parentheses with typeof?
04:35
<&[R]>
V8 does... but doesn't actually keep the value.
04:35
<&[R]>
Because it's not a function?
04:36
<@celticminstrel>
That's the same as Firefox, yes.
04:36
<@celticminstrel>
So?
04:38
<&[R]>
Adding parens doesn't increase legibility
04:38
<&[R]>
Do you have parens around all your returns?
04:38
<@celticminstrel>
I think there was actually a time when I did, but... no.
04:50
<@celticminstrel>
Well, it looks like it's working better now, but...
04:51
<@celticminstrel>
Why is the starting tile surrounded by impassable tiles... or is my cost function wrong...
05:11
<~Vornicus>
aaaaarg frustration what the hell is wrong with programmers
05:12
<~Vornicus>
"you need to have a working SDL 2 on your system" "okay I'll go get that. ...this is a DLL. How do I put it in a place where it knows where to find it?"
05:12
<~Vornicus>
*silence*
05:12
<~Vornicus>
"You can install this through pip" "okay great how do I do that?" *silence*
05:19
<&[R]>
DLL just put it beside the EXE
05:20
< Vash>
It's a script
05:24
<@celticminstrel>
...wait. The heap has 197,600 tiles. The map has 128,000 tiles. o.o
05:25
< Vash>
Something has gone terribly wrong here.
05:25
<@celticminstrel>
Now it has 388,000 tiles.
05:25
< Vash>
(this is vorn on vash's computer while I install shit for her)
05:25
<@celticminstrel>
What Vash said.
05:25
<@celticminstrel>
Oh, what Vorn said then..
05:30
<@celticminstrel>
Okay, so one problem is that unreachable tiles are being returned by the neighbours() function.
05:30
<@celticminstrel>
By which I mean, tiles that are off the edge of the map.
05:30
< Vash>
That is one problem
05:32
<@celticminstrel>
...so my check to avoid that was testing the coordinate of the current tile, not the coordinate of the neighbouring tile. That explains why they were all -1.
05:34 abudhabi [abudhabi@Nightstar-7nkq9k.de] has quit [Ping timeout: 121 seconds]
05:34
<@celticminstrel>
Clearly I should not have tried to expand that 749,068-element array in the debugger.
05:34
< Vash>
Almost certainly not.
05:40
<~Vornicus>
Ok figured out gosh annoyance
05:42
<@celticminstrel>
So I added a visited check after the pop and suddenly it's *zoom*.
05:43
<@celticminstrel>
For a single path, at least.
05:43
<~Vornicus>
Yes, that you must do
05:44
<@celticminstrel>
I thought someone said the visited check was only needed before push and not after pop.
05:44
<~Vornicus>
I've always been hammering on after pop.
05:45
<~Vornicus>
Or rather -- pre-push isn't technically necessary, but helps keep heap sizes low in situations where every entry to a node has the same cost. Post-pop is absolutely necessary.
05:45
<~Vornicus>
or rather rather, pre-push must be visited, not merely discovered
05:45
<@celticminstrel>
Oh, so it was the pre-push check that was optional.
05:45
<~Vornicus>
if you're going to do it
05:45
<@celticminstrel>
Eh?
05:46
<~Vornicus>
Visited means it's been popped from the heap once already
05:46
<~Vornicus>
Discovered means it's been pushed to the heap but not necessarily popped yet.
05:46
<@celticminstrel>
I'm not currently tracking discovered.
05:46 abudhabi [abudhabi@Nightstar-7nkq9k.de] has joined #code
05:46 mode/#code [+o abudhabi] by ChanServ
05:47
<~Vornicus>
pre-push visited checks helps keeps the heap small; post-pop visited checks prevent you from actually getting to the same node twice.
05:48
<@celticminstrel>
So checking visited rather than discovered before push is not wrong?
05:48
<~Vornicus>
It is indeed non-wrong
05:52
<@celticminstrel>
Forgot that console.log really slows it down a lot... removed that, and it now handles all the paths without Firefox complaining it might be in an infinite loop.
05:52
<@celticminstrel>
(It was there so I could debug without stepping through torturously in the debugger.)
05:52
<@celticminstrel>
So I guess this is done.
05:52
<@celticminstrel>
Finally.
05:53
<@celticminstrel>
I can move on to the next thing I was planning.
05:53 Vash [Vash@Nightstar-uhn82m.ct.comcast.net] has quit [Connection closed]
05:53
<@celticminstrel>
Assuming the paths actually appear.
05:54
<@celticminstrel>
Yup, looks like they did. (I made them use a different tile so it'd be obvious.)
05:54
<~Vornicus>
How zoom is it now?
05:55
<@celticminstrel>
I didn't time it, but definitely less than 15s including the DFS to find the continents (aka connected components) and the A* to connect them all.
05:55
<@celticminstrel>
Speaking of the DFS, I seem to recall saying I might switch that to BFS.
05:56
<@celticminstrel>
I say definitely less than 15s because that's the point at which Firefox starts to complain.
05:56
<~Vornicus>
DFS might be faster -- it avoids mass moves better
05:57
<~Vornicus>
unless you have a queue that doesn't work by popping off the first item of the list.
05:57
<@celticminstrel>
Oh, true, BFS would be using shift().
05:58
<@celticminstrel>
Which is a mass move.
05:58
<@celticminstrel>
And the obvious way of avoiding that is to mass-move on insert instead, which surely wouldn't helo in the least.
06:02
<@celticminstrel>
Heh, DLL could describe a way to avoid it. >_>
06:08
<~Vornicus>
(the right way to avoid it and still use arrays is to use a circular queue and some complex resizing logic when you discover you need more)
06:20
<@celticminstrel>
Either that was a fluke, or I did something, because now it seens to be slow again...
06:21
<~Vornicus>
ay.
06:25
<&[R]>
<pedja> heh, one of the most popular extensions for MS Code editor is vim-mode :)
06:36
<~Vornicus>
not terribly surprising
06:37
<~Vornicus>
vim's superpower is a small, easily accessed feature set (once you know the keys anyway)
06:40
<~Vornicus>
CHorded KEys ARe HArd TO HIt QUickly ANd ACcurately, so the single keystroke style makes getting through stuff fast. (that was hard to type)
07:08 Derakon is now known as Derakon[AFK]
08:11 catadroid [catalyst@Nightstar-i2o641.dab.02.net] has joined #code
08:33 Kindamoody[zZz] is now known as Kindamoody
08:34 Alek [Alek@Nightstar-cltq0r.il.comcast.net] has quit [Ping timeout: 121 seconds]
08:34
<@simon_>
besides transgendered people, who are discriminated in locker rooms at e.g. public swimming pools?
08:35
<@simon_>
I'm a little privilege blind on this. I'm thinking disabled people, but aren't they also discriminated against in the public swimming pool in general?
08:36 * catadroid blinks
08:37
<@simon_>
Vornicus, [R]: does MS Code actually have full support for vim's keybindings? or do they simulate a portion of it like all other editors with a broken vim clone inside?
08:37
< catadroid>
Fat folk, trans folk, people with visible injuries/birthmarks
08:37 * catadroid wonders where the question came from
08:37 Alek [Alek@Nightstar-cltq0r.il.comcast.net] has joined #code
08:37 mode/#code [+o Alek] by ChanServ
08:37
<~Vornicus>
wait there's such a thing as a public swimming pool?
08:37
< catadroid>
People with disabilities are often discriminated against by the actual lack of facilities themselves
08:38
<@simon_>
catadroid, thanks. well, it's a facebook debate. someone in the parliament of Denmark gave a pretty amazing speech on rights, and since it's televised, it's going viral. so I'm trying to raise a debate among friends.
08:38
<@simon_>
Vornicus, they're all over in Denmark :)
08:38
<~Vornicus>
holding out on us, eh
08:38
<@simon_>
Vornicus, most of them are inside. a few have outside sections.
08:39
<@simon_>
Vornicus, they cost money to access, but they're partly funded through taxes, too.
08:41
<@simon_>
catadroid, yes, the arrangement of benches in the locker room at the local swimming pool locker room makes it impossible to go through the room in a wheelchair. (I think they have some other doors for wheelchair access, though, but the building clearly wasn't designed for it).
08:42
<@simon_>
and no handles to avoid that blind people slip and fall. etc.
08:42
<@celticminstrel>
...I'm more surprised that Vorn is surprised at that.
08:43 * simon_ goes offline again.
08:43
<~Vornicus>
I was being partly facetious, but I'm not aware of any public swimming pools and I went looking
08:46
< catadroid>
Huh :o
09:06 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
09:08 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has joined #code
09:08 mode/#code [+o celticminstrel] by ChanServ
09:10 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
09:28
<@abudhabi>
TheWatcher: Works.
09:34 catadroid [catalyst@Nightstar-i2o641.dab.02.net] has quit [[NS] Quit: Bye]
09:38 catalyst [catalyst@Nightstar-bt5k4h.81.in-addr.arpa] has joined #code
10:28 catalyst [catalyst@Nightstar-bt5k4h.81.in-addr.arpa] has quit [Connection closed]
10:33
<@TheWatcher>
abudhabi: also, https:// will work, too
10:33
<@TheWatcher>
I may or may not force https eventually, I need to check to see whether there's embdeed http content in there first, but that'll be a while
12:20 Kindamoody is now known as Kindamoody|afk
12:51 catalyst [catalyst@Nightstar-bt5k4h.81.in-addr.arpa] has joined #code
13:31
<@simon_>
Vornicus, where would you go swimming if not in the sea? do you only have private swimming pools in your neck of the woods?
13:38
<~Vornicus>
There's the Y, which is a nonprofit, but
13:39
<~Vornicus>
here there is indeed the ocean
14:06
<&ToxicFrog>
Yeah, public swimming pools are both common and the default way of swimming here
14:06
<&ToxicFrog>
There's the conservation area lakes, but those are an hour+ drive depending on where you live and what kind of swimming you're after, and are seasonal
14:06
<&ToxicFrog>
The ocean is a multi-day trip away
14:28
<&McMartin>
To me the phrase "public swimming pool" means "open to the public", not "run by the city"
14:34
<&ToxicFrog>
McMartin: yes? Most public swimming pools here are run by the city, but I believe there's also stuff like the Y
14:40
<&McMartin>
Vorn's statement looked like the Y wasn't being considered
15:11
<@simon_>
McMartin, I should probably have said "municipal swimming pools". thing is, in Denmark, a part of the tax is municipal, but since Denmark is so small, most people see it all as "government tax".
15:36 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Ping timeout: 121 seconds]
16:40 Internets [ntrnt@Nightstar-c14.ot1.68.196.IP] has joined #code
16:41 Internets [ntrnt@Nightstar-c14.ot1.68.196.IP] has left #code []
18:43 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has joined #code
18:43 mode/#code [+o celticminstrel] by ChanServ
19:03 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has quit [[NS] Quit: KABOOM! It seems that I have exploded. Please wait while I reinstall the universe.]
19:04 celticminstrel [celticminst@Nightstar-h4m24u.dsl.bell.ca] has joined #code
19:04 mode/#code [+o celticminstrel] by ChanServ
20:26 Ogredude [quassel@Nightstar-dm1jvh.projectzenonline.com] has quit [Operation timed out]
20:26 Ogredude [quassel@Nightstar-dm1jvh.projectzenonline.com] has joined #code
20:26 mode/#code [+o Ogredude] by ChanServ
20:28 simon_ [simon@Nightstar-sjjvb1.dk] has quit [Operation timed out]
20:28 simon_ [simon@Nightstar-sjjvb1.dk] has joined #code
20:28 mode/#code [+o simon_] by ChanServ
20:29 Orthia [quassel@Nightstar-ksqup0.co.uk] has quit [Ping timeout: 121 seconds]
20:31 Orthia [quassel@Nightstar-ksqup0.co.uk] has joined #code
20:31 mode/#code [+o Orthia] by ChanServ
21:11 Derakon[AFK] is now known as Derakon
21:48 Kindamoody|afk is now known as Kindamoody
22:29 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code
22:29 mode/#code [+qo Vornicus Vornicus] by ChanServ
22:29 Kindamoody is now known as Kindamoody[zZz]
22:57 celticminstrel is now known as celmin|away
23:00
<&ToxicFrog>
argh
23:00
<&ToxicFrog>
every time I want to do something substantive in clojure, I think "this time I will do type checking"
23:00
<&ToxicFrog>
and every time I bounce off
23:01
<&ToxicFrog>
usually when I run into something where I can't even determine if it's a legitimate bug in the typechecker, a known limitation, or if I'm just not expressing my code quite in the way it expects
--- Log closed Sun Dec 04 00:00:36 2016
code logs -> 2016 -> Sat, 03 Dec 2016< code.20161202.log - code.20161204.log >

[ Latest log file ]