Python Daily
2.57K subscribers
1.48K photos
53 videos
2 files
38.9K links
Daily Python News
Question, Tips and Tricks, Best Practices on Python Programming Language
Find more reddit channels over at @r_channels
Download Telegram
This media is not supported in your browser
VIEW IN TELEGRAM
Deploy as many Django websites as you want with one simple command

/r/django
https://redd.it/gtguph
Where is the "default project template"?

The Django [docs](https://docs.djangoproject.com/en/3.0/ref/contrib/admin/) for the admin site say

> The admin is enabled in the default project template used by `startproject`.
>
If you’re not using the default project template, here are the requirements: [...]


This "default project template" is not defined. What is the default project template named, and where is it located? Web search and Docs search are turning up nothing.

/r/djangolearning
https://redd.it/gtdvgh
This media is not supported in your browser
VIEW IN TELEGRAM
A Hangman AI that tries to solve words given by the user!

/r/Python
https://redd.it/gtie5f
[D] Zero-Shot Learning for Text Classification

Hi everyone,

With GPT-3 released, there has been a renewed interest in zero-shot learning in the NLP community. I've written a summary of one of the earlier papers that proposed zero-shot text classification. Please check it out and share your feedback.

Article: https://amitness.com/2020/05/zero-shot-text-classification/

/r/MachineLearning
https://redd.it/gtij5d
What to use for front end development to make it easy and clean? Do nice html/css templates exist? Easy frameworks that work well with django?

I am a software developer that primarily develops applications. I am new to web apps so it might be no surprise to you I have 0 experience with front end development. Ideally, I would like to make the process as easy as possible. I like "minimalist" web app design which could also mean simpler front end code.

I have seen some suggestions online to use React with django? I have heard of people using bootstrap as well? I quite honestly don't know anything more about these 2 frameworks than what you can learn in a google search. I'm genuinely curious if the django community has a consensus on what to use if you are a backend developer looking to make front ends quickly and easily...

Thank you :)

/r/django
https://redd.it/gtpnsx
Two forms csrf token non-unique id chrome warning

Hi,

When using two flask forms on one page chrome is giving warning about non-unique ids of csrf id field. Is there any way to change the id of csrf field.

Or do I just ignore the error ?

/r/flask
https://redd.it/gtjwbt
Need Help! Jupyter Notebook shutting down immediately after opening.

So here is the detailed problem
I have installed anaconda package.
As soon as I click on the jupyter/anaconda, a little window pops up and exits immediately within a second.

Please help if you know the solution

/r/JupyterNotebooks
https://redd.it/gtv5mz
Any up to date tutorial on web scraping?

A lot of the tutorials I have found thus far are either out of date or confused me due to the websites they used being updated

/r/Python
https://redd.it/gttql2
This media is not supported in your browser
VIEW IN TELEGRAM
I created the first cross-platform Python library to create native context menus!

/r/Python
https://redd.it/gtzk7v
What is the best way to create Django + React project?

I wonder how to create django and react website, I know there is way when you create django app called frontend and put all react stuff there, but I'm not sure if it's the most convenient way.

/r/django
https://redd.it/gtwwyr
This media is not supported in your browser
VIEW IN TELEGRAM
[Update] Shooting pose analysis and basketball shot detection web App and API with Flask [GitHub repo in comment]

/r/flask
https://redd.it/gu055f
I configured my terminal to teach me a new word everyday! Every time I open a new terminal window, I have a python script that scrapes dictionary.com and gives me the word of the day. On top of that, I have a motivational quote displayed as well :)

/r/Python
https://redd.it/gu9nzq
Help with Python Claqses

Hi Guys and Girls.

I'm new to Python but not programming.

I having trouble understanding how I can update a class that is a Tkinter frame.

The frame is created with a def \_\_init\_\_ and all the text is added.

My question is how do I then reference this frame from a function to update the text on that frame. Basically I am updating a database and want to update the figures in the current frame / window.

Some of the code is below

### Create a class for the Dashboard page.  This will also be the start page when the application starts
`class Dashboard (tk.Frame):`
`def __init__(self, parent, controller):`
`tk.Frame.__init__(self,parent, bg="#263D42")`
`label = tk.Label(self, text="Author Dashboard", font=TITLE_FONT, bg="#263D42", fg="white", pady = 20)`
`label.grid(row=0, column=0, sticky="nsew")`
`stat = GetStatsSQL('allPapers')`

