Category Archives: Research

TensorFlow in Processing

The Java binding for the Google Deep Learning library, TensorFlow is now available. The binary library files for version 1.1.0-rc1 ¬†are also available for download here. Below is the code for the Hello World program included in the distribution that I modified for Processing.   import org.tensorflow.Graph; import org.tensorflow.Session; import org.tensorflow.Tensor; import org.tensorflow.TensorFlow;   Graph […]

Also posted in Software | Tagged , | Comments closed

OpenCV 3.2 Java Build

In preparing for the forthcoming book in Processing and OpenCV, I have tried to build the Java binding in OpenCV 3.2. It worked easily for the basic components. Nevertheless, when I included the contribution module – optflow, it failed. After a number of attempts in various platforms, I found it was due to the […]

Also posted in Books, Software | Tagged , | Comments closed

Save Processing screen as video with jCodec – new

It may not be easy for readers to get the old jcodec-0.1.5.jar for what I have done in the last post. I tried to work out for a newer solution but found that the latest version did change quite a lot. The latest jcodec source is 0.2.0. I built the latest two files for the […]

Also posted in Software | Tagged , | Comments closed

Save video in Processing with JCodec

As a side product of current research, I manage to save a Processing screen in an MP4 video file with the use of the JCodec library. Download the former¬†jcodec-0.1.5.jar into the code folder of your Processing sketch. The simplest way is to use the SequenceEncoder class to add a BufferedImage to the MP4 video. Remember […]

Also posted in Software, Testing | Tagged , , , | Comments closed

Searching in Weka with Processing

Further to the last Weka example, I used the same CSV data file for neighbourhood search. By pressing the mouse button, it generated a random sequence of numbers between 1 to 4. The program used the sequence as an instance to match against the database from the CSV data file. The closet match will be […]

Also posted in Software | Tagged , , | Comments closed

First trial of Weka in Processing

Instead of using the machine learning module (ML) of OpenCV, I also investigated another popular machine learning library for Java, Weka, from the University of Waikato. The first trial was to load an external CSV file into the proper data structure of the Weka library. The content of the CSV file is as follows. The […]

Also posted in Software | Tagged , , | Comments closed

Artificial Neural Network in OpenCV with Processing

This is the first trial of the Machine Learning module, artificial neural network in OpenCV with Processing. I used the same OpenCV 3.1.0 Java built files. The program took the live stream video (PImage) from webcam and down-sampled to a grid of just 8 x 6 pixels of greyscale. It started by default in the […]

Also posted in Software, Testing | Tagged , , | Comments closed

OpenCV 3.1 release Java build

It is the Java build of the new OpenCV 3.1 release. The zipped file contains the Java build for the 64 bit versions of Linux, Mac OSX and Windows. It is available for download at OpenCV 3.1.0 Java build (64 bit) Again, you can copy the individual files to your Processing code folder to play […]

Also posted in Software | Tagged , , | Comments closed

Processing 3.0 Video library in Ubuntu

I installed the new Processing 3.0 and its video library in Ubuntu and found that the Movie class could not display the digital video. It only played the audio track. The Capture class worked well. Afters some Google researches about the gstreamer package, I concluded that it can be the missing gstreamer0.10-ffmpeg module. By installing […]

Also posted in Software | Tagged , , | Comments closed

Chinese calligraphy in Processing

The following video is from my research project to integrate the writing of Chinese calligraphy, especially the script style with the fighting scenes in Chinese martial art films.  

Also posted in Graphics | Comments closed