« first day (1370 days earlier)      last day (3576 days later) » 

12:33 AM
hai
can somebody review this query?
-1
Q: Game of hog in Python

overexchangeBelow is the problem statement for Hog: In Hog, two players alternate turns trying to reach 100 points first. On each turn, the current player chooses some number of dice to roll, up to 10. She scores the sum of the dice outcomes, unless any of the dice come up a 1 (Pig out), in which case sh...

 
 
4 hours later…
4:56 AM
Cbg all
 
cbg all
 
Wotcha :-)
 
How's it going @Zero? Not seen you in a few days.
 
Not so bad :-) I've been here, on and off, just not saying much.
 
5:14 AM
CBG!
I see why people here don't use mechanize. You can do the same with requests and if it has a hidden from element just scrape it and send it in the post request
 
cbg all
 
Hola tila :-)
 
:- ) hola zero
 
5:33 AM
Hola tila :)
BTW which language is "hola"
This is how google defines it LOL!
In E. coli and other bacteria, holA is a gene that encodes the delta subunit of DNA polymerase III.
SPANISH interesting!
 
Hola Ufoguy!!: )
 
I was just thinking about asking a question here. I just googled it and got the answer
In case you want to know I was using this code
r = requests.get(url)
soup =BeautifulSoup(r.text)
event = soup.find(id="__EVENTVALIDATION")
I got this result when I printed event
<input id="__EVENTVALIDATION" name="__EVENTVALIDATION" type="hidden" value="/wEdAAPCY022rExX4zv1NcZFKbiIAmIy8Djh+8G+Gc0nRFml0PghyNihoa4DpHvw24QeCw09rXArGrDzBUUKxDLpJhDCAdLDXQ=="/>
I wanted to know how to get the value
I googled how to get value in beautifulsoup
And got the answer. All thanks to you guys I know how to google and not be a lazy asshole
Now I do
print event["value"]
and get only the value
 
@Ufoguy Congratulations :-)
 
@ZeroPiraeus Thanks. I also got some help from this book which I'm proud to say is written by an Indian amazon.com/Getting-Started-Beautiful-Soup-Vineeth/dp/1783289554
Ffisegydd thanks for being harsh on me when you should've been
 
5:50 AM
The official docs are also good ... in fact, the way they're laid out. they make a decent tutorial.
 
You're welcome, I will continue to be harsh when I need to be. I don't like doing it at all, but if it pays off then I can accept not liking it.
:P
Whenever I read the news I get the sudden urge to emigrate >.<
 
Without wanting to sound too much like an old codger, it seems to me that the post-facebook generation is much more likely to ask for the answer than search for it, even though the internet makes finding information much easier than it's ever been, and (to me at least) the satisfaction of finding out for yourself is worth more than getting a quick fix. I'm not altogether sure whether SO is a force pushing in one direction or the other, tbh.
Any news in particular?
 
Britain are looking to stop listening to the European Court of Human Rights.
 
Ah.
Bloody foreigners ;-)
 
This whole "Eurosceptic" stance in general really.
 
6:01 AM
Come to Chile - we've got telescopes :-) (dunno / can't remember what kind of physicist you are, but hey, telescopes are cool)
 
Telescopes are cool, unfortunately I'm at the other end of the spectrum.
And I'm not staying in Physics anyway.
 
Well, we've probably also got microscopes ;-)
So, which direction are you going (away from Physics)?
 
I'm tempted to go into data analysis/programming/etc
Need to start researching jobs really.
Leaving academia completely :P
 
I was completely unsuited temperamentally for academia, but the idea of being Emeritus Professor of Something has always sort of appealed to me, I must admit. I would cultivate a Reg Chronotis-like persona.
 
6:12 AM
I always wanted to go into academia but since doing my PhD...well...not a conversation for a public place but lets say I was convinced otherwise.
 
@vaultah oof, not fun.
 
Lazy people need a kick in the butt to be motivated. In case you didn't know yet I'm lazy
Caffine helps too
 
Properly applied, laziness is a virtue :-)
 
@ZeroPiraeus I guess that is why we RAD dev tools like Python and Jquery
And requests too. It's like urllib2 for lazy people
 
