« first day (1785 days earlier)      last day (3166 days later) » 

12:02 AM
Using the uploading feature here. You may not have enough reputation yet.
 
yes. I don't have enough points. Don't expect to ever have.
Alaxender, I have doctor appointments in 30 minutes. Are you anywhere close because u have to head out in 10 mins. Thanks a lot again.
Can you share your code, how you achieved the above using rowspan? Coz i did that via table in table
 
ok, python.
What's up?
 
Cbg @AaronHall
 
I haven't seen you guys all day.
 
@AjGauravdeep try this out dpaste.com/0V18REM
haven't got an environment to test on (on a chromebook), but might just work
 
12:13 AM
And @AjGauravdeep, here's the code:
http://pastebin.com/J6j2uk88

This won't work well, I just re-wrote your exact code so it would be readable to me.
 
Basically - don't embed a new table, just make first two cells in row 1 have rowspan = '5'
 
I think @JRichardSnape is right
 
I don't hear that very often :)
 
I think he is right too. Sorry, I'm restructuring code so I put like 20 seconds to look at the code.
And I hear it a lot :D
 
@AjGauravdeep your problem relates to html ... most people are not familliar with dominate ... your problem is logic and not necessarily specific to dominate... therefor of coarse people want to see code that they can copy and paste and run .... to help figure out your issue ...
 
12:15 AM
Note - Alexander's tidying up repeated code is nice - just I wanted to change as little as possible from your original. If it works, let me know and I'll post it on the main site
@AaronHall Hi Aaron.
 
Alaxender. Your code has few bugs. I am running late. Let me fix that after i come back. Thanks again.
fixed them and checking now
it works perfectly. Please paste an di will accept it. thanks again for all your time and help.
Running late to Doc...
 
Is that mine, or Alexander's?
 
I think yours @JRichardSnape :D I just restructured it.
 
I understand that if you want to do functional programming with Ruby you need to write functions as lambdas and call them with .call() - lame.
I'm sure I used to know that, but I looked it up again today.
 
hmm ok well the first thing i see wrong with that is ruby :P
 
12:25 AM
Yep, I kinda think Ruby is a crap language, um... no offense, Matz. Matz doesn't take offense because Matz is nice
waits for unittests to run again
It's like the compile step for Python. Did I break it?
 
I don't get why any language thinks forcing object-oriented design is a good idea: at least it has prototyping right?
 
Splain that statement.
 
@AjGauravdeep posted
oh, he's gone. hey ho.
 
So in JS, you can do something like:

Class A(object):
    pass

b = A()
b.method = lambda: 1

c = A()
# c has no method "method"

b.prototype.newmethod = lambda: 3

c.newmethod()
3

(Obviously, this has been done with Python syntax)
 
class A(object): pass

b = A()
b.method = lambda: 1
c = A()
# c has no method "method"
type(b).newmethod = lambda: 3
c.newmethod()
3
I didn't test it, obviously.
 
Fastest shredder in the west.
 
@AaronHall, ooh that is awesome. I did not know type(instance) could be used to prototype :D.
 
ok, just tested it, lambda needs to take self as an arg
It's not prototyping, it's monkey patching. no, it's not that either.
type(b) returns the instance, b's, class.
it's like saying
A.newmethod = lambda self: 3
or
A.newmethod = staticmethod(lambda: 3)
But just stick it in the class definition, or perhaps extend A.
 
Yeah. Just in JS it's called prototyping because each instance has a __proto__ attribute which is shared among all class instances and the .prototype modifies the same __proto__ attribute.
 
This claims to implement it for Python: github.com/airportyh/prototype.py/blob/master/doc.py
 
12:50 AM
How do I remove using underscores for formatting?
 
put code in backticks `__proto__`
 
YW.
 
Thanks davidism and Aaron :D
 
I'm sometimes precognitive. Plus I can read minds half the time, given even odds.
Yeah, it is monkey patching.
Anyways, avoid it if possible. Use only when you're 100% sure it's necessary.
 
Yeah, pretty similar principles. I typically avoid it in Python, in JS, it's pretty standard though.
 
