« first day (3437 days earlier)      last day (1735 days later) » 

00:03
Hi, I popped over from the Ruby chat to ask a meta-ish question. Do you know if there's any SO policy about job ads in chat? Does this room have a policy? I've got a user that has a Ruby job opening, and I'm wondering whether it's appropriate/allowed for them to post a link to the job opening in the Ruby channel. I'll search/ask on meta, but thought I'd ask here first because you're a sensible bunch.
@WayneConrad I saw someone do this on a different SE's main chat room. I don't think anyone started sharpening their pitchforks because of it
Then again they were a regular, so they had probably have a bit more leeway
The Ruby chat is pretty much dead these days, so it's not like one ad a year is going to overwhelm it. Given that job ads have been tolerated in the wild, I think I'll allow it. Thanks for the assist.
00:29
@WayneConrad nothing official, although unsolicited job ads might be seen as spam. We specifically don't like job adverts here, but I'm not sure it's anything official.
I don't think anyone will object if the room owners are OK with it
00:51
@WayneConrad my non-mod opinion is that when a post you don't like scrolls off the screen it may as well have never been made. I don't have a moderator opinion on this.
But I might push back and suggest they switch to Python. :)
@AaronHall Haha! I wouldn't fight that. Python is a mighty fine language.
Thanks for the additional feedback.
@WayneConrad stackoverflow does have jobs so you might point them at that. a surprising number of users are completely oblivious to the existence of chat
AMC
AMC
01:07
Hello! Does anyone know of a canonical question/answer for the seemingly common problem of people trying to parse a website using tools like Requests + Beautifulsoup, but can't find the data/elements they want because the content is dynamically generated?
01:22
what are the most import pandas Series methods?
to_numpy ;)
 
3 hours later…
04:27
Following this is giving me pygame.error: Unknown pixel format. Does anyone know why this might be happening?
Also here.
04:57
maybe you're passing in the (width, height) tuple wrong
are you saying their demo code is broken?
@Todd Seems to be the case.
The tuple seems right.
i would doubt their demo was broken.. might be how you have the setup configured.
I copy-pasted the code and it's giving me that error. Weird.
I also did pip3 install --upgrade pygame pycairo.
Might be an endian issue.
Weird. Kinda seems to work with cairo.FORMAT_ARGB32 on the cairo end and 'RGBA' on the pygame end.
But the R and B channels seem to be flipped.
"from BGRA to RGBA to BGRA"
Heh.
06:22
@AaronHall off the top of my head, the shift, ffill and backfill ones are pretty potent ones that numpy doesn't easily offer substitues for. In terms of important though, i suppose the more common ones like sum, mean, etc fit the bill, but they aren't as interesting. also, the str accessor methods are pretty nifty.
recbg
could always send a message to the owner of the git repo for that project @user76284
well.. maybe github doesn't have messages.. but you might be able to open an issue, or if they have a wiki page...
@roganjosh Depends on context. If you progressively sum a lot of floats of different magnitudes and different signs (alternating sum), without sorting them into order of increasing magnitude, you get rounding errors, and they get propagated. Eventually it will matter.
Kahan summation significantly reduces the numerical error in the total obtained by adding a sequence of finite-precision floating-point numbers, compared to the obvious (as-written) approach. This is done by keeping a separate running compensation (a variable to accumulate small errors).
06:39
@JonClements yes, sure. Sorry, got sidetracked yesterday. I'll reply to your message shortly
@smci I can't remember the example off the top of my head but I get the feeling that the errors accumulated much more rapidly than my intuition would have suggested. Even if I've imagined the example, I've at least got the correct message from it :)
@MisterMiyagi my clock has the same problem!
 
2 hours later…
08:18
cbg
 