urllib2 for non-masochists, at least ;-)
 
6:19 AM
I had to google masochists. zlol!
 
@Ffisegydd goddammit I am now utterly intrigued by your "not a conversation for a public place" comment. "I was convinced otherwise" sounds almost Corleonesque.
 
@Zero RO board?
 
@Ffisegydd Ah ...
 
I'll live.
It's not just him. I've also seen the reality of academia too and it's not a good thing.
After 7 years at university I would have to spend another 6-9 years working in different places for 2-3 years at a time, never settling down.
For a small amount of money.
Before I could even consider applying for a lecturers job (the bottom of the ladder)
Then if you want to be successful and rise in the ranks you have to put weekends and evenings in so you can get above your peers.
There are more important things in life.
Speaking of that, rbrb.
 
TTFN :-)
 
6:46 AM
BTW do I get a green card if I marry a homeless person in America
Or any other English speaking country
This is my evil plan for migrating to another country. Don't know if it will work
Tired of being stuck in India
 
No idea how it works in the US ... the UK has spent the past umpteen years erecting barriers to immigration though, and from anecdotal evidence I understand that they look very hard at conveniently-timed marriages.
A better bet might be to get a spectacularly good degree, then hired by a UK company that can plausibly claim they need you and no-one else.
 
They should be taking a look at arranged marriages in India. Both look at each others photos. See how much money they've got and get married and sleep right that day. Every marriage is like strangers sleeping together
 
I know an Indian here in Santiago who lived in the US for a while, actually ... I don't see him often, but if I remember, I'll ask how it was for him.
 
I think that arranged marriage is like prostitution. I hate it and for that reason I'm never gonna get married in India
If you ask someone out on a date they'll beat the heck out of you and file a sexual harrasment complaint
 
The idea of someone other than me deciding who I marry is alien to me, yeah.
 
6:55 AM
Seen many people victimised by this on quora.com
Even your parents will look at you like you're a sex offender if you ask someone on a date
Forced marriages and honor killings are also common here
@ZeroPiraeus
 
Will look at that tomorrow (3AM here, don't want to wake flatmates and can't be bothered to find earphones).
 
Ok. The news title says Man forced to marry girlfriend
 
In fact ... I should probably go to bed, thinking about it.
Hasta mañana ... rbrb
 
Bye!
 
7:24 AM
cbg
 
CBG @Mirac7
 
what's up @Ufoguy
 
Just chilling though I'm looking for simple scarping jobs on odesk.com @Mirac7
 
Cbg :)
 
cbg
 
8:16 AM
cabbage, guys
and girls, if any are present?
 
@holdenweb I've never seen a girl in this room
 
8:41 AM
You must definitely have, you just didn't know they were female :)
 
There used to be a badgergirl
>>> x = float("nan") >>> x == x False >>> [x] == [x] True >>>
 
I understand why float('nan') == float('nan') returns False but not sure why the lists return True
 
Another one
.@dabeaz >>> d = {float("nan"): 42} >>> d[float("nan")] Traceback... KeyError: nan >>> d[float("nan")] = 25 >>> d {nan: 42, nan: 25}
 
I think that one makes sense.
Kinda.
 
9:16 AM
It's called a Quokka. It lives in Australia, is endangered, & considered one of the happiest animals on Earth http://t.co/cXkve3KUhy
 
blog.stackoverflow.com/2014/07/… is very interesting from about 25 minutes onwards
Talks about using machine learning for looking for interesting questions and answers.
We must steal their ideas for Nidaba...
 
someone here who is using raspberry pi at the moment, can't seem to figure out why it is so slow.
 
9:32 AM
Amazing... Above podcast around 34 minute mark. "There's also tags that are bad. php. Even if you're asking a php question you should not tag it as such..." Java too...
cbg @Jon
 
cbg
@Ffisegydd STEWIE!!!!!!!!!!!!!
 
@Jon BRIIIIIIIAN!
 
cbg too
 
cbg @tila
 
user559633
morning :)
 
9:46 AM
anyone working on raspi ?
 
user559633
I can't stand FGIW "here's a placeholder copy/paste in the general area, then i'll edit that answer so i'll still have the oldest timestamp"
 