`tk.Label(self, text="Number of Publications in the Database", bg="#263D42", fg="white").grid(row=1, column=0, sticky="w")`
`tk.Label(self, text=stat, bg="#263D42", fg="white").grid(row=1, column=1)`
`stat = GetStatsSQL('authors')`

`tk.Label(self, text="Number of Authors in the Database", bg="#263D42", fg="white").grid(row=2, column=0, sticky="w")`
`tk.Label(self, text=stat, bg="#263D42", fg="white").grid(row=2, column=1)`
`stat = GetStatsSQL('journal')`

`tk.Label(self, text="Number of Journals in the Database", bg="#263D42", fg="white").grid(row=3, column=0, sticky="w")`

`tk.Label(self, text=stat, bg="#263D42", fg="white").grid(row=3, column=1)`
`stat = GetStatsSQL('conference')`
`tk.Label(self, text="Number of Conference Papers in the Database", bg="#263D42", fg="white").grid(row=4, column=0, sticky="w")`
`tk.Label(self, text=stat, bg="#263D42", fg="white").grid(row=4, column=1)`
`def update():`
`stat = GetStatsSQL('allPapers')`

`tk.Label(APP, text=stat, bg="#263D42", fg="white").grid(row=1, column=1)`

This is the dashboard class to create and display the dashboard. You can see in the code that there a functions that call SQL to return a result and display it.

What I want to to refresh this page after the database has been changed by another function.

I gave create a function in the Dashboard class but I'm unsure how I can change the tk.label test set when the class was created.

Thanks

Brian

/r/Python
https://redd.it/gudzii
[D] Machine Learning - WAYR (What Are You Reading) - Week 89

This is a place to share machine learning research papers, journals, and articles that you're reading this week. If it relates to what you're researching, by all means elaborate and give us your insight, otherwise it could just be an interesting paper you've read.

Please try to provide some insight from your understanding and please don't post things which are present in wiki.

Preferably you should link the arxiv page (not the PDF, you can easily access the PDF from the summary page but not the other way around) or any other pertinent links.

Previous weeks :

