Learning and Technology

This page delves some nimble tips and tricks on various topics of technology, mainly in computer science. It is with great hope I share these experiences so that if anybody else tumbles upon these kind of small or big issues, gets going the very moment with the right information. And is not left searching through loads of Googled content, which is frustrating in critical times. Just a small note: The level of detail varies from topic to topic depending on the exploration carried out.

Topic 6: Yamcha 0.33 – make issues
Errors/Tags/Keywords: Yamcha 0.33 make issues, Yamcha 0.33 installation issues
Date: 22-Feb-2014
Solution: Yamcha is an implementation of the SVM algorithm developed by the author of another famous implementation CRF++ (of the CRF algorithm). Yamcha 0.33 is the latest version of the tool at the time of writing this solution. And it is observed that on certain environments with a certain GNU C++ compiler the installation of Yamcha 0.33 gets stuck. The errors are discussed as follows with their solution.
Error 1: ‘strlen’ was not declared in this scope
This arises while compilation of the file param.cpp present in the src folder of the Yamcha main folder. One can solve this by adding #include<cstring> in the param.cpp file and then firing the make command again.
Error 2: ‘atoi’ is not a member of ‘std’
Once Error 1 is solved the make command moves ahead but gets stuck again at this error, which arises due to the compilation of the mkdarts.cpp file present in the libexec folder of the Yamcha main folder. One can solve this by adding #include<cstdlib> in the mkdarts.cpp file and then firing the make command again.


Topic 5: Sharing all my useful utility code on GitHub
Date: 05-Jan-2014
Discussion: I have shared a large part of code written by me during my research work at DAIICT at my GitHub corner. The link to the same is: https://github.com/nramrakhiyani
It contains code for some utility applications and useful code chunks currently. Will update this topic as I add more.


Topic 4: CRFSuite doesn’t install properly
Errors/Tags/Keywords: CRFSuite Installation problem, CRFSuite issue
Date: 20-Feb-2013
Solution: (To be enhanced with exact error/issue details and CRFSuite version)
1) CRFSuite when installed on a linux platform like Ubuntu in many cases doesn’t install and ends up giving an issue. As this is not a first hand experience, I am unable to provide here the exact issue detail. However, those who would have tried installing CRFSuite, would have come across some material on this.
2) The solution for this unknown issue is to define an environment variable LD_CONFIGURE_PATH with the value as the path to your system libraries (which is generally /usr/lib)


Topic 3: Writing Hindi(Devanagari) in Latex – The Hard Way
Errors/Tags/Keywords: Devanagari in latex, hindi in latex, indian language in hindi
Date: 16-Feb-2013
Solution:
1) Create a file Hindi.dn with the following content:-

\documentclass[12pt]{article}
\usepackage{devanagari}
\begin{document}
{\dn
<YOUR_TEXT_HERE>
}
\end{document}

2) In the {/dn <YOUR_TEXT_HERE>} section, enter your required Hindi text in the prescribed format. The prescribed format comprises of mapping the hindi characters to be written to roman characters (or group of characters). The mapping table is available in the document manual.pdf available on the ctan page – http://www.tex.ac.uk/ctan/fonts/devanagari/velthuis/doc/generic/velthuis/.
So if have to enter “नितिन एक लड़का है।”, then according to given table enter the following “nitina eka laRakA hE|” in the file hindi.dn.

3) If you are working on a Windows platform the file devnag.exe needs to be obtained from
ftp://ctan.mirror.ac.za/language/devanagari/velthuis/bin/win32/
and if you are working on a Linux platform the file devnag.c needs to be obtained from
ftp://ctan.mirror.ac.za/language/devanagari/velthuis/bin/
The downloaded file devnag.c needs to be converted to an out file – devnag.o using the gcc -o command.
Now run the following command from a command window.
devnag Hindi.dn (for Windows)
./devnag Hindi.dn (for Linux)

This command will produce a file Hindi.tex

4) Now copy the characters generated in Hindi.tex and in your main tex file enter them inside {\dn } tag. You may refer to the code of Main.tex presented below:-
\def\DevnagVersion{2.15}
\documentclass[12pt]{article}
\usepackage{devanagari}
\begin{document}
{\dn
<Characters Generated from the devnag command>
}
\end{document}

5) Compile Main.tex to see the output.

6) Ensure that you include the package – devanagari using the usepackage command. Further, also ensure to state the devanagari version above the documentclass command using the statement \def\DevnagVersion{2.15}. Both these commands need to be present in Hindi.dn and Main.tex both.


Topic 2: Configuration setting in Kile for compiling tex files with eps images
Errors/Tags/Keywords: Package pdftex.def Error: File `example-eps-converted-to.pdf’ not found.
example-eps-converted-to.pdf not found.
Date: 05-Feb-2013
Solution:
Point 1: Ensure the following lines are present in the tex file you are compiling:
\usepackage{graphicx} %Package for including graphicx support
\usepackage{epstopdf} %Package for on-the-fly conversion of eps images to pdf files.

Point 2: Ensure that the shell-escape option is applied when the command pdflatex gets fired. If you compile the latex code from the shell then you would use the command:
pdflatex -shell-latex <file.tex>.
However, in Kile you need to follow the following to enable the shell-escape option.

  1. Go to Settings >> Configure Kile >> Tools >> Build
  2. Choose PdfLatex from the left side list
  3. Add -shell-escape in the options box on the right. Also make sure it gets added before the already present command. Also ensure the space between the option added and the already present.

topic1img2     topic1img1


Topic 1: Easy Wallet Manager for Andriod Devices
Errors/Tags/Keywords: Wallet Manager Android, Money Management Android App
Date: 05-Jan-2012
Contribution: As a part of my Android learning, I developed this very small but quite useful Android app for Wallet Management. It allows recording of daily add and spend transactions under various heads like Bank Withdrawls, Food Expenses, Travel, etc. The app also gives two options of viewing the recorded transactions – Daily and Monthly. Version Support: Android 2.2
Future Work: There are plans to include a settings option and make it more generic, allowing the user to set the expense and addition heads. Also there are plans to develop it for the higher versions – 2.3 and eventually 4.x
Download Link: EasyWalletManager.zip
Installation Instructions: Download the File. Rename the file by removing the .key extension. Unzip it to get the .apk file which can be installed on your Android 2.2(preferably) phone.


Advertisements

3 thoughts on “Learning and Technology

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s