« first day (2908 days earlier)      last day (2265 days later) » 

00:00
he asked for indexes before and after as well as values, the link post just displays how to get value of said item
index**
 
1 hour later…
01:13
Do you know how to get the index for "bar"? If so, just subtract and add 1 to than value, respectively. — Martijn Pieters ♦ 1 hour ago
@coldspeed oh no I agree, but thats like me answering a question 'just do this, duh' it isnt usually well recieved
"just do this" (without the "duh") usually answers the question
tried that early aran called me out and I had a decent explanation, oh well in retrospect the question is of little importance
02:12
Hi, does anyone know how I could reduce the length of a string by a factor of 2, but keep the string in an undoable format, so that the string can be passed through an algorithm and the original string would be restored, I tried using RSA but that can't reduce its length
wat?
@JacobSchneider your question has lots of words but doesn't really explain what you want.
Sorry,
I basically need to get a string and cut it in half
which half?
but it must be lossless
so for example, the string abcd would become something of half that length
so you want to store the same data in half of the memory required by just plain characters?
02:15
yes
thank you that's it
sounds like you need to study information theory to see if that is even possible
and techniques for doing so
I know it sounds ridiculous, but I was wondering if there is at least a way of reducing the string length without using the compression algorithms that are used in 7zip or other software
reducing the length of data is the very definition of compression
yes, but I was wondering if there is another way instead of aaa becoming a3
you could always invent your own compression algorithm...but it's still a compression algorithm
02:21
that's actually what I'm getting at
but I want to compress it to the extreme
like I said, you need to study information theory
and existing compression algorithms
It's probably a good idea, but it was an Idea I had the other day
where you could compress a medium to such extremes that you could send it over the internet with ease
sounds like a good doctoral thesis
I just had an idea, you know how ASCII has 256 characters?
well, what if you store all possible combinations of 2 characters as a seperate table
so you just turn 2 characters into a number and reference the table
@Aran-Fey I have the same problem and I'm a native English-speaker.
@JacobSchneider What is the largest number you need to represent 2 characters?
02:32
65536 which is 16 bit
ASCII is 8 bit if I'm not mistaken
and how many bits do you need to store the two characters in normal ascii
16... damn it
so that doesn't seem to save any space.
not really
oops
I'm not trying to shoot your idea down. Instead I'm trying to illustrate the thought process and questions you need to ask in order to evaluate these ideas.
02:35
yes, I see. thank you
@vash_the_stampede Aran who? Oh you mean Rawing
@coldspeed aran-fey
lol is that his nickname
 