1:02 AM
There's some good Python answers on it, if you google it. I could link, but that's self-promotional. :D
 
Feel free :D (I don't mind, I like to learn)
 
Nope, self-imposed rule.
 
xD First link I see.
 
@AaronHall, think of a number between 1 and 50.
 
Probably better to subclass the object and do it that way for testing.
#python on freenode, right Cyphase? ok, 44.
 
1:14 AM
You're not supposed to tell me :/.
 
heh
 
And yea, I'm cyphase there as well.
 
would this count? 39.787775687116863
 
 
2 hours later…
3:06 AM
What part of "You're not supposed to tell me" did you not understand?
 
python3 -c 'for i in {1,3,5,7}: print("{}-{}".format(i,hash(i)))' [21:39:12]
1-1
3-3
5-5
7-7
I thought hashes were supposed to have some amount of randomness in python3?
 
3:25 AM
@NightShadeQueen I think the randomization was designed for strings. See PEP 0456.
 
3:45 AM
Morning all
 
Evening, vaultah :)
 
:p
 
 
2 hours later…
6:05 AM
Hey up all
 
6:32 AM
 
6:45 AM
Hi
anyone have used tweepy API with ajax?
I get
Internal Server Error - 500
when I import tweety
 
 
2 hours later…
8:35 AM
@tristan best of British!
 
Morning all
 
Morning @JRichardSnape
 
Did my first ever embedded HTML code snippet on SO last night. D'ya reckon that qualifies me for the title full stack developer :D
 
8:50 AM
Heh
 
9:31 AM
CBG

from collections import deque
d = deque()
d.extend('abc')
print d #Output deque(['a', 'b', 'c'])
d.extendleft('xyz')
print d #Output deque(['z', 'y', 'x', 'a', 'b', 'c'])

I saw the in python docs that extend left reverses the input order and then extend ... Was wondering why is reversing needed!?Is there any special purpose for this reversing operation?
 
9:50 AM
Cbg @vineet. To format a code block in a chat message, select all of it abd press Ctrl-k to indent
 
cbg all
 
Cbg :)
 
@VineetKumarDoshi that will certainly help if you link to those docs.
 
10:11 AM
@bereal https://docs.python.org/2/library/collections.html#collections.deque.maxlen

See the example's bottom most code.
 
 
2 hours later…
12:22 PM
Chicken, ham, and leek pie. Banging.
 
good morning
 
Cabaga Cbagi Cabbaga!! :P Cbg
 
:)
have you ever used a python game engine?
 
I havent
The only game I ever made using python was using import Turtle :D
 
hehe
what kind of software do you write with python?
 
12:34 PM
I create competitive coding tutorials and challenges of python on HackerRank.com (Part-time)

Don't really use it for something. Still looking for jobs to use my python skills :)
 
:D
never knew about this site, thanks!
 
is it very high level? or suitable for beginners?
 
tutorials are for beginners but contests are for all levels.

https://www.hackerrank.com/contests/pythonist2/challenges

You can try out these challenges ... they have challenges for all range of coders :)
 
cbg all
@JRichardSnape Whence came this myth that the text of a reply had to be selected for CTRL/K to work? For me it's always operated on the whole content of the message no matter what was selected
 
12:40 PM
cbg!
thanks @VineetKumarDoshi I just signed up
 
I still have to get a book on Python :D
 
Programming Python by Lutz is good.
Assuming you have prior programming experience
Otherwise do an online tutorial
 
Edx intoductory course on Python ... is just awesome!! .. and in-depth! ... Its is good for beginners :)
 
@Ffisegydd I am coming from Ruby. Okay thanks I will look at this
Ideally I would prefer something where you build programs throughout, instead of just plain syntax..
 
12:49 PM
Yeah ... edx gives projects ... but if you want to learn by making super cool games ... then must learn interactive python course offered by RICE UNIVERSITY on coursera :)
 
Cabbage
 
cbg PM 2Ring :)
 
@JonathanMusso to be honest, python has very good documentation and an excellent community. As such, I doubt you need a book.
 
