« first day (2815 days earlier)      last day (2358 days later) » 

00:46
I just answered a fun combinatorial question. My code seems to work ok for smallish data sets, but it might take a while, and chew up a lot of RAM, on larger data sets. :) stackoverflow.com/questions/51117776/…
That's an impressive answer!
01:21
@user3483203 Thanks! Some of the code's a bit messy, and I guess I could have used more meaningful variable names in a few places, but hopefully the accompanying text cuts through some of the confusion. :)
 
3 hours later…
04:28
cbg
05:27
cbg
@AndrasDeak Thanks man!
06:27
Hey there
can anyone please help me on this stackoverflow.com/questions/51120555/…
I'm trying estimator = SVR(kernel='poly').fit(X_train, y_train) but doesn't seem to work too
Hello. Unfortunately, the room rules discourage linking to recent questions. You should wait 48 hours + before linking to a question you've asked
oh is it.
first post in the room
anyways, any help on the post will be useful
07:35
@greenarrow welcome, we have some room guidelines / rules here - sopython.com/chatroom
headache-because-slept-less-because-chess cbg
08:20
@greenarrow add all relevant code (like the line you posted here) and relevant libraries (imports!) into your question. You already have some data so it's close to an MCVE
Also consider switching to python 3 for a modern programming language. 3.7 is just out.
08:38
are you unable to open the link? @AndrasDeak
08:50
Say guys, if I took 2 hours to write a detailed answer for someone and he ended up calling me a drivel-copying fanboy that doesn't understand anything (apparently he wasn't any less rude to the other people who also answered to his question). What shall I do?
@Bharel ignore and flag the comment
I mean, the answer can well fit the question. Shall I just post a Q&A with my answer?
@greenarrow no, but you posted another line of code here
@Bharel why not just post the answer there?
@AndrasDeak I'm just afraid the answer will be deleted together with his rude comments and question
And the question can really help people.
That's a risk, but you've already done the work, right?
08:55
@AndrasDeak I guess I did, but I can open it as Q&A and hopefully it will help someone no?
I'm not sure what you're asking exactly
just because OP is a jerk their question may be helpful
@AndrasDeak if it's ok if I'll open the same question and post my answer there.
asking the same question is a strict "no"
@AndrasDeak airtighty. Thanks mate :-)
no problem :)
if the original gets deleted you can go ahead
09:10
Happy maple leaf day, @DSM and @idjaw ;)
09:23
TIL the UK flag lacks mirror symmetry and thus has a "right side up"
cbg, all
Cbg, and belated happy birthday :)
10:02
@greenarrow Oh for yam's sake start reading. You were told twice that asking for help on new questions here is frowned upon, and I clearly told you that I don't have any problems reading your question (why would I?!), but you were missing information there that you wrote here. I figured two message trashings and a kick would convey the message. Well if at first you don't succeed
I've got all day
10:18
if num1 >= 10 or (num2 != 20) or (num3 != 30):
            return "not ok"
@neoDev yes?
@greenarrow instead of flagging my message you should follow my suggestion and start reading what people tell you when you ask for help
something is not working as expected
@neoDev please elaborate :)
my goal is to return "not ok" for numbers smaller or equal to 10
you are checking for numbers larger or equal than 10
10:20
but do an exception for 20 and 30
yes
and you're checking 3 different variables: num1, num2, num3
yep
I already told you that my OP is the query. I again said that in extension to what I posted there, I also tried SVM method. But it didn't work too.
so yes, it doesn't work as expected, but your expectations may be off ;)
There's no way where you can kick anyone out the group
10:21
@greenarrow OK
If we are doing this. What's the use of stackoverflow then
can you help me on the OP?
@AndrasDeak can you help me figure this out pls?
do I have to use not() instead?
@neoDev sure, but what you want and what you're doing seem to contradict each other. You said you want to print "not OK" for numbers smaller than or equal to 10, but you're testing for numbers larger than or equal to 10 in your code to print "not OK"
if num1 >= 10 or not(num2 == 20) or  not(num3 == 30):
    return "not ok"