3 hours later…
05:32
@JacobSchneider Some pigeons want to have a brief word with you en.wikipedia.org/wiki/Pigeonhole_principle
05:50
@PM 2Ring Pigeon Hole Principle is nice
@Tyto So simple, but very useful.
@PM2Ring I'm going to pretend like I see the correspondence
even though I actually don't
@JacobSchneider The pigeonhole principle says that a compression scheme that can work on any data is impossible.
Okay
so
my idea of compression is a shit one cause it'll only work sometimes? do I understand this correctly?
I'm a little lost, i'll be honest
i believe that didn't need mentioning... haha
Say you want to compress 16 bit messages. There are 65536 different possible inputs, so with lossless compression we need 16 bits of output on average for each message, otherwise there won't be enough pigeonholes to hold all the messages.
05:58
Right!
so, a pigeon hole is one character in my message?
However, it is often practical to use lossless compression because the range of messages we need to compress is a small fraction of the total space of possible inputs.
@JacobSchneider No, a pigeonhole is a whole encoded message.
Guys
I need some help
but it has nothing to do with python
but i need smart pple
y@PM2Ring wow, okay
this is so stupid
@user2277747 I would recommend @PM2Ring
06:02
but im hopeless
that looked bad
any takers?
So if there are 65536 possible inputs then we need 65536 pigeoholes to store the outputs.
bruh ok
06:02
@PM2Ring Oh, I get it
The median annual household income was $39,000. Among five randomly selected U.S. households, find the probability that four or more have incomes exceeding $39,000 per year.
and she gives us this
Show work by writing out the individual probability formulas for P(X = x) and letting C(n,x) = "n choose x" since you will need to know it for exam questions.
If it's an exam, that's cheating
not an exam
yes sir
it makes no sense to me
06:05
sir, wow, that's the most formal anyone has spoken to me
I try to be respectful :)
That seems like an exam or weekly test question to me
Oh, good. Eg, if you compress sensible English text you can get a reasonable compression ratio because you don't need to compress totally random input bytes, and the possible sensible inputs of a given size is a small percentage of the total collection of possible byte sequences of the same size.
its not, its part of a study material
try to work on it @user2277747, u will get it...no rocket science though
06:06
teacher is really bad
i've been at it for two hours
and have no leads
anyone understand it or dumbfounded like me hehe
@PM2Ring by sensible english text did u mean similar type of data
@PM2Ring I understand the last bit of what you said, but lost you at the first part, because a regular compression takes care of repetition, the most repetition in the enligsh langugae is 2 letters and very rarely 3 but nothing more. so there wouldn't be much compression.
@user2277747 hold up, interpreting question ...
any suggestions or should i leave lol
06:10
no, I can try help
ooh cool thanks
do you understand what the question is getting at?
i think so
see if 4 out of 5 make 39k a year
@user2277747 Hmm. We do discuss other stuff apart from Python here. If you have a programming question relating to another language, that won't go down well, unless you disguise it so it sounds like you're talking about Python. ;) We do sometimes discuss general mathematical problems. But your homework problem is pretty specific, and would be more suitable in a room focused on statistics.
oh cool
but the statistic rooms are not as active i think
06:12
I just made a room

Maths talk