^ I agree with @Ffisegydd
 
@Ffisegydd the book you recommend looks great, seems that you get to build tools for many different areas of the system.
 
12:51 PM
Just run a quick tutorial to learn the basic syntax then read blogs/examples for specific areas you're interested in.
 
Migration from Ruby to Python is not that tough ... in my opinion :)
 
We have a room regular who is a ruby programmer. He loves it and hasn't struggled at all.
Not sure he's in at the moment, unfortunately.
 
What Ffisegydd said. If you haven't done so already, please read the official Python tutorial. It's not designed for total beginners - it's aimed at people who already have some programming experience.
 
Np, I actually started to learn Python many years ago..but since took a turn from programming. Looking forward to learning it now.
 
The official Python tutorial isn't the sort of thing where you build a program, but it does have lots of little illustrative examples that you can run & experiment with.
 
12:56 PM
Make sure you know what Python version you want learn before learning :D

2 and 3 have lots of differences ...
 
Another benefit of working through the official tutorial is that most competent Python programmers are also familiar with that tutorial, which gives us a common starting point.
 
Wonderful, thanks guys, I will start with the official tutorial then on Ubuntu.
 
These days, there's not really a good reason for someone starting on Python to learn Python 2, unless you need to use 3rd party libraries that are locked into Python 2. It's better to learn Python 3 first, and then once you're confident with your Python skills you can learn how Python 3 differs from Python 2.
 
Ok, I plan to start with 3 yes.
If I look back at my old books it was all pre Python 3.
 
1:18 PM
cbg
@JonathanMusso Python 3.
@JonathanMusso and beware that @PM2Ring still uses Python 2.6, he's the lone dissident :D
 
Haha @AnttiHaapala thanks :d I will use Python 3.
 
But note that even though I still use Python 2 I was encouraging Jonathan to learn Python 3. :)
 
I have found a few cool books that I am interested in after the Python docs :D
 
yes, but I preach that which I do ;)
frankly many books that I've glimpsed are quite appalling :D
 
do you guys recommend that I use Linux? Currently I am on my Win10 tablet (Surface Pro)
 
1:22 PM
I would, but I am a bit biased :D
if you know programming well, you should watch some youtube, there are plenty of amazing conf talks about some advanced python features
that you'd mostly not come across in a book
 
Alright, just more comfy on the couch you know xD I will check out YT for sure, never really used it for programming before.
 
this one you can read from your surface.
the keyword for good YT experience is to search for "pycon" or "europython" or so :D
 
1:40 PM
google search .. learningpythonthehardway :D may help
 
Many of the people who regularly answer Python questions on SO are not big fans of Learn Python the Hard Way. Apart from the author's rabid anti-Python 3 stance, we've seen too many questions on SO from LPTHW students who have similar bad habits and have weird ideas about Python. Presumably, they got those bad habits & wrong ideas from LPTHW... And they tend to post huge slabs of code about their text-based adventure game code that's not doing what they want...
Just double-checking: set(generator_expression) doesn't build an intermediate list, does it?
I'm 99.99% sure it doesn't, but I don't like to make claims like that when I can't back it up with a link to some official docs. Re: this question
 
guy Zed A. Shaw is mostly known for being a rubyist... :d
@PM2Ring woot what's happenign there
 
2:02 PM
@AnttiHaapala I'm not quite sure. But I'm almost certain that xrange(n) being instantiated into a list is not responsible for what the OP's seeing. :)
 
and unutbu is not really helpful there either despite upvotes
 
No. He sounds like he knows what he's talking about, and he's usually pretty good. But I think he's speculating a bit in that answer.
 
OTOH, I'm not sufficiently an expert in this topic to take unutbu to task, or to write a better answer.
 
i am installing that profiler
because I do not know what values it is reporting
anw unutbu is wrong in that there'd be 10 sets, of course there is no 10 sets
 
