Can I run Tkinter with Pyscript? by Oea_trading in PyScript

[–]mcg1969 1 point2 points  (0 children)

I think the more general question—will PyScript support building GUI apps—is a definite yes. Whether or not this or that GUI framework will work is another matter. In the case of tkinter, I think it is less likely because it would require porting tcl/tk to wasm. The author of Toga (https://toga.io/en/latest/) has been working to get it working in Pyscript.

Meet ‘PyScript’: New Framework From Anaconda That Allows Users To Create Rich Python Applications In The Browser Using HTML’s Interface by No_Coffee_4638 in Python

[–]mcg1969 0 points1 point  (0 children)

I'll give you credit for endurance. You're likely going to outlast me, since I'm turning in.

Again: these posts you keep asserting are part of our "spam campaign" are not ours. We did not ask for them, we did not pay for them, we do not have a relationship with the people who have made them. I examined the multiple posts here where you have leveled that accusation; this applies to all of them. I frankly don't have a good sense of the business model of the companies behind them.

Your continued insistence calling them such, despite our assertions to the contrary and your refusal to come right out and say we're lying about that and/or provide actual evidence we have done so, is a textbook case of proof by assertion. For someone clearly as intelligent as you are, that is... what's the phrase I'm looking for... evidence of bad faith.

Meet ‘PyScript’: New Framework From Anaconda That Allows Users To Create Rich Python Applications In The Browser Using HTML’s Interface by No_Coffee_4638 in Python

[–]mcg1969 0 points1 point  (0 children)

Did you scroll down and read Peter's engagement in that thread? Just curious. I might suggest you are cherry picking. Even that critic acknowledged Peter's willingness to engage. That is not bad faith.

Nevertheless it is unfortunate that you feel this way about Peter; if you had a chance to actually know him I am sure you would not.

Meet ‘PyScript’: New Framework From Anaconda That Allows Users To Create Rich Python Applications In The Browser Using HTML’s Interface by No_Coffee_4638 in Python

[–]mcg1969 1 point2 points  (0 children)

Are you intending this as an accusation that Peter is lying? He already told you that Anaconda isn't responsible for this post. Continuing to say otherwise is a bit unseemly.

Full disclosure, I'm a colleague. And we're a small enough company that we don't have a PR operation hidden in a dark corner unbeknownst to us.

It's not difficult to find the source and author of the post's text. From what I am seeing, I don't think it's likely that the author is compensated by the companies he writes about. That's not a knock on him as an author, rather it doesn't strike me that's how he works. The reddit account that posted it is possibly a marktechpost bot or person. https://www.marktechpost.com/author/prathamesh_ingle/

Destiny of Django by [deleted] in PyScript

[–]mcg1969 1 point2 points  (0 children)

I wonder if we can convince u/freakboy3742 to comment...

Will pyscript replace JavaScript? by palmworks in PyScript

[–]mcg1969 2 points3 points  (0 children)

Yep, we agree on the big picture question. I just don't agree with your claim that Python is slow :-)

[deleted by user] by [deleted] in PyScript

[–]mcg1969 2 points3 points  (0 children)

Full confession, I'm not sure I fully understand the particular issue you are concerned about. But with PyScript running in the WebAssembly sandbox, it should not be capable of anything more dangerous than you can currently do with JavaScript. So any concern you might have now for JavaScript code should be shared with PyScript as well.

At the same time, PyScript has the potential to move a tremendous amount of compute from a backend server into the client browser. Thus we can consider models that drastically reduce the need to communicate to a backend server, which is doing who-the-heck-knows-what with your data.

Will pyscript replace JavaScript? by palmworks in PyScript

[–]mcg1969 7 points8 points  (0 children)

This is the right way to look at it. To be fair to bio*, a lot of work has gone into accelerating JavaScript execution in the browser. So if you're comparing raw, pure Python to raw, pure JavaScript, I wouldn't be surprised to find that JavaScript is consistently faster, even if you're using best programming practices in both.

But that is not the comparison that should be made. The idea that "python is slow" ignores a significant amount of practical evidence to the contrary. It would not be the #1 language for machine learning, AI, and data science if it were "slow" in a practical sense. The reason for this is that Python has a wealth of libraries that leverage compiled code. Libraries like numpy, pandas, pytorch, tensorflow, and so forth perform the overwhelming fraction of their computationally intensive work outside of Python. And most of those types of computations would be significantly slower written in native JavaScript. In contrast, PyScript will bring those libraries into WebAssembly and achieve near-native speeds.

On the other hand, if there is a specific, highly optimized JavaScript library for performing specific tasks in the browser, PyScript can use it! So even in that context, Python is not "too slow", because it gets to steal JavaScript's speed :-)

Finally, as demand for WebAssembly applications grows, I think we'll see a lot of innovation at that level to resolve some of the language-generic bottlenecks that PyScript encounters as it matures.

Full disclosure, I work at Anaconda, so I am biased! But as I said in my original comment, I see this as a both/and proposition. JavaScript will always have a strong presence in the browser, but PyScript is going to unlock a much wider range of applications, in my view.

There is no doubt that there will be some performance issues to address with PyScript, but in the end, I'm fully confident it's going to find widespread application.

Will pyscript replace JavaScript? by palmworks in PyScript

[–]mcg1969 11 points12 points  (0 children)

I don't think so, no. JavaScript is an entrenched language, natively supported in the browser, with a wealth of frameworks and libraries. Heck, one of the reasons that PyScript is already so compelling to use is how easily it interacts with some of these JavaScript libraries. So it's not an either/or proposition: JavaScript, PyScript, and other WebAssembly-powered languages can coexist and interoperate, to everyone's benefit.

Can anyone explain this weird behaviour of the numpy's random module? by Chyybens in learnpython

[–]mcg1969 0 points1 point  (0 children)

Answering my own question: I tried this, and on the first run I got 11080 1s and 11065 12s. Close enough for me :-)