user559633
@tilaprimera i have in the past, but it was far too slow to use for anything other than small services or as a toy
 
why are there still only two dozen words in salad language
 
If we have too many they'll get lost/unused.
A lot of them are already rarely used.
Plus there's only so many fruit/veg...
 
user559633
@Mirac7 because it's a little joke. We don't need declensions
 
9:49 AM
@tristan i have been using it for image processing and the camera's framerate is pretty rude....:/
 
user559633
I wasn't aware there was a camera. are you using this? adafruit.com/products/1367
 
yea that is the one
 
user559633
interesting. i wouldn't expect much from the onboard cpu -- i assume the rasp pi is under serious load?
 
the matter is that, i have set a certain framerate for the camera's video capture, and i need to use opencv, and seems the conversion of jpeg frame to opencv object is pretty slow, and causing randomness......in the frame captures........ :D more like, i have set the framerate to 24 fps and 24 frames is being received in 6 seconds, after conversio
something like that, the conversion is taking one hell of raspi's time.
 
user559633
what are your load averages?
 
9:57 AM
load average: 0.16, 0.06, 0.13
 
user559633
smaller than i expected if it's running the capture right now
 
11:28 AM
I will link again stackoverflow.com/questions/24617561/…, for I am benevolent, since 50 points bounty will go to waste in 2h if there is no satisfying answer
 
I was under the impression that there was a 24hr grace period after the end of the bounty to actually award it
 
I have no idea. But can you award it to any answer or does the answer has to be given within the original deadline?
 
erm, not entirely sure, sorry
 
6
Q: Bounty grace period - no answers - award it to who exactly?

WidorThe bounty I offered on this question is now in its grace period and the information box tells me: you must award this bounty as soon as possible But there are no answers - what do I do?

 
11:33 AM
You do get 24 hours before under some conditions, half of it may be automatically awarded... but you can award it to any answer present at the time
bonjour @Kevin
 
Bonjour, ma jaune chien
 
cbg @Martijn
 
12:29 PM
I feel like this should be closed, but I'm not sure of the reason. Didn't we used to have "this question is unlikely to be helpful to anyone else"?
 
cbg
 
you would usually downvote for not being useful (that's the tooltip when you hover over the down arrow)
I guess it could be said to be too broad
 
If anything, it's not broad enough. He needs special-snowflake help for his unique problem.
 
though I would close it as being off topic
the general description of off-topic actually
 
Tis gone.
 
12:34 PM
I feel like people that say, "email me the answer to this question" don't really get what the site is about.
 
guys, why is this necessary when changing the position from which to continue playing music in pygame
pygame.mixer.music.stop()
pygame.mixer.music.play(0,0)
time.sleep(0.1)
pygame.mixer.music.stop()
pygame.mixer.music.play(0,float((x-256))/640.0*tracklength)
 
recode.net/2014/07/17/… 15% of M$ staff being cut. 18,000 people...
 
@Kevin did you see that meta question about someone being phoned regarding an answer? :)
 
o.o
 
Yeah
 
12:42 PM
That would have freaked me out :)
 
@Mirac7 Why is what necessary?
 
if i don't use play(0,0), it won't go to correct position in the song, if i don't use time.sleep before stopping it, i'll get access violation
i have to stop it, reset it to 0, wait, stop it again and then set it to position i want
 
Sounds like a bug you should report to the pygame people
although I have a feeling they'll pass the buck to the SDL people
 
it's weird that without time.sleep, pythonw process keeps crashing saying stuff like Unhandled exception at 0x65F41535 (smpeg.dll) in pythonw.exe: 0xC0000005: Access violation reading location 0xFFFFFFF0.
note that dll name is not the same every time
 
cbg folks!
 
12:47 PM
cbg
 
Complete speculation: I bet it's a threading issue. you call play which sends a request to the sound playing thread, which says, "ok, it will take me 100 milliseconds to begin playing". Then, 1 millisecond later, you ask it to stop playing, but since it hasn't finished its song-starting procedure, it gets confused and crashes.
 
A less likely theory than @Kevin's... you need better music?
 
Sound in general gives me a lot of trouble in pygame. Half the time my sound effects come out at 10% the usual volume, with no apparent cause.
 
