Posts about python (old posts, page 1)

Bayesian Methods for Hackers

Bayesian Methods for Hackers is designed as an introduction to Bayesian inference from a computational/understanding-first, and mathematics-second, point of view. Of course as an introductory book, we can only leave it at that: an introductory book. For the mathematically trained, they may cure the curiosity this text generates with other texts designed with mathematical analysis in mind. For the enthusiast with less mathematical-background, or one who is not interested in the mathematics but simply the practice of Bayesian methods, this text should be sufficient and entertaining.

Python 3 is Winning Library Developer Support

Are you using Python 3 for your development? It has been out for 7+ years at this point. So, if you aren't using it, why not? Since December of 2008, the initial release of Python 3, it seems the new version of Python has lived in the shadow of Python 2. And here we are, 7 years later, still looking at a world where people are using Python 2 and talking about how Python 3 doesn't work for them.This made me wonder. Is Python 3 really inferior to Python 2? If not, why aren't people moving? I mean, there has to be a reason people are still clinging to the older technology. After some thought, it seemed to me the most recurring statement for why people are continuing to use Python 2 was "the packages I need just aren't on Python 3''. In attempt to get a statement I believed I could measure I framed this as "is Python 3 supported by library developers well enough for me to move?".

Python 3 is Winning Library Developer Support

I Know Python... A Bit

Back in 2014 I had the realisation that not every problem was a nail which could be hit with my clumsy php hammer. I needed to find a language which I could use to create desktop applications and settled on python. I'm very glad I did.

My initial apps were basic console based utilities but I quickly found myself wanting to create GUI based tools. I got my head around WXPython and have a couple of apps which I'm proud enough of that I'll let other people use them. Things that I'd always skipped over as being "too pro for me to bother with" such as unit tests, logging, error handling and code re-usability come second nature.

During 2015 I decided I liked python so much I didn't even want to use php for websites any more. I read a bunch of stuff about web frameworks such as django and pyramid but finally settled on flask (well, actually flask appbuilder). I've used this to create a handful of sites which are at a level of complexity that I'd never have even attempted in php.

The next big jump I made was learning about threading so that my GUI based apps were completely non-blocking and gave good feedback to the user about what was happening.

Better yet is that I've got all these things set up in project skeletons which I can quickly build on top of to kick start development of new tools.

My next step is to get my web based python stuff set up using docker, to make it even easier to shift around as required. This docker for beginners guide is my current reading.

!-- image i-know-python-a-bit_1.gif --!

Build An App Using Flask, SQLAlchemy and PostgreSQL

In this blog, we will write a todo application using Flask , Flask-SQLAlchemy , PostgreSQL , and Twitter Bootstrap. The purpose of this blog is not just to help developers write Python Flask web applications but to also help them deploy their application in the Cloud. In this blog, we will deploy our Flask todo application on OpenShift. OpenShift provides scalable hosting for Python web applications. Another purpose of this blog is to help newbie OpenShift Python application developers who want to get started with Python development on OpenShift. Finally, this blog will also show how to connect a Postgresql database from a Python application. By the end of this blog you will be able to see how using a Platform as a Service can quickly get you going with Python and PostgreSQL and we will have a todo application running on OpenShift