2:12 PM
@AnttiHaapala Agreed. At any time while reduce is running there will be at most 3 sets: the old accum_value, the current set created by (set(xrange(p, n, 10)), and their union, which will become the new accum_value.
 
yeah he's wrong ofc, but...
 
2:33 PM
@holdenweb oops, just shows the myths I can promulgate simply because I've always done it that way. My mistake.
@pm2 looks suspiciously like memory is accumulating across tests there, I.e. would you get the same if you started with test 3...
 
6
Q: Memory usage: creating one big set vs merging many small sets

usual meI used the %memit magic function to measure memory usage: In [1]: %memit n = pow(10, 7); range(n) peak memory: 568 MiB, increment: 272 MiB In [2]: %memit n = pow(10, 7); set(xrange(n)) peak memory: 824 MiB, increment: 447 MiB Ok so there seems to be an intermediate step where xrange(n) is ins...

 
@JRichardSnape He's not saving any of these sets, so they should get garbage collected. OTOH, just because Python's reclaimed the memory that doesn't mean that it's returned it to the OS.
As I said yesterday:
@JoeSmart: Bear in mind that when a Python object is freed its memory is returned to Python's memory arenas, it's not returned to the OS. Those memory arenas may be released to the OS, but not necessarily. See python - memory not being given back to kernel and the link on that page: Why doesn't Python release the memory when I delete a large object?. — PM 2Ring yesterday
 
@PM2Ring answered
unutbus answer is all bullshit
 
@AnttiHaapala Thanks, looks great (diveintopython)
 
@AnttiHaapala ALTVOR! :)
At Last, The Voice Of Reason.
 
2:45 PM
lol
@PM2Ring hmm this is very surprising behaviour
set.union(set(), *[xrange(p, n, 10) for p in range(10)])
the rv is 250 MiB
In [9]: result = set.union(set(), *[set(xrange(p, n, 10)) for p in range(10)])

In [10]: sys.getsizeof(result)
Out[10]: 268435688
like this, and still 250MiB
like this, and still 250MiB
 
3:03 PM
Hmmm. So why isn't the second way using more memory for the hash tables in the list of sets it's making...
 
hmm frankly this is beyond my interest :D
the 0.9 union 0.1 there just triggers some pathological behaviour / gets over some boundary...
 
3:14 PM
@AnttiHaapala Fair enough. I'm not that interested either. :) But I'm glad that you posted that answer and clarified a few points.
 
3:27 PM
I have been following a strategy of mostly looking at questions that are a couple of days old, because I'm not quick enough to compete with the people hovering over every incoming question, and because the askers have mostly lost interest in the ones that are months old. This means that nobody but the asker is around to see my answer, and apparently there is a badge for that.
 
Necromancers!
 
Nah, I have a badge for that too. But these questions are not dead yet!
 
Which badge?
I'm too lazy to look :P
Alright, I'm going to leave in thirty seconds. Don't look at my answer on this question:
105
Q: How Did Stack Overflow Help You?

bluefeetAs we continue the celebration of 10 million questions on Stack Overflow, we want to give away more stuff! We’ve already received some awesome stories about users going above and beyond for others, but before we give away more swag we need something from you. We want some stories about how Sta...

I will run away...
Bye peeps
 
This badge is for questions that are just resting.
 
@PatrickMaupin If you wish to join the hallowed ranks of the Unsung Heroes, I recommend concentrating on questions from 1 rep newbies, since they don't have enough rep to cast votes. It worked for me. :)
 
3:38 PM
Maybe you missed where I said I just got the badge... :)
 
@PM2Ring Really, I just answered questions, and then one day I discovered I had a gold badge and freaked out :/
 
@PatrickMaupin They're pining for the fjords.
@PatrickMaupin Yes, I missed that bit. :)
 
Actually, I didn't say it -- I just linked to my userID showing the badge...
It's my first gold one -- presents a conundrum. The people who understand don't care, and the people who care don't understand :)
 
It's nice to have gold, though. Although it'd be even nicer if more of those newbies went back after they'd earned some rep & upvoted those answers...
 
@PatrickMaupin is good for unsung hero
 
3:43 PM
Ah, I see you only got Unsung Hero 10 hours ago. Congratulations!
 