and i'm using pygame only to play music in the background here...
 
heya @Ahmad
 
12:51 PM
cbg bcg
how's it going?
 
yep... python interpreter reset itself when running this:
>>> def func(*args):
	pygame.mixer.init()
	pygame.mixer.music.load("C:/Users/Mirano/Desktop/demo_v4.mp3")
	pygame.mixer.music.play(0,20)
	pygame.mixer.music.stop()
	pygame.mixer.music.play(0,10)
 
wrote a new answer, is it good ?
0
A: tkinter case insensitive bind

Walle CyrilYou must bind twice in your case but you don't need to think about it once you write a clever function. Let's define a function that does this for us. def bind_(widget, before="", letter="", callback=None): widget.bind('<{}-{}>'.format(before,letter.upper()), callback) widget.bind('<{}-{}>...

 
What should the user do if he wants to bind q and Q? not ctrl-Q, just Q.
 
Yeah the function could be better I think
 
you defined function bind_ but used bind_all_?
 
12:53 PM
specifying before="" in the paramaters won't be enough, because then you're binding to "-Q", which isn't valid (I think)
 
brb...
 
Are there more arguments that can be passed to bind than just what you've given? *args and **kwargs for example?
 
I got a part time job in a small research company, could hardly come over here It's killing me :'(
 
D:
 
as far as i know, arguments are sequence, func and add
 
12:55 PM
Give me five minutes I write a better more polyvalent answer
 
Work is kinda exciting tho :)
 
@KDawG you've missed all the fun! davidism has been a busy bee...
 
@Ffisegydd Woah he made it? freakin AWESOME!!!! :D
 
Not finished yet, and not "live"
But it's looking pretty sweet.
 
@Ffisegydd Can confirm that sweetness :)
 
12:59 PM
By the way , I accidentally removed Cabbage from sopy.davidism.com/salad/# because I didn't knew I could really remove,(I thought it would ask for some password before you know)
 
...Monster...
 
facepalm
 
It's fine, it's not live. We'll probably make adding/deleting words not open to the public but some form of role.
 
@Ffisegydd So it was a local remove ?
 
No it has happened for all users
But that website is still being developed
So don't worry about it as we still have sopython.com
When it goes live (i.e. when sopython is hosting that Flask app) it'll only be allowed to certain users with certain roles.
 
So yeah turns out machine learning is really complicated...
 
@Ffisegydd well... the first step of the SkyNet project code named @MartijnPieters worked out okay
We just forgot to include an off switch :)
 
Did you see what I said earlier about the podcast? SO have already implented a Nidiba-esque system in the background and will be starting to look at flagging things automatically.
 
I noticed that
We shall beat them to it! cough
 
cabbage to all!
 
1:31 PM
cbg @Peter
 
wow.. this feels so strange... my new keyboard just arrived.. and I wanted to switch to ANSI layout..
 
Is it that Logitech one you linked the other day?
 
although it seems okay.. it is super strange;)
nope, but also a mechanical keyboard
 
Ooo, I remember having those
They're making a come back I guess
 
one of the ANSI layouts or the mechanical ones?
 
1:32 PM
Get yourself a wheel based mouse... the full retro experience (the mechanical ones)
 
I wanted the XT Stealth (with the side/front prints) but it is not available in europe because of legal issues
but I designed my own one, and will order it from WASD someday
@JonClements I haven't use mouse like 10+ years ago
I have a huge WACOM tablet and a small touchpad
it is way more relaxing using those
 
DSM
Morning cabbage to all.
 
cbg
 
@DSM cbg
 
@Ffisegydd That podcast has some great ideas, very timely. Vowpal Wabbit looks cool but complicated.
 
1:39 PM
wb @davidism
 
Yeah I'm just reading up on that, also been looking at scikit-learn as well.
 
cbg
 
DSM
scikit-learn is fun, although performance/memory isn't all it could be.
 
One thing that did occur to me is that the data dump will not have deleted questions so we may struggle to teach a model to look for deletable questions.
 
there's also nltk
 
1:40 PM
@Ffisegydd there's where the live capturing comes in
 
@WalleCyril Don't worry, it's all a demo, everyone can do everything right now.
 