a private room between me and user2277747
@user2277747 Fair point. And we do have some statistics experts who hang out here...
i knew the python-ers would be the smart ones
they tend to be, that's kinda python's audience
We could turn your problem into a Python problem. Try to figure out the formulas you need to calculate that stuff. Then write a program that generates a whole bunch of random test data, with each set of data being 5 households, then count how many sets have 4 or more households that earn more than 39,000.
haha, yea, that'd be fun
06:17
i'd love to learn python one day
it's not that hard, it's a brilliant language
and huge application range
@user2277747 You could do the same thing in JavaScript.
@JacobSchneider I often write little stats programs like that if I can't figure out the algebra for a combinations problem. Once you see the pattern, it can give you clues for what the formula has to look like.
@PM2Ring yes learning that way really helps..
Oh yea, it's quite common for me to do that too, in fact i downloaded DORY onto my phone just so I could use it as a calculator
@user2277747 Ok. The median is 39k. So if you pick a house at random the odds are .5 that they're above the median. With me so far?
06:26
yea
because there are 2 possible states, greater and less than?
okay yea
@PM2Ring Still here lol?
@JacobSchneider Sorry, I got distracted. Simple repetition is important, but there's more to compression than that. Say if you had a file that only contained the words "america", "europe", "africa", "asia". Since there are only 4 possibilities we can encode each word with 2 bits.
@user2277747 Sorry, I'm a bit slow at typing on my phone.
@PM2Ring oh you're good
i guess the .5 makes sense for the question
but the question has a part 2
Consider a random sample of 16 U.S households for the next question
What is the probability of seeing at least 10 of the 16 households with annual incomes under $39,000?
@user2277747 So this is exactly the same as flipping 5 fair coins & finding the odds of getting 4 or 5 heads. Do you understand how to write the formula for that in terms of C(n, r)?
06:35
not really
@user2277747 Let's stick with part 1 for the moment.
@user2277747 Ok. Forget C(n, r) for now. What's the odds of getting 5 heads?
Bzzzt! Wrong. If you can toss 5 coins and get 5 heads half the time you do it, I want you to come to a casino with me. :D
06:40
lool
but
if you have a 50% chance of getting heads or tails
wouidn't it be 50% to get heads each time for the 5 times
Toss one coin, times in a row. It's the same thing, since coins have no memory, and don't tell each other how to flip.
I spent more time on this than I'd like to admit. But it was fun. I know jack about javascript and canvas so this was a little experiment. pirsquared.github.io/clocks/PirClock
4
@user2277747 Yes. So if we toss a coin 5 times, on the first toss we have odds of .5 of getting a heads. On the 2nd toss we have .5 of getting heads, so to get heads both times the odds are .5 × .5 = .25
ohhh
true
We have 4 equall likely sequences: TT, HT, TH, HH, so each sequence has probability .25
So for 3 coins, the odds of HHH = .5×.5×.5=.125=1/8
06:46
oh ok
i have to go, but thank you all for the help
And for 5 coins, it's 1/32 to get HHHHH
@user2277747 No worries. Good luck.
@piRSquared Very pretty! I haven't done any JS in ages. But I must admit that the HTML5 canvas is very good, one of the best graphics APIs I've ever used.
Yeah, it was fun and thx (-:
if you want even better canvas interaction, check out processing's p5 JS library. it's one of the most well thought out and all round libraries i've seen other than JQuery who'se purpose is different entirely, so yes, p5 is amazing.
but wow very nice clock there @piRSquared
p5 looks interesting... will read that as well. thx for the heads up.
np, use it extensively
@PM2Ring I see, that's a very good example
which is what Iwas trying earlier when I mentioned ASCII
07:00
Another option, especially if you want to to vector graphics in the browser, is to use SVG. It can do some pretty cool stuff, however some parts of the SVG spec were designed by a total lunatic. ;) But it can do some nice synchronized animation stuff, especially in combination with JS. The downside is that SVG is a XML format, but that's motly tolerable, compared to some usages of XML I've seen.
so you'd have a unique number for each combination but you then made me realise that that wasn't the best way to go as it didn't do anything
well SVG (XML) and HTML are each quite similar, so an XML document shouldn't be too different from a HTML one
I gotta say, your SVG sugestion has its upsides, but bitmaps are still not entirely obsolete, can you imagine the struggle of having to use vector graphics in game development? it would be mroe hassle than what it's worth, if you ask me
@JacobSchneider Well, you don't often get files that are that simple. :) But it was just a simple example to illustrate a principle that can actually be useful in more complex situations. A classic example is LZW compression, which is used in GIF. It's quite easy to write an LZW compressor / decompressor in Python that works on ASCII text & normally gives around 50% compression on reasonable sized chunks of sensible text.
LZW, I'll keep that in mind, thank you
I've heard of a number of algorithms, but not by name
@JacobSchneider Vector graphics & bitmaps each have their own uses, with not a lot of overlap. But it is nice when you can combine them to get the best of both worlds.
@JacobSchneider for text I'd use LZ4 now... super fast
07:08
LZ4
okay, that sounds professional
all have trade-offs but LZ4 is such that you can speed up reading text from SSD disks by lz4:ing all data and decompressing upon use
In the very early days, almost all graphics was vector graphics. We simply didn't have enough RAM to waste it on luxuries like bitmaps.
huh, that's something I wouldn't have expected
@JacobSchneider in C64 the computer had 64KiB memory
RAM
07:10
that's not nowhere near enough
i take it
a full screen bitmap at 160x200 pixels and fake 16 color display required 8 KiB memory
And 10 year before then, that would have been considered a lot of RAM on a mainframe.
@JacobSchneider and if you go to youtube and look at the demos that they achieved on such hardware, with 64K...
07:11
I I've been into that sort of stuff recently
I came across a book called Code
16 color display, 1 MHz micro
@AnttiHaapala A C64 did have bitmaps, but it mostly used sprites, and character mapping.
07:12
1 min ago, by Antti Haapala
a full screen bitmap at 160x200 pixels and fake 16 color display required 8 KiB memory
I remember using a vector graphics terminal in the mid 70s. It did its output via line drawing, it couldn't receive or display a bitmap. But it did have a light pen. :)
I wasn't around to have whitmessed the struggle
@AnttiHaapala I mentioned LZW because it's easy to understand, and a good intro for someone who wants to understand compression algorithms beyond simple RLE.
I think LZSS is easier
the actual reason I asked about compression algorithms is because I was coding yesterday and needed to look something up, but because it was like 10:00pm every single person was online, my brother streaming fortnite videos while playing and voicecalling the dude next door, and dad was watching netflix, so naturally, everything slowed to a crawl. so I was wondering how one could easily speed up internet download speeds, so I though about reducing the payload by compressing it
07:28
cbg
any by compressing the content down so far that you could ship gigabytes worth of data in several kilobytes
CBG?
video codecs is a fascinating and crazy topic
> you could ship gigabytes worth of data in several kilobytes
already happening
how do i sign up for this cause I kid you not, I was waititng for 10 minutes before google loaded
10 minutes
07:29
well, I'm not 100% sure on the numbers, but video compression reduces size by orders of magnitude
@JacobSchneider no.
@JacobSchneider what compression does is to increase the SNR.
it means you're sending less of the non-information.
you guys are throwing acronyms at me!!!
not that.
07:31
2 mins ago, by Arne
^ that link
@AnttiHaapala But only if it works. If you're unlucky, you end up sending more noise.
@Aran-Fey well, yes.
so I will present you a simple compression algorithm that will have quite good compression ratio...
Salad language???? jeez, the world of people with a lot of time on their hands!
so it is this: [64-bit number of leading zeroes omitted][the rest of the bytes]
07:33
*claps* Ingenious! :P
so if you have a file that contains 18446744073709551615 zero bytes, instead of spending 18446744073709551615 bytes, you can use 8 bytes with the 18446744073709551615 as binary...
so you're saying you look at the file in binary form?
2305843009213693951 compression ratio
and every repetition you replace with how often it's repeated
isn't that just a standard compression algorithm that you use to generate zip files?
07:35
No, you're thinking of run length encoding. Zip is a bit better than that.
I watched a few computerphile videos on compression and what he did was create essentially a dictionary so everytime a word, phrase or passage is repeated, you reference the dictionary. what's that called?
I am peas
hahaha
@JacobSchneider that's "dictionary encoding"
other interesting encodings for lossless compression are prefix codes, i.e. Huffman
and arithmetic compression/coding
@AnttiHaapala Maybe. The flag bits make it a little more complicated, IMHO. But I've never tried coding LZSS, so maybe I'm biased. ;)
@PM2Ring the simple thing is that it specs a ring buffer
so the decompression goes like this: "get flag bits", "for i in range(0, 8): if the bit is set the next 2 bytes are a ring buffer reference, if not set, then the next byte is as is"
and for compression you need to have a buffer of maximum 2 * 8 bytes that
And then you have stuff like Burrows-Wheeler en.m.wikipedia.org/wiki/Burrows%E2%80%93Wheeler_transform which transforms data to make it more amenable to RLE.
07:45
then PNG...
is special because it is for 2D bitmaps
repetition in 2 directions
PNG is unusual because it has a variety of compression techniques it can choose from, depending on the data. But IIRC, the final layer of the compression scheme is gzip.
Most PNG savers will quickly try a couple of options and select what looks like the best one for the data. But a PNG optimizer can try a lot more options, and test more extensively, so if you can afford the time you can reduce a typical PNG considerably.
I recently checked if it's worth compressing png files, and to my surprise all of the 3 algorithms I tried actually made pngs smaller:
.png:
   BZip2   : 0.9956473003183502%
   LZMA2   : 0.9887321534718748%
   ZLib    : 0.9906717000228896%
