--- Log opened Fri May 01 00:00:40 2020 |
00:40 | | VirusJTG [VirusJTG@Nightstar-42s.jso.104.208.IP] has quit [Connection closed] |
00:41 | | VirusJTG [VirusJTG@Nightstar-42s.jso.104.208.IP] has joined #code |
00:41 | | mode/#code [+ao VirusJTG VirusJTG] by ChanServ |
01:03 | | Pinkhair [user1@Nightstar-g7hdo5.dyn.optonline.net] has joined #code |
01:07 | | Pink [user1@Nightstar-g7hdo5.dyn.optonline.net] has quit [Ping timeout: 121 seconds] |
01:29 | | Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Connection closed] |
01:38 | | catalyst_ [catalyst@Nightstar-4td1ib.dab.02.net] has quit [Connection closed] |
01:41 | | catalyst [catalyst@Nightstar-4td1ib.dab.02.net] has joined #code |
03:03 | | Pinkhair [user1@Nightstar-g7hdo5.dyn.optonline.net] has quit [Ping timeout: 121 seconds] |
03:03 | | Pink [user1@Nightstar-g7hdo5.dyn.optonline.net] has joined #code |
03:27 | | Pinkhair [user1@Nightstar-g7hdo5.dyn.optonline.net] has joined #code |
03:27 | | Pink [user1@Nightstar-g7hdo5.dyn.optonline.net] has quit [Ping timeout: 121 seconds] |
04:51 | | Degi [Degi@Nightstar-11pe9q.dyn.telefonica.de] has quit [Ping timeout: 121 seconds] |
04:52 | | Degi [Degi@Nightstar-7krfi6.dyn.telefonica.de] has joined #code |
05:30 | | catalyst [catalyst@Nightstar-4td1ib.dab.02.net] has quit [Ping timeout: 121 seconds] |
05:55 | | Vorntastic [uid293981@Nightstar-h2b233.irccloud.com] has joined #code |
05:55 | | mode/#code [+qo Vorntastic Vorntastic] by ChanServ |
06:29 | | catalyst_ [catalyst@Nightstar-kfdvn8.dab.02.net] has joined #code |
07:08 | | Emmy [Emmy@Nightstar-9p7hb1.direct-adsl.nl] has joined #code |
08:49 | | Emmy is now known as Emmy-Werk |
11:05 | | Pinkhair [user1@Nightstar-g7hdo5.dyn.optonline.net] has quit [Ping timeout: 121 seconds] |
11:05 | | Pink [user1@Nightstar-g7hdo5.dyn.optonline.net] has joined #code |
11:58 | | catalyst [catalyst@Nightstar-6lqcam.dab.02.net] has joined #code |
12:01 | | catalyst_ [catalyst@Nightstar-kfdvn8.dab.02.net] has quit [Ping timeout: 121 seconds] |
12:54 | | catalyst [catalyst@Nightstar-6lqcam.dab.02.net] has quit [[NS] Quit: -a- Connection Timed Out] |
12:59 | | catalyst [catalyst@Nightstar-6lqcam.dab.02.net] has joined #code |
15:06 | | Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code |
15:06 | | mode/#code [+qo Vornicus Vornicus] by ChanServ |
16:11 | <@Alek> | well. this is just week 3 of 5 of very basic python, but we're already getting into calling functions with parameters and returning parameters, which half a book of python hadn't gotten around to before, much less a semester of C or C++, from what I can recall. |
16:11 | <@Alek> | and next week we get image manipulation. <_< |
16:12 | <@TheWatcher> | Wait, wat |
16:12 | <@TheWatcher> | how do you do damn near anything in c or c++ without covering functions with parameters and return values?! |
16:12 | <@Alek> | no idea! |
16:13 | <@Alek> | everything in one function, I think. |
16:14 | <@Alek> | to be fair, the book I was doing a few years ago was Learn Python The Hard Way. >_> |
16:14 | <@Alek> | python2 instead of 3 now, but still, half a book without mentioning function parameters and returns is definitely doing it the hard way. <_< |
16:16 | <@Alek> | still to figure out: how to do or kludge global variables and named array calls (instead of indexed). |
16:16 | <@Alek> | perhaps make constants for index positions? |
16:29 | | Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Connection closed] |
17:03 | | Emmy-Werk is now known as Emmy |
17:12 | | Vorntastic [uid293981@Nightstar-h2b233.irccloud.com] has quit [[NS] Quit: Connection closed for inactivity] |
17:39 | <&McMartin> | Named array calls? like foo[bar]? |
17:39 | <&McMartin> | constants for index positions would work, but the most natural way to represent that is with a dictionary |
18:29 | | catalyst_ [catalyst@Nightstar-l4kab6.dab.02.net] has joined #code |
18:32 | | catalyst [catalyst@Nightstar-6lqcam.dab.02.net] has quit [Ping timeout: 121 seconds] |
19:16 | | catalyst_ is now known as catalyst |
19:39 | | Netsplit Deepthought.Nightstar.Net <-> Krikkit.Nightstar.Net quits: @Syloq |
19:40 | | Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code |
19:41 | | Netsplit over, joins: Syloq |
19:42 | < catalyst> | my crate is being downloaded between ten and thirty times a day recently :o |
19:42 | < catalyst> | I guess people find my cost useful |
19:42 | < catalyst> | code* |
19:45 | <&McMartin> | Always nice to see |
19:49 | < Emmy> | your crate? |
19:49 | < Emmy> | or was that also meant to be code? |
19:50 | <&McMartin> | "Crate": public Rust module |
19:50 | < catalyst> | ^ this |
19:50 | <&McMartin> | "Module" being a term of art in Rust that is smaller than a crate but slightly more than a mere namespace |
19:50 | < catalyst> | https://crates.io/crates/float_eq |
19:50 | < catalyst> | specifically this one |
19:51 | | * Emmy blinks |
19:52 | < Emmy> | I'll admit that code is above me ^.^; |
19:52 | < Emmy> | *beyond, not above |
19:54 | <&McMartin> | catalyst's niche appears to be the gruesome underbelly of library code. |
19:56 | < catalyst> | I do seem to live there a lot |
19:56 | < catalyst> | mostly I see my job as making hard things easier so people can get more done |
19:58 | <&McMartin> | I say the same thing about myself but seem to get up to very different things :) |
19:59 | < catalyst> | there's a lot of hard things :) |
20:00 | <&McMartin> | Yeah. I've been trying to develop my skills at a level of "presenting clean abstractions" at a level or two higher than this |
20:01 | <&McMartin> | The closest I've gotten to building something at this level was an asynchronous promise system to make up for C++'s and ObjC's lacks at the time, and even there it was part of a more generalized RPC mechanism that was what my "clients" really wanted. |
20:01 | | * Emmy shrugs |
20:02 | < Emmy> | i'm just a lowly VB(A/.net) / C# /SQL programmer. |
20:02 | < Emmy> | i make applications for administration work. |
20:03 | <&McMartin> | Your clients are the admins. |
20:03 | <&McMartin> | Broadly speaking, your clients are the ones who actually are doing work. You empower them. I empower you. Catalyst empowers me. |
20:03 | <&McMartin> | Seems to be the abstraction layers in which we work most comfortably, anyway. |
20:03 | < catalyst> | and I live on top of what the hardware engineers do for me |
20:04 | <&McMartin> | If you're a C# programmer, you *can* work at the level I prefer but may prefer not to or have to work harder at it than I would, and likewise for me at yours or catalyst's |
20:05 | < Emmy> | In the words of newton, 'dwarves standing on the shoulders of giants' :P |
20:05 | < catalyst> | I spent a while in C#, it's a very capable language, especially if what you want to do is applications for people to use |
20:05 | < catalyst> | honestly I prefer C# to C++ for most things |
20:05 | <&McMartin> | Yeah. |
20:05 | <&McMartin> | In fact the more I used C++ the more I realized I never preferred it for, well, nearly anything |
20:06 | | mode/#code [+o Syloq] by ChanServ |
20:06 | < Emmy> | my C# is somewhat beginner level, i think, though there was that one time last month where i had to correct a bug in the API library by a major (online) accounting company, so i've got that going for me :P |
20:06 | | mode/#code [+qo Vornicus Vornicus] by ChanServ |
20:07 | < catalyst> | the things c++ does well are almost entirely subsumed by rust |
20:07 | < catalyst> | so uh, I'm just using that now |
20:07 | | * McMartin nods |
20:08 | <&McMartin> | The companies interested in me seem to mostly be using Rust-generation languages that aren't as good as Rust, so I'm practicing a bit with their ugly corners to see how best to defang them. |
20:08 | < catalyst> | I'm honestly incredibly impressed with how far rust has come in five years |
20:09 | < catalyst> | D missed the boat |
20:09 | <&McMartin> | D had been hovering around for ages |
20:09 | <&McMartin> | It never seemed to have taken off |
20:09 | <&McMartin> | tbh Rust still hasn't but it brought more to the table. |
20:09 | <&McMartin> | D brought... mixins, which I think are a deleterious mutation to OO tbh |
20:21 | < catalyst> | rust just has almost Lisp macros |
20:21 | < catalyst> | which are lush |
20:21 | < catalyst> | Rust feels like it could take off in a way that D never quite seems to be close to |
20:22 | < catalyst> | it's the whole lifetimes and safety aspect as well as people knowing about it for WASM purposes |
20:22 | | * McMartin nods |
20:23 | <&McMartin> | I feel it still has some way to go. Right now it's at "trendy", but for too many people knowing Rust is a way to flex, not a way to improve productivity. |
20:23 | <&McMartin> | The state of the industry is so grim right now that Golang meaningfully improves productivity for many >_< |
20:24 | <&McMartin> | But I'm firmly in the camp that lifetime types are the correct solution for for what aggressive reference counting ultimately ends up mostly doing |
20:25 | <&McMartin> | It's not sufficient but it covers the 80% of cases that you absolutely need |
20:25 | <&McMartin> | (And for the rest, that's what Box<>, Rc<>, and Arc<> are for) |
20:25 | <&McMartin> | (I remember another games industry veteran telling me that Arc<> alone was a convincing argument for Rust uptake, which I did not expect to hear) |
20:33 | < catalyst> | interesting |
20:33 | < catalyst> | lifetimes actually enable a bunch of single threaded optimisations on base types that C++ just can't do because it's too difficult to be safe with them |
20:33 | < catalyst> | (I mean, it can do but I've also seen literally weeks of work time wasted tracking down the bugs) |
20:35 | <&McMartin> | Yep |
20:35 | <&McMartin> | Discipline is not a replacement for a machine's systematicity |
20:35 | <&McMartin> | Even though you (by necessity) use it as one |
20:35 | <&McMartin> | I don't have a fully formed thought attached to that yet but one is coalescing as I do more retrocoding work |
20:56 | < catalyst> | makes sense to me |
21:13 | < Yossarian> | Cleaning up and found a 2006 Canon Powershot SD630 that takes the custom CHDK firmware that lets you do different things. Wonder if I could write code to enumerate the camera as a webcam device under linux easily? Or if Walmart sells solder I can get one of these xbox 360 kinects to USB and the additional required 12vdc@1a (I have such a PSU, in my lipo charging bag for my RC stuff) |
21:17 | | JustLurk [justbob@ServerAdministrator.Nightstar.Net] has joined #code |
21:17 | | JustBob [justbob@Nightstar.Customer.Dissatisfaction.Administrator] has quit [NickServ (RECOVER command used by JustLurk)] |
21:17 | | JustLurk is now known as JustBob |
21:17 | | mode/#code [+o JustBob] by ChanServ |
21:19 | < Yossarian> | I have two Xbox 360 Kinect cams, they were going for peanuts at Goodwill when I walked in. They can be used for face tracking and even photogammetry in near real time. $3 and $4 respectively. |
21:27 | < Yossarian> | Although the newer Kinect for Xbone has a better resolution. I already wanted to get into scanning objects anyway but what I want to scan are certain laptop chassis for reproduction & modification |
21:35 | <~Vornicus> | kinects are amazing and underused |
22:34 | <@Alek> | ok, another python question. constants are global, by convention, but is there anything prohibiting functions from actually modifying them? |
22:35 | < ErikMesoy> | Yes, sort of: you have to say "global". |
22:37 | <~Vornicus> | You have to say global to *assign* to a global |
22:37 | <~Vornicus> | running methods, including invisible methods like indexing, is fine in all situations |
22:40 | < ErikMesoy> | Right. To be more specific, Alek - if you declare "blah=10" as a global, and inside a function say "blah = 12", the function will by default create a local variable blah that gets cleaned up at the end of the function. Global blah will still be 10. |
22:41 | <~Vornicus> | on the other hand: blah = {} as a global and then inside a function blah['monkeys'] = 'space' will modify the global blah |
22:43 | <@Alek> | I'm missing something obvious, I'm sure, because both examples seem to be the same. |
22:44 | < ErikMesoy> | Alek: A function saying "blah=12" will not touch global blah. A function calling "blah.MakeMeTwelve()" will touch global blah. Clearer? |
22:46 | <@Alek> | nooot quite, but that's probably because I haven't gotten as far as x.y() variables (as opposed to subfunctions) yet. |
22:51 | < ErikMesoy> | OK. Maybe it's better if I try to back up and briefly answer Alek's original question as asked, rather than getting into detail: Very little prevents python functions from modifying global constants. |
22:51 | <~Vornicus> | 'constants' |
22:52 | < ErikMesoy> | There's one layer of syntactic sugar, the "global" keyword, to make it harder to accidentally overwrite your global variables with local variables. |
22:53 | < ErikMesoy> | As Vorn says, 'constants' aren't really constant in Python. |
22:53 | < ErikMesoy> | They're more like 'variables with a note attached, saying to not vary them'. :P |
23:20 | <@Alek> | ok, thanks. |
23:21 | <@Alek> | I hope to get enough sleep tonight, but right now I've got to do and submit my assignments by the end of the day. -_- |
23:21 | <@Alek> | on very_much_not_enough_sleep |
23:26 | <@Alek> | I did manage to figure out how to retrieve an indexed entry of a list, when they haven't covered that yet, so there's that. |
23:26 | | Emmy [Emmy@Nightstar-9p7hb1.direct-adsl.nl] has quit [Ping timeout: 121 seconds] |
--- Log closed Sat May 02 00:00:42 2020 |