???
instead of guessing you need to think first
10:24
oh yes sorry. correct.. GREATHER
also not is not a function, so you usually don't parenthesize it
ok so it's an operator
sorry i'm new to this
it's OK, and that was only a style remark
so my 2nd example will work?
10:25
ahah ok
why??
your original should work if you really want "greater than or equal to 10" if you put num1 instead of num2 or num3...or there's some info missing from your description of the problem
Why are there 3 different variables in your if statement? You said you want to check if a variable is smaller than 10. What's with the other 2 variables?
ops.. I did a mistake
i need do exception for 2 and 3!
not 20 and 30
does that mean you've found the problem?
it's hard to cjeck i'll try it anyway
I just wonder if syntax is correct
10:27
yes, syntax is correct, but it may not do what you want
ok thanks
try to put together a small example, write out some cases on paper and check
if the syntax is wrong, python will tell you by raising a SyntaxError
yes clever idea! :)
@AndrasDeak so I understand better my problem now:
i have only num1 and num2
num1 >= 10 or
num2 == 2000000 or num2 == 3000000
now I wonder how I can put them on one line
with parentheses around the latter two
huh?
10:40
or num2 in [2000000,3000000]
am I missing something? What's wrong with num1 >= 10 or num2 == 2000000 or num2 == 3000000?
oh, maybe I am :P
three ors don't need parens
you see, even coffee isn't fool-proof
good, good. I thought I might need some coffee again for a minute there
thanks :p
@AndrasDeak oh :(
10:46
FWIW my latest commit was adding parentheses around A and B or C for clarity/safety
that's a good commit.
hello,
iam new in python and i want to access python documentation in eclipse,
i familiar in java as for any function i have to press ctrl+space and it shows the help menu but here iam not getting it
i searched over the net and it says help(module name)
dir(module name)
@Fawkes those are to be used in an interactive shell, and also there's great online documentation for many libs. This is more of an Eclipse configuration problem I think
I don't use eclipse but googling "eclipse python help" seems relevant
11:01
@AndrasDeak not sure if I wanna close that as dupe of a question that asks how to get both the values and the indices
@Aran-Fey thanks, I didn't notice that, I'll read again from laptop
It might be a suitable dupe; I don't know enough numpy to judge how different the solutions would have to be
Yeah, I know. Probably not that much: values are a single indexing step from indices
I'm sure there are a dozen other dupes, I'll find a better one
Sometimes I wish iterators had more convenience functions. Why can't I do some_iterator[4]? :/
what is some_iterator[3] after?
11:07
Same as list(some_iterator)[3], except it doesn't advance the iterator past the 4th element
so it automatically caches consumed elements?
unfortunately half the code is irrelevant to the question/answer
I guess you just indirectly answered my question: 'cause it's not obvious how it should behave
rhubarb for a while
I wouldn't have expected any caching; I'd just discard the first 3 elements
@AndrasDeak I think the first one was better, since the OP wants the values, not the indices. But really, I probably shouldn't stick my nose into numpy questions
11:24
OK, thanks :) FWIW the new answer is ~same as the accepted on the first dupe IIRC
11:36
It finally happened... I have a metaclass conflict in real code. Wonder if I can rewrite one of them to be a normal class...
@coldspeed Thank a lot
12:23
Why thank you. Had a brilliant one!
how can I get current datetime in the folowing format:
20180701 16:31
@holdenweb glad to hear that :)
@neoDev google strftime
yes i found module datetime
So you have the answer
12:43
got this but it's not leading zero :(
import datetime
now = datetime.datetime.now()
print("{}{}{} {}:{}".format(
    now.year,
    now.month,
    now.day,
    now.hour,
    now.minute
))
How about what I suggested? Does that not help?
that's very confusing
can you suggest a simple solution pls?
Is it.
I suggest reading the docs docs.python.org/3/library/…
ok thanks
If it's confusing, it'll probably help to find some examples to look at
12:54
Which "google strftime" would likely cover with a bit of tweaking at worst
 