2 hours later…
10:34
Hey folks for doing calculations with adjacency matrices (e.g exponentiation of a probabilistic adjacency matrix to find the probability of reaching each destinstion after n hops), should I use numpy.matrix or .array? (or networkx?)
numpy.matrix is being discouraged by numpy itself now, they're probably trying to get rid of it. that reason alone might be worth dropping that off
not sure about array vs networkx though im afraid.
@smci never matrix. I'd go the long way of using an array + np.linalg.matrix_power (or some non-numpy library, if available)
I don't know if other matrix functions (e.g. log) behave "well" for the matrix class, but you can define a thin wrapper at worst
(Also scipy.linalg.expm etc.)
11:19
i'm trying to login to this site using python requests this is my code: codeshare.io/GkRlNY (i can't give away my password)
this is the response i'm getting after post request:
i think it's some recaptcha thing which is hidden in the website
asparagus please
@Manik well, unless you have a way of getting around one of the most secure bot-rejecting algorithms, you basically can't login.
(may not be one of the most secure, but it's very widely used, and thus, quite good at rejecting bots)
have you seen the site? it has no reCAPTCHA visible
@Manik the recaptcha is there so you don't scrape it. It's working.
but someone has already done it and made an app
Good for them?
11:34
these are the requests from browser please look into it
(yes i changed my password)
requests when i login*
i have done this with Selenium but my friend told me that "its too memory extensive" i won't be able to handle multiple users so i must use requests instead. is he right?
12:07
does someone know what recaptcha does even if it is not visible on the site?
@AndrasDeak Thanks both of you. Has anyone used networkx for probabilistic adjacency matrix calculations?
Not my alley, sorry
That reminds me, has anyone here heard of the new Brave browser? Any opinions on it?
they claim to be super privacy-oriented, but honestly, that just makes me suspicious
brave browser was annoying it didn't launch for some reason in ubuntu
@Aran-Fey You don't need it unless you're very, very privacy conscious, in which case, it's not the only option out there.
12:11
is there a close reason for wrong assumptions? The OP has constructed a bad test, and now asks based on flawed results.
@MisterMiyagi too broad
I mean, I do need a browser. Is it worse than firefox?
chrome is good
If you don't like Firefox, then I would suggest Chrome, but since you're looking into Brave, I'm not sure you'll even consider Chrome.
I don't really have any problems with FF, but I'm not opposed to trying other options
12:13
@MisterMiyagi no repro
ah, yes, better close reason
good point
I use Chrome, mainly because I need to work with HTML / CSS (& thus need to test the most used browser very often). It's like the lesser of the evils out there. But I've given up on privacy, so Chrome's the best if you use a couple extensions as per need.
@AaronHall Well apart from the basic stuff like .loc/iloc accessors, apply, groupby, drop(), value_counts(). Really it depends on what the contents/dtype of the Series are and what you're doing with it: it could be the NA-filling/locating functions, or sum, mean and the descriptive statistics, or histogram. If the contents are string (or date) then its likely to be string (or date) methods via the .str/.dt accessors. If it's a categorical then maybe .unique/nunique/factorize/duplicated...
FF feels like Linux that can give you crappy / unsecure updates once in a blue moon, so doesn't feel as worthy.
12:17
..If you're doing a lot of vectorized boolean or mask expressions then maybe operators like .eq/ne/isin, any()/all(), mul/div... really impossible to answer... if you're a business/SQL type then nlargest()... if it's a timeseries then diff...
Didn't realize Brave doesn't have a bookmarks sidebar... that alone makes it unusable
user12940310
how to get the text which is found inside a nested Div tag using python BeautifulSoup
@Aran-Fey I'm sure they have a report-issues feature and github...if not, file it
@MisterMiyagi Before it gets closed, I made an 'interventionist' edit on the title, to question the OP's premises.
@davileo doesn't that div have a distinct attribute?
@smci I have seen that. I guess there is no need for me to repeat my stance on such practices.
12:29
@smci I think, it might be a feature :shrug:
@MisterMiyagi MM, I rarely do it these days (on open, confused questions) but in this case don't you think that something that makes the OP question their assumptions is helping?
@shad0w_wa1k3r dev edition updates very often
And there's nightly
Yes, they're usually good to have, but once in a long while they screw up & it makes quite some news. One of the minor reasons I gave up on FF.
@smci That's what comments are there for. I doubt the OP will realise the title has changed. The primary effect of changing the title is that it doesn't match the question anymore.
@shad0w_wa1k3r ah, I misunderstood
12:34
Though a dupe-vote for some python benchmarking may be appropriate now.
user12940310
@Manik yeah it have. All the text found inside a Div are belongs to the same class
@MisterMiyagi It does still match the question: OP starts out by merely saying I was wondering if there might be some performance impact to using this, then goes off the rails after that. I did read the question very carefully before retitling, so that the retitling does not invalidate the question. @AndrasDeak you rolled back to the original title that pushed the faulty premise.
@smci Nowhere in the question is the OP asking how to benchmark typing. They have benchmarked it (wrongly), and ask for an explanation of the observed effect.
@davileo so just use soup.find('div', attrs = {"id":"div_id_here"})
@smci indeed. That is what OP is asking. Your edit conflicted with their intent. In my opinion this is the same as removing the bug from a debugging question. OP has a faulty premise, end of story.
If it reminds you of a different, on-topic question go ahead and ask it
user12940310
12:43
@Manik All the texts found in the same class have different id so if i give id it only print out the text found in that specific id but not texts which is found under the same class
:48858246, Andras Really? If I write "I summed the numbers 1,2,3,4 and got 11, I am wondering about the effect of language feature X on my code's performance", it's not ok and useful to highlight the faulty premise? We just close it and it presumably gets deleted when the OP doesn't fix it or understand why they need to fix it. I suppose. Oh well. Can't teach them all.
Yeah, we can't. Or, we can try, but I don't think this is the right process. Closing it and letting OP ask the right questions is.
@davileo you can use any atrribute not necessarily id it is an example
In your example we'd close and point out the bug in comments. Well, I would.
user12940310
12:46
:48858267 <div class="_333v _45kb".....
    <div class="_2a_i" ...............
        <div class="_2a_j".......</div>
        <div class="_2b04"...........
            <div class="_14v5"........
                <div class="_2b06".....
                    <div class="_2b05".....</div>
                    <div id=............>**TEXT HERE**</div>
                </div>
            </div>
        </div>
    </div>
</div>
user12940310
@Manik the above is the sample of the html i want to get the text
@AndrasDeak Ok then.
@smci not sure if you point at the content of the answer, or that the answerer informed the OP of a faulty premise.
@MisterMiyagi That Meta discussion is about using comments as well as answers. (Isn't there general agreement we should not write an answer if the question premise is clearly faulty?)
@davileo text = soup.find("div", {"id":"......"}).text try this
12:52
@MisterMiyagi Yeah I see your point, the Meta poster's premise could itself be faulty... anyway makes all that quite garbled. Sigh. There must be something good and relevant on Meta.
@smci I'm on the fence about answering "clearly wrong" questions. The general agreement is usually with respect to unclear questions. A clearly wrong question might be different. But most clearly wrong questions can be dispelled in just a comment...
Leaving an answer usually implies that it should help future readers. But clearly wrong questions should not stick around.
So I guess I'm leaning toward "don't answer"
oO
the Q was closed 9 mintues ago, but now there is an A 1 minute old…
@MisterMiyagi 4-hour grace period, client-side checking
13:08
What is the policy you guys maintain on python2/3? I came across a highly upvoted answer that is python2 only (on a highly upvoted question) without any mention of this. I believe a simple modification could make the answer compatible with both python 2 and 3.
does anyone know if/when a new python 3 update will come out?
Now here's the problem: I suggested that modification in the comments because I wasn't completely sure (and because I can't make an edit suggestion because of non-python rep) and the author of the question - who is a user with very high rep - responded in no uncertain terms: he wants to keep the answer as is, despite it not working for newcomers to the question
what is the meaning of the transparency of users dp on the top right? does that mean they are online or offline?
If it's a minor edit (like adding parentheses to a print), I'd just go ahead and make the change. For major edits, I'd contact the original author (if they're still active). Last resort - post my own answer
@Jasper Is there another answer, less upvoted but correct for Python3?
13:14
@Manik it indicates how long it's been since they sent a message in chat
melon
@epicgamer300065 but micro updates to 3.7/3.8 come out often
@MisterMiyagi it's a bit of an open-ended question, with a ton of answers that suggest different approaches to the problem. There is no answer suggesting this approach that is python3 compatible and I'm pretty sure a new answer would be buried under far too many answers to ever climb highly.
If the question is seeing a lot of influx from people, they will automatically demote the Py2 answers and promote any Py3 answers. Give it time.
So if there isn't a Py3 answer, feel free to write one. If there is one, a comment on the question pointing to it can help a lot.
13:25
@Aran-Fey Yep, the solution was exactly that adding parentheses to a print. I'm going to keep it as is for now because multiple people agreed in the comments on not changing it, and I said that I wouldn't change things as long as that remained the unanimous sentiment in the comments (excluding me, obviously) and I would like to stick with that. But it's good to know what to do in the future.
gosh, people are still clinging to parentheses-free print? didn't they get the memo?
90% of the push for tauthon
ugh. I find the work down on Tauthon impressive, but their cruft from welding Py3 onto Py2 is scary.
The stated reasoning was basically keeping it for historical significance (so people can see how the language evolved)
@MisterMiyagi We're talking 500+ upvotes (on the one answer) here and 12 answers with a positive score. My guess would be that it would take longer for it to correct itself than for python 4 to be released
Anyway, thanks for your input, guys (m/f/o)!
that's an interesting time scale ^^
13:32
Last 3 python answers by the high-rep: 2014-15-16, respectively
not exactly "finger on the pulse of the language" based on that
what does dp becoming large in some messages indicate and why is reputation displayed sometimes?
that happens you post many messages (or a long message), it just grows to fill the available space
and the dotted lines?
they indicate that a lot of time has passed between 2 messages
ok melon Aran-Fey
13:45
@AndrasDeak Based on that name, I was expecting Tau to be a constant between 2 and 3 (like euler's number, for example)
user12940310
@Manik I tried it but it says: AttributeError: 'NoneType' object has no attribute 'text'
did you try putting brackets text()?
are you sure you put the right attributes?
if it is None then it means it couldn't find the tag
@davileo it should be just .text no brackets sorry i'm not an expert
user12940310
14:10
@Manik so do you know any other ways scrape FB comments using BeautifulSoup
@davileo i have never tried so i don't know i guess you could devise an iterative method to get the comments
14:44
fresh cbg everyone
 
2 hours later…
user12940310
17:00
I was trying to Scrape comments but i am getting error saying Invalid URL 'email'. Can anyone tell me why this code is not working : here u can see the code :repl.it/repls/BleakShorttermFormats
there are 219 lines in that code, and you haven't even specified where the error is thrown.
traceback helps
I keep having to check that we hadn't somehow added scraping to the room's tags these days :)
weekend cbg
17:15
cbg :)
Hi @JonClements, I have a question confusing me all day. Could you help me?
you can ask - no guarantee I can answer though...
easy piece for you I think. I am just being dump. Let me demostrate
I was reading some API documents today. And I was so damn confusing when I saw they specify "type" in request parameters.
For example , take a look at this one console.faceplusplus.com/documents/5679127
Then one I met is not this one, but in similar format. It specifies name and type in a x-www-form-urlencoded post body.
My question is : How would there be types in a x-www-form-urlencoded post body?
Aren't they all strings?
yup... but the "Type" is telling you how it expects to be able to then interpret that text
17:25
@JonClements Yes. That's my... conclusion after I did some study today...
it's as simple as that really :)
..Damn. This confused me all day long.
When I saw "String". No problem
When I saw "Int". ??? WTF? ?
Thanks for comfirming that. Now I can rest assured...
yeah... that example also shows what valid values are accepted if there's choices... the other thing you will often see is a type of "Date" but it will say "in format YYYYMMDD" or similar
Check this one
parameter name | type | required | description
X-TC-Timestamp | Integer | Yes |Current UNIX timestamp to record the time an API request was made.For example, 1529223702.Note: if you miss the server time by more than 5 minutes, you will cause a signature expiration error.
yep - seems clear enough
17:38
It's a content header
Then I made this header with a int unix timestamp with requests
And I got an exception. header values must be "string" or xxxx
Never mind. It's over now. Thank you :)
watermelon
user6568562
18:08
Cbg everyone
18:43
Happy Py day.
...i literally only just realised why pi day is today
whelp. happy pi day :P
18:59
@AaronHall with reference to one of your earlier post (cannot find it but it read most common pandas.series func?) : series.value_counts , series.map() , series.str.[func] , series.get(), series.reindex() , series.sort_values() , series.factorize()[0] , series.argsort , these are few I can remember as of now .. :) happy pi day
 
