I recently completed the Udacity Deep Learning Nanodegree (highly worth doing by the way), which focuses on implementing a variety of deep learning architectures using PyTorch. At the outset, it's pretty fundamental to understand the data structures you'll be encountering as inputs to and outputs from your neural network architecture. What I noticed was that... Continue Reading →
How to – KMeans clustering
Clustering is a type of unsupervised learning. Us humans would think of it as 'categorization' perhaps. For example, if I gave you a bag of red, blue and white balls and asked you to sort them (without telling you how) you would probably naturally gravitate towards sorting them by colour as this would be the... Continue Reading →
How to – Principal Component Analysis
I always like to understand concepts well before I use them (which is good because it's the right thing to do, but bad because it slows me down a lot!), so it was with great excitement that I came across Matt Brems' article A One-Stop Shop for Principal Component Analysis recently. If you read this... Continue Reading →
Regex can do amazing things with data cleanups - basically mandatory must use. But also tricky to retain in brain if not used frequently... Here are 3 great reference and test resources that can help: https://docs.python.org/3/howto/regex.html https://regexr.com/ https://regexone.com/
Getting results vs Understanding
Alexander Pope is famously quoted as saying: A little learning is a dangerous thing; drink deep, or taste not the Pierian spring: there shallow draughts intoxicate the brain, and drinking largely sobers us again. I've been thinking about these words the past few days as I worked on my latest challenge: a text classifier using... Continue Reading →
Learn Python Challenge on Kaggle
I signed up for this 7-day challenge to test my knowledge, and it's been an absolute delight! As a newbie, when I find myself on StackOverflow reading discussions about "the most Pythonic way" to do something, I usually feel a bit left out... I'll just be happy if I can do it any darned way... Continue Reading →
Small simple datasets for practising
It's all very well downloading complex datasets from Kaggle and similar sources to play with - they're amazing for learners because the data is always less clean than you would have hoped, more complex than you anticipated, and every bit as interesting as promised. BUT if you're learning a new concept it's easier to have... Continue Reading →
Adding labels to districts in GeoPandas
Once you have your districts drawn up nicely, using the polygons from your shapefile, it would be useful to be able to label them - but of course you need to be able to tell GeoPandas where to place these labels via co-ordinates or points - and in your shapefile you only have polygons which... Continue Reading →
GeoPandas – a detailed example
Dear World, Please send me more geographical data to plot so I can keep on using GeoPandas... Love from Sho't Left I can't believe how much fun this library is! So my goal was to find a way to map assessment ratings by region, showing the overall result for the region, as well as the... Continue Reading →
Which districts are my cities located in?
GeoPandas gets more and more exciting as the day wears on :). I've just discovered how ridiculously easy it is to take a set of cities and relate them to their corresponding districts, states or provinces and then plot the outcomes. Fanfare for... the marvellous GeoPandas spatial join! Here's a quick how-to guide to setting... Continue Reading →