Both from Ilya Grigorik:
A lot of times a project at hand has some components that can either be built from scratch, or a ready-to-use solution can be bought from a 3rd-party vendor. For example, there’s lots of ways to build a blog or a CMS, but most likely you will just use one of the many solutions already available on the market (such as WordPress).
Then, someone suggested we user a “cheaper” option – a rating component built on top of Appcelerator cloud services. Usage of the API is apparently free for up to a certain call volume (and who doesn’t like free?). I’m not opposed to using a better solution, so I decided to look deeper into this platform and what it offers.
Here’s essentially what it is: Appcelerator Cloud Services provides a back-end infrastructure mostly targeted towards mobile apps that use its Titanium development platform. The API provides a layer of methods and services that allows developers to build apps without worrying about server-side infrastructure. There are pre-built components that can allow for faster development, one of the components is Ratings and Reviews.
However, it’s not a plug-and-play deal. In order to achieve the star ratings functionality that we need, there are multiple implementation steps and gotchas:
- We would need to create a list of products we want to be rated as Custom Object type in the API
- To submit reviews we’ll have to know which product they apply to, so we’d have to map Custom Objects to products, probably performing a “GET” call to fetch Custom Object data and map it to products
- We’d need to create a mechanism to prevent duplicate submissions (session or cookie or IP-based). Appcelerator asks for a user_id value to be specified whenever a rating is submitted, so it means we would have to create and work with a User object as well
- Submitting a rating requires the user to be logged in – another API call
- It also turns out that PUT and DELETE API methods trigger an XHR error from 3rd-party domains. This is resolvable by adding headers (Access-Control-Allow-Origin per CORS specifications), but will require additional settings adjustment on the server-side
- And finally, any custom development will need to be thoroughly QA’d – which adds effort and time
I’m sure the Appcelerator cloud API is a great solution for certain cases, but for a super-simple component in my scenario it is much quicker and easier to go with a pre-built solution that satisfies all of my requirements.
Funny enough, we had another “build vs buy” discussion at lunch with Mike today, and thought that 80/20 rule can be applied to this problem: if spending 20% of the effort yields you 80% of result, that’s what you should go for.
Curious to hear about other build vs buy examples, so leave your notes in the comments!
Last week, due to awesomeness of the internet, I learned that PyCon 2015 conference is happening in April in Montreal. This got me super excited, even though I don’t quite get to use Python as much as I’d love to. The conference seems to be organized so well, in the beautiful city of Montreal, with amazing workshop options, hotel share options, AND on-site childcare!
So there I am, excited and trying to plan how I can swing it, looking up flights (bonus post for you on saving over 50% on flights) and emailing this girl about sharing a hotel room… Then bummer! Not only the conference was sold out, but also most of the workshops! (I was only hoping to attend tutorial days) But to re-phrase that old saying: if you can’t go to a conference, let a conference come to you!
I made a list of the workshops I would take if I could go, and started looking online for authors and their past presentations. Luckily, all of them had prep materials and some even had videos!
Here is the list focused on machine learning and data analysis for all of you, fellow curious Python lovers. Thank you so much to speakers for sharing these amazing study materials.
- Machine learning with Python, basics
Hands-on data analysis with Python by Sarah Guido
Python is quickly becoming the go-to language for data analysis. However, it can be difficult to figure out which tools are good to use. In this workshop, we’ll work through in-depth examples of tools for data wrangling, machine learning, and data visualization. I’ll show you how to work through a data analysis workflow, and how to deal with different kinds of data.
Hadoop with Python (video) by Donald Miner
In this tutorial, students will learn how to use Python with Apache Hadoop to store, process, and analyze incredibly large data sets. Hadoop has become the standard in distributed data processing, but has mostly required Java in the past. Today, there are a numerous open source projects that support Hadoop in Python and this tutorial will show students how to use them.
Learning Pandas by Brandon Rhodes
The typical Pandas user learns one dataframe method at a time, slowly scraping features together through trial and error until they can solve the task in front of them. In this tutorial you will re-learn how to think about dataframes from the ground up, and discover how to select intelligently from their abilities to solve your data processing problems through direct and deliberately-chosen steps.
Bayesian statistics made simple (video) by Allen Downey
An introduction to Bayesian statistics using Python. Bayesian statistics are usually presented mathematically, but many of the ideas are easier to understand computationally. People who know Python can get started quickly and use Bayesian analysis to solve real problems. This tutorial is based on material and case studies from Think Bayes (O’Reilly Media).
Building a recommendation engine with Python (video) by Diego Maniloff, Christian Fricke, Zach Howard
In this tutorial we’ll set ourselves the goal of building a minimal recommendation engine, and in the process learn about Python’s excellent Pydata and related projects and tools: NumPy, pandas, and the IPython Notebook.
This post begs a follow-up on takeaways from each class. To be continued…