1 hour later…
20:26
cbg why is this code not working? the selenium part works fine where it logs in but requests can't load the home page. i set all the cookies from the webdriver still it doesn't work :\
16
A: How to add a cookie to the cookiejar in python requests library

fat fantasmaI found out a way to do it by importing CookieJar, Cookie, and cookies. With help from @Lukasa, he showed me a better way. However, with his way I was not able to specify the "port_specified", "domain_specified", "domain_initial_dot" or "path_specified" attributes. The "set" method does it automa...

i followed this answer to add the cookies
 
1 hour later…
21:43
cbg-ning
Just watched Mama. We did a scoop on charity stores when I was looking for a Hawaiian shirt for the funeral a few weeks ago. "Oh, It's Del Toro, it's gonna be good". Just awful
I have a question
@roganjosh Benicio or Guillermo?
let's say I have something like this |1,2,3,3,5,2,3,2,1,4,5,5,2,3]
@AndrasDeak Guillermo
the aim is to have sublists that contain unique elements in it with all the elements in the main list
wait, I have the beginning of an answer
@AndyK can you please show what you expect as output? It's not clear to me at all.
@AndrasDeak I have an idea
list comprehension
@PabitraRoy I really think that question is going to be unanswerable on SO. I understand your points in the comment, but it doesn't fit very well into a Q/A site
21:50
@AndrasDeak yes
i think what they're saying is that they want to try something out first :P If you have a question Andy, take your time, set it up properly, and go ahead ask it once you're ready
@ParitoshSingh cheers. I was thinkiig outloud and it helped
rubber quack
21:52
@AndrasDeak yellow one? :)
that's the one :)
@AndyK I think you are looking for this: set(|1,2,3,3,5,2,3,2,1,4,5,5,2,3])
@PabitraRoy ugh
@PabitraRoy doing a set
will think about it tomo
but thanks
@roganjosh what should I do to improve my question that can answareable by people? what do u suggest?
22:00
Ugh, delete and edit are so close together :/
i missed that fully 😅
@PabitraRoy these questions are really tough to address. It might be more appropriate for stats exchange but you'll need more details about the model params. In any case, I think it'll just be guesses. It's really hard to deal with these kinds of questions on the platform
It would be nice if chat threw up an confirmation modal for deleted... but that would require 3 lines of code.
see you guys, rb. Stay safe
@roganjosh okay. I will mension the model's parameters and post it on stats exchange. let see what happens.
It needs quite a lot of detail beforehand
I don't wanna push an unanswerable question over to them. You need to be specific about the issue in their terms. IMO it's right that your question stays closed on SO; dont post another closable question over there
22:10
What more can needed?? 1.Dataset snippet. 2.Cleaned Data Snippet 3. Which thing I used to preprocess the values to feed into the model. 4.What model I am using 5.Model's Parameters 6. Expected Output
please let me know if i miss any point
7. Most important , Where am I stuck in
Simply put, you've done a great job. It's the issue of "what does the answer involve"
and the answer sadly is, the "answer" usually for ML problems involves a lot of trial and error
That is essentially rough in terms of what one should expect to be doing on a QnA site, and also tough to answer except in very broad and vague terms that go such as: try this. oh, didn't work? try that.
I'm almost tempted to say it can't be reasonably answered anywhere
Its honestly just a tricky thing to address, I personally don't have a good answer for it
(note also, im speaking in general terms, i haven't looked at your problem statement specifically. because it would be too big of a time investment for me to commit to right now)
I hold a similar opinion as roganjosh, but i also recognize it's an opinion. you don't have to agree with it, but i just hope the perspective helps.
Nicely put :)
hmm I understand..
Thank you guys for explaining.
22:21
for what it's worth, this is an issue with just about every ML question asked. Only a few ask for specific answerable things, usually around the concepts involved, or the programming implementation of a certain algorithm. All issues around ML questions that fall in the line of "i want my algorithm to give a better output" don't really fit those two categories, and requires trial and error, and time, more than anything else.
cough more data cough
yes I am reading lots of articles regarding that
@ParitoshSingh guys.. he's coughing. Get the collar.
oh dear
what are you doing getting close to me then, fly you fools!
I can't even argument with that. You shall not pass on covid19
gasp you've gone and named it out loud now! aah! panic!
(ps. please don't. and stop buying toilet rolls worth 2 years of use)
oh well :)
have people been asked to wfh so far over there yet?
22:39
Err, kinda? It's suggested, vaguely, but our policy has been pretty weak
In a strange way, i think this will make a lot more people here a lot more open to wfh
And by weak, I dont mean that I think its pathetic. Our govt seems resigned to the idea its gonna spread, so they're just trying to make the cases trickle rather than pour
wfh culture isn't really a familiar thing to many companies here, so it should be interesting that way
Which seems.. oddly sensible

« first day (3437 days earlier)      last day (1735 days later) »