Mouse Gesture Recognition with Hidden Markov Model.

Understanding gestures can be posed as a pattern recognition problem. These patterns(gestures) are variable but distinct and have an associated meaning.  Since gesture consists of continuous motion in sequential time, an HMM is an effective recognition tool.

My work is a demonstration of a mouse motion gesture recognition system using Dynamic HMM. It is developed in Java.

Code  Available @ : https://github.com/gtiwari333/mouse-gesture-recognition-java-hidden-markov-model

Main References were : 
DEMO VIDEO 


Redirecting JAVA IO to GUI by Redirecting IO Streams

Here is a small utility program for fun (but useful). It is written in Java  by redirecting IO Streams to GUI.
Its features are:
  • Reading console input from GUI --> No need of Black Screen.
  • Displaying console output (including exceptions) to GUI.
  • Easy to use.
  • Useful for Java Beginners
First lets see the code of test application.

Java Map Comparison- hashmap, linkedhashmap, treemap


Java Map Comparison :
  • HashMap is the fastest map with O(1) search and insertion times.
  • LinkedHashMap is a little slower for inserts, but maintains the insertion order.
  • TreeMap is the slowest map, but lets you iterate over the keys in a sorted order.

Android : Activity and View Understanding

What are Activity and View in Android:
Dissecting HelloAndroid.java - Activity and View

FirstSee this example:

Android: Application Project Structure in Eclipse

The Android project (under Eclipse ADT) consists of several folders:
Android - Project folder structure

  • src: Java Source codes. The Java classes must be kept in a proper package with at least two levels of identifiers (e.g., com.example...).

Android : AndroidManifest.xml description

What is and usage/purpose of androidmanifest.xml file
Android Application Descriptor File - AndroidManifest.xml
Each Android application has a manifest file named AndroidManifest.xml in the project's root directory. It descibes the application components.

Android: understanding R.Java

Understanding the R.Java class in Android: What is R.Java ??


The Eclipse ADT automatically generates a R.java, which keeps track of all the application resources, in hello\gen as follows:

Android First Program eclipse- getting started

Android apps are written in Java, and use XML extensively. I shall assume that you have basic knowledge of Java programming and XML.
Step 0: Read - Read "Hello, world" tutorial at http://developer.android.com/resources/tutorials/hello-world.html.
Step 1: Create a Android Virtual Device (AVD) - AVDs are emulators that allow you to test your application without the physical device. You can create AVDs for different android platforms (e.g., Android 2.3 for phone, Android 3.2 for tablet) and configurations (e.g., screen sizes and orientations, having SD card and its capacity).

java zip- create text file from list of string and zip them

java - create text files from list of string and zip them ( without creating temporary file)

 private static void list_of_string_into_text_file_and_zip_them_all(List dataList) throws Exception {

  File zipFile = new File("OutputZipFile.zip");
  ZipOutputStream out = new ZipOutputStream(new FileOutputStream(zipFile));
  int count = 0;

  for (String string : dataList) {

   // repeat for each string
   String fileNameInsideZip = ++count + "-inside_text_file.txt";
   ZipEntry e = new ZipEntry(fileNameInsideZip);
   out.putNextEntry(e);

   // write data into zip entry
   byte[] data = string.getBytes();
   out.write(data, 0, data.length);
   out.closeEntry();
  }
  out.flush();
  out.close();

 }

Testing the code :

 public static void main(String[] args) throws Exception {
  // store string into text file - and zip them . doesnot create a
  // temporary text file.
  List test = new ArrayList();
  test.add("This is amazing");
  test.add("What a wonderful world");
  test.add("This is a beautiful day ");
  list_of_string_into_text_file_and_zip_them_all(test);
 }

For creating a single text file from string and zip it - see  this post.

Final Report : Text Prompted Remote Speaker Authentication : Joint Speech and Speaker Recognition/Verification System

Here is complete report of our project :Text Prompted Remote Speaker Authentication : Joint Speech and Speaker Recognition/Verification System


Next time ... Runnable Project or may be snapshots..... just wait

Presentation Slide for this report and project work is here.