Skip to content

Instantly share code, notes, and snippets.

We are hiring!

Anand Chitipothu anandology

We are hiring!
Block or report user

Report or block anandology

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
anandology /
Created Mar 18, 2016
Function to plot the decision boundaries of a scikit-learn classification model.
def plot_decision_boundaries(X, y, model_class, **model_params):
"""Function to plot the decision boundaries of a classification model.
This uses just the first two columns of the data for fitting
the model as we need to find the predicted value for every point in
scatter plot.
One possible improvement could be to use all columns fot fitting
and using the first 2 columns and median of all other columns
for predicting.
"""Python is infinitely beautiful!
This program is a response to the post "Infinite work is less work" by
Damian Conway[1].
This program demonstrates how infinity can be handled elegantly in
Write a script to generate first 10 strong and weak prime numbers.
anandology /
Last active May 31, 2019
Script to extract voter info from voter rolls
"""Script to extract voter info from voter rolls.
This script expects the extracted text file from the voter-list pdf.
It can be done using:
$ pdftotext -layout AC1580002.pdf
import sys
anandology / pg-encoding.txt
Created Jul 8, 2013
Fixing PostgreSQL default encoding in Ubuntu
View pg-encoding.txt
# Option 1 - rebuild the cluster
# This will delete alle existing data
pg_dropcluster --stop 9.2 main
pg_createcluster --start -e UTF-8 9.2 main
# Option 2 - rebuild the template1 database
# All the database created after this will have UTF-8 encoding
anandology /
Last active Aug 31, 2018
We are looking for an experienced python engineer to join our team at Rorodata.

We are looking for an experienced python engineer to join our team at Rorodata, a data analytics startup based in Hyderabad. Interesting work in the intersection of data science, infrastructure and microservices.

This is a full-time position based out of Hyderabad. We can explore remote working only in exceptional cases.

Please ping us on if this sounds interesting to you.

About Rorodata

anandology /
Created Jun 22, 2017
POC implementation of reactive expressions for Dash
"""Reactive expressions for Dash!
Dash[1] is an interesting project build reactive web applications in Python.
While the ideas are exciting, the syntax for specifying custom code is way
too complicated that it should be.
Here is a sample code to display sum of two input values.
[Input(component_id='x', component_property='value')]
anandology / custom.css
Last active Dec 18, 2017
Custom CSS to optimize jupyter notebook presentation in full-screen when zoomed in
View custom.css
FILE: ~/.jupyter/custom/custom.css
Custom CSS to optimize jupyter notebook presentation in full-screen when zoomed in.
@media all and (max-width: 800px) {
/* Hide prompt when zoomed in */
.prompt {
display: none !important;
"""Fabric demo.
Setup Instructions:
pip install Fabric3
How to use:
fab --list
fab hello
anandology / Makefile
Created Nov 13, 2015
Makefile to export jupyterhub notebooks for all users to html
View Makefile
# Makefile to export ipython notebooks in each user home to html
# The output goes to build/$USER/$FILENAME.html
SOURCES=$(wildcard /home/*/*.ipynb)
TARGETS=$(shell echo $(SOURCES) | sed -e 's/.ipynb/.html/g' -e 's,/home/,build/,g')
default: $(TARGETS)
You can’t perform that action at this time.