@PM2Ring yes...
but all current good mallocs actually use mmap for larger objects.
something like 500M area for a set is certainly mmapped and not from sbrk, so it'd be fully released
 
That's good to know.
Rhubarb
 
4:01 PM
@AnttiHaapala That probably would have been the best reason to learn PHP. Oh, well, just got the badge, don't need no PHP :)
 
4:19 PM
cbg all
 
cbg
Python 3 all installed, ready to dive in :) Keep y'all posted.
 
cbg, Jon.
 
@Jonathan enjoy the adventure :p
 
cbg
 
cbg, Bhargav
 
4:27 PM
cbg Patrick
How to flag that profile ^
 
@JonClements Why thanks =) It's been about 10 years since I have looked at Python.
Pretty stoked now that I have been back working with computers.
 
@BhargavRao Hmmm, doesn't look like your other picture :-)
 
Wow... you'll find it's changed quite a lot :)
 
@PatrickMaupin Edited that :P
 
Well... the only post they had made was spam and was community spam deleted... I've nuked the account now - thanks
 
4:31 PM
Ty, @Jon. But how do we report those stuff?
 
They look ready to... program... to me!
 
Pat, Better remove that asap. :D
 
Iffy at best for the room @Patrick...
as ^^^ @BhargavRao says :p
@BhargavRao the tricky thing is, if they don't have any posts to flag... you errr, can't do anything
 
People around me will think that I am watching NSFW :(
 
Huh, won't let me delete it. I'll just flag it.
Ah, somebody else did it. Thanks -- sorry for the trouble. Didn't know it would show up so big.
 
4:35 PM
Why worry when puppy's here!
@JonClements [feature-request] :D But as Martijn puts, it is useless to flag such stuff
 
@JonClements Yes I bet there are lots of differences. If I remember correctly the most I did was build a simple sprite based game with PyGame many years ago. Heh
 
@JonClements level 1000 God zapped the spammy profile, yay.
@PM2Ring I got an upvote for my answer. So did unutbu :D
 
@Antti and while doing so, also discover that @Patrick has an interesting picture collection somewhere :p
 
wish there would be a thing that the upvotes would have additional weight of 1 for each 1 rep to the upgrader
 
Thank you @bhargav-rao, you're faster than me with Google. For some reason I couldn't find that post... — Robotit 34 secs ago
 
4:45 PM
@JonClements hem?
 
Fastest Googler in the West
@AnttiHaapala You're a RO! You shouldn't be asking that :P
 
@JonClements Years ago when I was working on graphics drivers, I explained in a meeting to my boss that skin tones were the hardest to get right, but fortunately I had a great set of pictures to test with. This was at DEC, and even back in the 90s they had cutesy names for their reeducation programs, so he said "Better be careful, Pat, or I might need to send you to 'Valuing diversity'". Of course, I replied, "Oh, but I do value diversity! Why else would I have so many pictures?"
 
Excellent :)
Um.... your rep gaining is going okay... only a couple of days since you had 3k isn't it?
 
My rep has hit the flat patch since I hit 15k.
I've lost a bit of interest to answer :(
 
@BhargavRao look at my curves :D
it is the logit alright?
 
4:52 PM
I know that month @Antti when you went hyper :D
 
I have moments where I think I should answer something but, that's extremely rare
 
@BhargavRao "my medication is better now" ;)
3
 
The fastest rep gainer right now is cyphase, I think...
 
I was the top repgainer for 3 days :D
 
4:55 PM
Let me get to my final semester. I will kick start Operation 20k
 
I hope no one reading the logs publicly do not get wrong my joke on medication,
or on cross-dressing for that matter :d
 
^ Some one take a pic of that and upload it on Twitter with the hashtag #AnttigoesHyper
 
Going to a Python meetup today, just for an excuse to force myself to work on Shanty.
It's a "Saturday study group" meetup, taking bets on how many school assignments there are.
 
Nice... :)
 
@AnttiHaapala Let me restate my case. Because people can effectively collect interest on old posts, I think you almost have to look at rep growth logarithmically. Cyphase has slowed down (I think he just got a contract), but still, look at the graph
 