@Jon yeah it'll just take time to adjust as more results come in I think (with my zero experience in machine learning.Unfortunately due to 7 years of Physics I have the tendency to arbitrarily judge other fields that I have no experience in and yes there is a related xkcd).
 
@Ffisegydd LOL
 
It can't be helped. All my friends are the same.
 
@wim: anything missing still? Or did you accidentally double-click the 'accept' mark?
 
1:44 PM
I, too, get the occasional bout of "how hard could it possibly be?"
 
(I don't say it out loud, though, in case the gods of irony are listening)
 
2.7 only unfortunately but maybe it can be 2to3'd
 
DSM
If you at-symbol someone who isn't in the room, do they get a message in their inbox?
 
the value i am getting is of type _ctypes.CFeild, and when i try variable.value it gives error that _ctypes.CField has no attribute value, I am sure that value is ctypes.c_uint32.. so wanting to convert that into int — oh_dear_i_love_coding 21 mins ago
I don't get it..
 
1:46 PM
@DSM yes I believe so. It used to happen to Soviero when his name was still Kevin.
 
@DSM only if they've been in the room recently
 
He came in one Monday and shouted at us because he had a few dozen notifications for The Real Kevin.
 
DSM
Wait, Kevin is Soviero?!
Ohhh, wait. I get it now.
Sorry, took a second. I thought you were saying that The Real Kevin changed his name from Soviero to avoid accidental messages.
 
should I buy a new computer?
 
No that would be silly. Kevin has always been here. When Joel and Jeff first launched SO they found him waiting for people to ask questions.
 
1:52 PM
All apparent Kevins are just the 3d cross-sections of a single four dimensional hyperKevin as it intersects our universe.
 
That looks like some camel case there...you're dangerously close to a lynching...
Crow's got the rope already.
 
The names of higher dimensional beings are always vaguely heretical.
 
@DSM oh btw I don't know if you followed the thread or not, but it turned out it wasn't a bug in the clang compiler.. however it is a not very well documented "feature", which can be guessed, if you are following other rules (although I still believe the exact reason we have generics as a special macro keyword is to ignore some rules..)
 
DSM
@PeterVaro: the whole thing hurt my brain, TBH. :^)
 
okay, okay, I just thought I will inform you about the updates ;)
@Kevin have you watched the very last episode of IT Crowd yet?
 
1:59 PM
Yes, I enjoyed it :-)
 
i think it was a super ending
 
I loved the lampshading in the scene where they're about to unveil their line of pepper spray, that looks like a perfume bottle. "think: is there something obvious we're missing that could backfire?" "... No, I think we're good"
 
a little bit longer than it should be
but it was brilliant too
@Kevin that was my favourite part too
and actually the beginning, you know, the coffee making scene
 
Yeah
I was annoyed at Moss for spilling the secret of women's trousers on his web series. I expected Reynholm to show up in a later scene and throttle him with his robot hand. "you betrayed me!!!" kind of thing.
 
2:05 PM
Nice to see them get a happy ending, though
 
yeah -- have you watched any of the ends of scrubs, chuck or friends?
 
DSM
[Mental note: combine natural language processing, machine learning, and greasemonkey to make an automatic spoiler protection tool.]
 
Scrubs yes, Friends maybe but I forget, Chuck no
 
wim
@MartijnPieters nothing missing, I just am in the habit of waiting 24 hrs to allow for any other helpful answers which may or may not come along
 
I love those series.. but for some reason, the writers thought: if it good bye, then it has to be a REAL goodbye
 
2:06 PM
@wim Sure, good policy.
The accept-immediate-unaccept threw me, that's all.
 
@DSM I won't spoil anything
 
And I have seen it happen that someone double-clicked. :-)
 
@Kevin both 3 were super sad.. I don't want to watch any of those last episodes again
 
@PeterVaro I've seen the end of Friends and Scrubs. Of course by the end of Scrubs I mean the true end at the end of the 8th season. They never made a 9th.
 
@PeterVaro As I recall, it was literal in the case of Scrubs. Bill Lawrence plays the janitor that says good night to JD.
 
2:09 PM
@Ffisegydd +100000000
cannot agree more
i didn't even start it..
 