@Aran-Fey it can be because the ancillary chunks are not processed.
try with pngcrush first
07:52
Or optipng
hi folks :-)
whats wrong with this line?
plt.scatter(kepmagtoflux,avgflux,marker='+', c=lambda pc: if "c06" in filename: pc='k')
@zabop statement in lambda.
mumbo jumbo
yep, I think I know sth is wrong w the lambda part but idk what
And even if you could use statements in a lambda, the assignment pc='k' wouldn't do anything.
@zabop all of it. Your question lacks the MCVE including the information about what this should do if it were correct
07:55
According to the docs c should be a string or an iterable, not a function
hmmm
alright I do it another way
also, an assignment isn't an expression
and you can only put expressions in a lambda
I'll stick with the def stuff then
I can make that work
oh, that's literally the first thing Antti wrote. my brain skipped that line
thanks anyway :-)
07:56
np, happy to help repeat
it still doesn't make any sense... but you're welcome anyway...
@Arne ----ike this---
like this
editors should really find a uniform way for strikethrough
1% is nothing. It doesn't make sense to compress the outer chunk structure of a PNG. You want utilitiez to be able to determine that structure, and extract stuff like bitmap size, pixel depth, wheter it's palette mapped or true colour, without having to decompress it first. And you want to be able to customize the compression for the actual pixel data, you don't want to apply that compression to the non-pixel data as well.
The vast majority of the data in a png is pixel data though, isn't it? So 1% is way more than I expected
@Aran-Fey how big a png?
08:09
No idea. I literally compressed hundreds of pngs I had lying around, so I imagine the sizes were all over the place
Most of them seem to be about 200KB or somewhere around 1MB
I actually haven't found a single file format that doesn't get smaller when compressed, not even videos
08:25
@Aran-Fey If you want to reduce PNG size, and this isn't simply an exercise in investigating compressors, definitely take a look at optipng and pngcrush. They do a good job, and the resulting files are standard PNG, so you don't need to decompress them with a separate program to use them.
will do
They normally use lossless compression, but optipng can also do some colour quantization too, if you want. IIRC. :) And I think it can also convert 24 bit to palette mapped, if the total number of colours is small enough. But I'd have to check the docs...
With the default options, 10% reduction is common. 30% isn't unusual, especially if you tell it to go crazy checking compression option combinations.
I wish there was a (easy) way to automatically run every png that's created anywhere on the file system through those programs
08:41
@AnttiHaapala A year or so ago I wrote some code to investigate ANS, which is interesting, but I didn't bother writing a practical compressor / decompressor because it's a bit slow doing stuff like that in Python. And my code wouldn't easily translate to C because I was doing the arithmetic with Python integers.
08:54
cabbage
Done with graduation....
09:11
@Aran-Fey I guess you could have a process tha sits in the background that optimizes PNGs written to certain directories. It's not efficient to watch everything. And optimization takes time (& of course CPU cycles), so the amount of optimization really should depend on the intended use of the file.
A file that's going to sit on a Web site & be downloaded many times should be aggressively optimized. Files that are just going to sit on your hard drive & are rarely viewed can afford to waste a few bytes.
@Azazel Does that mean congratulations are in order? You don't sound very enthusiastic...
I'm annoyed that It took 6 months more than I had originally planned.
Better late than never!
@user2277747 please don't bring your python-unrelated maths problems here. It's inconsiderate and annoying
@JacobSchneider thanks for that
09:31
idiotic Flask-Admin :F
doesn't support multicolumn primary keys
Open an issue :P
@AndrasDeak Fair point. I allowed it because it's language-agnostic and the room was quiet. And I think it's good for coders to know basic probability stuff like that.
But I must admit that when he couldn't answer my question about tossing 5 coins and getting all heads I almost told him that he needs to go back to his text book, or his teacher.
@PM2Ring "it's good for coders to know basic probability stuff like that": I completely agree ;)
I've seen multiple cases of "hey here's my completely unrelated math problem, please solve it because matlab people are smart" in the matlab room, and it gets old real fast. Like going to the butcher shop hoping that the butcher can give you sudoku tips
@AndrasDeak Sure. You may have noticed that I didn't actually give him the answer to his problem on a silver platter. ;) But I couldn't resist the opportunity to give him a little guidance in figuring it out himself.
yeah, I saw
I'm probably weird in that I don't mind them actually getting help, I'm just annoyed by their trying to ask for it here
09:49
I don't mind conversations about general principles. IMHO, that's no different to Kevin talking about doing stuff with Bézier curves. But when it's a "give me the exact answer to this homework problem", that's a different story.
Good Morning :)
OTOH, I'm not as strictly anti-homework problem as SE.Physics. The rules there are really strict... maybe a bit too strict. I understand why we don't want to deluge the site with worked solutions to every problem in every single physics textbook, or to have to check every crummy solution to homework exercises. But surely there must be some middle ground.
no duplicates.
But I guess that's a topic for conversation in the h-bar...
10:05
@Mornon room rules
> Don't ask for answers to your recent Stack Overflow questions. Those who can answer are already watching the queue on the main site.
> If your question is eligible for a bounty (>= 48 hours old) and hasn't received a useful response, then you may link to it.
@PM2Ring in my opinion a regular doing off-topic things makes all the difference
@Mornon also, I read the question 3 times but I don't understand it. Please try rephrasing it.
I'll gladly talk stochastics with the regulars here, I just don't want people to try to use us as a general-purpose helpdesk
@AndrasDeak Fair enough. And although it's reasonable for regulars to get a little more leeway because (presumably) they know the limits and won't go overboard, OTOH, we don't want to be unfair in our application of the room rules and leave ourselves open to accusations of favouritism.
10:15
I'm more than happy to openly and officially give leeway to regulars when it comes to being off topic :P
I don't think there's anything wrong with that from a social perspective
it's the difference between, say, friends on a hiking trip ending up talking about non-hiking things such as crocheting, and someone else approaching the hiking group with knitting questions out of the blue
@AndrasDeak Once again, fair point.
To be fair, hiking sticks are basically just oversized knitting needles
knitting the earth itself #sodeep
10:31
Hi @antt
Hi @AnttiHaapala thank´s for your information.