|1-10|11-20|21-30|31-40|41-50|51-60|61-70|71-80|81-90|
|----|-----|-----|-----|-----|-----|-----|-----|-----|
|[Week 1](https://www.reddit.com/4qyjiq)|[Week 11](https://www.reddit.com/57xw56)|[Week 21](https://www.reddit.com/60ildf)|[Week 31](https://www.reddit.com/6s0k1u)|[Week 41](https://www.reddit.com/7tn2ax)|[Week 51](https://reddit.com/9s9el5)|[Week 61](https://reddit.com/bfsx4z)|[Week 71](https://reddit.com/d7vno3)|[Week 81](https://reddit.com/f1f0iq)|||||||
|[Week 2](https://www.reddit.com/4s2xqm)|[Week 12](https://www.reddit.com/5acb1t)|[Week 22](https://www.reddit.com/64jwde)|[Week 32](https://www.reddit.com/72ab5y)|[Week 42](https://www.reddit.com/7wvjfk)|[Week 52](https://reddit.com/a4opot)|[Week 62](https://reddit.com/bl29ov)|[Week 72](https://reddit.com/de8h48)|[Week 82](https://reddit.com/f8fs6z)||
|[Week 3](https://www.reddit.com/4t7mqm)|[Week 13](https://www.reddit.com/5cwfb6)|[Week 23](https://www.reddit.com/674331)|[Week 33](https://www.reddit.com/75405d)|[Week 43](https://www.reddit.com/807ex4)|[Week 53](https://reddit.com/a8yaro)|[Week 63](https://reddit.com/bqlb3v)|[Week 73](https://reddit.com/dkox1s)|[Week 83](https://reddit.com/ffi41b)||
|[Week 4](https://www.reddit.com/4ub2kw)|[Week 14](https://www.reddit.com/5fc5mh)|[Week 24](https://www.reddit.com/68hhhb)|[Week 34](https://www.reddit.com/782js9)|[Week 44](https://reddit.com/8aluhs)|[Week 54](https://reddit.com/ad9ssz)|[Week 64](https://reddit.com/bw1jm7)|[Week 74](https://reddit.com/dr6nca)|[Week 84](https://reddit.com/fn62r1)||
|[Week 5](https://www.reddit.com/4xomf7)|[Week 15](https://www.reddit.com/5hy4ur)|[Week 25](https://www.reddit.com/69teiz)|[Week 35](https://www.reddit.com/7b0av0)|[Week 45](https://reddit.com/8tnnez)|[Week 55](https://reddit.com/ai29gi)|[Week 65](https://reddit.com/c7itkk)|[Week 75](https://reddit.com/dxshkg)|[Week 85](https://reddit.com/fvk7j6)||
|[Week 6](https://www.reddit.com/4zcyvk)|[Week 16](https://www.reddit.com/5kd6vd)|[Week 26](https://www.reddit.com/6d7nb1)|[Week 36](https://www.reddit.com/7e3fx6)|[Week 46](https://reddit.com/8x48oj)|[Week 56](https://reddit.com/ap8ctk)|[Week 66](https://reddit.com/cd7gko)|[Week 76](https://reddit.com/e4nmyk)|[Week 86](https://reddit.com/g4eavg)||
|[Week 7](https://www.reddit.com/52t6mo)|[Week 17](https://www.reddit.com/5ob7dx)|[Week 27](https://www.reddit.com/6gngwc)|[Week 37](https://www.reddit.com/7hcc2c)|[Week 47](https://reddit.com/910jmh)|[Week 57](https://reddit.com/auci7c)|[Week 67](https://reddit.com/cj0kyc)|[Week 77](https://reddit.com/eb4lxk)|[Week 87](https://reddit.com/gcx3uf)||
|[Week 8](https://www.reddit.com/53heol)|[Week 18](https://www.reddit.com/5r14yd)|[Week 28](https://www.reddit.com/6jgdva)|[Week 38](https://www.reddit.com/7kgcqr)|[Week 48](https://reddit.com/94up0g)|[Week 58](https://reddit.com/azjoht)|[Week 68](https://reddit.com/cp1jex)|[Week 78](https://reddit.com/ehbfst)|[Week 88](https://reddit.com/glm6sv)||
|[Week 9](https://www.reddit.com/54kvsu)|[Week 19](https://www.reddit.com/5tt9cz)|[Week 29](https://www.reddit.com/6m9l1v)|[Week 39](https://www.reddit.com/7nayri)|[Week 49](https://reddit.com/98n2rt)|[Week 59](https://reddit.com/b50r5y)|[Week 69](https://reddit.com/cvde5a)|[Week 79](https://reddit.com/entcxy)||
|[Week 10](https://www.reddit.com/56s2oa)|[Week 20](https://www.reddit.com/5wh2wb)|[Week 30](https://www.reddit.com/6p3ha7)|[Week 40](https://www.reddit.com/7qel9p)|[Week 50](https://reddit.com/9cf158)|[Week
60](https://reddit.com/bakew0)|[Week 70](https://reddit.com/d1g1k9)|[Week 80](https://reddit.com/euctyw)||

Most upvoted papers two weeks ago:

/u/randombrandles: [Complex Societies and the Growth of the Law\]([https://arxiv.org/abs/2005.07646](https://arxiv.org/abs/2005.07646)

/u/ratatouille_artist: [Integrating Graph Contextualized Knowledge into

/r/MachineLearning
https://redd.it/gu5t0d
Photo Color Filter

Hello, first time poster! :) I wrote a small script to grayscale pixels not listen in the color list.

[Example Photos](http://imgur.com/a/W7QgCaN)

My code can be viewed here, for any one who wants to take a look.

https://github.com/CyrusKashef/Small_Projects

I'd like feedback, even if it's negative. I want to grow as a coder. My next step would have been to make a gui with checkboxes for the colors and an ability to browse for the picture (tkinter probably?).

/r/Python
https://redd.it/gu7mn6
ROS package and virtual environment

I have a virtual environment in which I have installed Tensorflow and Jupyter Notebook. I have to import a module from a ROS package in a notebook

I have sourced the setup.bash from workspace/devel/, still I get a ModuleNotFoundError for this module. Note that in the virtual environment, when I run a python file which uses this module, I get no error.

What should I do?

/r/IPython
https://redd.it/guf3ko