I watched 3 episodes of the not-Scrubs and then said "Nah that's enough of that..."
 
@Kevin hmm..
 
I've never watched an episode of Not-Scrubs. I know a finale when I see one.
On the other hand, I continued watching Futurama after the first finale, and the second.
 
Too broad
The OP is looking for general advice on how to figure out a problem for which they cannot post the code.
@Ffisegydd Thanks, b*sterd.
Now I have to live with that unresolved tension all day.
 
2:21 PM
:)
 
DSM
I prefer to think of it as hopeful and open-ended, rather than unresolved.
 
and there's the matching right paren.
 
DSM
@Kevin: heh.
 
so, when sites have that kinda glossy, blurry overlay on a picture, how do they achieve that?
 
I bet there's some slick HTML5 CSS tag like mozilla-blur: true or something
 
2:23 PM
@Kevin and it worth every single minute of it, doesn't?
 
I don't know why it would start with mozilla. That just seems to be the style for fancy effects.
 
:D incidentally it always annoys me when people use smileys inside parentheses and then don't match them up (and relevant xkcd)
 
@Ffisegydd omg I love it
although I prefer (this syntax:) as it is easier to write..
 
user559633
i encapsulate with brackets. it's not hard. [see? ;)]
 
Russians typically use only parentheses. Like this ))))
Hate that
 
2:24 PM
@PeterVaro the later seasons had some misses for me, but the hits were as strong as ever till the end.
 
I hate when people use it like this (:
it is a common tradition in hugary..
 
Yeah same though I don't mind D: too much
 
user559633
@vaultah my girlfriend will use both and if i've been coding all day, it hurts my brain. e.g. :) )))
 
Yeah, D: is the only emoticon I'll use with eyes on the right
 
C:
 
DSM
2:26 PM
The streams are crossing. I just got the message error: unterminated function-like macro invocation -- due to a missing right parenthesis.
 
I don't use these ones
 
I was using :-I before awkward situation seal was cool.
 
@Kevin something like this: riotdesign.eu/en
 
@Crow for that webpage that's an effect of the photograph itself
 
omg.. instant get..
 
2:30 PM
Hey, it's another page with that Web 2.0 parallax background effect.
Much trendy.
 
Known as depth of field.
 
the client wants trendy, I shall not question her
 
You could possibly photoshop it in
@Crow amateurphotographer.co.uk/how-to/tech-explained/536453/… as I said you could possibly photoshop it in, but it's a physical thing due to the aperture of the camera and the focusing distance.
 
man. I suck at photography
 
It's much easier to get with photographs of things close up
 
2:33 PM
Photography rules
 
I love photography. I should do more of it but can't find the time anymore.
 
@PeterVaro somehow creepy
 
I just don't get photography :\ I like cinematography though, which is a little hypocritical
 
it is.. but I always wanted a robot like that..
and actually I really love the design of this one (the physical part the UI is a crap atm)
 
> Jibo is a platform, so its capabilities will keep expanding.
Market speak translation: "it can't do much yet, but we're hoping third parties will contribute software that people will find actually useful"
 
2:35 PM
nice.. super nice actually..
although it reminds me of Her a bit.. what if he will evolve too fast?
 
Did they mention that it can learn at all?
 
Only our weaknesses.
 
;)
@Kevin nope, but if it will be community driven, then it will learn a lot
and will learn fast -- but I know how you meant it..
 
Perhaps in the same sense that the Project Gutenberg database knows a lot about 19th century literature.
If you're worried about a Skynet scenario, I'd suggest not worrying about this guy specifically; he's as likely to rise up against humanity as any other computer system.
 
Hm. I'm trying to put my design goggles on. What's the "pretty" way to display a file path in a GUI? It's a tiny window and it gets super resized when the file path goes from "None" to "C:\file0\file1\file2..."
and re: parenthesis in text... yeah. ))))))))))
well eastern european text at least
 
2:50 PM
Can you not keep your window size the same size but simply show the last N characters of the file name?
Then have it so the user can scroll backwards (towards C:) if necessary?
 
oh that's a really good idea
 
It's more important to show the far end (with the actual file name) than it is to show the directories I think
 

« first day (1370 days earlier)      last day (3576 days later) »