What I want to know is how the status of me can be displayed in a log.

I have now completed this in an answer to you.
@Mornon that's not an answer, it's a comment (fortunately). But instead of leaving comments, edit your question with all relevant information
(moved the redundant comment copy)
@Mornon you can edit/delete messages for 2 minutes after posting, please use it. And there's no need to leave so many empty lines in your messages.
Years ago, in response to a question on xkcd, I wrote a Python program that generates crocheting patterns for crocheting a sphere, given the size of the circumference. The OP posted patterns for 2 or 3 different sizes, and I figured out how to generalise them.
But when I showed a pattern to my mother (who was a knitting & crochet expert) she said the pattern used non-standard notation, so it was hard for her to read. She was going to help me change it to a more normal notation, but we never got around to it.
@AndrasDeak thank´s for your information! i´m new here. so sorry!
No worries, just try to look around, read the local rules, the chat faq and help and similar resources like this to familiarize yourself with how chat works ;)
10:42
I'm pretty sure my crochet program works properly, but it would be nice to actually test it by getting someone to actually crochet a sphere with it. Unfortunately, the OP on xkcd was a newbie who disappeared. I guess I could go looking for a crocheting forum... or something on Facebook. But I've never been on Facebook, and have no intention of changing that.
Let's talk program architecture: As everyone probably knows by now, I'm working on a backup program. Since the program will be started many times with similar settings (which files should be backed up, where should they be backed up to, etc), I'm planning to make a BackupConfig class to encapsulate all of these settings and to dump them to disk for future use. But there's also some data that shouldn't be dumped to disk, like the password that's used to encrypt the backup.
So I'm thinking of making another class, say BackupContext, that only exists while a backup is in progress, to store this temporary data. Basically like this. Does that sound reasonable, or is there a better way to go about this?
@PM2Ring the wife crochets, but I don't know how confusing that notation of yours is :)
@Aran-Fey seems reasonable to me
Sometimes I wonder how these things would be implemented in other programming languages... without **kwargs and vars(self).update this'd be huge pain
that's why this is the productive programming cabbage
10:47
Which is why I was thinking that there might (must?) be a better way to do it
@AndrasDeak Ah! Your wife is also a mathematician, so she might be able to help me translate the notation to a more canonical form. :) The sphere pattern is fairly uniform, and only uses a very small number of stitch types.
I thought there were only a very small number of stitch types to begin with :D
like, single crochet, double crochet, chain and...that's it
@AndrasDeak Every time I remember that the Builder Pattern is actually used in real life I praise Guido for giving us a good programming language
@Aran-Fey proper OO patterns. Delegation and so on.
@Aran-Fey ConcreteBuilder. But what if you're building a wooden cottage?
10:51
@Aran-Fey you seem to misunderstand all the patterns deliberately
...deliberately?
Car (the factory) is a car builder... if you do not actually confuse it with Car the type
there is nothing to be gained by not understanding what the GoF patterns are about
and how to realize them in Python without writing more classes...
@AndrasDeak This pattern only uses treble, and of course chain to get it started. The only complication is how the row length increase or decrease, which requires connecting 2 stitches in the current row to 1 in the previous when increasing. And I think that's the part of the notation that my mum said was weird.
I'm pretty sure I haven't heard of a treble before. I'll ask her later if I don't forget
@AnttiHaapala It's not the kind of builder that the builder pattern is referring to though, is it? Wikipedia lists "Requires creating a separate ConcreteBuilder for each different type of product." and "Requires the builder classes to be mutable." as two disadvantages, neither of which is true in python
10:57
@Aran-Fey Does BackupConfig save a hash of the password? Or do you not bother with that, and just attempt to use the password and catch the exception if it fails?
now find one on intellipaat ;)
@PM2Ring I don't save a hash of the password, but I do have a mechanism that validates the password. I store a small encrypted chunk of data that I test the password against
remember that each file must use a separate IV
I know, thanks :)
11:02
@AndrasDeak Thanks. It might be a double rather than a treble. :) That would actually make more sense geometrically. I wrote this code 10 years ago, so I'm a bit hazy on the details.
just to be clear this is not criticism, merely a statement of my ignorance in the art of crocheting :D
@AnttiHaapala I'm only 3 paragraphs in, but the sentence "Functions are objects, first class objects (whatever that means)." is already getting me worried
I sure hope this guy knows what that means
@AndrasDeak I don't know much either. I can do chain stitch, though. :D I learned to knit when I was a kid, but mum always had to help me cast on & off. And I haven't done any knitting since then. It's pretty yamming boring if you have to concentrate on it. It's ok if you've learned to do it well enough so you can do it on autopilot while watching TV.
FWIW, mum was taught to knit by her dad, who was a carpenter by trade, and a general all-round handyman. Her mum didn't have the patience to be a good teacher. :)
11:19
I do saddle stitch
My step-dad's mum was a prolific knitter, who kept the family supplied with excellent jumpers. But I didn't fully appreciate them at the time. :( I thought they were the poor person's alternative to "proper" machine-knitted clothes. What an idiot...
I'm just hand stitching, it's kind of discouraging though it fulfills needs programming doesn't ... madidos.files.wordpress.com/2017/01/wp-1484400369912.jpg
right...though to be fair when growing up, you probably didn't wear the jumpers for long ... kids are like weeds growing up so fast
@Mirv Pretty neat. The only creative stuff I do these days apart from coding is cooking. And I don't often get very creative with that. :)
Sorry about the triple ping. I'm getting tired & my typing & reading accuracy is deteriorating...
@AnttiHaapala Sorry, I didn't really get much out of that article. I still don't think that python has anything equivalent to a builder in the sense of the builder pattern. We have factories, yes - but not builders.
I only saw one - so it's all good.
11:32
My grandpa could estimate the size of a piece of timber by eye accurate to 1/8 inch. And calculate the area of a board in his head accurate to 1/64 square inch. Not bad for a bloke who had to leave school at the end of 6th grade because he was needed on the family farm.
I have a question regarding several IP's that I have to call in a test.

The structure is as follows:

SSH on Switch 1
SSH on switch 2

My current source connects only to a switch
My current source connects only to a switch

def setUp(self):

self.s = testcore.control.ssh.SSH(host = '172.23.56.xxx', username='admin',
password='admin',
type_of_dut='ecos')



logger.info('self.s = testcore.control.ssh.SSH')
self.s.query_interactive=True

did anyone have a ideo how to change this source up to a second IP?
11:49
I think you want to generate parametrized tests? (The IP address would be the parameter)
@Aran-Fey yes!
@Mornon Shouldn't you be working on making a MCVE for that question on the main site that you linked here an hour ago? If you don't do that, it will be very hard for anyone to give you a useful answer, so the question may be closed.

« first day (2908 days earlier)      last day (2265 days later) »