PLAY PODCASTS
Build Streamlit Data Science Dashboards & Verbose Regex f-Strings
Episode 113

Build Streamlit Data Science Dashboards & Verbose Regex f-Strings

The Real Python Podcast · Real Python

June 10, 202250m 13s

Audio is streamed directly from the publisher (dts.podtrac.com) as published in their RSS feed. Play Podcasts does not host this file. Rights-holders can request removal through the copyright & takedown page.

Show Notes

<p>Would you like a fast way to share your data science project results as an interactive dashboard instead of a Jupyter notebook? Streamlit is a library for creating simple web apps and dashboards using just Python. This week on the show, Christopher Trudeau is here, bringing another batch of PyCoder&rsquo;s Weekly articles and projects.</p> <p>We talk about the article &ldquo;Forget About Jupyter Notebooks - Showcase Your Research Using Dashboards.&rdquo; It covers the basics of turning a data science script into an interactive dashboard using Streamlit. We also share some additional resources to get you started with the library. </p> <p>Christopher discusses an article covering ways to make life easier when working with Python regular expressions. He talks about composing verbose regexes using f-strings and potentially reusing these patterns.</p> <p>We cover several other articles and projects from the Python community, including a news roundup, a step-by-step project to build a URL shortener with FastAPI, the fact that Python&rsquo;s functions are sometimes classes, an automatic water pistol pigeon deterrent project, a discussion about music playlists for coding, a project for Python metadata extraction without execution, and a powerful audio-to-MIDI converter library.</p> <div class="alert alert-primary" role="alert"> <p><strong>Course Spotlight:</strong> <a href="https://realpython.com/courses/using-python-class-constructors/">Using Python Class Constructors</a></p> <p>In this video course, you&rsquo;ll learn how class constructors work in Python. You&rsquo;ll also explore Python&rsquo;s instantiation process, which has two main steps: instance creation and instance initialization.</p> </div> <p>Topics:</p> <ul> <li>00:00:00 &ndash; Introduction</li> <li>00:02:22 &ndash; ctx Library Hijacked to Steal AWS Keys</li> <li>00:04:33 &ndash; Typosquatting Attack on &lsquo;requests&rsquo;</li> <li>00:06:55 &ndash; Build a URL Shortener With FastAPI and Python</li> <li>00:10:51 &ndash; Sponsor: Rookout</li> <li>00:11:31 &ndash; Python&rsquo;s Functions Are Sometimes Classes</li> <li>00:14:05 &ndash; Forget Jupyter, Showcase Your Data with Dashboards</li> <li>00:22:08 &ndash; The Unreasonable Effectiveness of f-strings and re.VERBOSE</li> <li>00:25:43 &ndash; Robotic Water Pistol as Pigeon Deterrent</li> <li>00:28:13 &ndash; Video Course Spotlight</li> <li>00:29:34 &ndash; Do You Have a Favorite Playlist for Coding?</li> <li>00:40:05 &ndash; dowsing: Metadata Extraction Without Execution</li> <li>00:42:01 &ndash; spotify/basic-pitch: A lightweight yet powerful audio-to-MIDI converter </li> <li>00:49:12 &ndash; Thanks and goodbye</li> </ul> <p>News:</p> <ul> <li><a href="https://www.bleepingcomputer.com/news/security/popular-python-and-php-libraries-hijacked-to-steal-aws-keys/">ctx Library Hijacked to Steal AWS Keys</a></li> <li><a href="https://medium.com/checkmarx-security/typosquatting-attack-on-requests-one-of-the-most-popular-python-packages-3b0a329a892d">Typosquatting Attack on &lsquo;requests&rsquo; - One of the Most Popular Python packages</a></li> </ul> <p>Topic Links:</p> <ul> <li><a href="https://realpython.com/build-a-python-url-shortener-with-fastapi/">Build a URL Shortener With FastAPI and Python</a> &ndash; In this step-by-step project, you&rsquo;ll build an app to create and manage shortened URLs. Your Python URL shortener can receive a full target URL and return a shortened URL. You&rsquo;ll also use the automatically created documentation of FastAPI to try out your API endpoints.</li> <li><a href="https://www.pythonmorsels.com/class-function-and-callable/">Python&rsquo;s Functions Are Sometimes Classes</a> &ndash; Ever use <code>list()</code> or <code>enumerate()</code>? Think of them as functions? They&rsquo;re not&mdash;they&rsquo;re classes. Sometimes we call classes functions in Python. Why? And what&rsquo;s a &ldquo;callable&rdquo;?</li> <li><a href="https://blog.esciencecenter.nl/forget-about-jupyter-notebooks-showcase-your-research-using-dashboards-5d13451ba374">Forget Jupyter, Showcase Your Data with Dashboards</a> &ndash; Streamlit can be used as an alternative to Jupyter notebooks for sharing research data. Streamlit is a relatively new library for creating simple web apps and dashboards using just Python. Learn why it might be the right choice for your next data project.</li> <li><a href="https://death.andgravity.com/f-re">The Unreasonable Effectiveness of f-strings and re.VERBOSE</a> &ndash; A look at one or two ways to make life easier when working with Python regular expressions.</li> <li><a href="https://maxnagy.com/posts/pigeons/">Robotic Water Pistol as Pigeon Deterrent</a> &ndash; Max built a wifi-equipped water gun to shoot the pigeons on his balcony. It is controlled over the Internet by a Python script running <code>openCV</code> reading the camera image from an old iPhone. See all the details.</li> </ul> <p>Discussion:</p> <ul> <li><a href="https://twitter.com/python_engineer/status/1525795191965220865">Do You Have a Favorite Playlist for Coding?</a></li> </ul> <p>Projects:</p> <ul> <li><a href="https://github.com/python-packaging/dowsing">dowsing: Metadata Extraction Without Execution</a></li> <li><a href="https://github.com/spotify/basic-pitch">spotify/basic-pitch: A lightweight yet powerful audio-to-MIDI converter with pitch bend detection</a></li> </ul> <p>Additional Links:</p> <ul> <li><a href="https://12factor.net/">The Twelve-Factor App</a></li> <li><a href="https://medium.datadriveninvestor.com/streamlit-vs-dash-vs-voil%C3%A0-vs-panel-battle-of-the-python-dashboarding-giants-177c40b9ea57#8026">Streamlit vs Dash vs Voilà vs Panel — Battle of The Python Dashboarding Giants</a> </li> <li><a href="https://vickiboykis.com/2020/06/09/getting-machine-learning-to-production/">Getting machine learning to production | Vicki Boykis</a></li> <li><a href="https://towardsdatascience.com/detecting-deforestation-from-satellite-images-7aa6dfbd9f61">Detecting deforestation from satellite images | André Ferreira</a></li> <li><a href="https://docs.streamlit.io/library/get-started/create-an-app">Create an app - Streamlit Docs</a></li> <li><a href="https://github.com/spotify/pedalboard">spotify/pedalboard: 🎛 🔊 A Python library for manipulating audio.</a></li> <li><a href="https://realpython.com/podcasts/rpp/96/">Episode #96: Manipulating and Analyzing Audio in Python – The Real Python Podcast</a></li> <li><a href="https://realpython.com/podcasts/rpp/15/">Episode #15: Python Regular Expressions, Views vs Copies in Pandas, and More – The Real Python Podcast</a></li> <li><a href="https://realpython.com/podcasts/rpp/64/">Episode #64: Detecting Deforestation With Python &amp; Using GraphQL With Django and Vue – The Real Python Podcast</a></li> </ul> <p>Level up your Python skills with our expert-led courses:</p> <ul> <li><a href="https://realpython.com/courses/data-viz-with-dash/">Data Visualization Interfaces in Python With Dash</a></li> <li><a href="https://realpython.com/courses/building-regexes-python/">Regular Expressions and Building Regexes in Python</a></li> <li><a href="https://realpython.com/courses/using-python-class-constructors/">Using Python Class Constructors</a></li> </ul> <p><a rel="payment" href="https://realpython.com/join">Support the podcast &amp; join our community of Pythonistas</a></p>