4:58 PM
@PatrickMaupin Even this
 
@davidism well, as long as you don't end up with hangman, tic-tac-toe, towers of hanoi, or reversing a string or, implementing a basic calculator etc... :p
 
@BhargavRao For some reason, I thought he'd been around longer. Yeah, that's impressive.
 
@PatrickMaupin 40 to 23k in 1 quarter. :D
 
@AnttiHaapala Did you copy your curve from here?
 
yes
@PatrickMaupin cyphase is now #61. Percentagewise possibly the fastest growth however.
 
5:04 PM
BTW anyone got any delv-votes? 6 questions left
 
cbg, Tristan! Jon can leave now that you're here to protect the rest of the room from me.
 
user559633
cbg @PatrickMaupin :)
 
@tristan haha... keep an eye on that @Patrick - he's got an "image collection" on the go :p
 
Hehe @Jon Pin your message so that all ROs can see Patrick's image collection :D
 
aww... That'd just be too nasty to Mr Maupin :)
 
5:20 PM
Well, if you want to do it, I'm sure I can find some much better pictures than that one!
 
@BhargavRao 2 more questions, 2 more votes
 
I need moar delv-votes
 
Umm.... right... just need to head scratch over using the Amazon Product API...
@BhargavRao get more rep then! :p
 
Do you have a link where they explain [delv-votes]?
 
I need to get to 20k :(
 
5:23 PM
@BhargavRao I think it's, you get 5 at 10k, then one more per 1k up until 30 votes
 
Then I need to get to 35k asap :P
@vaultah 2 more 1 each \o/
 
@BhargavRao yes you do... so get cracking! :p
 
Yeah. Just waiting for this [penultimate] semester to get over. So that I can devote my whole time to SO
 
Whole time? Err, wouldn't go that far :)
 
I basically have no job next semester :P
 
5:57 PM
rbrb all
 
rbrb vaul
 
6:13 PM
rbrb
 
[fdisk] burninated \o/
 
In Quake II there were prisoners who would whine "kill me", "it hurts" etc. That's what some of those cv-pls questions remind me.
 
Ok, let's give it a nice Kevorkian.
 
I was told, you get that function removed after 10k.
 
6:49 PM
@bereal lol
 
7:10 PM
1
Q: What is the correct way to mix feature sparse matrices with sklearn?

ml_guyThe other day I was dealing with a machine learning task that required to extract several types of feature matrices. I save this feature matrices as numpy arrays in disk in order to later use them in some estimator (this was a classification task). After all, when I wanted to use all the features...

 
7:23 PM
cbg
 
user559633
7:51 PM
dupe stackoverflow.com/questions/32416986/… the dupe that he already asked is in my comment
 
8:29 PM
Reacting to the title does not lead to constructive comments.
0
Q: What is needed for curses in Python 3.4 on Windows7?

PaebbelsI have a running Python 2.7/3.4 installation on my Windows 7 (x64) machine. I would like to test curses on Windows. Curses is installed but not working: >>> import curses Traceback (most recent call last): File "<stdin>", line 1, in <module> File "C:\Tools\Python3.4.2\lib\curses\__init__.py...

Answers:
* Using Python on Windows makes me curse.
3
* Dropping a hammer on your foot? Python and Windows optional
Any more?
 
lol...
confused seek= with skip=, and now my MBR is overwritten by zeroes, yay.
 
DSM
Few hours of work cabbage for all.
 
8:51 PM
that feeling... when you go to #ubuntu in freenode
and ask for some MBR magic and realize no one understands your question.
 
user559633
9:43 PM
"Nothing, Windows7 brings all it needs to make you curse"
 
10:17 PM
cbg Steve
Not convinced over Amazon's Product API... returns different results than via its own web search... makes it rather frustrating to test properly
 
10:31 PM
hi guys, could any of you tell me how to launch the IPython shell?
 
11:06 PM
Hi, if im building an app that has its own virtualenv, should i link that python in Bin to Aptana when writing my code?
 

« first day (1785 days earlier)      last day (3166 days later) »