6 hours later…
unclear; closed
I need 20k
that's fine, I'll put it out there anyway. stackoverflow.com/questions/51126092/… no roomba
19:32
I just realized that my first comment on this question got deleted, probably when I closed it as dupe
And vaultah's "Possible duplicate" comment is still there
did it have a Q&A link?
Nope, no links whatsoever
vaultah's comment isn't possible duplicate, then again I'd expect it to be auto-removed anyway
Hmm, I don't think it should get auto-removed without a link
what was it about?
perhaps it got flagged
Something about how I found it shady that the question got 3 upvotes within 1 minute
Oh, then it simply got flagged :D
I suggest flagging the question instead :P
19:36
People sure flag a lot of weird stuff
yup, and even more nowadays in the age of welcomingness
19:56
I flagged a question recently for "Fat shaming and anti-fat bias in code", didn't expect it to be declined
But it was
nice
perhaps Poe's Law
Well, reverse Poe's Law, in that they may have taken your flag as a joke
I'd like to see what happens when Twitter gets a hint that body-positivity isn't on Stack Overflow's "To Enforce" list
20:38
Jan 15 '17 at 2:26, by Andras Deak
In case anybody else is into casual "flash" games, I stumbled onto a puzzle called Mine of Sight which is loosely based on the logics of minesweeper. I found it really entertaining (controls can be changed so that right click flags a mine)
just rediscovered this ^
21:17
@vaultah come to think about it, that may be worth asking on meta
21:35
@vaultah how was it engaging in "Fat shaming and anti-fat bias in code"
@vaultah also is that like some kind of passive aggressive threat to the ether, its not an ultimatum if you're throwing it to people who have no power on that end
The Welcoming happened because of Twitter
@vaultah not sure what that even is?
also MartijnPieters and your icon seammlessly transition into one another when they are next to each other
except for the seam
@Skyler this
21:51
Well SO is definitely not very welcoming to anyone but experienced coders. Bringing creed and color into it seems a little silly for a community where nobody knows the other's identity
cabbage
But you thicken your skin, get used to those first few downvotes for asking your question like an idiot, and then get a useful answer
Cbg
hahaha!
and it makes it all worth it
21:52
I got three downvotes on my first question just because I didn't post the complete question!
Because users will see the (incomplete) question immediately and will downvote it implying that urgent action is needed
@Skyler I could disagree there, but generally yes it helps.
I netted only 5 up votes in the first 10 questions
and i think a good few of those were negative back then
until i did clean up
I netted two upvoted dupe question
I almost got banned from asking, I stopped asking and started answering.
I am definitely an answerer. I always inspect my question hoping that it gets approved before I can consider asking it.
Recently I asked this Java question: Is there any problems or points that require editing? stackoverflow.com/questions/51126879/…
@Skyler did you edit your negatively-voted questions?
21:59
I did, and sometimes others beat me to the punch. Still see a few chastizing comments sitting for a few bad practices I did
hahaha!
I even flagged my first negatively voted question.
also your question seems fine
and ugh... for as much trouble as django is I prefer it so much to this wordpress project im working on now
yea, I dont see anything obviously and apparently wrong
Thanks. I just want my questions pre-approved and upvoted.
22:05
scratch "and upvoted" from your list
we can help with pre-approving python questions
Thanks. So that no questions end up as duplicate?
I don't understand the question
I was merely saying that you shouldn't post anything here to get upvotes, and that Java questions aren't exactly up our alley
Okay. I am just talking with Skyler regarding early negatively-voted questions
Sometimes I like to reduce my questions on sites to a final single bolded one line question or a 2-3 part list
to really drive whats bugging me home
22:08
That's kind of what an MCVE is about. If the problem can be reduced that much, it should.
We don't want hard to debug and unclear messy code
it's partly that (doing all the work you can to help those who help you for free), and partly that reducing your problem to an MCVE will make you solve it yourself in 95% of cases
Oh you are one of the users with more downvotes than upvotes. Do you usually downvote questions of questionable quality?
Always.
And I also vote to close. But if it seems salvageable I usually keep them open for a while and see if OP improves
Sure. rhubarbs - I will come back around 30 min
22:20
voting is not about punishing users, it's about controling quality
rbrb
22:42
back
 
1 hour later…
23:45
cbg

« first day (2815 days earlier)      last day (2358 days later) »