<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Python on Nyghtowl</title>
    <link>https://nyghtowl.com/tags/python/</link>
    <description>Recent content in Python on Nyghtowl</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <copyright>&lt;a href=&#34;https://creativecommons.org/licenses/by-nc-sa/4.0/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;CC BY-NC-SA 4.0&lt;/a&gt;</copyright>
    <lastBuildDate>Tue, 23 Jun 2020 17:21:13 +0000</lastBuildDate>
    <atom:link href="https://nyghtowl.com/tags/python/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Setup and Invoke Cloud Functions using Python</title>
      <link>https://nyghtowl.com/posts/2020/06/setup-and-invoke-cloud-functions-using-python/</link>
      <pubDate>Tue, 23 Jun 2020 17:21:13 +0000</pubDate>
      <guid>https://nyghtowl.com/posts/2020/06/setup-and-invoke-cloud-functions-using-python/</guid>
      <description>&lt;h3 id=&#34;setup-and-invoke-cloud-functions-usingpython&#34;&gt;Setup and Invoke Cloud Functions using Python&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://nyghtowl.com/posts/2020/06/setup-and-invoke-cloud-functions-using-python/img-01.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;&#xA;&lt;p&gt;Oh the fun I’ve had learning Cloud Functions. It has actually be fun while also frustrating and definitely enlightening to explore serverless services that are supposed to make things easy. Granted I’ve been around long enough to know there is always ramp up, even when it is simple.&lt;/p&gt;&#xA;&lt;p&gt;Cloud Functions is a service that allows you to run code on Google Cloud servers without needing to deal with server configuration or scaling. It is a pay as you go approach that means you pay for what you use and that can help optimize costs. I’ve started using it for a couple functions that I need to run multiple times and that is where it can be very valuable. There was a learning curve especially when connecting different services and this post covers key learnings on these subjects.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cloud Storage with Gsutils &amp; Python Client Library</title>
      <link>https://nyghtowl.com/posts/2020/02/cloud-storage-with-gsutils-python-client-library/</link>
      <pubDate>Sat, 29 Feb 2020 01:05:19 +0000</pubDate>
      <guid>https://nyghtowl.com/posts/2020/02/cloud-storage-with-gsutils-python-client-library/</guid>
      <description>&lt;h3 id=&#34;cloud-storage-with-gsutils--python-clientlibrary&#34;&gt;Cloud Storage with Gsutils &amp;amp; Python Client Library&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://nyghtowl.com/posts/2020/02/cloud-storage-with-gsutils-python-client-library/img-01.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;&#xA;&lt;p&gt;BLOB (binary large object) storage is aptly named. Google Cloud Storage is a BLOB storage solution that stores unstructured data. It’s like the closet you can shove a bunch of stuff into and don’t have to organize the information before putting it inside. It’s insanely flexible in size meaning it can hold anything and doesn’t need any special processing to store it.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Setup Compute Engine with Python ML Libraries</title>
      <link>https://nyghtowl.com/posts/2020/02/setup-compute-engine-with-python-ml-libraries/</link>
      <pubDate>Sat, 15 Feb 2020 01:43:42 +0000</pubDate>
      <guid>https://nyghtowl.com/posts/2020/02/setup-compute-engine-with-python-ml-libraries/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://nyghtowl.com/posts/2020/02/setup-compute-engine-with-python-ml-libraries/img-01.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;&#xA;&lt;p&gt;Below I will step through how I setup a Virtual Machine on Google Compute Engine with standard requirements as well as Python and related packages. In a previous post, I went through how to setup a VM and access to it from my laptop CLI.&lt;/p&gt;&#xA;&lt;p&gt;As mentioned, I like accessing the remote server through the CLI and below I walk through commands to setup the remote instance with basic packages for Linux instance and common Python machine learning packages. Also, the instance I worked with was based on the Debian/GNU Linux 9 image. If you use a different instance, the commands may change but the general steps are similar.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Ruby on Rails &amp; Python Trek</title>
      <link>https://nyghtowl.com/posts/2013/07/ruby-on-rails-python-trek/</link>
      <pubDate>Sat, 20 Jul 2013 11:40:14 +0000</pubDate>
      <guid>https://nyghtowl.com/posts/2013/07/ruby-on-rails-python-trek/</guid>
      <description>&lt;p&gt;Wow its been a while since I last posted. Lots going on with interviews last month and then deciding to teach myself Ruby on Rails and being obsessed with Julython. I completed and launched my first Rails app (technically second after the sample app from the tutorial) at the beginning of this week. It is a simple thing that literally is just a button and I couldn’t be prouder.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;What is Python Trek?&lt;/strong&gt;&lt;br&gt;&#xA;Python Trek is a mashup of Stark Trek and Monty Python scripts, quotes, etc. I built a program to generate random sentence or sentences using a Markov Chain algorithm and post those to the Twitter account @pythontrek. I used Ruby to build the program that generates the tweets and I applied Rails to set up a webpage where anyone can press a button that will generate the random tweet and post it.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Ode to .shutil.move() – ‘Oh how you frustrate me’</title>
      <link>https://nyghtowl.com/posts/2013/03/ode-to-shutil-move/</link>
      <pubDate>Tue, 12 Mar 2013 04:44:00 +0000</pubDate>
      <guid>https://nyghtowl.com/posts/2013/03/ode-to-shutil-move/</guid>
      <description>&lt;p&gt;In Hackbright, we had a project from our first week that I was finishing this weekend, and it asked us to use the &lt;a href=&#34;http://docs.python.org/library/shutil.html#shutil.move&#34;&gt;.shutil.move()&lt;/a&gt; function. Based on the reading for this function (linked above), it says &lt;em&gt;“The destination directory must not already exist.”&lt;/em&gt; This threw me off for a while because you should have the directory already existing to move a file to it.&lt;/p&gt;&#xA;&lt;p&gt;My experience with coding it and understanding at this point is that you need to create the directory before you reference it in the function and the quote I pulled is more to warn that if something already exists, it will be overwritten. If anyone has a different take on this function let me know and I’ll update the post.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
