Category Archives: Programming

Programming

Laravel for Django Developers, prelude.

It appeared to me that “Laravel” is kind of similar to Django in the way of implementation concept, so this is my obvious choice. I did a google search “Laravel for Django developers” and got pretty much nothing useful, sure, who would have move back to PHP from Python? I think this only happens in… Read More »

One goal reached, a few days late

I sorta set myself some goals randomly and one was trying to reach 5k points on Stackoverflow before 2016, but I was a few points short before the new years eve. This morning at mid January 2016, 25 more points added to my profile so I am over 5k goal now.  

Python OpenCV Facial Detection On OSX

Just a code snippet to demo Python script using OpenCV

Installation: pip install numpy (sometimes you might need to run as sudo) brew tap homebrew/science brew install opencv export PYTHONPATH=/usr/local/Cellar/opencv/2.4.7.1/lib/python2.7/site-packages/ download the xml file https://warai.googlecode.com/files/haarcascade_frontalface_alt.xml and place it in the same folder.

RequireJS + Zurb Foundation

django-rest-framework: api versioning

Django Rest Framework is a very solid api framework, but it doesn’t provide out-of-box versioning mechanism, here is my attempt to implement version specific APIs. The goal is to achieve something like http://localhost:8000/api/(resource)/ http://localhost:8000/api/v1/(resource)/ plus allowing clients to specify the version in request header (X-Version), here is how we did it. Structure in side the… Read More »

My Vim Configuration

I have been using vim for a few years now and had been using my very own vim configuration, mainly with Nerdtree and CtrlP, in the past few days I have discovered a well packaged vim configuration with lots of plugins. But shortly I discovered that the tab space is set to 2, which I… Read More »

Django CMS Haystack 2.0 Search Index

Currently django-cms-search doesn’t support haystack 2.0 yet, so here is my modified version to work on haystack 2.0 based on