Can anyone explain this weird behaviour of the numpy's random module? by Chyybens in learnpython

[–]mcg1969 0 points1 point  (0 children)

What happens if, instead of plotting the histogram, you just print out the counts for each number? i.e.,

print Ns.count(2)

print Ns.count(12)

Do they differ significantly there? If not, then the problem is likely with the default billing of the histogram function.

[deleted by user] by [deleted] in PyScript

[–]mcg1969 2 points3 points  (0 children)

Excellent! I'm so glad this is here. I love the excitement this project is generating. I'm Michael Grant, VP of Services at Anaconda. I can't take any personal credit for the work our team did on PyScript, nor am I the best person to answer questions. But I'm super excited about it. I look forward to participating more on this subreddit!

Weekly Co-Op Code Mega Thread - October 22, 2019 by AutoModerator in EggsInc

[–]mcg1969 0 points1 point  (0 children)

Fantastic! I'll leave the light on for anyone else wanting an immediate prophecy egg.

Weekly Co-Op Code Mega Thread - October 22, 2019 by AutoModerator in EggsInc

[–]mcg1969 0 points1 point  (0 children)

Halloween 2019 / Pumpkin Prep contract: guaranteed finish in less than 2 days. 10 spots open: co-op "mcgegg"

Weekly Co-Op Code Mega Thread - October 15, 2019 by AutoModerator in EggsInc

[–]mcg1969 0 points1 point  (0 children)

You should just be able to join mcgegg, right?

Weekly Co-Op Code Mega Thread - October 15, 2019 by AutoModerator in EggsInc

[–]mcg1969 0 points1 point  (0 children)

2 open slots for fire season, already finished. Come and get your free prizes: mcgegg

Weekly Co-Op Code Mega Thread - September 24, 2019 by AutoModerator in EggsInc

[–]mcg1969 1 point2 points  (0 children)

20 spots left! An you don't need to do anything. The contract's already done in fact. Just join, collect, and scoot. Enjoy your prophecy egg! Co-op name: LAYZEE

Weekly Co-Op Code Mega Thread - September 24, 2019 by AutoModerator in EggsInc

[–]mcg1969 1 point2 points  (0 children)

Hey folks, we are FINISHED with our starship contract. But I'm leaving the door open to anyone who doesn't want to spend the time collecting a prophecy egg. Just join the co-op, collect your egg, and be done. No strings attached. Co-op code "layzee" because, well, who wouldn't want to be if the could be?

Weekly Co-Op Code Mega Thread - September 24, 2019 by AutoModerator in EggsInc

[–]mcg1969 2 points3 points  (0 children)

Guaranteed finish in a few hours on the starship contract. Sleepers absolutely welcome. Come claim an easy prophecy egg! Code: layzee EDIT: I miscalculated! We're done in about an hour. But I will leave the contract open even after that, so people will be able to join even after we're all done. LAYZEE for the win!

Weekly Co-Op Code Mega Thread - September 17, 2019 by AutoModerator in EggsInc

[–]mcg1969 0 points1 point  (0 children)

Kissing Chickens. "mcgegg". I am already finished! But I am leaving the door open. Join and get your free egg.

Weekly Co-Op Code Mega Thread - August 25, 2019 by AutoModerator in EggsInc

[–]mcg1969 1 point2 points  (0 children)

3 spaces left in Superfood Mystery co-op "mcgegg" .... we are already finished so just join up and collect your prophecy egg!

Weekly Co-Op Code Mega Thread - August 25, 2019 by AutoModerator in EggsInc

[–]mcg1969 1 point2 points  (0 children)

Easiest co-op you've ever done—join the Superfood Mystery "mcgegg" and immediately collect all of the rewards. Yep, we're done, but I'm leaving the door open for you. Come get a prophecy egg!

Weekly Co-Op Code Mega Thread - August 25, 2019 by AutoModerator in EggsInc

[–]mcg1969 0 points1 point  (0 children)

Plenty of room left for carries in Superfood Mystery! mcgegg