This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'whatever/classifier' | |
classifier = Classifier.new | |
# training: | |
classifier.add_document(:text => "blah", :class => :a) | |
classifier.add_document(:text => "bleh", :class => :b) | |
# get model; training is automatically finalised | |
model = classifier.get_model |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Engineer by choice, Researcher at heart, Entrepreneur by nature. | |
Siddhartha has over 4 years of experience working in the broad areas of Information Engineering—Retrieval, Extraction & Management, Machine Learning, Scalability and Cloud Computing; with a focus on application to the World Wide Web. | |
He started working on Information Retrieval as a research when pursuing a Masters degree in Information Technology at IIIT-Bangalore in 2005,06. After graduation, he joined Ziva Software, a mobile search startup, in 2006. He has since been working on various aspects of developing and running Ziva's flagship mobile search engine Zook as a part of the core 3-member tech team. | |
Siddhartha's contribution at Ziva has been manifold, including, but not limited to, system architecture for the various sub-systems (crawling, extraction, processing, indexing and search), user experience, API, | |
Siddhartha blogs on these topics at http://grok.in/ (The Art Of Information Engineering). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Forcing a particular domain ### | |
RewriteCond %{HTTP_HOST} !^www.sids.in$ [NC] | |
RewriteRule ^(.*)$ http://www.sids.in$1 [R=301,L] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; use warnings; | |
use URI::Escape; | |
# http://www.perlhowto.com/encode_and_decode_url_strings | |
my $string = "Hello world!"; | |
my $encode = uri_escape($string); | |
print "Original string: $string\n"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Recipe: Tomato Pappu | |
^^^^^^^^^^^^^^^^^^^^ | |
Ingredients | |
=========== | |
Toor Dal : 1 measure | |
Tomatoes : 4-5 measures | |
Turmeric Powder : a pinch | |
Oil : 1 tea spoon / measure |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## setup | |
git config user.name "Siddhartha Reddy" | |
git config user.email "" | |
## setup -- global | |
git config --global user.name "Siddhartha Reddy" | |
git config --global user.email "" | |
git config --global color.branch "auto" | |
git config --global color.status "auto" | |
git config --global color.diff "auto" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# sshd config tips | |
# add these lines at the end of /etc/ssh/sshd_config | |
# don't try reverse-dns lookup on connecting clients (this speeds up the initial connection establishment a lot): | |
UseDNS no | |
# make sure the client does not get disconnect due to being idle (ping every 5 mins): | |
ClientAliveInterval 300 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# setting up auxiliary swap in linux | |
dd if=/dev/zero of=/auxswap bs=1M count=2048 | |
mkswap /auxswap | |
swapon /auxswap | |
# trun it on: | |
swapon -s | |
# turn it off: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://gist.github.com/2125 | |
Examples of database handling in Perl. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.DataOutputStream; | |
public class PackTest { | |
public static void main (String[] args) throws Exception { | |
DataOutputStream out = new DataOutputStream(System.out); | |
out.writeInt(11351); | |
out.flush(); | |
} | |
} |